#include "include/raven.h" using namespace std; // RAVEN_OPENGL is the only available mode for now #define VIDEOMODETYPE RAVEN_OPENGL Core *core; Renderer *renderer; int main(int argc,char *argv[]) { cout.sync_with_stdio(); /* this should pretty much ALWAYS be used in my opinion. It ensures that switching between printf and cout does NOT disrupt the stream. Since C/C++ are used together very often this is a must. */ // set up the core factory CoreFactory::Singleton().Set("Test App",640,480,16,16,0); // create the system core. this has our video context and handles OS specific junk. if (!(core=CoreFactory::Singleton().Create(VIDEOMODETYPE))) { cerr<<"Failed to create system core!"<BeginScene(true,true,Vector4(0.0f)); // begin scene, clear color/depth renderer->EndScene(true); // end scene, flip if (renderer->GetCore()->KeyDown(RAVEN_KEY_ESCAPE)||renderer->GetCore()->IsAppTerm()) run=false; } delete renderer; if (!core->Stop()) { cerr<<"Failed to stop system core!"<