AppletTalk.com Forum Index AppletTalk.com
Java discussions newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Points to intervale [-1,1]

 
Post new topic   Reply to topic    AppletTalk.com Forum Index -> 3D Graphics API's for Java
View previous topic :: View next topic  
Author Message
Guest






PostPosted: Sun Apr 08, 2007 10:47 pm    Post subject: Points to intervale [-1,1] Reply with quote



Hi!! I have got points like this (in a file): X=2,923, Y=-0,232,
Z=7,890.

In Java 3D, points must be between -1 and 1 (in a intervalo [-1,1]).
How do you change this points to intervale [-1,1] ????

Regards!
Back to top
Tim Hemig
Guest





PostPosted: Tue Apr 10, 2007 8:08 pm    Post subject: Re: Points to intervale [-1,1] Reply with quote



Misterysword (AT) hotmail (DOT) com wrote:

Quote:
Hi!! I have got points like this (in a file): X=2,923, Y=-0,232,
Z=7,890.

In Java 3D, points must be between -1 and 1 (in a intervalo [-1,1]).
How do you change this points to intervale [-1,1] ????

I think you have to figure out, what dimensions your points have, so what is
your maximum in each dimension. After that you can normalize (word
correct?) the point into the intervall of [-1,1] where 1 (-1) is the
relative maximum.
depends also on the position of your figure. if it should be shown in center
with best fit, you can take the one biggest absolute value of x,y or z and
divide all coordinates with that scalar.

Greetings
Tim
Back to top
Guest






PostPosted: Thu Apr 12, 2007 3:56 pm    Post subject: Re: Points to intervale [-1,1] Reply with quote



thanks you!
Back to top
Display posts from previous:   
Post new topic   Reply to topic    AppletTalk.com Forum Index -> 3D Graphics API's for Java All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.