setFromJSON Method

Set an Angle from a JSON object

  • A simple number is considered as degrees.
  • specified json.degrees or json._degrees is degree value.
  • specified son.radians or json._radians is radians value.

setFromJSON(json?: AngleProps, defaultValRadians?: number): void

Parameter Type Description
json AngleProps object from JSON.parse. If a number, value is in DEGREES
defaultValRadians number if json is undefined, default value in radians.

Returns - void

Defined in

Last Updated: 23 November, 2024