[vtkusers] problems getting a LODActor to render

James Dessart james at rogue-research.com
Tue Jun 17 15:14:05 EDT 2003


I've been working on getting VTK working on Mac OS X, using 
CodeWarrior, and I managed to get a little demo application running.  
It works to my expectations, and I'm happy with it.  I decided to move 
the sample into another, bigger application, since my final goal is to 
use VTK from within this application.

However, using the following code:

	vtkSTLReader *theReader = vtkSTLReader::New();
	theReader->SetFileName( "/source/VTKData/Data/42400-IDGH.stl" );

	vtkPolyDataMapper *theMapper = vtkPolyDataMapper::New();
	theMapper->SetInput( theReader->GetOutput() );

	vtkLODActor *theActor = vtkLODActor::New();
	theActor->SetMapper( theMapper );

	mRenderer->AddActor( theActor );
	mRenderer->Render();

the actor does not render.  I've been able to set the background colour 
of the renderer, but the actor doesn't seem to render.  I even tried 
stepping through the code, and found that somehow the renderer loses 
track of what props it plans to render at some point.  What might I be 
missing that would prevent this actor from being rendered?

Thanks,
James




More information about the vtkusers mailing list