Page 2 of 2 FirstFirst 12
Results 11 to 13 of 13

Thread: OpenGL Camera Tutorial???

  1. #11

    Re: OpenGL Camera Tutorial???

    I gave the link in a previous post:
    Now, I have to setup a base matrix for translation, rotation, and scale then use that * the current matrix to perform translations, rotation, and scaling within 3D space. According to one article I found (http://www.gamedev.net/reference/art...article415.asp) those matrix should be:
    Just in case, the link is: http://www.gamedev.net/reference/art...article415.asp

    Looks like your using row based instead of column based matrices since your x, y, z are running vertical (if I'm reading properly through the plethora of articles).

    Looking specifically at his rotation matrices he refers to q, and so do many many others (just as an example, hit just about any of the articles on GameDev about Matrix Math and Rotations http://www.gamedev.net/reference/lis...categoryid=259). So, my basic question is, what is q?

    - Jeremy

  2. #12

    Re: OpenGL Camera Tutorial???

    In the article, q means angle. It means basically similar calculation than what glRotate uses. Article just defines matrices around set X, Y or Z axis instead of any vector.
    The sections answer to question "I have axis Y and i want to turn q degrees around it, what is the rotation matrix?"

    I just wrote in form that came to mind first. It is different thing how different libraries define their matrix array. However with OpenGL everyone is using the same system.

  3. #13

    Re: OpenGL Camera Tutorial???

    The key to all the 3d goodness lies in the understanding of matrices and vectors. Vectors aren't that hard, and I think you understand those pretty well. The matrices on the other hand are quite tough.

    First you should exactly understand what a matrix does. It defines the relationship between two coordinate spaces and can be used to transform vectors from coordinate space A to coordinate space B. Read some more articles about matrices until you can visualize this.

    If you really want to dive into this, I suggest you buy "3d math primer for graphics and game development". I have a hard copy here, and its definitely a good read. It covers all vector and matrix math you will need.
    Coders rule nr 1: Face ur bugz.. dont cage them with code, kill'em with ur cursor.

Page 2 of 2 FirstFirst 12

Bookmarks

Posting Permissions

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