Viewport.ToScreen and camera translation

13 views
Skip to first unread message

Bon

unread,
Mar 6, 2011, 1:22:19 PM3/6/11
to Physics2D.Net
What is the recommended way of moving the camera perspective in game?
I've been playing with passing Matrix2x3 objects to it and have been
trying to get a handle on that, but my linear algebra is way rusty.
Before I dedicate time refreshing on linear algebra is this even a
suggested way to do what I want?

JonoPorter

unread,
Mar 10, 2011, 12:41:39 PM3/10/11
to Physics2D.Net
Yeah thats the way to move the camera's perspective.

Here is the matrix for translation:

1 0 X
0 1 Y

with the field names:

m00 m01 m02
m10 m11 m12

so m02 = x, m12 = Y
that should refresh your memory.
Reply all
Reply to author
Forward
0 new messages