[vtkusers] clip spheres (depending on a direction vector)

M. Jordan mjordan at live.at
Wed Dec 14 07:56:20 EST 2016


Hi,

i would like to clip some spheres into two equal parts and color them.
There are many of these spheres placed onto a surface.

I tried <vtkClipPolyData> but the problem is that I want to achieve an equal look from all directions.

Therefore I tried to cut the spheres with a plane resulting from the direction vector (e).


plane->SetNormal(ex, ey ez);


Now the "backside" of the spheres is cutted when looking at them onto the surface (normal vector of the plane = direction vector of the spheres center).

But I would like to rotate the plane about 90 degree to cut the spheres in the middle. When you look onto the surface, every sphere on it should look the same.

Some ideas of how to do that?

Is there a simplier solution to color half of a sphere and show both halfes equally independent from the point of view.

Kind Regards
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtkusers/attachments/20161214/05cc45bd/attachment.html>


More information about the vtkusers mailing list