@@ -1795,7 +1795,13 @@ def book_path(*pathelems):
1795
1795
args = args )
1796
1796
1797
1797
@requires_graphics_hardware
1798
- def test_gles2_emulation (self ):
1798
+ @parameterized ({
1799
+ 'normal' : (['-s' , 'FULL_ES2=1' ],),
1800
+ # Enabling FULL_ES3 also enables ES2 automatically
1801
+ 'full_es3' : (['-s' , 'FULL_ES3=1' ],)
1802
+ })
1803
+ def test_gles2_emulation (self , args ):
1804
+ print (args )
1799
1805
shutil .copyfile (path_from_root ('tests' , 'glbook' , 'Chapter_10' , 'MultiTexture' , 'basemap.tga' ), 'basemap.tga' )
1800
1806
shutil .copyfile (path_from_root ('tests' , 'glbook' , 'Chapter_10' , 'MultiTexture' , 'lightmap.tga' ), 'lightmap.tga' )
1801
1807
shutil .copyfile (path_from_root ('tests' , 'glbook' , 'Chapter_13' , 'ParticleSystem' , 'smoke.tga' ), 'smoke.tga' )
@@ -1817,13 +1823,12 @@ def test_gles2_emulation(self):
1817
1823
path_from_root ('tests' , 'glbook' , 'Common' , 'esShader.c' ),
1818
1824
path_from_root ('tests' , 'glbook' , 'Common' , 'esShapes.c' ),
1819
1825
path_from_root ('tests' , 'glbook' , 'Common' , 'esTransform.c' ),
1820
- '-s' , 'FULL_ES2=1' , '- lGL' , '-lEGL' , '-lX11' ,
1821
- '--preload-file' , 'basemap.tga' , '--preload-file' , 'lightmap.tga' , '--preload-file' , 'smoke.tga' ])
1826
+ '-lGL' , '-lEGL' , '-lX11' ,
1827
+ '--preload-file' , 'basemap.tga' , '--preload-file' , 'lightmap.tga' , '--preload-file' , 'smoke.tga' ] + args )
1822
1828
1823
1829
@requires_graphics_hardware
1824
1830
def test_clientside_vertex_arrays_es3 (self ):
1825
- # NOTE: Should FULL_ES3=1 imply client-side vertex arrays? The emulation needs FULL_ES2=1 for now.
1826
- self .btest ('clientside_vertex_arrays_es3.c' , reference = 'gl_triangle.png' , args = ['-s' , 'USE_WEBGL2=1' , '-s' , 'FULL_ES2=1' , '-s' , 'FULL_ES3=1' , '-s' , 'USE_GLFW=3' , '-lglfw' , '-lGLESv2' ])
1831
+ self .btest ('clientside_vertex_arrays_es3.c' , reference = 'gl_triangle.png' , args = ['-s' , 'USE_WEBGL2=1' , '-s' , 'FULL_ES3=1' , '-s' , 'USE_GLFW=3' , '-lglfw' , '-lGLESv2' ])
1827
1832
1828
1833
def test_emscripten_api (self ):
1829
1834
self .btest ('emscripten_api_browser.cpp' , '1' , args = ['-s' , '''EXPORTED_FUNCTIONS=['_main', '_third']''' , '-lSDL' ])
0 commit comments