| 
	   The Lightflow Rendering Interface  | 
      |
| 
	   
	    
	      The Lightflow Rendering Interface is
	      an object oriented programming interface to synthetic
	      rendering, which provides a common environment and description language to treat light distribution
	      in three dimensional spaces.  
	 | 
	
	  
	  
#include < Lightflow.h >
int main (int argc, char* argv[])
{
    LfLocalSceneProxy* scene = new LfLocalSceneProxy();
    LfArgList list;
    list.Reset();
    list << "position" << LfPoint(5.0, -5.0,  4.0);
    list << "color"    << LfColor(1.0,  1.0,  1.0)*3e2;
    scene->LightOn(  scene->NewLight( "point", list ) );
    list.Reset();
    list << "ka" << LfColor( 0.0, 0.0, 0.5 );
    list << "kc" << LfColor( 1.0, 0.5, 0.5 );
    list << "kd" << 0.5;
    list << "km" << 0.1;
    LfInt plastic = scene->NewMaterial( "standard", list );
    scene->MaterialBegin( plastic );
    list.Reset();
    list << "radius" << 1.0;
    scene->AddObject( scene->NewObject( "sphere", list ) );
    scene->MaterialEnd();
    list.Reset();
    list << "file" << "ball1.txt";
    LfInt saver = scene->NewImager( "saver", list );
    scene->ImagerBegin( saver );
    list.Reset();
    list << "eye" << LfPoint(0.0, -4.0,  0.0);
    list << "aim" << LfPoint(0.0,  0.0,  0.0);
    LfInt camera = scene->NewCamera( "pinhole", list );
    scene->ImagerEnd();
    scene->Render( camera, 400, 300 );
    delete scene;
}
	    
	  
	 | 
      
| 
	   
	    
	      All the images present in this document were created and rendered with
	      the Lightflow Rendering Tools by Jacopo
	      Pantaleoni, and they can be redistributed only with the
	      following copyright notice:  | 
      |