[vtkusers] Fwd: Re: vtkPolyDataSilhouette troubles
Lars Friedrich Lars
lars-friedrich at gmx.net
Thu Feb 25 16:09:42 EST 2010
-------- Original-Nachricht --------
Datum: Thu, 25 Feb 2010 22:08:56 +0100
Von: "Lars Friedrich Lars" <lars-friedrich at gmx.net>
An: felixmeissner <felix.meissner at student.fh-kiel.de>
Betreff: Re: [vtkusers] vtkPolyDataSilhouette troubles
hi,
have a look at this thread:
http://old.nabble.com/3D-surface-to-2D-silhouette-td26642059.html
I added a code snippet and data that show what the class does.
However, when I look at the images you added (CT-slices, right?), I guess you would like to visualize the contours of a structure (set) at the current slice. To accomplish that you can simply use vtkCutter. This class does the desired cutting (non-projective in contrast to vtkPolyDataSilhouette).
regards,
lars
-------- Original-Nachricht --------
> Datum: Thu, 25 Feb 2010 11:01:09 -0800 (PST)
> Von: felixmeissner <felix.meissner at student.fh-kiel.de>
> An: vtkusers at vtk.org
> Betreff: [vtkusers] vtkPolyDataSilhouette troubles
>
> Hi,
>
> I'm trying to draw a vtkPolyDataSilhouette based on a vtkPolyData-Model to
> a
> vtkImageViewer2. This Works partially, but the silhouette is rendered only
> in small parts to the image:
>
> http://de.tinypic.com/view.php?pic=1zx1jer&s=6
>
> As you can see only parts of the "silhouette" are painted.
>
> Im not sure if vtkPolyDataSilhouette is the right class to use for this
> purpose or if I missed an option so that the contour is continous. Any
> suggestens are welcome.
>
> Thank you, Felix
>
> ==== some code snippets Im using =====
>
> self.silhouette = vtk.vtkPolyDataSilhouette()
> self.silhouette.SetInput(model.GetOutput())
> self.silhouette.BorderEdgesOn()
> self.silhouette.PieceInvariantOn()
>
> self.silhouette.SetCamera(self.viewer.GetRenderer().GetActiveCamera())
>
> mapper = vtk.vtkPolyDataMapper()
> mapper.SetInput(self.silhouette.GetOutput())
> self.__SilhouetteActor = vtk.vtkActor()
> self.__SilhouetteActor.SetMapper(mapper)
> self.__SilhouetteActor.GetProperty().SetColor(1, 0, 0)
>
> self.__SilhouetteActor.SetOrigin(x, y, z)
> self.__SilhouetteActor.VisibilityOn()
> self.__SliceViewer.GetRenderer().AddActor(self.__SilhouetteActor)
> self.__SliceViewer.Render()
> --
> View this message in context:
> http://old.nabble.com/vtkPolyDataSilhouette-troubles-tp27714500p27714500.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
>
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
--
Sicherer, schneller und einfacher. Die aktuellen Internet-Browser -
jetzt kostenlos herunterladen! http://portal.gmx.net/de/go/chbrowser
--
GRATIS für alle GMX-Mitglieder: Die maxdome Movie-FLAT!
Jetzt freischalten unter http://portal.gmx.net/de/go/maxdome01
More information about the vtkusers
mailing list