view different viewports in different windows for the same point cloud. QT/PCL/VTK

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

view different viewports in different windows for the same point cloud. QT/PCL/VTK

Sameer
This post was updated on .
Hi all, sorry for asking alot..
I'm working on a qt desktop application which uses pcl and vtk libraries..
I have a mainWindow which uses QVtkWidget to view point cloud using pcl
RenderWindow.
i want to show a new window which has the same pointcloud  but using another
viewport.
but, the problem is : i can interact only with  the last created window.

mainWindow.cpp code:

    AnnotaLight::AnnotaLight(QWidget* parent)
  : QMainWindow(parent),
    ui(new Ui::AnnotaLight),
    m_pclViewer(new pcl::visualization::PCLVisualizer("PCL Visualizer",
true))
   {
     // initialize UI

    // add m_qvtkWidget to main windows
   m_qvtkWidget = new QVTKWidget;
   ui->splitterVertical->addWidget(m_qvtkWidget);

  m_qvtkWidget->SetRenderWindow(m_pclViewer->getRenderWindow());

   }


new viewport class :
here i'm passing the same pclVisualizer object to the new viewport class
object

 Viewport::Viewport(pcl::visualization::PCLVisualizer::Ptr viewer, QWidget
*parent) :
        QWidget(parent),
        ui(new Ui::Viewport),
        m_pclVisualizer(new pcl::visualization::PCLVisualizer("PCL
Visualizer1", true))
    {
              ui->setupUi(this);
        m_vtkWidget = new QVTKWidget;


        ui->verticalLayout_pclVisualizer->addWidget(m_vtkWidget);
        m_vtkWidget->SetRenderWindow(viewer->getRenderWindow());
    }
image:
  <http://www.pcl-users.org/file/t499251/AU_ANNOTA_36_3.png



--
Sent from: http://www.pcl-users.org/
_______________________________________________
PCL-users@pointclouds.org / http://pointclouds.org
http://pointclouds.org/mailman/listinfo/pcl-users
Reply | Threaded
Open this post in threaded view
|

Re: view different viewports in different windows for the same point cloud. QT/PCL/VTK

Sérgio Agostinho

New window means automatically new viewport. Are you mixing the term viewpoint with viewport?

Cheers


_______________________________________________
[hidden email] / http://pointclouds.org
http://pointclouds.org/mailman/listinfo/pcl-users

signature.asc (836 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: view different viewports in different windows for the same point cloud. QT/PCL/VTK

Sameer
Hello, thanks for your reply.
i meant that i want to view the same rendering window in multiple window..
so i can interact with the renderWindow from any window, and aother windows
will be updated synchronously..
like blender:
<http://www.pcl-users.org/file/t499251/blender.png>




--
Sent from: http://www.pcl-users.org/
_______________________________________________
[hidden email] / http://pointclouds.org
http://pointclouds.org/mailman/listinfo/pcl-users
Reply | Threaded
Open this post in threaded view
|

Re: view different viewports in different windows for the same point cloud. QT/PCL/VTK

Sameer
any other ideas ?



--
Sent from: http://www.pcl-users.org/
_______________________________________________
[hidden email] / http://pointclouds.org
http://pointclouds.org/mailman/listinfo/pcl-users