Welcome, Guest. Please login or register.

Login with username, password and session length

 
Advanced search

12046 Posts in 1593 Topics- by 595 Members - Latest Member: KeelmHaxabefe

21. May 2013, 06:03:50 am
Xith3D CommunityGeneral CategorySupport (Moderator: Marvin Fröhlich)Direct camera movement!
Pages: 1 [2]
Print
Author Topic: Direct camera movement!  (Read 1411 times)
Marvin Fröhlich
Xith Lord
Administrator
Guru
*****
Offline Offline

Posts: 4403


May the 4th, be with you...


View Profile
« Reply #15 on: 21. May 2012, 09:22:07 pm »

Code:
view.getTransform().rotAxis( axis, angle );

If you want to know the facing direction:
Code:
Vector3f facingDir = new Vector3f();
view.getFacingDirection( facingDir );
Logged
sickfar
Enjoying the stay
*
Offline Offline

Posts: 46


Eat fish - it contains phosphor

358797535
View Profile WWW Email
« Reply #16 on: 21. May 2012, 09:28:12 pm »

Code:
view.getTransform().rotAxis( axis, angle );

That's right, I understand it and I'll do it after getting rotation axis, thanks! And for this one more question: after getting facing direction vector, can I quickly calculate perpendicular vector or perpendicular plane? : ) I'm sorry for this simple questions, but I don't  usterstand a little mathematics in computer 3D : )
Logged
Marvin Fröhlich
Xith Lord
Administrator
Guru
*****
Offline Offline

Posts: 4403


May the 4th, be with you...


View Profile
« Reply #17 on: 22. May 2012, 10:58:12 am »

The view also has methods to retrieve the right-directio and up-direction. These are perpendicular to the facing-direction.
Logged
sickfar
Enjoying the stay
*
Offline Offline

Posts: 46


Eat fish - it contains phosphor

358797535
View Profile WWW Email
« Reply #18 on: 22. May 2012, 12:15:57 pm »

Niiiicccce! Thank you very much!
Logged
Pages: 1 [2]
Print
Jump to:  

Theme orange-lt created by panic