[vtkusers] QVTKWidget, vtkResliceImageViewer question

Imre Goretzki goretzki.imre at gmail.com
Tue Mar 8 09:58:10 EST 2016


Ok thank you Dean.

Am 08.03.2016 um 15:43 schrieb DL I:
> Hi Imre,
>
> it sounds like you want to set a specific pair of window/level values 
> instead of
> interactively setting them by mouse movement. vtkResliceImageViewer is
> a subclass of vtkImageViewer2 which has methods to set window and 
> level values:
> void SetColorWindow(double w)
> void SetColorLevel(double l)
>
> If you dont want the viewer's vtkInteractorStyleImage to do 
> window/levelling you
> can handle those events and process them yourself by subclassing your own
> interactor style from vtkInteractorStyleImage.
>
> - Dean
>
>
> On Tue, Mar 8, 2016 at 8:05 AM, Imre Goretzki <goretzki.imre at gmail.com 
> <mailto:goretzki.imre at gmail.com>> wrote:
>
>     Hey guys,
>
>     I have a question about the attributes when holding down the left
>     mouse button while moving the cursor up and down
>     in the render window.
>
>     Set up is a combination of QVTKWidget and vtkResliceImageViewer:
>
>     view = vtkSmartPointer<vtkResliceImageViewer>
>
>     ...
>
>     view->SetInputData(vtkImageData);
>     ui->display->SetRenderWindow(view->GetRenderWindow())
>     view->SetupInteractor(ui->display->GetRenderWindow()->GetInteractor());
>     view->Render();
>     ui->display->update();
>
>     ui->display: QVTKWidget
>     view: vtkSmartPointer<vtkResliceImageViewer>
>
>     Whenever I hold the left mouse button and move the cursor, the
>     displayed image becomes darker (while moving up)
>     and brighter (while moving down) respectively.
>
>     I want to set the attribute to a certain level. I guess I have to
>     override some events, but I need to know the attribute that will
>     be set / changed during the described processes.
>
>     Thanks in advance
>
>     Imre
>     _______________________________________________
>     Powered by www.kitware.com <http://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
>
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtkusers/attachments/20160308/804f7094/attachment.html>


More information about the vtkusers mailing list