[vtkusers] Why vtkplane and vtkplanesource display at different position?

Yongqiang yq_zhao76 at yahoo.com.cn
Sun Nov 19 02:17:04 EST 2006


Hi all,

 

I meet the following question:

I get the normal of the plane and a point on the plane.

 

vtkPlaneSource plane = vtkPlaneSource::New();

plane->SetCenter(pointposition);

plane->SetNormal(normal);  

 

The position of plane is what I expected.

 

Then I use myPlane to cut polydata. But after cutting, it seems that the
myPlane is parallel to plane, but its position is not what I expect.

 

vtkPlane *myPlane = vtkPlane::New();

myPlane->setOrigin(pointposition);

myPlane->setNormal(normal);

 

The only difference between these two setting is SetCenter and SetOrigin

 

In the vtk document, 

vtkPlane->SetOrigin : Set point through which plane passes.

vtkPlaneSource->SetCenter: Set the center of the plane

 

To define a plane, just need normal and a point at the plane. From the
document, I think these two functions are same. They just set a point
position.

 

So why myPlane is not at the position where plane stays?

Is my understanding wrong or other reasons?

 

Thanks for any help!!

 

___________________________________________

Yongqiang

 

 

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20061119/739d6611/attachment.htm>


More information about the vtkusers mailing list