1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Sep 2010
    Rep Power

    Can OpenGL Do Math for Me?

    Google has been no help, and I'm interested in finding out if OpenGL can do math for me. If I had a vertex and wanted to rotate it, is there anyway I could have OpenGL accomplish this? I'm assuming that OpenGL could do this faster than if I were to rotate the vertex myself using the CPU.
  2. #2
  3. No Profile Picture
    Lost in code
    Devshed Supreme Being (6500+ posts)

    Join Date
    Dec 2004
    Rep Power
    Both Nvidia and ATI have special APIs that allow you to perform mathmatical operations using a GPU. Nvidia's is called CUDA. I think ATI's is called FireStream. There is also a rough equilvant to OpenGL called OpenCL that allows you to use these interfaces with a common API. This approach makes sense if you're trying to get the coordinates of the rotated vertex back and are not trying to just display the rotated vertex.

    However, if you're trying to rotate and display a vertex then it just makes more sense to use OpenGL to do it. You could write a vertex shader to do it, or use the glRotate function.

    Originally Posted by Spad
    Ah USB, the only rectangular connector where you have to make 3 attempts before you get it the right way around

IMN logo majestic logo threadwatch logo seochat tools logo