[Paraview] Re: Arbitrary Stereo Modes

Fabian Braennstroem f.braennstroem at gmx.de
Thu May 31 19:01:28 EDT 2007


Hi, Andreas,

we just tested the stereo feature; actually we are interested in an active 
mode too. Do you know, if ther are any plans to integrate you small changes 
into the general code; maybe in 3.x!?
Would be nice ...

Greetings!
Fabian

On Thursday 12 April 2007 21:38, Andreas M. Gerndt wrote:
> Hi all,
>
> ParaView offers a flag called "--stereo". This enables Red-Blue stereo,
> which is not really the best approach to present scientific data in stereo.
>
> Some small changes of ParaView's source code (v.2.6.0) yield a more
> flexible stereo mode selection:
>
> ===========================================================================
> Servers/Common/vtkPVOptions.cxx:
> ...
>   /*this->AddBooleanArgument("--stereo", 0, &this->UseStereoRendering,
>                            "Tell the application to enable stereo
> rendering" " (only when running on a single process).",
> vtkPVOptions::PVCLIENT | vtkPVOptions::PARAVIEW);*/ this->AddArgument
> ("--stereo", 0, &this->UseStereoRendering,
>                            "Tell the application which stereo render mode
> to use."
>                            " (only when running on a single process).",
>                            vtkPVOptions::PVCLIENT |
> vtkPVOptions::PARAVIEW); ...
>
> ===========================================================================
> Servers/ServerManager/vtkSMRenderModuleProxy.cxx:
> ...
>   if (pvm->GetOptions()->GetUseStereoRendering() > 0)
>     {
> ...
>     // vtkRenderWindow.h:
>     // #define VTK_STEREO_CRYSTAL_EYES 1
>     // #define VTK_STEREO_RED_BLUE     2
>     // #define VTK_STEREO_INTERLACED   3
>     // #define VTK_STEREO_LEFT         4
>     // #define VTK_STEREO_RIGHT        5
>     // #define VTK_STEREO_DRESDEN      6
>     // #define VTK_STEREO_ANAGLYPH     7
>     ivp = vtkSMIntVectorProperty::SafeDownCast(
>       this->RenderWindowProxy->GetProperty("StereoType"));
>     if (!ivp)
>       {
>       vtkErrorMacro("Failed to find property StereoType.");
>       return;
>       }
>       ivp->SetElement(0, pvm->GetOptions()->GetUseStereoRendering());
>     }
> ...
>
> ===========================================================================
> Servers/ServerManager/Resources/rendering.xml:
> ...
>   <ProxyGroup name="renderwindow">
> ...
>       <IntVectorProperty
>         name="StereoType"
>         command="SetStereoType"
>         number_of_elements="1"
>         default_values="0">
>         <IntRangeDomain name="range" min="0" max="7"/>
>       </IntVectorProperty>
> ...
> ===========================================================================
>
> Now e.g. "paraview --stereo=1" can be used to switch active stereo on. I
> wonder whether my changes are already sufficient for a general purpose in
> ParaView.
>
> Changing stereo settings by means of the GUI would be a nice think. Is this
> already possible?
>
> I can use ParaView now on our large immersive displays, but the eye
> distance is too large. How can I additionally change EyeAngle, Distance
> etc. of the vtkCamera object to adjust the stereo parallax?
>
> Andreas


More information about the ParaView mailing list