<!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 5.50.4913.1100" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2>A beginner needs help:</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>I want to map a texture on a sphere but
encountered the following problems:</FONT></DIV>
<DIV><FONT face=Arial size=2>Please see <A
href="http://www.cs.rpi.edu/~cana/Problems.htm">http://www.cs.rpi.edu/~cana/Problems.htm</A></FONT></DIV>
<DIV><FONT face=Arial size=2>1) The ascept ratio is lost, although I am using
the same scale factor for each dimension</FONT></DIV>
<DIV><FONT face=Arial size=2>xform[1]->SetScale(1.3, 1.3,
1.3); </FONT></DIV>
<DIV><FONT face=Arial size=2>2) There is a leak in the texture.... Please see
the above web site.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>3) I couldn't find any documentation about what the
units are for the command </FONT></DIV>
<DIV><FONT face=Arial size=2>xform->SetPosition(float, float,
float);</FONT></DIV>
<DIV><FONT face=Arial size=2>What are the units of these floats; rad, degree,
pixel?</FONT></DIV>
<DIV><FONT face=Arial size=2>More importantly, if you can direct me to web
adresses that I can find such information that would be great.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>I used the following classes. </FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2> sphere =
vtkSphereSource::New();<BR> tmapper =
vtkTextureMapToSphere::New();<BR></FONT><FONT face=Arial size=2>
vtkTransformTextureCoords *xform;<BR> vtkDataSetMapper
*sphereMapper;</FONT></DIV>
<DIV><FONT face=Arial size=2>
texture->SetInput(picReader->GetOutput());<BR>
texture->InterpolateOff();<BR> texture->RepeatOff();<BR></FONT><FONT
face=Arial size=2> sphereActor->SetMapper(sphereMapper);<BR>
sphereActor->SetTexture(texture);<BR></FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>Thanks,</FONT></DIV>
<DIV><FONT face=Arial size=2>Ali Can,</FONT></DIV>
<DIV><FONT face=Arial size=2>
<P style="MARGIN: 0in 0in 0pt; TEXT-ALIGN: center" align=center><SPAN
style="FONT-SIZE: 11pt; COLOR: black; mso-ansi-language: EN-US; mso-bidi-font-size: 12.0pt">Woods
Hole Oceanographic Institution,<?xml:namespace prefix = o ns =
"urn:schemas-microsoft-com:office:office" /><o:p></o:p></SPAN></P>
<P style="MARGIN: 0in 0in 0pt; TEXT-ALIGN: center" align=center><SPAN
style="FONT-SIZE: 11pt; COLOR: black; mso-ansi-language: EN-US; mso-bidi-font-size: 12.0pt">Deep
Submergence laboratory,<o:p></o:p></SPAN></P>
<H1 style="MARGIN: 0in 0in 0pt; TEXT-ALIGN: center" align=center><SPAN
style="FONT-WEIGHT: normal; FONT-SIZE: 10pt; COLOR: black; mso-ansi-language: EN-US; mso-bidi-font-size: 24.0pt">Blake
206, MS #7,<BR>Woods Hole, MA, 02543.<BR>Tel: (508) 289-3740<SPAN
style="mso-spacerun: yes"> </SPAN>Fax: (508) 457-2191<BR>Email:
acan@whoi.edu<SPAN style="mso-spacerun: yes"> </SPAN>Web:
http://www.cs.rpi.edu/~cana/</SPAN><SPAN
style="FONT-WEIGHT: normal; FONT-SIZE: 10pt; COLOR: black; mso-ansi-language: EN-US; mso-bidi-font-size: 12.0pt"><o:p></o:p></SPAN></H1></DIV></FONT></BODY></HTML>