aboutsummaryrefslogtreecommitdiffstats
path: root/src/classes/com/sun/opengl/impl/macosx
diff options
context:
space:
mode:
Diffstat (limited to 'src/classes/com/sun/opengl/impl/macosx')
-rw-r--r--src/classes/com/sun/opengl/impl/macosx/MacOSXGLContext.java12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/classes/com/sun/opengl/impl/macosx/MacOSXGLContext.java b/src/classes/com/sun/opengl/impl/macosx/MacOSXGLContext.java
index 16855efb8..02bf81f2e 100644
--- a/src/classes/com/sun/opengl/impl/macosx/MacOSXGLContext.java
+++ b/src/classes/com/sun/opengl/impl/macosx/MacOSXGLContext.java
@@ -277,6 +277,18 @@ public abstract class MacOSXGLContext extends GLContextImpl
return (nsContext != 0);
}
+ public void copy(GLContext source, int mask) throws GLException {
+ long dst = getNSContext();
+ long src = ((MacOSXGLContext) source).getNSContext();
+ if (src == 0) {
+ throw new GLException("Source OpenGL context has not been created");
+ }
+ if (dst == 0) {
+ throw new GLException("Destination OpenGL context has not been created");
+ }
+ CGL.copyContext(dst, src, mask);
+ }
+
protected void resetGLFunctionAvailability()
{
super.resetGLFunctionAvailability();