geometry Archive

  • Many things are cool, like this screenshot of XCode for example… this is what happens when debugging iOS apps that use OpenGL, there’s a handy button to click that lets...

    Scenegraphs are cool…

    Many things are cool, like this screenshot of XCode for example… this is what happens when debugging iOS apps that use OpenGL, there’s a handy button to click that lets...

    Continue Reading...

  • There has been progress on my “fly endlessly down some sort of canyon” iPad thing. Quite a lot of this progress has been non-visual infrastructure code where I’ve taken hastily...

    Speeding over the icy wastelands of $insert_name_here

    There has been progress on my “fly endlessly down some sort of canyon” iPad thing. Quite a lot of this progress has been non-visual infrastructure code where I’ve taken hastily...

    Continue Reading...

  • Back when I owned an ST (well, I still have it, but you know what I mean) one of my favourite demos was Ooh Crikey! Wot a Scorcher By The Lost...

    OOh Crikey! Wot a lot of green!

    Back when I owned an ST (well, I still have it, but you know what I mean) one of my favourite demos was Ooh Crikey! Wot a Scorcher By The Lost...

    Continue Reading...

  • After a lot of chopping of code, rewriting bits and pieces and generally trying to turn a hacked mess into something more structured I have this… What you’re looking at...

    OpenGL ES 2.0 First Light

    After a lot of chopping of code, rewriting bits and pieces and generally trying to turn a hacked mess into something more structured I have this… What you’re looking at...

    Continue Reading...

  • So after creating a fun little iOS game using OpenGL ES 1.1 I decided the next thing I create should use ‘real’ 3D, rather than simply bashing OpenGL into managing...

    Debugging via telepathy

    So after creating a fun little iOS game using OpenGL ES 1.1 I decided the next thing I create should use ‘real’ 3D, rather than simply bashing OpenGL into managing...

    Continue Reading...

  • There will be a less predictable image in a future post, once I produce something worth looking at that makes sense to you. I’ve been spending the past few weeks...

    Linear Algebra, Analytic Geometry and other stuff you never saw the point of

    There will be a less predictable image in a future post, once I produce something worth looking at that makes sense to you. I’ve been spending the past few weeks...

    Continue Reading...

  • // Finds the angle that is 180 degrees from the given angle, but in radians fmodf((angle + M_PI), (M_PI * 2))

    Find opposite angle in radians

    // Finds the angle that is 180 degrees from the given angle, but in radians fmodf((angle + M_PI), (M_PI * 2))

    Continue Reading...

  • #include < stdio.h > #include < math.h >   #define M_PI 3.141 #define PI180 (M_PI/180) #define DEG2RAD(x) (x * PI180)   float getShortAngle(float a1, float a2) { float angle =...

    LERP between angles in radians

    #include < stdio.h > #include < math.h >   #define M_PI 3.141 #define PI180 (M_PI/180) #define DEG2RAD(x) (x * PI180)   float getShortAngle(float a1, float a2) { float angle =...

    Continue Reading...

  • float getShortAngle(float a1, float a2) { float angle = abs(a1 - a2)%360;   if(angle > 180) angle = 360 - angle;   return angle; };   printf ("%f", getShortAngle(360, 720));

    Shortest distance between two angles

    float getShortAngle(float a1, float a2) { float angle = abs(a1 - a2)%360;   if(angle > 180) angle = 360 - angle;   return angle; };   printf ("%f", getShortAngle(360, 720));

    Continue Reading...

  • Let’s take a diversion into the world of OpenGL, specifically the implementation of OpenGL that lives inside an Android powered device. So, OpenGL ES 1.0 then. I’ll be learning about...

    Android Notes: OpenGL ES 1.0

    Let’s take a diversion into the world of OpenGL, specifically the implementation of OpenGL that lives inside an Android powered device. So, OpenGL ES 1.0 then. I’ll be learning about...

    Continue Reading...