POV-Ray Scene Description Language Quick Reference
Derived from the POV-Ray 3.1g User Documentation
by Robert Chaffe

This is an accumulation and refinement of the entire syntax for the PO V-Ray Scene Description Language. Please note that accuracy is NOT guaranteed! The official user documentation may be acquired at the POV-Ray site.

The following syntax conventions are used.
ITEMAn item not in brackets indica tes that it is a required item.
[ITEM]Brackets surround an optiona l item. If brackets are part of the item, that is noted where applicable .
ITEM...An ellipsis indicates an it em that may be used one or more times.
[ITEM...]An ellipsis within bracke ts indicates an item that may be used zero or more times.
ITEM ITEMTwo or more juxtapos ed items indicates that they should be used in the given order.
ITEM | ITEMA pipe separa tes two or more alternatives from which only one item should be used.
ITEM & ITEM An ampersand separates two or more items that may be used in any order.

Juxtaposition has precedence over the pipe or ampersand. In the follo wing example, you would select one of the keyword and vector pairs. For that last pair, the keyword itself is optional.
   rgb VECTOR | rgbf 4D_VECTOR | rgbt 4D_VECTOR | [rgbft] 5D_VECTOR

Some item names are simply descriptive in nature. An indication of th e item's type is given by a prefix on the item name, as follows.
F_A FLOAT item
I_An INT item
V_A VECTOR item
V4_ A 4-D VECTOR item


The Scene
Describe a POV-Ray scene
SCENE:
SCENE_ITEM...
The scene must have at l east one OBJECT.
SCENE_ITEM:
LANGUAGE_DIRECTIVE | CAMERA | OBJECT | ATMOSP HERIC_EFFECT | GLOBAL_SETTINGS


Language Basics
Float Expression
FLOAT:
NUMERIC_TERM [SIGN NUMERIC_TERM]
SIGN:
+ | -
NUMERIC_TERM:
NUMERIC_FACTOR [MULT NUMERIC_FACTOR]
MULT:
* | /
NUMERIC_FACTOR:
FLOAT_LITERAL | FLOAT_IDENTIFIER | SIGN  NUMERIC_FACTOR | FLOAT_FUNCTION | FLOAT_BUILT_IN_IDENT | ( FU LL_EXPRESSION ) | ! NUMERIC_FACTOR | VECTOR.DOT_I TEM
FLOAT_LITERAL:
[DIGIT...][.]DIGIT...[EXP[SIGN]DIGIT...]
DIGIT:
0 | 1 | 2 | 3 | < b>4 | 5 | 6 | 7 | 8 | 9
EXP:
e | E
FLOAT_FUNCTION:
abs(FLOAT) | acos(FLOAT< b>) | asc(STRING) | asin(FLOAT) | atan 2(FLOAT,FLOAT) | ceil(FLOAT) | cos(FLOAT< b>) | defined(IDENTIFIER) | degrees(FLOAT) | dimensions(ARRAY_IDENTIFIER) | dimension_size(AR RAY_IDENTIFIER,INT) | div(FLOAT,FLOAT) | exp( FLOAT) | file_exists(FILE_NAME) | floor(FLOAT ) | int(FLOAT) | log(FLOAT) | max(< /b>FLOAT,FLOAT) | min(FLOAT,FLOAT) | mod(FLOA T,FLOAT) | pow(FLOAT,FLOAT) | radians(FLOAT) | rand(FLOAT) | seed(FLOAT) | sin(< /b>FLOAT) | sqrt(FLOAT) | strcmp(STRING,STRIN G) | strlen(STRING) | tan(FLOAT) | val(STRING) | vdot(VECTOR,VECTOR) | vlength(< /b>VECTOR)
FLOAT_BUILT_IN_IDENT:
clock | pi | version | < b>clock_delta | BOOLEAN_KEYWORD
BOOLEAN_KEYWORD:
true | yes | on | fal se | no | off
FULL_EXPRESSION:
LOGICAL_EXPRESSION [? FULL_EXPRESSION : FULL_EXPRESSION]
LOGICAL_EXPRESSION:
REL_EXPRESSION [LOGICAL_OPERATOR REL_EXPRESSI ON]
LOGICAL_OPERATOR:
& | |
REL_EXPRESSION:
FLOAT [REL_OPERATOR FLOAT]
REL_OPERATOR:
< | <= | = | < b>>= | > | !=
DOT_ITEM:
x | y | z | t | < b>u | v | red | green | blue | filter< /b> | transmit
INT:
FLOAT
Any fractional part is d iscarded.
BOOL:
BOOLEAN_KEYWORD | LOGICAL_EXPRESSION
Vector
VECTOR:
NUMERIC_TERM [SIGN NUMERIC_TERM]
NUMERIC_TERM:
NUMERIC_FACTOR [MULT NUMERIC_FACTOR]
NUMERIC_FACTOR:
VECTOR_LITERAL | VECTOR_IDENTIFIER | SIGN&nbs p;NUMERIC_FACTOR | VECTOR_FUNCTION | VECTOR_BUILT_IN_IDENT | (&nbs p;FULL_EXPRESSION ) | ! NUMERIC_FACTOR | FLOAT
VECTOR_LITERAL:
< FLOAT, FLOAT [, FLOAT [, FLOAT [, FLOAT ]]] >
VECTOR_FUNCTION:
vaxis_rotate(VECTOR,VECTOR,FLOAT) | vcross(VECTOR,VECTOR) | vnormalize(VECTOR) | vrotate(VECTOR,VECTOR)
VECTOR_BUILT_IN_IDENT:
x | y | z | t | < b>u | v
Color
COLOR:
[color] COLOR_BODY
COLOR_BODY:
COLOR_VECTOR | COLOR_KEYWORD_GROUP | COLOR_ID ENTIFIER
COLOR_VECTOR:
rgb VECTOR | rgbf 4D_ VECTOR | rgbt 4D_VECTOR | [rgbft] 5D_VECTOR
COLOR_KEYWORD_GROUP:
[COLOR_IDENTIFIER] COLOR_KEYWORD_ITEMS
COLOR_KEYWORD_ITEMS:
[red FLOAT] & [green&n bsp;FLOAT] & [blue FLOAT] & [filter FLOAT ] & [transmit FLOAT]
String
STRING:
STRING_FUNCTION | STRING_IDENTIFIER | STRING_ LITERAL
Limited to 256 printable characters.
STRING_FUNCTION:
chr(INT) | concat(STRING ,STRING[,STRING...]) | str(FLOAT,INT,INT) | strlw r(STRING) | strupr(STRING) | substr(STRIN G,INT,INT)
STRING_LITERAL:
QUOTE ASCII_CHARACTER... QUOTE
QUOTE:
"
Array
Define an array
ARRAY_DECLARATION:
#declare ARRAY_IDENTIFIER = array DIMENSION [DIMENSION...] [ARRAY_INITIALIZER] |
#local ARRA Y_IDENTIFIER = array DIMENSION [DIMENSION...] [ARRAY_INITIALIZER ]
Limited to five dimensions.
DIMENSION:
[ INT ]
The brackets here are part of the dim ension declaration.
ARRAY_INITIALIZER:
{ ARRAY_INITIALIZER [, ARRAY_INITIALIZ ER...] } |
{ RVALUE [, RVALUE...] }
Reference an array
ARRAY_REFERENCE:
ARRAY_IDENTIFIER ELEMENT [ELEMENT...]
ELEMENT:
[ INT ]
The brackets here are part of the ele ment expression.


Language Directive
Control the parsing of section s of the scene file
LANGUAGE_DIRECTIVE:
INCLUDE_DIRECTIVE | IDENTIFIER_D ECLARATION | UNDEF_DIRECTIVE | FOPEN_DIRECTIVE | FCLOSE_DIRECTIVE | READ_ DIRECTIVE | WRITE_DIRECTIVE | DEFAULT_DIRECTIVE | VERSION_DIRECTIVE | IF_ DIRECTIVE | IFDEF_DIRECTIVE | IFNDEF_DIRECTIVE | SWITCH_DIRECTIVE | WHILE _DIRECTIVE | TEXT_STREAM_DIRECTIVE | MACRO_DEFINITION
File Inclusion
Insert content of another scene f ile
INCLUDE_DIRECTIVE:
#include FILE_NAME
FILE_NAME:
STRING
Limited to 40 characters including double-quotes.
Identifier Declaration
Create an identifier for a value, object, etc.
IDENTIFIER_DECLARATION:
#declare IDENTIFIER = RVALUE |
#local IDENTIFIER = RVALUE
Up to 40 characters, starting with a letter, consisting of letters, digits or an underscore.
RVALUE:
FLOAT; | VECTOR; | COLOR; | STRING | OBJECT | MATERIAL | TEXTURE | PIGMENT | NORMAL | FINISH | INTERIOR | MEDIA | DENS ITY | TEXTURE_MAP | COLOR_MAP | PIGMENT_MAP | SLOPE_MAP | NORMAL_MAP | DE NSITY_MAP | CAMERA | FOG | RAINBOW | SKY_SPHERE | TRANSFORM
Destroy an identifier
UNDEF_DIRECTIVE:
#undef IDENTIFIER
File Input/Output
Open a text file
FOPEN_DIRECTIVE:
#fopen FILE_HANDLE_IDENT FILE_NAME OPE N_TYPE
OPEN_TYPE:
read | write | append
Close a text file
FCLOSE_DIRECTIVE:
#fclose FILE_HANDLE_IDENT
Read string, float or vector valu es from a text file
READ_DIRECTIVE:
#read ( FILE_HANDLE_IDENT, DATA_IDENTI FIER [, DATA_IDENTIFIER...] )
DATA_IDENTIFIER:
UNDECLARED_IDENTIFIER | FLOAT_IDENTIFIER | VE CTOR_IDENTIFIER | STRING_IDENTIFIER
Write string, float or vector val ues to a text file
WRITE_DIRECTIVE:
#write ( FILE_HANDLE_IDENT, DATA_ITEM [, DATA_ITEM...] )
DATA_ITEM:
FLOAT | VECTOR | STRING
Default Texture
Specify a default texture, pigmen t, normal and/or finish
DEFAULT_DIRECTIVE:
#default { DEFAULT_ITEM }
DEFAULT_ITEM:
PLAIN_TEXTURE | PIGMENT | NORMAL | FINISH
Version Compatibility
Specify the POV-Ray compatibility version number
VERSION_DIRECTIVE:
#version FLOAT;
Conditional Directives - M ay nest conditional directives 200 levels deep
Conditionally parse a section of the scene file, depending on a boolean expression
IF_DIRECTIVE:
#if ( LOGICAL_EXPRESSION ) SCEN E [#else SCENE] #end
Conditionally parse a section of the scene file, depending on the existence of an identifier
IFDEF_DIRECTIVE:
#ifdef ( IDENTIFIER ) SCENE [#else SCENE] #end
IFNDEF_DIRECTIVE:
#ifndef ( IDENTIFIER ) SCENE [< b>#else SCENE] #end
Conditionally parse a section of the scene file, depending on the value of a float expression
SWITCH_DIRECTIVE:
#switch ( FLOAT ) SWITCH_CLAUSE ... [#else SCENE] #end
SWITCH_CLAUSE:
#case ( FLOAT ) SCENE [#brea k] |
#range ( F_LOW, F_HIGH ) SCENE [#break]< /tt>
Repeat a section of the scene fil e while a boolean condition is true
WHILE_DIRECTIVE:
#while ( LOGICAL_EXPRESSION ) S CENE #end
Message Streams
Send a message to a text stream
TEXT_STREAM_DIRECTIVE:
#debug STRING | #error&nbs p;STRING | #render STRING | #statistics STRING | #warning STRING
Macro
Define a macro
MACRO_DEFINITION:
#macro MACRO_IDENTIFIER ( [PARA M_IDENTIFIER [, PARAM_IDENTIFIER...]] ) MACRO_BODY #end
MACRO_BODY:
SCENE
Excludes another macro definition; ma y not nest them.
Invoke a macro
MACRO_INVOCATION:
MACRO_IDENTIFIER ( [ACTUAL_PARAM [, AC TUAL_PARAM...]] )
ACTUAL_PARAM:
IDENTIFIER | RVALUE
Embedded Directives
Limited directives may be embedde d in CAMERA, OBJECT and ATMOSPHERIC_EFFECT statements. However, the dire ctives should only include items (if any) that are valid for a given stat ement. They should also not disrupt the required order of items, where a pplicable.
LIMITED_DIRECTIVE:
IDENTIFIER_DECLARATION | UNDEF_DIRECTIVE | IF _DIRECTIVE | IFDEF_DIRECTIVE | IFNDEF_DIRECTIVE | SWITCH_DIRECTIVE | WHIL E_DIRECTIVE | TEXT_STREAM_DIRECTIVE


Transformation
Rotate, resize, move, or other wise manipulate the coordinates of an object or texture
TRANSFORMATION:
rotate VECTOR | s cale VECTOR | translate VECTOR | transform&nb sp;TRANSFORM_IDENTIFIER |
matrix < F_VAL00, F_VAL01, F_VAL02 , F_VAL10, F_VAL11, F_VAL12, F_VAL20, F_VAL21, F_VAL22, F_VAL30, F_VAL31, F_VAL32 >
The scale vector components are non-zero values.
TRANSFORM_DECLARATION:
#declare TRANSFORM_IDENTIFIER = t ransform { TRANSFORMATION... } |
#local TRANSFORM_ID ENTIFIER = transform { TRANSFORMATION... }


Camera
Describe the position, project ion type and properties of the camera viewing the scene
CAMERA:
camera { [CAMERA_TYPE] [C AMERA_ITEMS] [CAMERA_MODIFIERS] } |
camera { [CAMERA_ITE MS] [CAMERA_MODIFIERS] orthographic }
CAMERA_TYPE:
perspective | orthographic | fisheye | ultra_wide_angle | omnimax | panoramic | cylinder CYLINDER_TYPE
CYLINDER_TYPE:
1 | 2 | 3 | 4
Vertical fixed, horizontal fixed, ver tical movable, or horizontal movable.
CAMERA_ITEMS:
[CAMERA_IDENTIFIER...] & [location  VECTOR] & [right VECTOR] & [up VECT OR] & [direction VECTOR] & [sky VECTOR]
CAMERA_MODIFIERS:
[CAMERA_IDENTIFIER...] & [angle&nb sp;FLOAT] & [look_at VECTOR] & [FOCAL_BLUR] & [NO RMAL] & [TRANSFORMATION...]
The angle is a po sitive value.
FOCAL_BLUR:
aperture FLOAT & blur_samp les INT & [focal_point VECTOR] & [confide nce FLOAT] & [variance FLOAT]
The aperture and blur_sampl es are non-negative values. The confidence and variance are values between 0.0 and 1.0.


Object
Describe an object in the scen e
OBJECT:
FINITE_SOLID_OBJECT | FINITE_PAT CH_OBJECT | INFINITE_SOLID_OBJECT | CSG_OBJECT | LIGHT_SOURCE | OBJECT_ST ATEMENT
OBJECT_STATEMENT:
object { OBJECT_IDENTIFIER [OBJECT_MOD IFIERS] }
Finite Solid Primitive
Describe a solid finite shape
FINITE_SOLID_OBJECT:
BLOB | BOX | CONE | CYLINDER | HEIGHT_FIELD | JULIA_FRACTAL | LATHE | PRISM | SPHERE | SUPERELLIPSOID | SOR | TEXT | T ORUS
The blob object
BLOB:
blob { BLOB_ITEM... [threshold FLOAT] [BLOB_MODIFIERS] }
The threshold is a positive value.
BLOB_ITEM:
sphere { V_CENTER, F_RADIUS, [stren gth] F_STRENGTH [COMPONENT_MODIFIERS] } |
cylinder { V_END1, V_END2, F_RADIUS, [strength] F_STRENGTH [COMPONENT_MODIFI ERS] }
The strength is a non-zero val ue.
COMPONENT_MODIFIERS:
[TEXTURE] & [PIGMENT] & [NORMAL] & ; [FINISH] & [TRANSFORMATION...]
BLOB_MODIFIERS:
[hierarchy [BOOL]] & [stur m [BOOL]] & [OBJECT_MODIFIERS]
The box object
BOX:
box { V_CORNER1, V_CORNER2 [OBJECT_MOD IFIERS] }
The cone object
CONE:
cone { V_BASE_CENTER, F_BASE_RADIUS, V _CAP_CENTER, F_CAP_RADIUS [open] [OBJECT_MODIFIERS] }
One, but not both, of F_BASE_RADIUS o r F_CAP_RADIUS can be negative or zero.
The cylinder object
CYLINDER:
cylinder { V_BASE_CENTER, V_CAP_CENTER , F_RADIUS [open] [OBJECT_MODIFIERS] }
The height field object
HEIGHT_FIELD:
height_field { HF_TYPE FILE_NAME [HF_M ODIFIERS] }
HF_TYPE:
gif | tga | pot | png | pgm | ppm | sys
HF_MODIFIERS:
[hierarchy [BOOL]] & [smoo th [BOOL]] & [water_level FLOAT] & [OBJECT_M ODIFIERS]
The water_level is a value bet ween 0.0 and 1.0.
The Julia fractal object
JULIA_FRACTAL:
julia_fractal { 4D_VECTOR [JF_ITEMS] [ OBJECT_MODIFIERS] }
JF_ITEMS:
[ALGEBRA_ITEM] & [max_iteration&nb sp;INT] & [precision FLOAT] & [slice V4_N ORMAL, F_DISTANCE]
The max_iteration is a positiv e value. The slice vector must not have zero length or a zero for the fourth component. The precision is 1.0 or greater.
ALGEBRA_ITEM:
quaternion [QUATER_FUNCTION] | hypercomplex [HYPER_FUNCTION]
QUATER_FUNCTION:
sqr | cube
HYPER_FUNCTION:
sqr | cube | exp | re ciprocal | sin | asin | sinh | asinh | cos | acos | cosh | acosh | tan | ata n | tanh | atanh | log | pwr(FLOAT,FLOAT< b>)
The lathe object
LATHE:
lathe { [SPLINE_TYPE] I_NUM_POINTS, PO INT_LIST [LATHE_MODIFIERS] }
The I_NUM_POINTS is 2 or greater for linear_spline, 3 or greater for quadratic_spline, and 4 or greater for cubic_spline or bezier_spline.
SPLINE_TYPE:
linear_spline | quadratic_spline | cubic_spline | bezier_spline
POINT_LIST:
A quantity I_NUM_POINTS of 2D_VECTORs separated b y commas
LATHE_MODIFIERS:
[sturm [BOOL]] & [OBJECT_MODIFIERS ]
The prism object
PRISM:
prism { [PRISM_ITEMS] F_HEIGHT1, F_HEI GHT2, I_NUM_POINTS, POINT_LIST [open] [PRISM_MODIFIERS] }
The I_NUM_POINTS is 3 or greater for linear_spline, 5 or greater for quadratic_spline, and 6 or greater for cubic_spline or bezier_spline.
PRISM_ITEMS:
[SPLINE_TYPE] & [SWEEP_TYPE]
SPLINE_TYPE:
linear_spline | quadratic_spline | cubic_spline | bezier_spline
SWEEP_TYPE:
linear_sweep | conic_sweep
PRISM_MODIFIERS:
[sturm [BOOL]] & [OBJECT_MODIFIERS ]
The sphere object
SPHERE:
sphere { V_CENTER, F_RADIUS [OBJECT_MO DIFIERS] }
The F_RADIUS is a positive value.
The superquadric ellipsoid object
SUPERELLIPSOID:
superellipsoid { < FLOAT, FLOAT > ; [OBJECT_MODIFIERS] }
The FLOATs are positive values.
The surface of revolution object
SOR:
sor { I_NUM_POINTS, POINT_LIST [ope n] [SOR_MODIFIERS] }
The I_NUM_POINTS is 4 or greater.
SOR_MODIFIERS:
[sturm [BOOL]] & [OBJECT_MODIFIERS ]
The text object
TEXT:
text { ttf FILE_NAME STRING F_THICKNES S, V_OFFSET [OBJECT_MODIFIERS] }
The torus object
TORUS:
torus { F_MAJOR_RADIUS, F_MINOR_RADIUS [TORUS_MODIFIERS] }
TORUS_MODIFIERS:
[sturm [BOOL]] & [OBJECT_MODIFIERS ]
Finite Patch Primitive
Describe an infinitely thin, fini te shape
FINITE_PATCH_OBJECT:
BICUBIC_PATCH | DISC | MESH | POLYGON | TRIAN GLE | SMOOTH_TRIANGLE
The bicubic patch object
BICUBIC_PATCH:
bicubic_patch { PATCH_ITEMS CONTROL_PO INTS [OBJECT_MODIFIERS] }
PATCH_ITEMS:
type PATCH_TYPE & u_steps< /b> INT & v_steps INT & [flatness FL OAT]
The u_steps and v_steps are positive values. The flatness is a non-negative value.
PATCH_TYPE:
0 | 1
Minimal memory or speedier render.
CONTROL_POINTS:
16 VECTORs separated by commas
The disc object
DISC:
disc { V_CENTER, V_NORMAL, F_RADIUS [, F_HOLE_RADIUS] [OBJECT_MODIFIERS] }
The F_RADIUS is greater than the F_HO LE_RADIUS.
The mesh object
MESH:
mesh { MESH_TRIANGLE... [MESH_MODIFIER S] }
MESH_TRIANGLE:
triangle { V_CORNER1, V_CORNER2, V_COR NER3 [MESH_TEXTURE] } |
smooth_triangle { V_CORNER1, V_N ORMAL1, V_CORNER2, V_NORMAL2, V_CORNER3, V_NORMAL3 [MESH_TEXTURE] }
MESH_TEXTURE:
texture { TEXTURE_IDENTIFIER }< /tt>
MESH_MODIFIERS:
[hierarchy [BOOL]] & [OBJECT_MODIF IERS]
The polygon object
POLYGON:
polygon { I_NUM_POINTS, POINT_LIST [OB JECT_MODIFIERS] }
The I_NUM_POINTS is 3 or greater.
The triangle object
TRIANGLE:
triangle { V_CORNER1, V_CORNER2, V_COR NER3 [OBJECT_MODIFIERS] }
The smooth triangle object
SMOOTH_TRIANGLE:
smooth_triangle { V_CORNER1, V_NORMAL1 , V_CORNER2, V_NORMAL2, V_CORNER3, V_NORMAL3 [OBJECT_MODIFIERS] }< /tt>
Infinite Solid Primitive
Describe a solid, possibly infini te, shape
INFINITE_SOLID_OBJECT:
PLANE | POLY | CUBIC | QUARTIC | QUADRIC
The plane object
PLANE:
plane { V_NORMAL, F_DISTANCE [OBJECT_M ODIFIERS] }
The poly object
POLY:
poly { ORDER, < POLY_COEFFICIENTS & gt; [POLY_MODIFIERS] }
ORDER:
2 | 3 | 4 | 5 | < b>6 | 7
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 &g t; [POLY_MODIFIERS] }
QUARTIC_COEFFICIENTS:
35 FLOATs separated by commas
The quadric object
QUADRIC:
quadric { < FLOAT, FLOAT,  FLOAT >, < FLOAT, FLOAT, FLOAT >, < FLOAT, FLOAT, FLOAT >, FLOAT [OBJECT_MODIFIE RS] }
Constructive Solid Geometry
Describe one complex shape from m ultiple shapes
CSG_OBJECT:
UNION | INTERSECTION | DIFFERENCE | MERGE
Combine multiple shapes into one
UNION:
union { OBJECT... [OBJECT_MODIFIERS] < b>}
Create a new shape from the overl apping portions of multiple shapes
INTERSECTION:
intersection { SOLID_OBJECT... [OBJECT _MODIFIERS] }
SOLID_OBJECT:
FINITE_SOLID_OBJECT | INFINITE_SOLID_OBJECT | CSG_OBJECT
Subtract one or more shapes from another
DIFFERENCE:
difference { SOLID_OBJECT... [OBJECT_M ODIFIERS] }
Combine multiple shapes into one, removing internal surfaces
MERGE:
merge { SOLID_OBJECT... [OBJECT_MODIFI ERS] }
Light Source
Describe the position, type and p roperties of a light source for the scene
LIGHT_SOURCE:
light_source { V_LOCATION, COLOR [LIGH T_SOURCE_ITEMS] }
LIGHT_SOURCE_ITEMS:
[LIGHT_TYPE] & [AREA_LIGHT_ITEMS] & [ LIGHT_MODIFIERS]
LIGHT_TYPE:
shadowless | spotlight SPO TLIGHT_ITEMS | cylinder SPOTLIGHT_ITEMS
SPOTLIGHT_ITEMS:
point_at VECTOR & [radius< /b> FLOAT] & [falloff FLOAT] & [tightness  FLOAT]
The falloff is a positive valu e less than 90.0. The radius is a value between -90.0 and 90.0. The radius should not be greater than the falloff. The tightness is a value between 1.0 and 100.0.
AREA_LIGHT_ITEMS:
area_light V_AXIS1, V_AXIS2, I_SIZE1, I_SIZE2 [adaptive INT] [jitter FLOAT]
The V_AXIS1 should be perpendicular t o the V_AXIS2. The I_SIZE1 and I_SIZE2 are positive values. The adap tive is a non-negative value.
LIGHT_MODIFIERS:
[looks_like { OBJECT }] & [TRANSFORMATION...] & [fade_distance FLOAT] & [fade_power FLOAT] & [media_attenuation&nbs p;[BOOL]] & [media_interaction [BOOL]]
The fade_distance is a non-zer o value.
Object Modifier
Manipulate the appearance of an o bject
OBJECT_MODIFIERS:
[CLIPPED_BY] & [BOUNDED_BY] & [INTERI OR] & [MATERIAL] & [TEXTURE] & [PIGMENT] & [NORMAL] & [FINISH] & [TRANSFORMATION...] & [no_shadow] & [in verse] & [hollow [BOOL]]
Slice a portion of a shape
CLIPPED_BY:
clipped_by { UNTEXTURED_SOLID_OBJECT.. . } |
clipped_by { bounded_by }
UNTEXTURED_SOLID_OBJECT:
FINITE_SOLID_OBJECT | INFINITE_SOLID_OBJECT
Note, neither with a texture applied.
Specify a bounding shape for an o bject
BOUNDED_BY:
bounded_by { UNTEXTURED_SOLID_OBJECT.. . } |
bounded_by { clipped_by }
The material "wrapper"
MATERIAL:
material { [MATERIAL_IDENTIFIER] [MATE RIAL_ITEMS] }
MATERIAL_ITEMS:
TEXTURE & INTERIOR & [TRANSFORMATION. ..]


Interior
Describe the interior of an ob ject
INTERIOR:
interior { [INTERIOR_IDEN TIFIER] [INTERIOR_ITEMS] }
INTERIOR_ITEMS:
[ior FLOAT] & [caustics FLOAT] & [fade_distance FLOAT] & [fade_powe r FLOAT] & [MEDIA...]
The ior and ca ustics are positive values. The fade_distance is a non-zero v alue.


Texture
Describe the surface of an obj ect
TEXTURE:
PLAIN_TEXTURE | LAYERED_TEXTURE | PATTERNED_TEXTURE
Plain Texture
Describe a texture consisting of a single pigment, normal and finish
PLAIN_TEXTURE:
texture { [TEXTURE_IDENTIFIER] [PNF_ID ENTIFIERS] [PNF_ITEMS] }
PNF_IDENTIFIERS:
[PIGMENT_IDENTIFIER] & [NORMAL_IDENTIFIER ] & [FINISH_IDENTIFIER]
PNF_ITEMS:
[PIGMENT] & [NORMAL] & [FINISH] & [TRANSFORMATION...]
Layered Texture
Describe a texture consisting of two or more semi-transparent layers
LAYERED_TEXTURE:
texture { LAYERED_TEXTURE_IDENT } | PLAIN_TEXTURE...
Patterned Texture
Describe a texture using a patter n or blending function
PATTERNED_TEXTURE:
texture { PATTERNED_TEXTURE_IDENT [TRA NSFORMATION...] } |
texture { TEXTURE_PATTERN [PATTERN_M ODIFIERS] } |
texture { tiles TEXTURE tile2 TEXTU RE [TRANSFORMATION...] } |
texture { MATERIAL_MAP }
TEXTURE_PATTERN:
MAP_PATTERN TEXTURE_MAP | TEXTURE_LIST_PATTER N
TEXTURE_LIST_PATTERN:
brick TEXTURE TEXTURE [brick_size VECTOR] [mortar FLOAT] |
checker TEXTURE TE XTURE |
hexagon TEXTURE TEXTURE TEXTURE
TEXTURE_MAP:
texture_map { TEXTURE_MAP_BODY } [BLEND_MAP_MODIFIERS]
TEXTURE_MAP_BODY:
TEXTURE_MAP_IDENTIFIER | TEXTURE_MAP_ENTRY...
There may be from 2 to 2 56 map entries.
TEXTURE_MAP_ENTRY:
[ FLOAT TEXTURE ]
Note, the brackets here are part of t he map entry. The FLOAT is a value between 0.0 and 1.0, or any positive value for the average pattern.
MATERIAL_MAP:
material_map { BITMAP_TYPE FILE_NAME [ BITMAP_MODIFIERS] TEXTURE... [TRANSFORMATION...] }
BITMAP_TYPE:
gif | tga | iff | ppm | pgm | png | sys
Pigment
Describe a color or pattern of co lors for a texture
PIGMENT:
pigment { [PIGMENT_IDENTIFIER] [PIGMEN T_TYPE] [PIGMENT_MODIFIERS] }
PIGMENT_TYPE:
PIGMENT_PATTERN | COLOR | IMAGE_MAP
PIGMENT_PATTERN:
MAP_PATTERN [COLOR_MAP] | MAP_PATTERN&nb sp;PIGMENT_MAP | COLOR_LIST_PATTERN | PIGMENT_LIST_PATTERN
COLOR_LIST_PATTERN:
brick [COLOR [, COLOR]] [brick_size  VECTOR] [mortar FLOAT] |
checker [COLOR [ , COLOR]] |
hexagon [COLOR [, COLOR [, COLOR]]]
PIGMENT_LIST_PATTERN:
brick PIGMENT PIGMENT [brick_size VECTOR] [mortar FLOAT] |
checker PIGMENT PI GMENT |
hexagon PIGMENT PIGMENT PIGMENT
IMAGE_MAP:
image_map { BITMAP_TYPE FILE_NAME [IMA GE_MAP_MODIFIER...] [BITMAP_MODIFIERS] }
IMAGE_MAP_MODIFIER:
filter I_PALETTE, F_AMOUNT | filter all F_AMOUNT | transmit I_PALETTE,&n bsp;F_AMOUNT | transmit all F_AMOUNT
The I_PALETTE is a non-negative value . The F_AMOUNT is a value between 0.0 and 1.0.
PIGMENT_MODIFIERS:
[PATTERN_MODIFIERS] & [quick_color  COLOR]
COLOR_MAP:
color_map { COLOR_MAP_BODY } [B LEND_MAP_MODIFIERS]
COLOR_MAP_BODY:
COLOR_MAP_IDENTIFIER | COLOR_MAP_ENTRY...
There may be from 2 to 256 map entrie s.
COLOR_MAP_ENTRY:
[ FLOAT COLOR ]
Note, the brackets here are part of t he map entry. The FLOAT is a value between 0.0 and 1.0, or any positive value for the average pattern.
PIGMENT_MAP:
pigment_map { PIGMENT_MAP_BODY } [BLEND_MAP_MODIFIERS]
PIGMENT_MAP_BODY:
PIGMENT_MAP_IDENTIFIER | PIGMENT_MAP_ENTRY...
There may be from 2 to 256 map entrie s.
PIGMENT_MAP_ENTRY:
[ FLOAT PIGMENT ]
Note, the brackets here are part of t he map entry. The FLOAT is a value between 0.0 and 1.0, or any positive value for the average pattern.
Normal
Simulate the visual or tactile su rface characteristics of a texture
NORMAL:
normal { [NORMAL_IDENTIFIER] [NORMAL_T YPE] [NORMAL_MODIFIERS] }
NORMAL_TYPE:
NORMAL_PATTERN | BUMP_MAP
NORMAL_PATTERN:
MAP_PATTERN [ F_DEPTH] [SLOPE_MAP] |
MAP_P ATTERN NORMAL_MAP [SLOPE_MAP] |
NORMAL_LIST_PATTERN
Note that the bumps, dents, quilte d, ripples, waves and wrinkles patterns cannot use a NORMAL_MA P or SLOPE_MAP.
NORMAL_LIST_PATTERN:
brick NORMAL NORMAL [brick_size  VECTOR] [mortar FLOAT] |
brick F_DEPTH [br ick_size VECTOR] [mortar FLOAT] |
checker NORMAL NORMAL |
checker F_DEPTH |
hexagon NORMAL NORM AL NORMAL |
hexagon F_DEPTH
BUMP_MAP:
bump_map { BITMAP_TYPE FILE_NAME [BUMP _MAP_MODIFIERS] }
BUMP_MAP_MODIFIERS:
[BITMAP_MODIFIERS] & [use_index] & amp; [use_color] & [bump_size FLOAT]
The bump_size is a non-zero va lue.
NORMAL_MODIFIERS:
[PATTERN_MODIFIERS] & [bump_size&n bsp;FLOAT]
The bump_size is a non-zero va lue.
NORMAL_MAP:
normal_map { NORMAL_MAP_BODY } [BLEND_MAP_MODIFIERS]
NORMAL_MAP_BODY:
NORMAL_MAP_IDENTIFIER | NORMAL_MAP_ENTRY...
There may be from 2 to 256 map entrie s.
NORMAL_MAP_ENTRY:
[ FLOAT NORMAL ]
Note, the brackets here are part of t he map entry. The FLOAT is a value between 0.0 and 1.0, or any positive value for the average pattern.
SLOPE_MAP:
slope_map { SLOPE_MAP_BODY } [B LEND_MAP_MODIFIERS]
SLOPE_MAP_BODY:
SLOPE_MAP_IDENTIFIER | SLOPE_MAP_ENTRY...
There may be from 2 to 256 map entrie s.
SLOPE_MAP_ENTRY:
[ FLOAT, < F_HEIGHT, F_SLOPE > < b>]
Note, the brackets here are part of t he map entry. The FLOAT is a value between 0.0 and 1.0.
Finish
Describe the reflective propertie s of a surface
FINISH:
finish { [FINISH_IDENTIFIER] [FINISH_I TEMS] }
FINISH_ITEMS:
[ambient COLOR] & [diffuse  FLOAT] & [brilliance FLOAT] & [PHONG] & [SPECULAR] & [REFLECTION] & [IRID] & [crand FLOA T]
The diffuse is a value between 0.0 and 1.0.
PHONG:
phong FLOAT & [phong_size< /b> FLOAT] & [metallic [FLOAT]]
The metallic is a value betwee n 0.0 and 1.0.
SPECULAR:
specular FLOAT & [roughnes s FLOAT] & [metallic [FLOAT]]
The roughness is a non-zero va lue. The metallic is a value between 0.0 and 1.0.
REFLECTION:
reflection COLOR & [reflec tion_exponent FLOAT]
The reflection is a value betw een 0.0 and 1.0.
IRID:
irid { F_AMOUNT [IRID_ITEMS] }< /tt>
The F_AMOUNT is a value between 0.0 a nd 1.0.
IRID_ITEMS:
[thickness FLOAT] & [turbu lence FLOAT]
Pattern
Specify a pattern function for a texture, pigment, normal or density
MAP_PATTERN:
AGATE | average | boxed | bo zo | bumps | crackle | cylindrical | DENSITY_FIL E | dents | gradient VECTOR | granite | leop ard | mandel I_MAX_ITERATION | marble | onion | planar | QUILTED | radial | ripples | spheri cal | spiral1 I_NUM_ARMS | spiral2 I_NUM_ARMS | spotted | waves | wood | wrinkles
The I_MAX_ITERATION is a positive val ue. The I_NUM_ARMS is a positive value.
AGATE:
agate [agate_turb FLOAT]
DENSITY_FILE:
density_file df3 FILE_NAME [interpo late DENSITY_INTERPOLATE]
DENSITY_INTERPOLATE:
0 | 1
None or trilinear.
QUILTED:
quilted [control0 FLOAT] [ control1 FLOAT]
The control0 and control1 are values between 0.0 and 1.0.
Pattern Modifier
Modify the evaluation of a patter n function
PATTERN_MODIFIERS:
[TURBULENCE] & [WARP...] & [TRANSFORM ATION...]
TURBULENCE:
turbulence VECTOR & [octav es INT] & [omega FLOAT] & [lambda&nbs p;FLOAT]
The octaves is a value between 1 and 10.
WARP:
warp { WARP_ITEM }
WARP_ITEM:
REPEAT_WARP | BLACK_HOLE_WARP | TURBULENCE
REPEAT_WARP:
repeat VECTOR [REPEAT_ITEMS]
REPEAT_ITEMS:
[offset VECTOR] & [flip VEC TOR]
BLACK_HOLE_WARP:
black_hole V_LOCATION, F_RADIUS [BLACK _HOLE_ITEMS]
BLACK_HOLE_ITEMS:
[strength FLOAT] & [fallof f FLOAT] & [inverse] & [repeat VECTOR  [turbulence VECTOR]]
Modify the usage of a blend map
BLEND_MAP_MODIFIERS:
[frequency FLOAT] & [phase FLOAT] & [WAVEFORM]
WAVEFORM:
ramp_wave | triangle_wave | sine_wave | scallop_wave | cubic_wave | poly_wave [F_EXPONENT]
Specify how a 2-D bitmap is to be applied to a 3-D surface
BITMAP_MODIFIERS:
[once] & [map_type MAP _TYPE] & [interpolate INTERPOLATE_TYPE]
MAP_TYPE:
0 | 1 | 2 | 5
Planar, spherical, cylindrical or tor oidal.
INTERPOLATE_TYPE:
2 | 4
Bilinear interpolation or normalized distance.


Media
Describe particulate matter
MEDIA:
media { [MEDIA_IDENTIFIER ] [MEDIA_ITEMS] }
MEDIA_ITEMS:
[intervals INT] & [samples  I_MIN, I_MAX] & [confidence FLOAT] & [ variance FLOAT] & [ratio FLOAT] & [abs orption COLOR] & [emission COLOR] & [SCATTER ING] & [DENSITY...] & [TRANSFORMATION...]
The intervals, I_ MIN and I_MAX are positive values. The confidence, variance and < b>ratio are values between 0.0 and 1.0.
SCATTERING:
scattering { SCATTERING_TYPE, COLOR [< b>eccentricity FLOAT] [extinction FLOAT] }
The extinction is a value betw een 0.0 and 1.0.
SCATTERING_TYPE:
1 | 2 | 3 | 4 | < b>5
Isotropic, Mie haze, Mie murky, Rayle igh or Henyey-Greenstein.
DENSITY:
density { [DENSITY_IDENTIFIER] [DENSIT Y_TYPE] [PATTERN_MODIFIERS] }
DENSITY_TYPE:
DENSITY_PATTERN | COLOR
DENSITY_PATTERN:
MAP_PATTERN [COLOR_MAP] | MAP_PATTERN&nb sp;DENSITY_MAP | COLOR_LIST_PATTERN | DENSITY_LIST_PATTERN
DENSITY_LIST_PATTERN:
brick DENSITY DENSITY [brick_size VECTOR] [mortar FLOAT] |
checker DENSITY DE NSITY |
hexagon DENSITY DENSITY DENSITY
DENSITY_MAP:
density_map { DENSITY_MAP_BODY } [BLEND_MAP_MODIFIERS]
DENSITY_MAP_BODY:
DENSITY_MAP_IDENTIFIER | DENSITY_MAP_ENTRY...
There may be from 2 to 256 map entrie s.
DENSITY_MAP_ENTRY:
[ FLOAT DENSITY ]
Note, the brackets here are part of t he map entry. The FLOAT is a value between 0.0 and 1.0, or any positive value for the average pattern.


Atmospheric Effect
Describe various background an d atmospheric features
ATMOSPHERIC_EFFECT:
MEDIA | BACKGROUND | FOG | SKY_S PHERE | RAINBOW
Background
Specify a background color for th e scene
BACKGROUND:
background { COLOR }
Fog
Simulate a hazy or foggy atmosphe re
FOG:
CONSTANT_FOG | GROUND_FOG
CONSTANT_FOG:
fog { [FOG_IDENTIFIER] [fog_type&nb sp;1] FOG_ITEMS }
GROUND_FOG:
fog { [FOG_IDENTIFIER] fog_type&nbs p;2 GROUND_FOG_ITEMS }
FOG_ITEMS:
distance FLOAT & COLOR & [TURBULENCE [turb_depth FLOAT]]
GROUND_FOG_ITEMS:
FOG_ITEMS & fog_offset FLOAT & fog_alt FLOAT & [up VECTOR [TRANSF ORMATION...]]
Sky Sphere
Specify a sky pigment
SKY_SPHERE:
sky_sphere { [SKY_SPHERE_IDENTIFIER] [ SKY_SPHERE_ITEM...] }
SKY_SPHERE_ITEM:
PIGMENT | TRANSFORMATION
Rainbow
Specify a rainbow arc
RAINBOW:
rainbow { [RAINBOW_IDENTIFIER] [RAINBO W_ITEMS] }
RAINBOW_ITEMS:
direction VECTOR & angle FLOAT & width FLOAT & distance FL OAT & COLOR_MAP & [jitter FLOAT] & [up&nbs p;VECTOR] & [arc_angle FLOAT] & [falloff_angle  FLOAT]
The arc_angle is a value between 0 and 360. The falloff_angle should not be greate r than the arc_angle.


Global Settings
Specify various settings that apply to the entire scene
GLOBAL_SETTINGS:
global_settings { GLOBAL_ SETTINGS_ITEMS }
GLOBAL_SETTINGS_ITEMS:
[adc_bailout FLOAT] & [amb ient_light COLOR] & [assumed_gamma FLOAT] & [hf_gray_16 [BOOL]] & [irid_wavelength COLOR] & [max_intersections INT] & [max_trace_level& nbsp;INT] & [number_of_waves INT] & [RADIOSITY]
The max_intersections , max_trace_level and number_of_waves are positive values.
RADIOSITY:
radiosity { [RADIOSITY_ITEMS] }
RADIOSITY_ITEMS:
[brightness FLOAT] & [coun t INT] & [distance_maximum FLOAT] & [erro r_bound FLOAT] & [gray_threshold FLOAT] & [< b>low_error_factor FLOAT] & [minimum_reuse FLOAT ] & [nearest_count INT] & [recursion_limit&nbs p;INT]
The nearest_count is a value b etween 1 and 10. The recursion_limit is the value 1 or 2.