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

Fixes some bugs in IOSurface #98

Merged
merged 4 commits into from
Jan 13, 2025
Merged

Conversation

webner
Copy link
Contributor

@webner webner commented Jan 13, 2025

This PR fixes some IOSurface bugs on MacOS.

  • The fetchGLTexId method did not work when JavaFX activated another texture unit.
  • Restores the state of the SCISSOR_TEST and restores the active texture

@webner
Copy link
Contributor Author

webner commented Jan 13, 2025

@husker-dev can you take a look at this?

@husker-dev
Copy link
Owner

Hi,
I knew that in IOSurface some OpenGL variables change during manipulations. But is it so critical?
In test cases, there were no problems. Have you encountered cases where it did not work?

Especially interesting with glEnable(GL_SCISSOR_TEST) - I think it is enabled by default in JavaFX, so checking may be unnecessary.

@webner
Copy link
Contributor Author

webner commented Jan 13, 2025

GL_SCISSOR_TEST is not always enabled. It is disabled when the clipRect is null or empty.
See https://github.com/openjdk/jfx/blob/dcfe56bd87ab9160d90b4b0aa634ca0b41788283/modules/javafx.graphics/src/main/java/com/sun/prism/es2/ES2Context.java#L318

@husker-dev
Copy link
Owner

Thank you, I see

@husker-dev husker-dev merged commit 3595ffc into husker-dev:master Jan 13, 2025
@webner
Copy link
Contributor Author

webner commented Jan 13, 2025

Thanks. Could you also create a new release with the last fixes?

@husker-dev
Copy link
Owner

Launched build 4.1.19, in about 20 minutes you can use 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