[vtkusers] VTK rendering problem

jsl n jsantam.hm at hotmail.com
Mon Oct 20 10:26:16 EDT 2008


Dear all,

   I noticed an strange rendering behavior when loading a .OBJ model and
next applying a particular transform. This is part of the code:

...
...
    // Load the 3D model
    vtkOBJReader* model = vtkOBJReader::New();
    model->SetFileName(model);

    vtkTransformPolyDataFilter* TransformPolyDataFilter = vtkTransformPolyDataFilter::New();
    TransformPolyDataFilter->SetInput(model->GetOutput());

    TransformPolyDataFilter->SetTransform(Transform);
    TransformPolyDataFilter->Update();

    // Set the 3D model mapper
    vtkPolyDataMapper* geomMap = vtkPolyDataMapper::New();
    geomMap->SetInputConnection(TransformPolyDataFilter->GetOutputPort());

    // Set the 3D model actor
    vtkActor* geomActor = vtkActor::New();
    geomActor->SetMapper(geomMap);
    geomActor->GetProperty()->SetColor(0.74, 0.52, 0.06);
...
...

However, as I've just said before, the rendering of the model is quite suspicious.
I've attached one screenshot of the transformed 3D model. Yo can see how the
skull's back is rendered over the front part of the skull. Please, Any advice will
be greatly appreciated.

Regards.

_________________________________________________________________
¿Eres un cotilla? Disfruta de todas las novedades en MSN Corazón
http://entretenimiento.es.msn.com/corazon/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: screen-wrong-rendering.jpg
Type: image/jpeg
Size: 14468 bytes
Desc: not available
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20081020/15dfb566/attachment.jpg>


More information about the vtkusers mailing list