[vtkusers] ClipClosedSurface - Choose which side of plane to keep

Edward Wang ed1996 at gmail.com
Fri Sep 16 17:56:58 EDT 2016


Hi Bill,

After taking a break and looking at this again, negating the normal did
solve my problem. I don't know why it wasn't before, but I'm sure it was my
fault. Just as well, because I don't know what you mean by your second
paragraph. I've seen some reference to CMake when using Slicer, but I've
never actually used it successfully. Could you direct me to a resource
where I can learn more about this? I am working on a Windows if that is
relevant.

Thanks,
Edward

On Fri, Sep 16, 2016 at 11:35 AM, Bill Lorensen <bill.lorensen at gmail.com>
wrote:

> I just wrote a quick example. When I flip the normal, the other side is
> shown.
>
> Can you post a self-contained, compiplable example and CMakeLists.txt
> file that illustrates your problem? You can use a vtkSphereSource as
> your polydata.
>
>
> On Fri, Sep 16, 2016 at 2:06 PM, EdwardWang <ed1996 at gmail.com> wrote:
> > Hi all,
> >
> >
> > This feels like a trivial issue, but I've been having some trouble with
> > vtkClipClosedSurface. Basically, I describe a plane using the normal and
> an
> > origin point, and try to clip based on that plane.
> > This image shows what I'm trying to do.
> > <http://vtk.1045678.n5.nabble.com/file/n5740367/clip.png>
> >
> > The problem is that the wrong side of the plane is being returned. The
> grey
> > is the original model and the yellow is the result of the clipping. I
> want
> > the grey part, not the yellow part.
> >
> > I've tried flipping the sign of the normal vector, but that hasn't
> helped.
> > Any ideas on how to do this?
> >
> > For reference, I am using Slicer3D, which uses vtk.
> >
> > Thank you,
> > Edward
> >
> >
> >
> > --
> > View this message in context: http://vtk.1045678.n5.nabble.
> com/ClipClosedSurface-Choose-which-side-of-plane-to-keep-tp5740367.html
> > Sent from the VTK - Users mailing list archive at Nabble.com.
> > _______________________________________________
> > Powered by 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
>
>
>
> --
> Unpaid intern in BillsBasement at noware dot com
>



-- 
Edward
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtkusers/attachments/20160916/9a9a0da6/attachment.html>


More information about the vtkusers mailing list