Objects

### 10.1.8 Objects

Describe an object in the scene
OBJECT:
  `FINITE_SOLID_OBJECT | FINITE_PATCH_OBJECT | INFINITE_SOLID_OBJECT | ISOSURFACE | PARAMETRIC | CSG_OBJECT | OBJECT_STATEMENT`
OBJECT_STATEMENT:
  `object { OBJECT_IDENTIFIER [OBJECT_MODIFIERS] }`

Quick Reference Contents

#### 10.1.8.1 Finite Solid Objects

Describe a solid finite shape:
FINITE_SOLID_OBJECT:
  `BLOB | BOX | CONE | CYLINDER | HEIGHT_FIELD | JULIA_FRACTAL | LATHE | PRISM | SPHERE | SPHERE_SWEEP | SUPERELLIPSOID | SOR | TEXT | TORUS`

The blob object:
BLOB:
  Jump to SDL
  `blob { [threshold FLOAT] BLOB_ITEM... [BLOB_MODIFIERS] }`
BLOB_ITEM:
  `sphere { V_CENTER, F_RADIUS, [strength] F_STRENGTH [COMPONENT_MODIFIERS] } |
  cylinder { V_END1, V_END2, F_RADIUS, [strength] F_STRENGTH [COMPONENT_MODIFIERS] }`
COMPONENT_MODIFIERS:
  `[TEXTURE] & [PIGMENT] & [NORMAL] & [FINISH] & [TRANSFORMATION...]`
BLOB_MODIFIERS:
  `[hierarchy [BOOL]] & [sturm [BOOL]] & [OBJECT_MODIFIERS]`

The box object:
BOX:
  Jump to SDL
  `box { V_CORNER1, V_CORNER2 [BOX_MODIFIERS] }`
BOX_MODIFIERS:
  `[UV_MAPPING] & [OBJECT_MODIFIERS]`

The cone object:
CONE:
  Jump to SDL
  `cone { V_BASE_CENTER, F_BASE_RADIUS, V_CAP_CENTER, F_CAP_RADIUS [open] [OBJECT_MODIFIERS] }`

The cylinder object:
CYLINDER:
  Jump to SDL
  `cylinder { V_BASE_CENTER, V_CAP_CENTER, F_RADIUS [open] [OBJECT_MODIFIERS] }`

The height field object:
HEIGHT_FIELD:
  Jump to SDL
  `height_field { HF_IMAGE [HF_MODIFIERS] }`
HF_IMAGE:
  `FUNCTION_IMAGE | [HF_TYPE] FILE_NAME`
HF_TYPE:
  `gif | tga | pot | png | pgm | ppm | jpeg | tiff | sys`
HF_MODIFIERS:
  `[hierarchy [BOOL]] & [smooth [BOOL]] & [water_level FLOAT] & [OBJECT_MODIFIERS]`

The Julia fractal object:
JULIA_FRACTAL:
  Jump to SDL
  `julia_fractal { 4D_VECTOR [JF_ITEMS] [OBJECT_MODIFIERS] }`
JF_ITEMS:
  `[ALGEBRA_ITEM] & [max_iteration INT] & [precision FLOAT] & [slice V4_NORMAL, F_DISTANCE]`
ALGEBRA_ITEM:
  `quaternion [QUATER_FUNCTION] | hypercomplex [HYPER_FUNCTION]`
QUATER_FUNCTION:
  `sqr | cube`
HYPER_FUNCTION:
  `sqr | cube | exp | reciprocal | sin | asin | sinh | asinh | cos | acos | cosh | acosh | tan | atan | tanh | atanh | ln | pwr (FLOAT,FLOAT)`

The lathe object:
LATHE:
  Jump to SDL
  `lathe { [LATHE_SPLINE_TYPE] I_NUM_POINTS, POINT_LIST [LATHE_MODIFIERS] }`
LATHE_SPLINE_TYPE:
  `linear_spline | quadratic_spline | cubic_spline | bezier_spline`
POINT_LIST:
  `2D_VECTOR [, 2D_VECTOR]...`
  The quantity of 2D_VECTORs is specified by the I_NUM_POINTS value.
LATHE_MODIFIERS:
  `[sturm [BOOL]] & [UV_MAPPING] & [OBJECT_MODIFIERS]`

The prism object:
PRISM:
  Jump to SDL
  `prism { [PRISM_ITEMS] F_HEIGHT1, F_HEIGHT2, I_NUM_POINTS, POINT_LIST [open] [PRISM_MODIFIERS] }`
PRISM_ITEMS:
  `[PRISM_SPLINE_TYPE] & [PRISM_SWEEP_TYPE]`
PRISM_SPLINE_TYPE:
  `linear_spline | quadratic_spline | cubic_spline | bezier_spline`
PRISM_SWEEP_TYPE:
  `linear_sweep | conic_sweep`
PRISM_MODIFIERS:
  `[sturm [BOOL]] & [OBJECT_MODIFIERS]`

The sphere object:
SPHERE:
  Jump to SDL
  `sphere { V_CENTER, F_RADIUS [SPHERE_MODIFIERS] }`
SPHERE_MODIFIERS:
  `[UV_MAPPING] & [OBJECT_MODIFIERS]`

The sphere sweep object:
SPHERE_SWEEP:
  Jump to SDL
  `sphere_sweep { SWEEP_SPLINE_TYPE I_NUM_SPHERES, SPHERE_LIST [tolerance F_DEPTH_TOLERANCE] [OBJECT_MODIFIERS] }`
SWEEP_SPLINE_TYPE:
  `linear_spline | b_spline | cubic_spline`
SPHERE_LIST:
  `V_CENTER, F_RADIUS [, SPHERE_LIST]`
  The quantity of V_CENTER, F_RADIUS pairs is specified by the I_NUM_SPHERES value.

The superquadric ellipsoid object:
SUPERELLIPSOID:
  Jump to SDL
  `superellipsoid { < FLOAT, FLOAT > [OBJECT_MODIFIERS] }`

The surface of revolution object:
SOR:
  Jump to SDL
  `sor { I_NUM_POINTS, POINT_LIST [open] [SOR_MODIFIERS] }`
SOR_MODIFIERS:
  `[sturm [BOOL]] & [UV_MAPPING] & [OBJECT_MODIFIERS]`

The text object:
TEXT:
  Jump to SDL
  `text { ttf FILE_NAME STRING F_THICKNESS, V_OFFSET [OBJECT_MODIFIERS] }`

The torus object:
TORUS:
  Jump to SDL
  `torus { F_MAJOR_RADIUS, F_MINOR_RADIUS [TORUS_MODIFIERS] }`
TORUS_MODIFIERS:
  `[sturm [BOOL]] & [OBJECT_MODIFIERS]`

Quick Reference Contents

#### 10.1.8.2 Finite Patch Objects

Describe a totally thin, finite shape:
FINITE_PATCH_OBJECT:
  Jump to SDL
  `BICUBIC_PATCH | DISC | MESH | MESH2 | POLYGON | TRIANGLE | SMOOTH_TRIANGLE`

The bicubic patch object:
BICUBIC_PATCH:
  Jump to SDL
  `bicubic_patch { PATCH_ITEMS [PATCH_UV_VECTORS] CONTROL_POINTS [BICUBIC_PATCH_MODIFIERS] }`
PATCH_ITEMS:
  `type PATCH_TYPE & [u_steps INT] & [v_steps INT] & [flatness FLOAT]`
PATCH_TYPE:
  `0 | 1`
PATCH_UV_VECTORS:
  `uv_vectors V2_CORNER1, V2_CORNER2, V2_CORNER3, V2_CORNER4`
CONTROL_POINTS:
  16 VECTORs, optionally separated by commas.
BICUBIC_PATCH_MODIFIERS:
  `[UV_MAPPING] & [OBJECT_MODIFIERS]`

The disc object:
DISC:
  Jump to SDL
  `disc { V_CENTER, V_NORMAL, F_RADIUS [, F_HOLE_RADIUS] [OBJECT_MODIFIERS] }`

The mesh object:
MESH:
  Jump to SDL
  `mesh { MESH_TRIANGLE... [MESH_MODIFIERS] }`
MESH_TRIANGLE:
  `triangle { V_CORNER1, V_CORNER2, V_CORNER3 [MESH_UV_VECTORS] [MESH_TEXTURE] } |
  smooth_triangle { V_CORNER1, V_NORMAL1, V_CORNER2, V_NORMAL2, V_CORNER3, V_NORMAL3 [MESH_UV_VECTORS] [MESH_TEXTURE] }`
MESH_UV_VECTORS:
  `uv_vectors V2_CORNER1, V2_CORNER2, V2_CORNER3`
MESH_TEXTURE:
  `texture { TEXTURE_IDENTIFIER } |
  texture_list { TEXTURE_IDENTIFIER TEXTURE_IDENTIFIER TEXTURE_IDENTIFIER }`
MESH_MODIFIERS:
  `[inside_vector V_DIRECTION] & [hierarchy [BOOL]] & [UV_MAPPING] & [OBJECT_MODIFIERS]`

The mesh2 object:
MESH2:
  Jump to SDL
  `mesh2 { MESH2_VECTORS [TEXTURE_LIST] MESH2_INDICES [MESH2_MODIFIERS] }`
MESH2_VECTORS:
  `VERTEX_VECTORS [NORMAL_VECTORS] [UV_VECTORS]`
VERTEX_VECTORS:
  `vertex_vectors { I_NUM_VERTICES, VECTOR [, VECTOR]... }`
NORMAL_VECTORS:
  `normal_vectors { I_NUM_NORMALS, VECTOR [, VECTOR]... }`
UV_VECTORS:
  `uv_vectors { I_NUM_UV_VECTORS, 2D_VECTOR [, 2D_VECTOR]... }`
TEXTURE_LIST:
  `texture_list { I_NUM_TEXTURES, TEXTURE [, TEXTURE]... }`
MESH2_INDICES:
  `FACE_INDICES [NORMAL_INDICES] [UV_INDICES]`
FACE_INDICES:
  `face_indices { I_NUM_FACES, FACE_INDICES_ITEM [, FACE_INDICES_ITEM]... }`
FACE_INDICES_ITEM:
  `VECTOR [, I_TEXTURE_INDEX [, I_TEXTURE_INDEX, I_TEXTURE_INDEX ]]`
NORMAL_INDICES:
  `normal_indices { I_NUM_FACES, VECTOR [, VECTOR]... }`
UV_INDICES:
  `uv_indices { I_NUM_FACES, VECTOR [, VECTOR]... }`
MESH2_MODIFIERS:
  `[inside_vector V_DIRECTION] & [UV_MAPPING] & [OBJECT_MODIFIERS]`

The polygon object:
POLYGON:
  Jump to SDL
  `polygon { I_NUM_POINTS, V_POINT [, V_POINT]... [OBJECT_MODIFIERS] }`
  The quantity of V_POINTs is specified by the I_NUM_POINTS value.

The triangle object:
TRIANGLE:
  Jump to SDL
  `triangle { V_CORNER1, V_CORNER2, V_CORNER3 [OBJECT_MODIFIERS] }`

The smooth triangle object:
SMOOTH_TRIANGLE:
  Jump to SDL
  `smooth_triangle { V_CORNER1, V_NORMAL1, V_CORNER2, V_NORMAL2, V_CORNER3, V_NORMAL3 [OBJECT_MODIFIERS] }`

Quick Reference Contents

#### 10.1.8.3 Infinite Solid Objects

Describe a solid, possibly infinite, shape:
INFINITE_SOLID_OBJECT:
  `PLANE | POLY | CUBIC | QUARTIC | QUADRIC`

The plane object:
PLANE:
  Jump to SDL
  `plane { V_NORMAL, F_DISTANCE [OBJECT_MODIFIERS] }`

The poly object:
POLY:
  Jump to SDL
  `poly { ORDER, < POLY_COEFFICIENTS > [POLY_MODIFIERS] }`
ORDER:
  An integer value between 2 and 15 inclusive.
POLY_COEFFICIENTS:
  A quantity n of FLOATs separated by commas, where n is `((ORDER+1)*(ORDER+2)*(ORDER+3))/6.`
POLY_MODIFIERS:
  `[sturm [BOOL]] & [OBJECT_MODIFIERS]`

The cubic object:
CUBIC:
  `cubic { < CUBIC_COEFFICIENTS > [POLY_MODIFIERS] }`
CUBIC_COEFFICIENTS:
  20 FLOATs separated by commas.

The quartic object:
QUARTIC:
  `quartic { < QUARTIC_COEFFICIENTS > [POLY_MODIFIERS] }`
QUARTIC_COEFFICIENTS:
  35 FLOATs separated by commas.

The quadric object:
QUADRIC:
  Jump to SDL
  `quadric { < FLOAT, FLOAT, FLOAT >, < FLOAT, FLOAT, FLOAT >, < FLOAT, FLOAT, FLOAT >, FLOAT [OBJECT_MODIFIERS] }`

Quick Reference Contents

#### 10.1.8.4 Isosurface

Describe a surface via a mathematical function:
ISOSURFACE:
  Jump to SDL
  `isosurface { FLOAT_USER_FUNCTION [ISOSURFACE_ITEMS] [OBJECT_MODIFIERS] }`
ISOSURFACE_ITEMS:
  `[contained_by { CONTAINER }] & [threshold FLOAT] & [accuracy FLOAT] & [max_gradient FLOAT [evaluate F_MIN_ESTIMATE, F_MAX_ESTIMATE, F_ATTENUATION]] & [open] & [INTERSECTION_LIMIT]`
CONTAINER:
  `sphere { V_CENTER, F_RADIUS } | box { V_CORNER1, V_CORNER2 }`
INTERSECTION_LIMIT:
  `max_trace INT | all_intersections`

Quick Reference Contents

#### 10.1.8.5 Parametric

Describe a surface using functions to locate points on the surface:
PARAMETRIC:
  Jump to SDL
  `parametric { FLOAT_USER_FUNCTION, FLOAT_USER_FUNCTION, FLOAT_USER_FUNCTION 2D_VECTOR, 2D_VECTOR [PARAMETRIC_ITEMS] [OBJECT_MODIFIERS] }`
PARAMETRIC_ITEMS:
  `[contained_by { CONTAINER }] & [max_gradient FLOAT] & [accuracy FLOAT] & [precompute I_DEPTH, x, y, z]`
CONTAINER:
  `sphere { V_CENTER, F_RADIUS } | box { V_CORNER1, V_CORNER2 }`

Quick Reference Contents

#### 10.1.8.6 CSG

Describe one complex shape from multiple shapes:
CSG_OBJECT:
  Jump to SDL
  `UNION | INTERSECTION | DIFFERENCE | MERGE`

Combine multiple shapes into one:
UNION:
  `union { UNION_OBJECT UNION_OBJECT... [UNION_MODIFIERS] }`
UNION_OBJECT:
  `OBJECT | LIGHT`
UNION_MODIFIERS:
  `[split_union BOOL] & [OBJECT_MODIFIERS]`

Create a new shape from the overlapping portions of multiple shapes:
INTERSECTION:
  `intersection { SOLID_OBJECT SOLID_OBJECT... [INTERSECTION_MODIFIERS] }`
SOLID_OBJECT:
  `FINITE_SOLID_OBJECT | INFINITE_SOLID_OBJECT | ISOSURFACE | CSG_OBJECT`
INTERSECTION_MODIFIERS:
  `[cutaway_textures] & [OBJECT_MODIFIERS]`

Subtract one or more shapes from another:
DIFFERENCE:
  `difference { SOLID_OBJECT SOLID_OBJECT... [DIFFERENCE_MODIFIERS] }`
DIFFERENCE_MODIFIERS:
  `[cutaway_textures] & [OBJECT_MODIFIERS]`

Combine multiple shapes into one, removing internal surfaces:
MERGE:
  `merge { SOLID_OBJECT SOLID_OBJECT... [OBJECT_MODIFIERS] }`

Quick Reference Contents