<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</tt></b></td></tr>
<tr><td><tt><a href="#file1">display.h</a></tt></td><td id="added" class="headtd2" style="padding-left:.3em;padding-right:.3em; background-color:#ddffdd;" align="right">+1</td><td></td><td class="headtd2" style="padding-left:.3em;padding-right:.3em;" nowrap="nowrap">d63f73cc586f -> a9d29fe74bf3</td></tr>
<tr class="alt" style=";" ><td><tt>drivers/<a href="#file2">video_egl.c</a></tt></td><td id="addedalt" class="headtd2" style="padding-left:.3em;padding-right:.3em; background-color:#ccf7cc;" align="right">+1</td><td></td><td class="headtd2" style="padding-left:.3em;padding-right:.3em;" nowrap="nowrap">d63f73cc586f -> a9d29fe74bf3</td></tr>
<tr><td><tt> /<a href="#file3">video_gl.c</a></tt></td><td id="added" class="headtd2" style="padding-left:.3em;padding-right:.3em; background-color:#ddffdd;" align="right">+1</td><td></td><td class="headtd2" style="padding-left:.3em;padding-right:.3em;" nowrap="nowrap">d63f73cc586f -> a9d29fe74bf3</td></tr>
<tr class="alt" style=";" ><td><tt> /<a href="#file4">video_glx.c</a></tt></td><td id="addedalt" class="headtd2" style="padding-left:.3em;padding-right:.3em; background-color:#ccf7cc;" align="right">+1</td><td></td><td class="headtd2" style="padding-left:.3em;padding-right:.3em;" nowrap="nowrap">d63f73cc586f -> a9d29fe74bf3</td></tr>
<tr><td><tt> /<a href="#file5">video_nsgl.m</a></tt></td><td id="added" class="headtd2" style="padding-left:.3em;padding-right:.3em; background-color:#ddffdd;" align="right">+1</td><td></td><td class="headtd2" style="padding-left:.3em;padding-right:.3em;" nowrap="nowrap">d63f73cc586f -> a9d29fe74bf3</td></tr>
<tr class="alt" style=";" ><td><tt>pvr2/<a href="#file6">gl_sl.c</a></tt></td><td id="addedalt" class="headtd2" style="padding-left:.3em;padding-right:.3em; background-color:#ccf7cc;" align="right">+18</td><td></td><td class="headtd2" style="padding-left:.3em;padding-right:.3em;" nowrap="nowrap">d63f73cc586f -> a9d29fe74bf3</td></tr>
<tr><td><tt> /<a href="#file7">glrender.c</a></tt></td><td id="added" class="headtd2" style="padding-left:.3em;padding-right:.3em; background-color:#ddffdd;" align="right">+1</td><td id="removed" class="headtd2" style="padding-left:.3em;padding-right:.3em; background-color:#ffdddd;" align="right">-12</td><td class="headtd2" style="padding-left:.3em;padding-right:.3em;" nowrap="nowrap">d63f73cc586f -> a9d29fe74bf3</td></tr>
<tr class="alt" style=";" ><td><tt> /<a href="#file8">glutil.h</a></tt></td><td id="addedalt" class="headtd2" style="padding-left:.3em;padding-right:.3em; background-color:#ccf7cc;" align="right">+1</td><td></td><td class="headtd2" style="padding-left:.3em;padding-right:.3em;" nowrap="nowrap">d63f73cc586f -> a9d29fe74bf3</td></tr>
<tr><td><tt> /<a href="#file9">pvr2.h</a></tt></td><td id="added" class="headtd2" style="padding-left:.3em;padding-right:.3em; background-color:#ddffdd;" align="right">+1</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">d63f73cc586f -> a9d29fe74bf3</td></tr>
<tr class="alt" style=";" ><td><tt> /<a href="#file10">texcache.c</a></tt></td><td id="addedalt" class="headtd2" style="padding-left:.3em;padding-right:.3em; background-color:#ccf7cc;" align="right">+2</td><td id="removed" class="headtd2" style="padding-left:.3em;padding-right:.3em; background-color:#ffdddd;" align="right">-2</td><td class="headtd2" style="padding-left:.3em;padding-right:.3em;" nowrap="nowrap">d63f73cc586f -> a9d29fe74bf3</td></tr>
<tr><td></td><td id="added" class="headtd2" style="padding-left:.3em;padding-right:.3em; background-color:#ddffdd;" align="right">+28</td><td id="removed" class="headtd2" style="padding-left:.3em;padding-right:.3em; background-color:#ffdddd;" align="right">-15</td><td></td></tr>
</table>
<small id="info" style="color: #888888;" >10 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;" >
Move glsl loading into common gl code, and set a display capability flag
</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</span><br />
<div class="fileheader" style="margin-bottom:.5em;" ><big><b>display.h</b></big> <small id="info" style="color: #888888;" >d63f73cc586f -> a9d29fe74bf3</small></div>
<pre class="diff" style="margin:0;" ><small id="info" style="color: #888888;" >--- lxdream/src/display.h
+++ lxdream/src/display.h
@@ -110,6 +110,7 @@
</small></pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" >
struct display_capabilities {
gboolean has_gl;
</pre><pre id="added" class="diff" style="margin:0; background-color:#ddffdd;" >+ gboolean has_sl;
</pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" > int depth_bits;
int stencil_bits; /* 0 = no stencil buffer */
};
</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/drivers</span><br />
<div class="fileheader" style="margin-bottom:.5em;" ><big><b>video_egl.c</b></big> <small id="info" style="color: #888888;" >d63f73cc586f -> a9d29fe74bf3</small></div>
<pre class="diff" style="margin:0;" ><small id="info" style="color: #888888;" >--- lxdream/src/drivers/video_egl.c
+++ lxdream/src/drivers/video_egl.c
@@ -126,6 +126,7 @@
</small></pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" > display_egl_driver.capabilities.depth_bits = 16; /* TODO: get from config info */
gl_fbo_init(&display_egl_driver);
gl_vbo_init(&display_egl_driver);
</pre><pre id="added" class="diff" style="margin:0; background-color:#ddffdd;" >+ glsl_init(&display_egl_driver);
</pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" > fbo_created = TRUE;
} else {
ERROR( "Display does not support FBO" );
</pre></div>
<hr /><a name="file3" /><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/drivers</span><br />
<div class="fileheader" style="margin-bottom:.5em;" ><big><b>video_gl.c</b></big> <small id="info" style="color: #888888;" >d63f73cc586f -> a9d29fe74bf3</small></div>
<pre class="diff" style="margin:0;" ><small id="info" style="color: #888888;" >--- lxdream/src/drivers/video_gl.c
+++ lxdream/src/drivers/video_gl.c
@@ -272,6 +272,7 @@
</small></pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" > display_gl_driver.capabilities.has_gl = TRUE;
gl_fbo_init(&display_gl_driver);
gl_vbo_init(&display_gl_driver);
</pre><pre id="added" class="diff" style="margin:0; background-color:#ddffdd;" >+ glsl_init(&display_gl_driver);
</pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" > return TRUE;
} else {
return FALSE;
</pre></div>
<hr /><a name="file4" /><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/drivers</span><br />
<div class="fileheader" style="margin-bottom:.5em;" ><big><b>video_glx.c</b></big> <small id="info" style="color: #888888;" >d63f73cc586f -> a9d29fe74bf3</small></div>
<pre class="diff" style="margin:0;" ><small id="info" style="color: #888888;" >--- lxdream/src/drivers/video_glx.c
+++ lxdream/src/drivers/video_glx.c
@@ -250,6 +250,7 @@
</small></pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" > return FALSE;
}
gl_vbo_init(driver);
</pre><pre id="added" class="diff" style="margin:0; background-color:#ddffdd;" >+ glsl_init(driver);
</pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" > return TRUE;
}
</pre></div>
<hr /><a name="file5" /><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/drivers</span><br />
<div class="fileheader" style="margin-bottom:.5em;" ><big><b>video_nsgl.m</b></big> <small id="info" style="color: #888888;" >d63f73cc586f -> a9d29fe74bf3</small></div>
<pre class="diff" style="margin:0;" ><small id="info" style="color: #888888;" >--- lxdream/src/drivers/video_nsgl.m
+++ lxdream/src/drivers/video_nsgl.m
@@ -54,6 +54,7 @@
</small></pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" > return FALSE;
}
gl_vbo_init(driver);
</pre><pre id="added" class="diff" style="margin:0; background-color:#ddffdd;" >+ glsl_init(driver);
</pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" >
return TRUE;
}
</pre></div>
<hr /><a name="file6" /><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>gl_sl.c</b></big> <small id="info" style="color: #888888;" >d63f73cc586f -> a9d29fe74bf3</small></div>
<pre class="diff" style="margin:0;" ><small id="info" style="color: #888888;" >--- lxdream/src/pvr2/gl_sl.c
+++ lxdream/src/pvr2/gl_sl.c
@@ -492,3 +492,21 @@
</small></pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" > glsl_use_program(0);
}
</pre><pre id="added" class="diff" style="margin:0; background-color:#ddffdd;" >+gboolean glsl_init( display_driver_t driver )
+{
+ gboolean result;
+ if( glsl_is_supported() && isGLMultitextureSupported() ) {
+ if( !glsl_load_shaders( ) ) {
+ WARN( "Unable to load GL shaders" );
+ result = FALSE;
+ } else {
+ INFO( "Shaders loaded successfully" );
+ result = TRUE;
+ }
+ } else {
+ INFO( "Shaders not supported" );
+ result = FALSE;
+ }
+ driver->capabilities.has_sl = result;
+ return result;
+}
</pre></div>
<hr /><a name="file7" /><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>glrender.c</b></big> <small id="info" style="color: #888888;" >d63f73cc586f -> a9d29fe74bf3</small></div>
<pre class="diff" style="margin:0;" ><small id="info" style="color: #888888;" >--- lxdream/src/pvr2/glrender.c
+++ lxdream/src/pvr2/glrender.c
@@ -115,21 +115,10 @@
</small></pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" > */
void pvr2_setup_gl_context()
{
</pre><pre id="removed" class="diff" style="margin:0; background-color:#ffdddd;" >- if( glsl_is_supported() && isGLMultitextureSupported() ) {
- if( !glsl_load_shaders( ) ) {
- WARN( "Unable to load GL shaders" );
- } else {
- INFO( "Shaders loaded successfully" );
- have_shaders = TRUE;
- }
- } else {
- INFO( "Shaders not supported" );
- }
-
</pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" > #ifdef APPLE_BUILD
CGL_MACRO_CONTEXT = CGLGetCurrentContext();
#endif
</pre><pre id="removed" class="diff" style="margin:0; background-color:#ffdddd;" >- texcache_gl_init(<span id="removedchars" style="background-color:#ff9999;font-weight:bolder;" >have_shaders</span>); // Allocate texture IDs
</pre><pre id="added" class="diff" style="margin:0; background-color:#ddffdd;" >+ texcache_gl_init(); // Allocate texture IDs
</pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" >
/* Global settings */
glDisable( GL_CULL_FACE );
</pre></div>
<hr /><a name="file8" /><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>glutil.h</b></big> <small id="info" style="color: #888888;" >d63f73cc586f -> a9d29fe74bf3</small></div>
<pre class="diff" style="margin:0;" ><small id="info" style="color: #888888;" >--- lxdream/src/pvr2/glutil.h
+++ lxdream/src/pvr2/glutil.h
@@ -136,6 +136,7 @@
</small></pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" >
/****** Shader handling (gl_sl.c) *****/
</pre><pre id="added" class="diff" style="margin:0; background-color:#ddffdd;" >+gboolean glsl_init( display_driver_t driver );
</pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" > gboolean glsl_is_supported(void);
const char *glsl_get_version(void);
gboolean glsl_load_shaders( );
</pre></div>
<hr /><a name="file9" /><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>pvr2.h</b></big> <small id="info" style="color: #888888;" >d63f73cc586f -> a9d29fe74bf3</small></div>
<pre class="diff" style="margin:0;" ><small id="info" style="color: #888888;" >--- lxdream/src/pvr2/pvr2.h
+++ lxdream/src/pvr2/pvr2.h
@@ -316,7 +316,7 @@
</small></pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" > /**
* Initialize the GL side of the texture cache (texture ids and such).
*/
</pre><pre id="removed" class="diff" style="margin:0; background-color:#ffdddd;" >-void texcache_gl_init( gboolean withShaders );
</pre><pre id="added" class="diff" style="margin:0; background-color:#ddffdd;" >+void texcache_gl_init( );
</pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" >
/**
* Flush all textures and delete. The cache will be non-functional until
</pre></div>
<hr /><a name="file10" /><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;" >d63f73cc586f -> a9d29fe74bf3</small></div>
<pre class="diff" style="margin:0;" ><small id="info" style="color: #888888;" >--- lxdream/src/pvr2/texcache.c
+++ lxdream/src/pvr2/texcache.c
@@ -89,12 +89,12 @@
</small></pre><pre id="context" class="diff" style="margin:0; background-color:#eeeeee;" > * Setup the initial texture ids (must be called after the GL context is
* prepared)
*/
</pre><pre id="removed" class="diff" style="margin:0; background-color:#ffdddd;" >-void texcache_gl_init( gboolean withShaders )
</pre><pre id="added" class="diff" style="margin:0; background-color:#ddffdd;" >+void texcache_gl_init( )
</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( withShaders ) {
</pre><pre id="added" class="diff" style="margin:0; background-color:#ddffdd;" >+ if( display_driver->capabilities.has_sl ) {
</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></div>
<center><small>Chaos Theory</small></center>
</div></body></html>