Mercurial > hg > Game > Cerium
annotate example/basic/ppe/Twice.cc @ 199:1fd0107ebb25 draft
add SceneGraph(ieshoot), add SystemSceneGraph(Camera)
author | gongo@gendarme.cr.ie.u-ryukyu.ac.jp |
---|---|
date | Mon, 26 Jan 2009 14:02:45 +0900 |
parents | 028ffc9c0375 |
children | 768452fab95e |
rev | line source |
---|---|
109 | 1 #include <stdio.h> |
2 #include "SchedTask.h" | |
3 #include "Twice.h" | |
4 #include "Func.h" | |
5 | |
6 /* ¤³¤ì¤Ïɬ¿Ü */ | |
7 SchedDefineTask(Twice); | |
8 | |
9 int | |
10 Twice::run(void *rbuf, void *wbuf) | |
11 { | |
12 int *i_data; | |
13 int *o_data; | |
14 int length; | |
15 | |
16 i_data = (int*)get_input(rbuf, 0); | |
17 o_data = (int*)get_output(wbuf, 0); | |
18 length = get_param(0); | |
19 | |
20 for (int i = 0; i < length; i++) { | |
21 o_data[i] = i_data[i] * 2; | |
22 } | |
23 | |
24 return 0; | |
25 } |