EasyGL Tutorial - Getting Started


#include <iostream.h>
#include "easygl.h"

void EasyRender()
{
   clearGraph();

   //Stuff to draw
   pset(500, 200, 1.0, 1.0, 1.0, 1.0); //You can specify the color in the cmd

   color(0.0, 0.0, 1.0, 1.0); //Or set and use a default color
   print(10, 10, "Hello World");

   line(200, 200, 500, 500);

   color(0.0, 1.0, 0.0, 1.0);
   square(20, 20, 50, 50);

   circle(100, 100, 25);

   ngon(300, 300, 8, 15, 1.0, 1.0, 1.0, 1.0);

  update();
}

int main()
{
   initEasyGL();
   return 1;
}

 

 

All code, graphics and content
(C) Thomas A. McDonley 2003
Unless otherwise noted.