1.1 --- a/src/pvr2/rendcore.c Wed Jan 17 09:21:09 2007 +0000
1.2 +++ b/src/pvr2/rendcore.c Mon Jan 22 11:45:37 2007 +0000
1.5 - * $Id: rendcore.c,v 1.9 2007-01-17 09:21:09 nkeynes Exp $
1.6 + * $Id: rendcore.c,v 1.10 2007-01-21 11:28:43 nkeynes Exp $
1.8 * PVR2 renderer core.
1.14 - int e = ((half & 0x7C00) >> 10) - 15 + 127;
1.15 + /* int e = ((half & 0x7C00) >> 10) - 15 + 127;
1.17 temp.i = ((half & 0x8000) << 16) | (e << 23) |
1.18 - ((half & 0x03FF) << 13);
1.19 + ((half & 0x03FF) << 13); */
1.20 + temp.i = ((uint32_t)half)<<16;
1.24 @@ -125,6 +126,16 @@
1.25 glEnable(GL_TEXTURE_2D);
1.26 texcache_get_texture( (texture&0x000FFFFF)<<3, width, height, texture );
1.27 glTexEnvi( GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, POLY2_TEX_BLEND(poly2) );
1.28 + if( POLY2_TEX_CLAMP_U(poly2) ) {
1.29 + glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP );
1.31 + glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT );
1.33 + if( POLY2_TEX_CLAMP_V(poly2) ) {
1.34 + glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP );
1.36 + glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT );
1.39 glDisable( GL_TEXTURE_2D );
1.41 @@ -134,11 +145,6 @@
1.42 int srcblend = POLY2_SRC_BLEND(poly2);
1.43 int destblend = POLY2_DEST_BLEND(poly2);
1.44 glBlendFunc( srcblend, destblend );
1.45 - if( POLY2_TEX_ALPHA_ENABLE(poly2) ) {
1.46 - glEnable(GL_BLEND);
1.48 - glDisable(GL_BLEND);
1.52 void render_vertexes( uint32_t poly1, uint32_t *vertexes, int num_vertexes, int vertex_size,
1.54 vertex_length *= 2 ;
1.59 if( (entry & 0xE0000000) == 0x80000000 ) {
1.61 int strip_count = ((entry >> 25) & 0x0F)+1;