Select a fir by mouse click using glReadPixels
Tools: SDL3, Emscripten, C++, CMake, OpenGL ES 2.0, GLM, and stb_image

Select a fir by mouse click using glReadPixels
Tools: SDL3, Emscripten, C++, CMake, OpenGL ES 2.0, GLM, and stb_image

Click buttons with color ID using glReadPixels
This example uses the following GUI asset: Free UI Hologram Interface by Wenrexa. You can find a lot of GUI assets on itch: Top game assets tagged Graphical User Interface (GUI) - itch.io I packed the GUI textures using Free Texture Packer to one texture + JSON. RapidJSON is used to parse the JSON file.
Tools: SDL3, Emscripten, C++, CMake, OpenGL ES 2.0, GLM, stb_image, Free Texture Packer, and RapidJSON

A new version: Deploying SDL3 app on Android using SDL3-x.y.z.aar
New version for SDL 3.3: Setting Up SDL 3.3 for Android Development
Result of testing: Discord
Testing of the GitHub - madebr/sdlcross: Little SDL application buildable on Desktop + Android example with SDL3 Renderer API that shows squares when we touch the screen:

Example in pure OpenGL ES 2.0 that draws a simple green triangle:
I used the https://github.com/Genymobile/scrcpy app to create a screenshot on PC using USB cable from the phone.
Added the following info to the guide: Setting Up SDL 3.3 for Android Development
CMakeLists.txt:# Declare the project
project(my-project)
.java file located at app\src\main\java\com\example\sdlcross, inside the getLibraries() method:package com.example.sdlcross;
import org.libsdl.app.SDLActivity;
public class MyActivity extends SDLActivity {
protected String[] getLibraries() {
return new String[] { "my-project" };
}
}
There is my mistake above. The executable name should be the same with the return new String[] { "sdlcross" };:
CMakeLists.txt:add_executable(sdlcross src/main.c)
.java file located at app\src\main\java\com\example\sdlcross, inside the getLibraries() method:package com.example.sdlcross;
import org.libsdl.app.SDLActivity;
public class MyActivity extends SDLActivity {
protected String[] getLibraries() {
return new String[] { "sdlcross" };
}
}
Note. The SDL 3.3 is not release yet. I call the currect master branch like 3.3.