Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: [Solved] SetPosition  (Read 15260 times)

0 Members and 1 Guest are viewing this topic.

l0calh05t

  • Full Member
  • ***
  • Posts: 200
    • View Profile
[Solved] SetPosition
« on: July 25, 2008, 10:23:03 am »
How is the coordinate system for Sound.SetPosition set up?

x is obviously left->right
but what about y and z?
is the coordinate system right-handed? is y the back->front (or front->back) axis? etc.

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
[Solved] SetPosition
« Reply #1 on: July 25, 2008, 10:44:04 am »
Here is what you have to know about the audio coordinate system :
- it is right handed
- the up axis is always (0, 1, 0)
- the right and front axis are deduced from the target and listener positions
Laurent Gomila - SFML developer

l0calh05t

  • Full Member
  • ***
  • Posts: 200
    • View Profile
[Solved] SetPosition
« Reply #2 on: July 25, 2008, 10:49:19 am »
ah, ok, so because the listener is at (0,0,0)' by default, and the default listener target is (0,0,-1)':

(-1,0,0)' is to the left of the listener
(1,0,0)' is to the right of the listener
(0,0,1)' is in front of the listener
(0,0,-1)' is behind the listener

correct?

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
[Solved] SetPosition
« Reply #3 on: July 25, 2008, 11:37:27 am »
Yep, should be correct.
Laurent Gomila - SFML developer