Top Description Fields Methods
com.jogamp.nativewindow

public Interface ProxySurface

extends MutableSurface
Known Direct Implementers
jogamp.nativewindow.ProxySurfaceImpl
Imports
jogamp.nativewindow.Debug

Provides a mutable NativeSurface, i.e. MutableSurface, while allowing an UpstreamSurfaceHook to influence the lifecycle and information.
See Also
UpstreamSurfaceHook, MutableSurface, NativeSurface

Field Summary

Modifier and TypeField and Description
public static final boolean
public static final int
OPT_PROXY_OWNS_UPSTREAM_DEVICE

Implementation specific bit-value stating this ProxySurface owns the upstream's AbstractGraphicsDevice.

public static final int
OPT_PROXY_OWNS_UPSTREAM_SURFACE

Implementation specific bit-value stating this ProxySurface owns the upstream's surface handle

public static final int
OPT_UPSTREAM_SURFACELESS

Implementation specific bitvalue stating the upstream's NativeSurface's zero handle is valid.

public static final int
OPT_UPSTREAM_WINDOW_INVISIBLE

Implementation specific bitvalue stating the upstream's NativeSurface is an invisible window, i.e. maybe incomplete.

Method Summary

Modifier and TypeMethod and Description
public void
addUpstreamOptionBits(int v)

Add the given bit-mask to this instance upstream-option-bits using bit-or w/ v.

public void
clearUpstreamOptionBits(int v)

Clear the given bit-mask from this instance upstream-option-bits using bit-and w/ ~v

public boolean
containsUpstreamOptionBits(int v)

Returns true if the give bit-mask v is set in this instance upstream-option-bits, otherwise false.

public void
createNotify()

UpstreamSurfaceHook#create(ProxySurface) is being issued and the proxy surface/window handles shall be set.

public void
destroyNotify()

UpstreamSurfaceHook#destroy(ProxySurface) is being issued and all proxy surface/window handles shall be cleared.

public void
public StringBuilder
public int
public NativeSurface
getUpstreamSurface()

Returns the optional upstream NativeSurface if used by implementation, otherwise null.

public UpstreamSurfaceHook
getUpstreamSurfaceHook()

Returns the UpstreamSurfaceHook if set, otherwise null.

public void
setGraphicsConfiguration(AbstractGraphicsConfiguration cfg)

Allow redefining the AbstractGraphicsConfiguration

public void
public StringBuilder
public String
Inherited from com.jogamp.nativewindow.MutableSurface:
setSurfaceHandle

Field Detail

DEBUGback to summary
public static final boolean DEBUG
OPT_PROXY_OWNS_UPSTREAM_DEVICEback to summary
public static final int OPT_PROXY_OWNS_UPSTREAM_DEVICE

Implementation specific bit-value stating this ProxySurface owns the upstream's AbstractGraphicsDevice.

See Also
addUpstreamOptionBits(int), clearUpstreamOptionBits(int), getUpstreamOptionBits()
OPT_PROXY_OWNS_UPSTREAM_SURFACEback to summary
public static final int OPT_PROXY_OWNS_UPSTREAM_SURFACE

Implementation specific bit-value stating this ProxySurface owns the upstream's surface handle

See Also
addUpstreamOptionBits(int), clearUpstreamOptionBits(int), getUpstreamOptionBits()
OPT_UPSTREAM_SURFACELESSback to summary
public static final int OPT_UPSTREAM_SURFACELESS

Implementation specific bitvalue stating the upstream's NativeSurface's zero handle is valid.

See Also
addUpstreamOptionBits(int), clearUpstreamOptionBits(int), getUpstreamOptionBits()
OPT_UPSTREAM_WINDOW_INVISIBLEback to summary
public static final int OPT_UPSTREAM_WINDOW_INVISIBLE

Implementation specific bitvalue stating the upstream's NativeSurface is an invisible window, i.e. maybe incomplete.

See Also
addUpstreamOptionBits(int), clearUpstreamOptionBits(int), getUpstreamOptionBits()

Method Detail

addUpstreamOptionBitsback to summary
public void addUpstreamOptionBits(int v)

Add the given bit-mask to this instance upstream-option-bits using bit-or w/ v.

clearUpstreamOptionBitsback to summary
public void clearUpstreamOptionBits(int v)

Clear the given bit-mask from this instance upstream-option-bits using bit-and w/ ~v

containsUpstreamOptionBitsback to summary
public boolean containsUpstreamOptionBits(int v)

Returns true if the give bit-mask v is set in this instance upstream-option-bits, otherwise false.

createNotifyback to summary
public void createNotify()

UpstreamSurfaceHook#create(ProxySurface) is being issued and the proxy surface/window handles shall be set.

destroyNotifyback to summary
public void destroyNotify()

UpstreamSurfaceHook#destroy(ProxySurface) is being issued and all proxy surface/window handles shall be cleared.

enableUpstreamSurfaceHookLifecycleback to summary
public void enableUpstreamSurfaceHookLifecycle(boolean enable)

Enables or disables the UpstreamSurfaceHook lifecycle functions UpstreamSurfaceHook#create(ProxySurface) and UpstreamSurfaceHook#destroy(ProxySurface).

Use this for small code blocks where the native resources shall not change, i.e. resizing a derived (OpenGL) drawable.

getUpstreamOptionBitsback to summary
public StringBuilder getUpstreamOptionBits(StringBuilder sink)
getUpstreamOptionBitsback to summary
public int getUpstreamOptionBits()
getUpstreamSurfaceback to summary
public NativeSurface getUpstreamSurface()

Returns the optional upstream NativeSurface if used by implementation, otherwise null.

The upstream NativeSurface is retrieved via the UpstreamSurfaceHook, i.e. UpstreamSurfaceHook#getUpstreamSurface().

One example is the JOGL EGLWrappedSurface, which might be backed up by a native platform NativeSurface (X11, WGL, CGL, ..).

getUpstreamSurfaceHookback to summary
public UpstreamSurfaceHook getUpstreamSurfaceHook()

Returns the UpstreamSurfaceHook if set, otherwise null.

setGraphicsConfigurationback to summary
public void setGraphicsConfiguration(AbstractGraphicsConfiguration cfg)

Allow redefining the AbstractGraphicsConfiguration

setUpstreamSurfaceHookback to summary
public void setUpstreamSurfaceHook(UpstreamSurfaceHook hook)

Overrides the UpstreamSurfaceHook.

toStringback to summary
public StringBuilder toString(StringBuilder sink)
toStringback to summary
public String toString()
Annotations
@Override