[vtkusers] Standard Views
Jeff Lee
jeff at cdnorthamerica.com
Mon Jan 21 12:52:48 EST 2002
Hi Ted,
Something like
given xv, yv, zv, (camera position)
given nx, ny, nz (camera viewup)
vtkCamera cam1 = ren.GetActiveCamera();
cam1.SetFocalPoint(0,0,0);
cam1.SetPosition(xv, yv, zv);
cam1.ComputeViewPlaneNormal();
cam1.SetViewUp(nx, ny, nz);
cam1.OrthogonalizeViewUp();
so your application just has to provide the camera viewup vector and
the camera position...
-Jeff
Ted Christiansen wrote:
>Hello,
>
>What is the best way to offer standard views in an application using
>vtk? I have studied vtkCamera, but it is not obvious to me how to do
>this most effectively. I searched the archives on public.kitware and
>this question was asked (by Ben Held) in Sept 2000, but I found no
>answer.
>
>Any help would be appreciated.
>
>Ted
>
>_______________________________________________
>This is the private VTK discussion list.
>Please keep messages on-topic. Check the FAQ at: <http://public.kitware.com/cgi-bin/vtkfaq>
>Follow this link to subscribe/unsubscribe:
>http://public.kitware.com/mailman/listinfo/vtkusers
>
>
More information about the vtkusers
mailing list