Nelze vybrat více než 25 témat Téma musí začínat písmenem nebo číslem, může obsahovat pomlčky („-“) a může být dlouhé až 35 znaků.
 
 
 

80 řádky
1.3 KiB

  1. //
  2. // Lol Engine
  3. //
  4. // Copyright: (c) 2010-2011 Sam Hocevar <sam@hocevar.net>
  5. // This program is free software; you can redistribute it and/or
  6. // modify it under the terms of the Do What The Fuck You Want To
  7. // Public License, Version 2, as published by Sam Hocevar. See
  8. // http://sam.zoy.org/projects/COPYING.WTFPL for more details.
  9. //
  10. #if defined HAVE_CONFIG_H
  11. # include "config.h"
  12. #endif
  13. #if defined _XBOX
  14. # include <xtl.h>
  15. #endif
  16. #include "core.h"
  17. #include "lolgl.h"
  18. #include "xboxapp.h"
  19. namespace lol
  20. {
  21. /*
  22. * XboxApp implementation class
  23. */
  24. class XboxAppData
  25. {
  26. friend class XboxApp;
  27. private:
  28. #if defined _XBOX
  29. #endif
  30. };
  31. /*
  32. * Public XboxApp class
  33. */
  34. XboxApp::XboxApp(char const *title, ivec2 res, float fps) :
  35. data(new XboxAppData())
  36. {
  37. #if defined _XBOX
  38. Ticker::Setup(fps);
  39. Video::Setup(res);
  40. #endif
  41. }
  42. void XboxApp::ShowPointer(bool show)
  43. {
  44. ;
  45. }
  46. void XboxApp::Run()
  47. {
  48. while (!Ticker::Finished())
  49. {
  50. /* Tick the renderer, show the frame and clamp to desired framerate. */
  51. Ticker::TickDraw();
  52. #if defined _XBOX
  53. extern D3DDevice *g_d3ddevice;
  54. g_d3ddevice->Present(NULL, NULL, NULL, NULL);
  55. #endif
  56. }
  57. }
  58. XboxApp::~XboxApp()
  59. {
  60. #if defined _XBOX
  61. #endif
  62. delete data;
  63. }
  64. } /* namespace lol */