Mercurial > hg > Game > Cerium
diff Renderer/Engine/task/DataUpdate.cc @ 677:24054155368c draft
add Load light info for some spe
author | yutaka@henri.cr.ie.u-ryukyu.ac.jp |
---|---|
date | Sun, 06 Dec 2009 07:40:26 +0900 |
parents | |
children | 3a97fdd53a8e |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Renderer/Engine/task/DataUpdate.cc Sun Dec 06 07:40:26 2009 +0900 @@ -0,0 +1,28 @@ +#include <stdio.h> +#include "DataUpdate.h" +#include "Func.h" + +/* これは必須 */ +SchedDefineTask(DataUpdate); + +static int +run(SchedTask *s, void *rbuf, void *wbuf) +{ + + float *idata = (float*)s->get_input(rbuf, 0); + int load_id = (int)s->get_param(0); + float *global_data = (float*)s->global_get(load_id); + + global_data[0] = idata[0]; + global_data[1] = idata[1]; + global_data[2] = idata[2]; + global_data[3] = idata[3]; + +#if 0 + s->printf("spe %f ",idata[0]); + s->printf("spe %f ",idata[1]); + s->printf("spe %f\n",idata[2]); +#endif + + return 0; +}