Commit Graph

10 Commits

Author SHA1 Message Date
Martin Fouilleul d01dc832fb [gles] Support for exposing GLES surfaces to orca apps
- update gles surface example
- add mp_dispatch_on_main_thread_sync() to osx threads
- add /experimental:c11atomics to glesTriangle build.bat
- mp_dispatch_on_main_thread_sync: win32 impl
- move mp_dispatch_on_main_thread_sync() on app layer
- configure dlmalloc to not assume contiguity. This allows us to reserve blocks on our end without trashing malloc-owned zones. This way we can add a block to store GL static strings when needed.
- implement deselect interface
- Log an error when an OpenGL function is called while no OpenGL API is selected, or if that function is not part of the selected API
- avoid dispatching calls to image or canvas API if surface is not selected. However, we could later allow it and temporarily select the surface _on behalf of the user_.
- Adding support for format string and optional parameters in assert macros
2023-08-08 22:15:53 +02:00
martinfouilleul 660ad33ddc [win32, gl canvas] persistently map input buffers 2023-07-12 15:54:02 +02:00
Martin Fouilleul 592f4cdecd end of line renormalization 2023-03-05 16:05:43 +01:00
martinfouilleul 1250dfd7c1 hardcode GL/GLES versions per-platform for now 2023-02-22 18:30:10 +01:00
martinfouilleul 665c63c3d0 [win32 build/link]
- Build milepost as a dynamic library
- Add import/export directives to public API symbols
- Change example build scripts accordingly
2023-02-21 18:43:30 +01:00
martinfouilleul 64d7b31e5c destroy gles surfaces resources 2023-02-20 19:38:24 +01:00
Martin Fouilleul 2232b647ed reintroduced GLES backend to osx 2023-02-20 11:05:01 +01:00
martinfouilleul 20e425494f Use a custom GL loader to allow different versions of GL/GLES APIs to co-exist. The loader fills an api struct with GL functions pointers.
We have a per-thread pointer to select which api struct is used, and GL functions are pound-defined to call the versions in that struct.
GL/GLES surfaces can use one of the loader function to load their api, and the prepare proc of the surface sets its api as the current one
before gl calls are issued.
2023-02-16 19:35:01 +01:00
martinfouilleul 4e816a838b [Clean canvas/shaders]
- Simplified shader names, prefix embedded strings by "glsl_"
- Extracted shader compilation in common function
- Add shader version string and common structs in canvas code rather than in every shader file
- Renamed zIndex with shapeIndex everywhere
2023-02-09 16:14:15 +01:00
martinfouilleul 8e87837fcc working on gles 3.1 canvas on windows 2023-01-31 15:51:50 +01:00