sphere Element Reference
Creates a sphere. More...
Inheritance diagram for sphere:

Attributes | |
| vector3 | position |
| Center of sphere. | |
| ureal_t | radius |
| Radius of sphere. | |
Detailed Description
Creates a sphere.
- Note:
- If left unspecified, the center of the sphere will default to the origin, and the radius of the sphere will default to 0.5 (contained in the unit box ranging from [ -.5, -.5, -.5 ] to [ .5, .5, .5 ]).
sphere corresponds to the underlying Milton class 'Sphere.'
Example usage:
"scene" : {
// declare the same translated, uniformly scaled sphere two different ways
"sphere" : {
"position" : [ 10, 5, 4 ],
"radius" : 8,
},
"transform" : {
"translate" : [ 10, 5, 4 ],
"scale" : [ 16, 16, 16 ],
"sphere" : { },
},
},
Attribute Documentation
| vector3 sphere::position |
Center of sphere.
Expects 3 scalar values: [ px, py, pz ].
| type | vector3 |
| optional | true |
| default | [ 0, 0, 0 ] (origin) |
| ureal_t sphere::radius |
Generated on 28 Feb 2009 for MiltonScenefileFormat by
1.5.6