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

Improve documentation of View.getCurrentGL() #17

Closed
martinpernollet opened this issue Apr 19, 2013 · 0 comments
Closed

Improve documentation of View.getCurrentGL() #17

martinpernollet opened this issue Apr 19, 2013 · 0 comments

Comments

@martinpernollet
Copy link
Contributor

Retrieving current GL imply synchronisation and locking in JOGL. If the user is not aware of this, he/she might encounter exception if the context is not release as expected.

See Britta's report: https://groups.google.com/forum/?fromgroups=#!topic/jzy3d/P7tkJYml428

Might show projectMouse(...) implementation as an example:

public Coord3d projectMouse(int x, int y) {
    GL2 gl = getCurrentGL();
    Coord3d p = cam.screenToModel(gl, glu, new Coord3d((float) x, (float) y, 0));
    getCurrentContext().release();
    return p;
}
@jzy3d jzy3d closed this as completed Jan 23, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants