Scene api ApplyTransform issue after update to v2.20.2

Hello,

After updating from 2.18.0 to the version 2.20.2 of sdv.concat.js. I’m getting this error when using the applyTransformation func:

TypeError: Cannot read property 'isMatrix4' of undefined*
TypeError: Cannot read property 'isMatrix4' of undefined*
at t.applyPluginTransformation (SceneGeometryManager.js:714)*
at module$src$api$v2$implementation$ApiSceneImplementationV2_1.default.applyTransformation (ApiSceneImplementationV2.1.js:397)

The code unchanged :

    const m = new THREE.Matrix4();
    m.elements = this._api.scene.getTransformation(this._api.scene.TRANSFORMATIONTYPE.PLUGIN).data;
    m.makeRotationX(dir * Math.PI / 180 * 90);
    this._api.scene.applyTransformation(this._api.scene.TRANSFORMATIONTYPE.PLUGIN, '', m);

To quickly fix the error I must now provide m.elements (instead of m the matrix4 object instance directly) to the function applyTransformation

However the doc seems to be the same between the two version about the object Transformation passed to the func which could be either an Array<Number, either a THREE.Matrix4

Transformation

Transformation matrix - Array containing the 16 elements of a 4x4 matrix in row-major format, or a THREE.Matrix4.

Type:
  • Array. | THREE.Matrix4

Thank you.

Thanks for reporting this, it seems like a bug. Our team is looking into the issue and we will let you know once we know more.

Ok, thank you, let me know if you need something else.

Despite of my fix about passing an array of number instead of Matrix4, the transformation result is not exactly the one I was expecting.

The v2.19.4 has good result. But from 2.20.0, there is the same issue as in 2.20.4.
I will update my webapp to this one while waiting for your analysis about the last version.

Regards,