Guest User

Untitled

a guest
Sep 14th, 2012
28
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #include <irrlicht.h>
  2.  
  3. using namespace irr;
  4.  
  5. using namespace core;
  6. using namespace scene;
  7. using namespace video;
  8. using namespace io;
  9. using namespace gui;
  10.  
  11. #ifdef _IRR_WINDOWS_
  12. #pragma comment(lib, "Irrlicht.lib")
  13. #pragma comment(linker, "/subsystem:windows /ENTRY:mainCRTStartup")
  14. #endif
  15.  
  16.  
  17. int main() {
  18. IrrlichtDevice *device =
  19. createDevice( video::EDT_OPENGL, dimension2d<u32>(640, 480), 16,
  20. false, false, false, 0);
  21.  
  22. if (!device) {
  23. return 1;
  24. }
  25.  
  26. device->setWindowCaption(L"Hello World! - Irrlicht Engine Demo");
  27.  
  28. IVideoDriver* driver = device->getVideoDriver();
  29. ISceneManager* smgr = device->getSceneManager();
  30. IGUIEnvironment* guienv = device->getGUIEnvironment();
  31.  
  32. guienv->addStaticText(L"Hello World! This is the Irrlicht Software renderer!", rect<s32>(10,10,260,22), true);
  33.  
  34.  
  35.  
  36. return 0;
  37. }
RAW Paste Data