Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[rlgl] Adding warnings in case OpenGL 4.3 is not enabled #4202

Merged
merged 2 commits into from
Aug 9, 2024

Conversation

MaximKn1
Copy link
Contributor

@MaximKn1 MaximKn1 commented Aug 1, 2024

Hi
I added warnings for the functionality related to OpenGL 4.3 features in case GRAPHICS_API_OPENGL_43 is not defined.

Personally, been struggling to make compute shaders work, only to discover that I am not on the correct API version (as the default one is 3.3). I think it is better to add some logging to notify about incorrect OpenGL version. Currently 4.3 related functions are virtually empty if you are not using 4.3 and you can call them even if you are on 3.3. Shader compiler even says it managed to compile a compute shader when using 3.3.

@raysan5
Copy link
Owner

raysan5 commented Aug 4, 2024

@MaximKn1 Some of those warnings could spam the log if the functions are called every frame, please, remove the ones from functions that can potentially be called on a frame basis.

@MaximKn1
Copy link
Contributor Author

MaximKn1 commented Aug 7, 2024

@raysan5 Removed logging as you suggested, except rlBindImageTexture, because as far as I can tell, there is no way to tell if proper OpenGL version is used for this functionality before calling it.

@raysan5 raysan5 merged commit 2590a30 into raysan5:master Aug 9, 2024
@raysan5
Copy link
Owner

raysan5 commented Aug 9, 2024

@MaximKn1 Thanks for the review!

@raysan5
Copy link
Owner

raysan5 commented Aug 9, 2024

@MaximKn1 I'm afraid this PR breaks raylib compilation for web, please, could you review it?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants