Mercurial > hg > Members > kono > Cerium
changeset 122:a802b19ab9ae
add SceneGraph move
author | gongo@charles.cr.ie.u-ryukyu.ac.jp |
---|---|
date | Tue, 25 Nov 2008 00:37:04 +0900 |
parents | a52e193f9a42 |
children | 001583879ac3 |
files | TaskManager/Test/test_render/Makefile.def TaskManager/Test/test_render/spe/DrawSpan.cpp TaskManager/Test/test_render/task/update_sgp.cpp TaskManager/Test/test_render/viewer.cpp |
diffstat | 4 files changed, 19 insertions(+), 8 deletions(-) [+] |
line wrap: on
line diff
--- a/TaskManager/Test/test_render/Makefile.def Tue Nov 25 00:18:49 2008 +0900 +++ b/TaskManager/Test/test_render/Makefile.def Tue Nov 25 00:37:04 2008 +0900 @@ -3,10 +3,10 @@ # include/library path # ex: macosx #CERIUM = /Users/gongo/Source/Concurrency/Game_project/Cerium -CERIUM = /Users/gongo/Source/hg/Cerium +#CERIUM = /Users/gongo/Source/hg/Cerium # ex: linux/ps3 -#CERIUM = /home/gongo/Cerium +CERIUM = /home/gongo/Cerium #CERIUM = ../../..
--- a/TaskManager/Test/test_render/spe/DrawSpan.cpp Tue Nov 25 00:18:49 2008 +0900 +++ b/TaskManager/Test/test_render/spe/DrawSpan.cpp Tue Nov 25 00:37:04 2008 +0900 @@ -11,7 +11,7 @@ SchedDefineTask(DrawSpan); -unsigned char *tex; +static unsigned char *tex; void DrawSpan::linebuf_init(int *buf, int x, int rgb) @@ -109,7 +109,8 @@ for (int i = 0; i < rangey; i++) { linebuf[i] = (int*)smanager->get_output(i); - linebuf_init(linebuf[i], rangex, 0x00ff00ff); + //linebuf_init(linebuf[i], rangex, 0x00ff00ff); + linebuf_init(linebuf[i], rangex, 0); } do { @@ -195,6 +196,6 @@ free(free_sp); free(linebuf); free(zRow); - + free(tex); return 0; }
--- a/TaskManager/Test/test_render/task/update_sgp.cpp Tue Nov 25 00:18:49 2008 +0900 +++ b/TaskManager/Test/test_render/task/update_sgp.cpp Tue Nov 25 00:37:04 2008 +0900 @@ -80,6 +80,15 @@ } } +static void +move4(SceneGraphNodePtr node, int w, int h) +{ + node->angle[1] += 1.0f; + if (node->angle[1] > 360.0f) { + node->angle[1] = 0.0f; + } +} + static void coll(SceneGraphNodePtr node, int w, int h) @@ -90,7 +99,7 @@ init(void) { moveList[0] = move0; - moveList[1] = move1; + moveList[1] = move4; moveList[2] = move2; collList[0] = coll;
--- a/TaskManager/Test/test_render/viewer.cpp Tue Nov 25 00:18:49 2008 +0900 +++ b/TaskManager/Test/test_render/viewer.cpp Tue Nov 25 00:37:04 2008 +0900 @@ -281,8 +281,9 @@ // Draw Background (現在は塗りつぶし) //break; task_draw = manager->create_task(TASK_DRAW_BACK); - task_draw->add_param(0x00ffcc55); - //task_draw->add_param(st_rgb); + //task_draw->add_param(0x00ffcc55); + task_draw->add_param(0); +//task_draw->add_param(st_rgb); } for (int k = 0; k < rangey; k++) {