Mercurial > hg > Game > Cerium
diff Renderer/Test/universe.cc @ 557:764772be1e3c draft
fix examlples (on going)
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Thu, 22 Oct 2009 17:34:12 +0900 |
parents | 4c5264373c51 |
children | 338ad9c856fc |
line wrap: on
line diff
--- a/Renderer/Test/universe.cc Thu Oct 22 14:05:24 2009 +0900 +++ b/Renderer/Test/universe.cc Thu Oct 22 17:34:12 2009 +0900 @@ -1,6 +1,6 @@ #include <stdlib.h> #include "SceneGraphRoot.h" -#include "SGList.h" +#include "universe.h" static void earth_collision(SceneGraphPtr node, int screen_w, int screen_h, @@ -40,8 +40,8 @@ } } -void -universe_init(TaskManager *manager) +MainLoopPtr +universe::init(Viewer *sgroot, int screen_w, int screen_h) { SceneGraphPtr earth; SceneGraphPtr moon; @@ -65,4 +65,35 @@ // SceneGraphRoot に、使用する SceneGraph を設定する // このとき、ユーザーが記述した SceneGraph の root を渡す。 sgroot->setSceneData(earth); + return sgroot; } + + +extern Application * +application() { + return new ball_bound(); +} + +const char *usr_help_str = "Usage: ./test_nogl [OPTION]\n"; + +extern int init(TaskManager *manager, int argc, char *argv[]); +extern void task_initialize(); +static void TMend(TaskManager *manager); + +int +TMmain(TaskManager *manager, int argc, char *argv[]) +{ + task_initialize(); + manager->set_TMend(TMend); + return init(manager, argc, argv); + +} + +void +TMend(TaskManager *manager) +{ + printf("test_nogl end\n"); +} + +/* end */ +