25 #define RFILE "/cfs/johns/anim/frame" 27 #define RFILE "outfile" 30 int main(
int argc,
char **argv) {
70 if (
rt_mynode()==0) printf(
"Rendering frame %d \n",i);
73 printf(
"Rendering frame %d \n",i);
75 ctr1.
x= i / 20.0 - 5.0;
77 ctr1.
z= i / 20.0 + 5.0;
82 rt_light(scene, txarray[0], ctr1, f1);
84 ctr1.
x= i / 15.0 - 5.0;
91 rt_light(scene, txarray[1], ctr1, f1 / 3.0 );
97 ctr.
z=10.0 + 2.0*cos((j*
RAD) /
LOOP);
107 ctr.
z=10.0 + 2.0*cos((j*
RAD) /
LOOP);
117 ctr.
z=10.0 + 2.0*cos((j*
RAD) /
LOOP);
144 rt_plane(scene, txarray[6], ctr, vect2);
147 sprintf(fname,
".%4.4d.tga",i);
148 strcpy(fname2,
RFILE);
149 strcat(fname2, fname);
float g
Green color component.
float r
Red color component.
void * rt_texture(SceneHandle sc, apitexture *apitex)
Translate a texture definition into the internal format used by Tachyon, and returns an opaque pointe...
apicolor col
base object color
void rt_resolution(SceneHandle voidscene, int hres, int vres)
Set the horizontal and vertical resolution (in pixels) for the specified scene.
int main(int argc, char **argv)
flt diffuse
diffuse reflection
flt opacity
how opaque the object is
flt specular
specular reflection
void rt_renderscene(SceneHandle voidscene)
Render the current scene.
void rt_sphere(SceneHandle scene, void *tex, apivector ctr, flt rad)
Define a sphere with associated texture, center, and radius.
int rt_initialize(int *argc, char ***argv)
Initialize Tachyon library, must be first Tachyon API called.
flt x
X coordinate or direction component.
flt apiflt
for backward compatibility
flt y
Y coordinate or direction component.
SceneHandle rt_newscene(void)
Allocate, initialize, and return a handle for a new scene.
void rt_outputfile(SceneHandle voidscene, const char *outname)
Set the filename for the output image for the specified scene.
void rt_deletescene(SceneHandle voidscene)
Destroy and deallocate the specified scene.
int texturefunc
which texture function to use
flt ambient
ambient lighting
void rt_finalize(void)
Shut down Tachyon library for good, at final use before program termination.
float b
Blue color component.
void rt_plane(SceneHandle scene, void *tex, apivector ctr, apivector norm)
Define a plane.
int rt_mynode(void)
distributed memory parallel node rank
Tachyon public API function prototypes and declarations used to drive the ray tracing engine...
void * rt_light(SceneHandle voidscene, void *tex, apivector ctr, flt rad)
Define a point light with associated texture, position, and radius.
flt z
Z coordinate or direction component.