<html>
<body>
  <div id="body" style="background-color:#ffffff;" >
<table cellspacing="0" cellpadding="0" border="0" rules="cols">
<tr class="head" style="border-bottom-width:1px;border-bottom-style:solid;" ><td class="headtd" style="padding:0;padding-top:.2em;" colspan="4">Commit in <b><tt>lxdream/src/pvr2</tt></b></td></tr>
<tr><td><tt><a href="#file1">scene.c</a></tt></td><td id="added" class="headtd2" style="padding-left:.3em;padding-right:.3em; background-color:#ddffdd;" align="right">+6</td><td id="removed" class="headtd2" style="padding-left:.3em;padding-right:.3em; background-color:#ffdddd;" align="right">-1</td><td class="headtd2" style="padding-left:.3em;padding-right:.3em;" nowrap="nowrap">dc60a0987db9 -> fd82bfba61c4</td></tr>
<tr class="alt" style=";" ><td><tt><a href="#file2">texcache.c</a></tt></td><td id="addedalt" class="headtd2" style="padding-left:.3em;padding-right:.3em; background-color:#ccf7cc;" align="right">+17</td><td id="removed" class="headtd2" style="padding-left:.3em;padding-right:.3em; background-color:#ffdddd;" align="right">-1</td><td class="headtd2" style="padding-left:.3em;padding-right:.3em;" nowrap="nowrap">dc60a0987db9 -> fd82bfba61c4</td></tr>
<tr><td></td><td id="added" class="headtd2" style="padding-left:.3em;padding-right:.3em; background-color:#ddffdd;" align="right">+23</td><td id="removed" class="headtd2" style="padding-left:.3em;padding-right:.3em; background-color:#ffdddd;" align="right">-2</td><td></td></tr>
</table>
<small id="info" style="color: #888888;" >2 modified files</small><br />
<pre class="comment" style="white-space:-moz-pre-wrap;white-space:-pre-wrap;white-space:-o-pre-wrap;white-space:pre-wrap;word-wrap:break-word;padding:4px;border:1px dashed #000000;background-color:#ffffdd;" >
Fix call to isGLMultitextureSuppported() in texcache
Add debug helper to print idx4 textures on console
Change pvr2_scene_dump() to just dump to stdout
</pre>
<hr /><a name="file1" /><div class="file" style="border:1px solid #eeeeee;margin-top:1em;margin-bottom:1em;" >
<span class="pathname" style="font-family:monospace; float:right;" >lxdream/src/pvr2</span><br />
<div class="fileheader" style="margin-bottom:.5em;" ><big><b>scene.c</b></big> <small id="info" style="color: #888888;" >dc60a0987db9 -> fd82bfba61c4</small></div>
<pre class="diff" style="margin:0;" ><small id="info" style="color: #888888;" >--- lxdream/src/pvr2/scene.c
+++ lxdream/src/pvr2/scene.c
@@ -936,7 +936,7 @@
</small></pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" > /**
  * Dump the current scene to file in a (mostly) human readable form
  */
</pre><pre id="removed" class="diff" style="margin:0; background-color:#ffdddd;" >-void pvr2_scene_<span id="removedchars" style="background-color:#ff9999;font-weight:bolder;" >dump</span>( FILE *f )
</pre><pre id="added" class="diff" style="margin:0; background-color:#ddffdd;" >+void pvr2_scene_<span id="addedchars" style="background-color:#99ff99;font-weight:bolder;" >print</span>( FILE *f )
</pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" > {
     int i,j;
 
</pre><pre class="diff" style="margin:0;" ><small id="info" style="color: #888888;" >@@ -974,3 +974,8 @@
</small></pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" >     }
 
 }
</pre><pre id="added" class="diff" style="margin:0; background-color:#ddffdd;" >+
+void pvr2_scene_dump()
+{
+    pvr2_scene_print(stdout);
+}
</pre></div>
<hr /><a name="file2" /><div class="file" style="border:1px solid #eeeeee;margin-top:1em;margin-bottom:1em;" >
<span class="pathname" style="font-family:monospace; float:right;" >lxdream/src/pvr2</span><br />
<div class="fileheader" style="margin-bottom:.5em;" ><big><b>texcache.c</b></big> <small id="info" style="color: #888888;" >dc60a0987db9 -> fd82bfba61c4</small></div>
<pre class="diff" style="margin:0;" ><small id="info" style="color: #888888;" >--- lxdream/src/pvr2/texcache.c
+++ lxdream/src/pvr2/texcache.c
@@ -94,7 +94,7 @@
</small></pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" >     int i;
     GLuint texids[MAX_TEXTURES];
 
</pre><pre id="removed" class="diff" style="margin:0; background-color:#ffdddd;" >-    if( glsl_is_supported() && isGLMultitextureSupported ) {
</pre><pre id="added" class="diff" style="margin:0; background-color:#ddffdd;" >+    if( glsl_is_supported() && isGLMultitextureSupported<span id="addedchars" style="background-color:#99ff99;font-weight:bolder;" >()</span> ) {
</pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" >         texcache_have_palette_shader = TRUE;
         texcache_palette_valid = FALSE;
         glGenTextures(1, &texcache_palette_texid );
</pre><pre class="diff" style="margin:0;" ><small id="info" style="color: #888888;" >@@ -898,3 +898,19 @@
</small></pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" >         }
     }
 }
</pre><pre id="added" class="diff" style="margin:0; background-color:#ddffdd;" >+
+void texcache_print_idx4( uint32_t texture_addr, int width )
+{
+    unsigned x,y;
+    int src_bytes = (width*width>>1);
+    char tmp[src_bytes];
+    char data[width*width];
+    pvr2_vram64_read_twiddled_4( tmp, texture_addr, width, width );
+    decode_pal4_to_pal8( data, tmp, src_bytes );
+    for( y=0; y<width; y++ ) {
+        for( x=0; x<width; x++ ) {
+            printf( "%1x", data[y*width+x] );
+        }
+        printf( "\n" );
+    }
+}
</pre></div>
<center><small>Chaos Theory</small></center>
</div></body></html>