toJson method

Map<String, Object?> toJson()

Implementation

Map<String, Object?> toJson() => <String, Object?>{
      'projection': 'perspective',
      'fovY': fovYDegrees,
      'near': near,
      'far': far,
      if (isOrbit)
        'orbit': <String, Object?>{
          'target': orbitTarget!.toList(),
          'distance': orbitDistance,
          if (orbitYawDegrees != 0) 'yaw': orbitYawDegrees,
          if (orbitPitchDegrees != 0) 'pitch': orbitPitchDegrees,
          if (controls) 'controls': true,
        },
    };