[vtkusers] problem with stereo rendering

Olivier Ameline olivameline at gmail.com
Thu Jul 16 11:38:25 EDT 2015


Hello everyone,

I am trying to draw an helix in a QVTKWidget with stereoscopic 3D.
I'm equiped with a Nvidia Quadro graphic card with 3D glasses and 3D Asus
monitor, and the stereo works well in other programs.

Here is a part of my code :

    // Add the graph in the view

    view->GetScene()->AddItem(chart.GetPointer());

    // Add a plot to the graph

    plot->SetInputData(table.GetPointer());
    plot->GetPen()->SetColorF(0.0, 0.0, 0.0, 0.5);
    chart->AddPlot(plot.GetPointer());
    chart->RecalculateBounds();

    // Stereo rendering

    view->GetRenderer()->ResetCamera();
    view->GetRenderWindow()->StereoCapableWindowOn();
    view->GetRenderWindow()->SetStereoRender(1);
    view->GetRenderWindow()->SetStereoTypeToAnaglyph();
    view->GetRenderWindow()->StereoUpdate();

    // Put the view in the QVTKWidget

    view->SetInteractor(ui->vueCourbe->GetInteractor());
    ui->vueCourbe->SetRenderWindow(view->GetRenderWindow());

-------------------------------------------------------------------------------------------

When I compile, the helix is displayed without any stereo.
I don't know what is wrong.


Thanks for your help

Olivier.



--
View this message in context: http://vtk.1045678.n5.nabble.com/problem-with-stereo-rendering-tp5732934.html
Sent from the VTK - Users mailing list archive at Nabble.com.


More information about the vtkusers mailing list