JOGL v2.6.0-rc-20250706
JOGL, High-Performance Graphics Binding for Java™ (public API).
GLOffscreenAutoDrawable.java
Go to the documentation of this file.
1/**
2 * Copyright 2012 JogAmp Community. All rights reserved.
3 *
4 * Redistribution and use in source and binary forms, with or without modification, are
5 * permitted provided that the following conditions are met:
6 *
7 * 1. Redistributions of source code must retain the above copyright notice, this list of
8 * conditions and the following disclaimer.
9 *
10 * 2. Redistributions in binary form must reproduce the above copyright notice, this list
11 * of conditions and the following disclaimer in the documentation and/or other materials
12 * provided with the distribution.
13 *
14 * THIS SOFTWARE IS PROVIDED BY JogAmp Community ``AS IS'' AND ANY EXPRESS OR IMPLIED
15 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
16 * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JogAmp Community OR
17 * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
18 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
19 * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
20 * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
21 * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
22 * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
23 *
24 * The views and conclusions contained in the software and documentation are those of the
25 * authors and should not be interpreted as representing official policies, either expressed
26 * or implied, of JogAmp Community.
27 */
28
29package com.jogamp.opengl;
30
31import com.jogamp.nativewindow.NativeWindowException;
32
33/**
34 * Platform-independent {@link GLAutoDrawable} specialization,
35 * exposing offscreen functionality.
36 * <p>
37 * This class distinguishes itself from {@link GLAutoDrawable}
38 * with it's {@link #setSurfaceSize(int, int)} functionality.
39 * </p>
40 * <p>
41 * <a name="contextSharing"><h5>OpenGL Context Sharing</h5></a>
42 * To share a {@link GLContext} see the following note in the documentation overview:
43 * <a href="../../../overview-summary.html#SHARING">context sharing</a>
44 * as well as {@link GLSharedContextSetter}.
45 * </p>
46 */
48
49 /**
50 * Resize this {@link GLAutoDrawable}'s surface
51 * @param newWidth new width in pixel units
52 * @param newHeight new height in pixel units
53 * @throws NativeWindowException in case the surface could no be locked
54 * @throws GLException in case of an error during the resize operation
55 */
56 void setSurfaceSize(int newWidth, int newHeight) throws NativeWindowException, GLException;
57
58 /**
59 * Set the upstream UI toolkit object.
60 * @see #getUpstreamWidget()
61 */
62 void setUpstreamWidget(Object newUpstreamWidget);
63
64 /** {@link FBObject} based {@link GLOffscreenAutoDrawable} specialization */
65 public interface FBO extends GLOffscreenAutoDrawable, GLFBODrawable {
66 }
67}
A generic exception for OpenGL errors used throughout the binding as a substitute for RuntimeExceptio...
A generic exception for OpenGL errors used throughout the binding as a substitute for RuntimeExceptio...
A higher-level abstraction than GLDrawable which supplies an event based mechanism (GLEventListener) ...
Platform-independent GLDrawable specialization, exposing FBObject functionality.
FBObject based GLOffscreenAutoDrawable specialization
Platform-independent GLAutoDrawable specialization, exposing offscreen functionality.
void setUpstreamWidget(Object newUpstreamWidget)
Set the upstream UI toolkit object.
void setSurfaceSize(int newWidth, int newHeight)
Resize this GLAutoDrawable's surface.
Adds capabilities to set a shared GLContext directly or via an GLAutoDrawable.