Results 1 to 3 of 3

Thread: Applying <lookat> transforms

  1. #1
    Junior Member
    Join Date
    Feb 2007
    Posts
    3

    Applying <lookat> transforms

    Hi,

    I'm a little confused as to how to handle the <lookat> transform. As far as I can tell, this transform is for cameras only, so does that mean that I should ignore it unless the node has a camera? If a camera is instantiated and a lookat transform exists on the node, should it ignore any other transforms or should I somehow convert the lookat transform into a matrix and concatenate it with the other matrices like usual?

    Thanks,
    David

  2. #2
    Senior Member
    Join Date
    Aug 2005
    Location
    California
    Posts
    165
    You treat the <lookat> just like any other transform. It gets post multiplied in the transform stack.

    Each transform can be thought of as a matrix and they all get concatenated together in the order they are specified. <lookat> acts the same as the OpenGL gluLookAt function. As you may recall gluLookAt applies the matrix to the current matrix. The GL API doesn't make any difference what matrix mode you are in, could be MODELVIEW, PROJECTION, or even TEXTURE matrix. That is the same as COLLADA works.

    -Andy

  3. #3
    Junior Member
    Join Date
    Feb 2007
    Posts
    3
    Ah, seems I was overthinking.
    Thanks.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •