Mercurial > hg > Members > kono > Cerium
changeset 616:f21603a335aa
Rendering not yet worked.
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Sat, 14 Nov 2009 20:17:37 +0900 |
parents | f7d78b3c1106 |
children | 360032cc500e |
files | Renderer/Engine/Func.h Renderer/Engine/task/DrawSpan.cc Renderer/Engine/viewer.cc |
diffstat | 3 files changed, 5 insertions(+), 10 deletions(-) [+] |
line wrap: on
line diff
--- a/Renderer/Engine/Func.h Sat Nov 14 18:57:54 2009 +0900 +++ b/Renderer/Engine/Func.h Sat Nov 14 20:17:37 2009 +0900 @@ -11,7 +11,6 @@ CreateSpan, DrawSpan, - DrawSpanEnd, DrawBack, LoadTexture,
--- a/Renderer/Engine/task/DrawSpan.cc Sat Nov 14 18:57:54 2009 +0900 +++ b/Renderer/Engine/task/DrawSpan.cc Sat Nov 14 20:17:37 2009 +0900 @@ -118,8 +118,8 @@ { int **linebuf = (int**)smanager->allocate(height*sizeof(int*)); for(int h = 0;h<height;h++) { - int *buf = linebuf[height] = (int*)smanager->get_output(height); - for (int i = 0; i < width*height; i++) { + int *buf = linebuf[h] = (int*)smanager->get_output(h); + for (int i = 0; i < width; i++) { buf[i] = rgb; } } @@ -484,9 +484,6 @@ free(free_spack); - TaskPtr nextTask = smanager->create_task(DrawSpanEnd); - nextTask->add_param((memaddr)g); - smanager->wait_task(nextTask); return 0; }
--- a/Renderer/Engine/viewer.cc Sat Nov 14 18:57:54 2009 +0900 +++ b/Renderer/Engine/viewer.cc Sat Nov 14 20:17:37 2009 +0900 @@ -525,11 +525,10 @@ (memaddr)&pixels[(startx-1) + this->width*(starty-1)]); task_draw->add_param(1,this->width); - int height = rangey; - for (int i = 0; i < height; i++) { + for (int i = 0; i < rangey; i++) { task_draw->add_outData( - &pixels[(startx-1) + this->width*(starty-1)], - this->width*sizeof(int)); + &pixels[(startx-1) + this->width*(starty-1 + i) ], + (endx-startx+1)*sizeof(int)); } } else { // 7.7.3 SL1 Data Cache Range Set to Zero コマンド