What's the coordinate system of orx, is it opengl compatible?
What's the different about the camera coordinate, object coordinate, viewport coordinate? and word position, screen position?
The coordinate system is right handed and is an extension of the traditional 2D:
X point right
Y pointing down
Z pointing toward the screen
When we speak of <referential> coordinates, it just means that that system's origin is the <referential> and that the axes are rotated/scaled according to the referential.
All those systems are world coordinates. Screen coordinates are 2D only and are the traditional ones:
X pointing right
Y pointing down
Origin being the top left corner
Conversion between screen & world coordinates are done using the transformations applied by the camera/viewport couple (and there are functions for this in orxRender).
What's the comara direction?
Suppose i define a camera
[Camera]
; We use the same size for the camera than our display on screen so as to obtain a 1:1 ratio
FrustumWidth = @Display.ScreenWidth
FrustumHeight = @Display.ScreenHeight
FrustumFar = 100.0
FrustumNear = 0.0
Position = (10.0, 100.0, -1.0)
Where is the camera locate? which direction does the camera towards?
I have done a lot of test, now make sense thank you
By the way, the camera/viewport transform just make the opengl coordinate system the same as screen one, right i means two dimension compare.
Yes, we've tried to hide the differences as much as possible. Up till recently one would still need to vertically flip compressed textures and invert texture coordinates in shaders but it's not required anymore.
Comments
X point right
Y pointing down
Z pointing toward the screen
When we speak of <referential> coordinates, it just means that that system's origin is the <referential> and that the axes are rotated/scaled according to the referential.
All those systems are world coordinates. Screen coordinates are 2D only and are the traditional ones:
X pointing right
Y pointing down
Origin being the top left corner
Conversion between screen & world coordinates are done using the transformations applied by the camera/viewport couple (and there are functions for this in orxRender).
Suppose i define a camera
[Camera]
; We use the same size for the camera than our display on screen so as to obtain a 1:1 ratio
FrustumWidth = @Display.ScreenWidth
FrustumHeight = @Display.ScreenHeight
FrustumFar = 100.0
FrustumNear = 0.0
Position = (10.0, 100.0, -1.0)
Where is the camera locate? which direction does the camera towards?
As for your camera location, you just wrote it's position the line above.
By the way, the camera/viewport transform just make the opengl coordinate system the same as screen one, right i means two dimension compare.
If you sync the repository, you should be good.
Also I'll answer your other questions tonight as I'm on my phone at the moment.