Sphere#
Sphere
A solid sphere. Created using POST /drawing/add-sphere.
Note
The sphere is drawn with an additive material, so a darker color draws it more transparent.
A Sphere object is passed and returned as its identifier, a number. A path that acts on
an object takes it as (id).
- GET /drawing/sphere/(id)/center#
Position of the center of the sphere.
- Parameters:
id – The identifier of the Sphere object.
- Response JSON Object:
value (tuple<double, double, double>)
- PUT /drawing/sphere/(id)/center#
Position of the center of the sphere.
- Parameters:
id – The identifier of the Sphere object.
- Request JSON Object:
value (tuple<double, double, double>) – The new value.
- GET /drawing/sphere/(id)/radius#
Radius of the sphere, in meters.
- Parameters:
id – The identifier of the Sphere object.
- Response JSON Object:
value (double)
- PUT /drawing/sphere/(id)/radius#
Radius of the sphere, in meters.
- Parameters:
id – The identifier of the Sphere object.
- Request JSON Object:
value (double) – The new value.
- GET /drawing/sphere/(id)/reference-frame#
Reference frame for the positions of the object.
- Parameters:
id – The identifier of the Sphere object.
- Response JSON Object:
value (SpaceCenter.ReferenceFrame)
- PUT /drawing/sphere/(id)/reference-frame#
Reference frame for the positions of the object.
- Parameters:
id – The identifier of the Sphere object.
- Request JSON Object:
value (SpaceCenter.ReferenceFrame) – The new value.
- GET /drawing/sphere/(id)/visible#
Whether the object is visible.
- Parameters:
id – The identifier of the Sphere object.
- Response JSON Object:
value (bool)
- PUT /drawing/sphere/(id)/visible#
Whether the object is visible.
- Parameters:
id – The identifier of the Sphere object.
- Request JSON Object:
value (bool) – The new value.
- GET /drawing/sphere/(id)/color#
The color of the object.
- Parameters:
id – The identifier of the Sphere object.
- Response JSON Object:
value (StdLib.ColorRGB)
- PUT /drawing/sphere/(id)/color#
The color of the object.
- Parameters:
id – The identifier of the Sphere object.
- Request JSON Object:
value (StdLib.ColorRGB) – The new value.
- GET /drawing/sphere/(id)/material#
Material used to render the object. Creates the material from a shader with the given name.
- Parameters:
id – The identifier of the Sphere object.
- Response JSON Object:
value (string)