Browse Source

Cleanups.

Mark Sibly 8 years ago
parent
commit
343a446420

+ 4 - 4
modules/mojo/graphics/glexts/glexts.cpp

@@ -5,8 +5,8 @@
 #include <stdlib.h>
 #include <string.h>
 
-void* SDL_GL_GetProcAddress( const char *proc );
-int SDL_GL_ExtensionSupported( const char *extension );
+extern "C" void* SDL_GL_GetProcAddress( const char *proc );
+extern "C" int SDL_GL_ExtensionSupported( const char *extension );
 
 namespace bbGLexts{
 
@@ -19,11 +19,11 @@ namespace bbGLexts{
 	
 	void init(){
 	
-		if( GL_draw_buffers=SDL_GL_ExtensionSupported( "GL_EXT_draw_buffer" ) ){
+		if( GL_draw_buffers=SDL_GL_ExtensionSupported( "GL_EXT_draw_buffers" ) ){
 			
 			glDrawBuffers=(void(*)(int,const GLenum*)) SDL_GL_GetProcAddress( "glDrawBuffersEXT" );
 			
-		}else if( GL_draw_buffers=SDL_GL_ExtensionSupported( "GL_WEBGL_draw_buffer" ) ){
+		}else if( GL_draw_buffers=SDL_GL_ExtensionSupported( "GL_WEBGL_draw_buffers" ) ){
 		
 			glDrawBuffers=(void(*)(int,const GLenum*)) SDL_GL_GetProcAddress( "glDrawBuffersWEBGL" );
 		}

+ 2 - 2
modules/mojo/graphics/glexts/glexts.monkey2

@@ -1,7 +1,7 @@
 
 Namespace mojo.graphics.glexts
 
-#If __TARGET__="windows" Or __WEB_TARGET__
+#If __TARGET__="windows" Or __MOBILE_TARGET__ Or __WEB_TARGET__
 
 #Import "glexts.cpp"
 #Import "glexts.h"
@@ -29,7 +29,7 @@ Const GL_COLOR_ATTACHMENT13:Int=$8CED
 Const GL_COLOR_ATTACHMENT14:Int=$8CEE
 Const GL_COLOR_ATTACHMENT15:Int=$8CEF
 
-#If __TARGET__="windows" Or __WEB_TARGET__
+#If __TARGET__="windows" Or __MOBILE_TARGET__ Or __WEB_TARGET__
 
 Extern
 

+ 0 - 2
modules/mojo/graphics/rendertarget.monkey2

@@ -5,8 +5,6 @@ Class RenderTarget Extends Resource
 	
 	Method New( colorTextures:Texture[],depthTexture:Texture )
 		
-		Assert( colorTextures.Length<2 Or glexts.GL_draw_buffers,"Multiple render targets not supported" )
-		
 		_colorTextures=colorTextures.Slice( 0 )
 		
 		_depthTexture=depthTexture