toJSON method

  1. @override
Map<String, dynamic> toJSON({
  1. Object3dMeta? meta,
})
override

Implementation

@override
Map<String, dynamic> toJSON({Object3dMeta? meta}) {
  var data = super.toJSON(meta: meta);

  data["object"]["zoom"] = zoom;
  data["object"]["left"] = left;
  data["object"]["right"] = right;
  data["object"]["top"] = top;
  data["object"]["bottom"] = bottom;
  data["object"]["near"] = near;
  data["object"]["far"] = far;

  if (view != null) {
    data["object"]["view"] = json.decode(json.encode(view));
  }

  return data;
}