[vtkusers] problem with stereo rendering
Cory Quammen
cory.quammen at kitware.com
Thu Jul 16 13:36:59 EDT 2015
Olivier,
Try calling
view->GetRenderWindow()->SetStereoTypeToCrystalEyes();
view->GetRenderWindow()->StereoRenderOn();
instead of
view->GetRenderWindow()->SetStereoTypeToAnaglyph();
This has worked on a system similar to yours.
HTH,
Cory
On Thu, Jul 16, 2015 at 11:38 AM, Olivier Ameline <olivameline at gmail.com>
wrote:
> 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.
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the VTK FAQ at:
> http://www.vtk.org/Wiki/VTK_FAQ
>
> Search the list archives at: http://markmail.org/search/?q=vtkusers
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/vtkusers
>
--
Cory Quammen
R&D Engineer
Kitware, Inc.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtkusers/attachments/20150716/20474f9d/attachment.html>
More information about the vtkusers
mailing list