<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2800.1522" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2>
<DIV><FONT face=Arial size=2>Hi, I am trying to orientate&nbsp;a 3D&nbsp;model 
so that a particular&nbsp;vector is aligned with the z-axis in world 
coordinates.</FONT></DIV>
<DIV><FONT face=Arial size=2>I have tried:</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>vtkSTLReader model</FONT></DIV>
<DIV><FONT face=Arial size=2>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; model 
SetFileName "C:/myFile"</FONT></DIV>
<DIV><FONT face=Arial size=2>...</FONT></DIV>
<DIV><FONT face=Arial size=2>I am applying an instance of vtkCutter to this 
model.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>vtkCutter cutter1</FONT></DIV>
<DIV><FONT face=Arial size=2>cutter1&nbsp;SetInput [model GetOutput] 
</FONT></DIV>
<DIV><FONT face=Arial size=2>...</FONT></DIV>
<DIV><FONT face=Arial size=2>then when I transform the model&nbsp;using 
</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; modelActor 
RotateWXYZ angle1 0 0 1</FONT></DIV>
<DIV><FONT face=Arial size=2>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; modelActor 
RotateWXYZ angle2 0 1 0</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>the model is transforming correctly but cutter1 is 
not&nbsp;cutting the model anymore.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>When I use a transform:</FONT></DIV>
<DIV><FONT face=Arial size=2>vtkTransform modelTransform</FONT></DIV>
<DIV><FONT face=Arial size=2>&nbsp;&nbsp;&nbsp; </FONT></DIV>
<DIV><FONT face=Arial size=2>vtkTransformPolyDataFilter 
modTransform<BR>&nbsp;&nbsp;&nbsp; modTransform SetTransform 
modelTransform<BR>&nbsp;&nbsp;&nbsp; modTransform SetInput [model 
GetOutput]</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>and then</FONT></DIV>
<DIV><FONT face=Arial size=2>cutter1 SetInput [modelTransform 
GetOutput]</FONT></DIV>
<DIV><FONT face=Arial size=2>...</FONT></DIV>
<DIV><FONT face=Arial size=2>and then transform the model using</FONT></DIV>
<DIV><FONT face=Arial size=2>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; 
modelTransform RotateWXYZ angle1 0 0 1</FONT></DIV>
<DIV><FONT face=Arial size=2>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; 
modelTransform RotateWXYZ angle2 0 1 0</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>its producing the wrong output - i think it might 
be using the model coordinates instead of the world ones.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Any ideas on how to set the cutter to work on the 
(correctly) transformed model??</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Clare</FONT></DIV></FONT></DIV></BODY></HTML>