.. default-domain:: http .. highlight:: json Sphere ====== .. _http-Drawing.Sphere: .. rubric:: Sphere A solid sphere. Created using :http:post:`/drawing/add-sphere`. .. note:: The sphere is drawn with an additive material, so a darker color draws it more transparent. | Base class: :ref:`SphereShape ` A ``Sphere`` object is returned as ``{"id": ..., "class": ...}``, its identifier and the name of its own class. An argument is that object or the identifier alone. A path that acts on an object takes the identifier as ``(id)``. .. http:get:: /drawing/sphere/(id)/center Position of the center of the sphere. :param id: The identifier of the :ref:`Sphere ` object. :resjson tuple value: .. http:put:: /drawing/sphere/(id)/center Position of the center of the sphere. :param id: The identifier of the :ref:`Sphere ` object. :reqjson tuple value: The new value. .. http:get:: /drawing/sphere/(id)/radius Radius of the sphere, in meters. :param id: The identifier of the :ref:`Sphere ` object. :resjson double value: .. http:put:: /drawing/sphere/(id)/radius Radius of the sphere, in meters. :param id: The identifier of the :ref:`Sphere ` object. :reqjson double value: The new value. .. http:get:: /drawing/sphere/(id)/reference-frame The reference frame for the positions of the object. Inherited from :ref:`SphereShape `. :param id: The identifier of the :ref:`Sphere ` object. :resjson SpaceCenter.ReferenceFrame value: .. http:put:: /drawing/sphere/(id)/reference-frame The reference frame for the positions of the object. Inherited from :ref:`SphereShape `. :param id: The identifier of the :ref:`Sphere ` object. :reqjson SpaceCenter.ReferenceFrame value: The new value. .. http:get:: /drawing/sphere/(id)/visible Whether the object is visible. Inherited from :ref:`Drawable `. :param id: The identifier of the :ref:`Sphere ` object. :resjson bool value: .. http:put:: /drawing/sphere/(id)/visible Whether the object is visible. Inherited from :ref:`Drawable `. :param id: The identifier of the :ref:`Sphere ` object. :reqjson bool value: The new value. .. http:get:: /drawing/sphere/(id)/color The color of the object. Inherited from :ref:`Drawable `. .. note:: For a path drawn with more than one color, this is the color at its start. :param id: The identifier of the :ref:`Sphere ` object. :resjson StdLib.ColorRGB value: .. http:put:: /drawing/sphere/(id)/color The color of the object. Inherited from :ref:`Drawable `. .. note:: For a path drawn with more than one color, this is the color at its start. :param id: The identifier of the :ref:`Sphere ` object. :reqjson StdLib.ColorRGB value: The new value. .. http:get:: /drawing/sphere/(id)/material The material used to render the object. Creates the material from a shader with the given name. Throws an exception if the object is a marker, which the game draws with its own material. Inherited from :ref:`Drawable `. :param id: The identifier of the :ref:`Sphere ` object. :resjson string value: .. http:put:: /drawing/sphere/(id)/material The material used to render the object. Creates the material from a shader with the given name. Throws an exception if the object is a marker, which the game draws with its own material. Inherited from :ref:`Drawable `. :param id: The identifier of the :ref:`Sphere ` object. :reqjson string value: The new value. .. http:post:: /drawing/sphere/(id)/remove Remove the object. Inherited from :ref:`Drawable `. :param id: The identifier of the :ref:`Sphere ` object.