# HG changeset patch # User gongo@localhost.localdomain # Date 1231223434 -32400 # Node ID 54787f182881254e6c7ee22916cbb86f1d49b8da # Parent df3cfc04e7968d8fa4cda51db7d8b433d85b5a77 fix diff -r df3cfc04e796 -r 54787f182881 TaskManager/Test/test_render/Makefile.def --- a/TaskManager/Test/test_render/Makefile.def Tue Dec 23 16:27:07 2008 +0900 +++ b/TaskManager/Test/test_render/Makefile.def Tue Jan 06 15:30:34 2009 +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 = /Users/tkaito/hg/Game/Cerium #CERIUM = ../../.. diff -r df3cfc04e796 -r 54787f182881 TaskManager/Test/test_render/spe/DrawSpan.cpp --- a/TaskManager/Test/test_render/spe/DrawSpan.cpp Tue Dec 23 16:27:07 2008 +0900 +++ b/TaskManager/Test/test_render/spe/DrawSpan.cpp Tue Jan 06 15:30:34 2009 +0900 @@ -162,7 +162,7 @@ next_spack = NULL; } - for (int t = 0; t < spack->info.size; t++) { + for (int t = spack->info.start; t < spack->info.size; t++) { span = &spack->span[t]; Uint32 rgb = 0x00ff00; diff -r df3cfc04e796 -r 54787f182881 TaskManager/Test/test_render/task/CreateSpan.cpp --- a/TaskManager/Test/test_render/task/CreateSpan.cpp Tue Dec 23 16:27:07 2008 +0900 +++ b/TaskManager/Test/test_render/task/CreateSpan.cpp Tue Jan 06 15:30:34 2009 +0900 @@ -128,7 +128,8 @@ /** - * span の width,height と texture の width,height を比べて + * span の width と Triangle の height に対して、 + * texture の width,height をそれぞれ比べて * span を描画する際に使う texture の比率を求める * * @param[in] width Width of span @@ -384,7 +385,7 @@ (int)(span->tex_width*tex_x_len), (int)(span->tex_height*tex_y_len), tex_scale_max); - //scale = (4 > tex_scale_max) ? tex_scale_max : 4; + //scale = (8 > tex_scale_max) ? tex_scale_max : 8; uint32 *tapestry = getTapestry(tex_width, tex_height, scale, tex_addr); @@ -431,40 +432,11 @@ for (int i = 0; i < pp->info.size; i++) { triPack = &pp->tri[i]; - -#if 0 + + // 参照渡しだからレジスタに乗らないでほげほげ〜で + // 最適化でいうと微妙? make_vertex(triPack, &vMin, &vMid, &vMax); -#else - if (triPack->ver1.y <= triPack->ver2.y) { - if (triPack->ver2.y <= triPack->ver3.y) { - vMin = &triPack->ver1; - vMid = &triPack->ver2; - vMax = &triPack->ver3; - } else if (triPack->ver3.y <= triPack->ver1.y) { - vMin = &triPack->ver3; - vMid = &triPack->ver1; - vMax = &triPack->ver2; - } else { - vMin = &triPack->ver1; - vMid = &triPack->ver3; - vMax = &triPack->ver2; - } - } else { - if (triPack->ver1.y <= triPack->ver3.y) { - vMin = &triPack->ver2; - vMid = &triPack->ver1; - vMax = &triPack->ver3; - } else if (triPack->ver3.y <= triPack->ver2.y) { - vMin = &triPack->ver3; - vMid = &triPack->ver2; - vMax = &triPack->ver1; - } else { - vMin = &triPack->ver2; - vMid = &triPack->ver3; - vMax = &triPack->ver1; - } - } -#endif + make_vMid10(vMid10, vMin, vMid, vMax); /** diff -r df3cfc04e796 -r 54787f182881 TaskManager/Test/test_render/task/DrawSpan.cpp --- a/TaskManager/Test/test_render/task/DrawSpan.cpp Tue Dec 23 16:27:07 2008 +0900 +++ b/TaskManager/Test/test_render/task/DrawSpan.cpp Tue Jan 06 15:30:34 2009 +0900 @@ -162,7 +162,7 @@ next_spack = NULL; } - for (int t = 0; t < spack->info.size; t++) { + for (int t = spack->info.start; t < spack->info.size; t++) { span = &spack->span[t]; Uint32 rgb = 0x00ff00;