setTransformationMatrices method

dynamic setTransformationMatrices([
  1. Matrix4? camera,
  2. Matrix4? gizmos
])

Set values in transformation object @param {Matrix4} camera Transformation to be applied to the camera @param {Matrix4} gizmos Transformation to be applied to gizmos

Implementation

setTransformationMatrices([Matrix4? camera, Matrix4? gizmos]) {
  if (camera != null) {
    if (_transformation['camera'] != null) {
      _transformation['camera']!.copy(camera);
    } else {
      _transformation['camera'] = camera.clone();
    }
  } else {
    _transformation.remove('camera');
  }

  if (gizmos != null) {
    if (_transformation['gizmos'] != null) {
      _transformation['gizmos']!.copy(gizmos);
    } else {
      _transformation['gizmos'] = gizmos.clone();
    }
  } else {
    _transformation.remove('gizmos');
  }
}