Enabling GLES20 error

Monkey Targets Forums/Android/Enabling GLES20 error

Panda(Posted 2012) [#1]
Hi guys

I wanted to try the GLES20 option added to recent Monkey versions. If I add the following config to any of the Monkey demos (horsey, spiralmatrix, etc):

#OPENGL_GLES20_ENABLED="true"


and build for my Android device (Samsung Galaxy S 2), the app just shows:

Monkey runtime error: Rendering operations can only be performed inside OnRender
modules/mojo/graphics.monkey<241>
modules/mojo/graphics.monkey<391>
...


The stacktrace relates to:

Function DebugRenderDevice()
	If Not renderDevice Error "Rendering operations can only be performed inside OnRender"
End


and

Function Cls( r#=0,g#=0,b#=0 )
#If CONFIG="debug"
	DebugRenderDevice


Does this mean Monkey is not identifying the SGS2 as a GLES20 device?


marksibly(Posted 2012) [#2]
Hi,

You cannot use mojo with gles2, only gles1.1.

gles2 apps must use 'pure' gl.