Mercurial > hg > Members > kono > Cerium
comparison TaskManager/Test/test_render/spe/DrawSpan.cpp @ 126:7635f223fc7d
fix RGBA mask (bgr -> rgba)
author | gongo@charles.cr.ie.u-ryukyu.ac.jp |
---|---|
date | Tue, 25 Nov 2008 11:37:57 +0900 |
parents | f515436feb71 |
children | 776eca0daa02 |
comparison
equal
deleted
inserted
replaced
125:c3d8216ca79c | 126:7635f223fc7d |
---|---|
72 smanager->dma_wait(TEX_LOAD); | 72 smanager->dma_wait(TEX_LOAD); |
73 | 73 |
74 char *p = get_pixel(tx%8, ty%8, tex); | 74 char *p = get_pixel(tx%8, ty%8, tex); |
75 #endif | 75 #endif |
76 | 76 |
77 blue = (Uint8) p[0]; | 77 alpha = 255; |
78 red = (Uint8) p[0]; | |
78 green = (Uint8) p[1]; | 79 green = (Uint8) p[1]; |
79 red = (Uint8) p[2]; | 80 blue = (Uint8) p[2]; |
80 alpha = 255; | |
81 | 81 |
82 return (red & 0xff) * 0x10000 + (green & 0xff) * 0x100 | 82 return (red & 0xff) * 0x10000 + (green & 0xff) * 0x100 |
83 + (blue & 0xff) + (alpha << 24); | 83 + (blue & 0xff) + (alpha << 24); |
84 } | 84 } |
85 | 85 |