<div dir="ltr"><div dir="ltr">Hello,</div><div dir="ltr"><br></div><div dir="ltr">Would you mind posting your question to <a href="https://discourse.vtk.org">https://discourse.vtk.org</a>? Community support for VTK is transitioning to that forum, and you are more likely to get an answer there.<br></div><div dir="ltr"><br></div><div>Thanks,</div><div>Cory</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, Mar 11, 2019 at 9:48 AM zandarina <<a href="mailto:esmeralda.ruiz@alma3d.com">esmeralda.ruiz@alma3d.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Dear all,<br>
<br>
I want to do segmentation with itk and i would like to select a seed using<br>
vtk with the mouse. I get the coordinates in world coordinates<br>
<br>
            int x = this->Interactor->GetEventPosition()[0];<br>
            int y = this->Interactor->GetEventPosition()[1];<br>
            std::cout << "(x,y) = (" << x << "," << y << ")" << std::endl;<br>
<br>
            seeds[0] = x;<br>
            seeds[1] = y;<br>
<br>
but when i want to use it as a seed for itk i see it is the wrong place. I<br>
tried the transformphysicalpointoindex but the result is even worst<br>
<br>
        bool isInside =<br>
            extractFilter->GetOutput()->TransformPhysicalPointToIndex(coordinate_vtk,<br>
coordinate_itk);<br>
        if (isInside) {<br>
<br>
<br>
            ImageType::PixelType pixelValue =<br>
extractFilter->GetOutput()->GetPixel(coordinate_itk);<br>
        }<br>
<br>
Any help about the coordinates in vtk?<br>
<br>
Thanks<br>
<br>
<br>
<br>
<br>
<br>
--<br>
Sent from: <a href="http://vtk.1045678.n5.nabble.com/VTK-Users-f1224199.html" rel="noreferrer" target="_blank">http://vtk.1045678.n5.nabble.com/VTK-Users-f1224199.html</a><br>
_______________________________________________<br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the VTK FAQ at: <a href="http://www.vtk.org/Wiki/VTK_FAQ" rel="noreferrer" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Search the list archives at: <a href="http://markmail.org/search/?q=vtkusers" rel="noreferrer" target="_blank">http://markmail.org/search/?q=vtkusers</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="https://vtk.org/mailman/listinfo/vtkusers" rel="noreferrer" target="_blank">https://vtk.org/mailman/listinfo/vtkusers</a><br>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature">Cory Quammen<br>Staff R&D Engineer<br>Kitware, Inc.</div>