mirror of
https://github.com/processing/processing4.git
synced 2026-02-04 06:09:17 +01:00
add getContext() method, and a tweak or two for javadoc
This commit is contained in:
@@ -108,8 +108,8 @@ public class PGraphicsOpenGL extends PGraphics3D {
|
||||
* that is visible on screen in order to work properly.
|
||||
* @param parent the host applet
|
||||
*/
|
||||
public PGraphicsOpenGL(int width, int height, PApplet iparent) {
|
||||
super(width, height, iparent);
|
||||
public PGraphicsOpenGL(int width, int height, PApplet parent) {
|
||||
super(width, height, parent);
|
||||
|
||||
// if (parent == null) {
|
||||
// throw new RuntimeException("PGraphicsOpenGL can only be used " +
|
||||
@@ -278,6 +278,15 @@ public class PGraphicsOpenGL extends PGraphics3D {
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Get the current context, for use by libraries that need to talk to it.
|
||||
* @return
|
||||
*/
|
||||
public GLContext getContext() {
|
||||
return context;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Make the OpenGL rendering context current for this thread.
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user