I use PCLVisualizer in qt with qvtkwidget for visualizing a pointcloud.
Instead of using the mouse to click and rotate the camera, I would like to be able to programmatically move the camera l degrees to the left, r degrees to the right, u degrees up, d degrees down.
I have used setCameraPosition () to move the viewer like this: viewer->setCameraPosition(73,-9242,-800,-21,-226,2703,0,0,1); However, this is in a cartesian coordinate system.
I would like to give angles in degrees (or radians) instead. I imagine that there would be possible to use some elegant matrix operation instead of having to calculate this by moving along a circle etc.
Anyone that can help/ suggest how to move the camera specifying angles (polar coordinate system)? Some example code would be great as well!
Dominion Software, Inc.
825 Beacon Street
Newton, MA 02459
Medical, Scientific, and Industrial Software
> On Feb 3, 2018, at 7:46 AM, Mike6000 <[hidden email]> wrote:
> Hi again. The _rens apears to be private
> However by inspecting the header file of pcl_visualizer it appears that
> there are some public members that return pointers to the underlying Render
> Window, Renderer Collection, CloudActorMap
> /** \brief Return a pointer to the underlying VTK Render Window used. */
> getRenderWindow ()
> return (win_);
> /** \brief Return a pointer to the underlying VTK Renderer
> Collection. */
> getRendererCollection ()
> return (rens_);
> /** \brief Return a pointer to the CloudActorMap this visualizer
> uses. */
> getCloudActorMap ()
> return (cloud_actor_map_);
> /** \brief Return a pointer to the ShapeActorMap this visualizer
> uses. */
> getShapeActorMap ()
> return (shape_actor_map_);
> https://github.com/PointCloudLibrary/pcl/blob/master/visualization/include/pcl/visualization/pcl_visualizer.h >
> Would it be possible to help me get further by providing an example that
> compiles uses these public methods?
> Sent from: http://www.pcl-users.org/ > _______________________________________________
> [hidden email] / http://pointclouds.org > http://pointclouds.org/mailman/listinfo/pcl-users