Top Fields Constructors Methods
com.jogamp.nativewindow

public Class UpstreamSurfaceHookMutableSize

extends Object
implements MutableSize
Class Inheritance
All Implemented Interfaces
com.jogamp.nativewindow.UpstreamSurfaceHook.MutableSize, com.jogamp.nativewindow.UpstreamSurfaceHook
Known Direct Subclasses
com.jogamp.nativewindow.UpstreamWindowHookMutableSizePos, jogamp.nativewindow.macosx.OSXDummyUpstreamSurfaceHook, jogamp.nativewindow.windows.GDIDummyUpstreamSurfaceHook, jogamp.nativewindow.x11.X11DummyUpstreamSurfaceHook, jogamp.opengl.egl.EGLDummyUpstreamSurfaceHook, com.jogamp.nativewindow.DelegatedUpstreamSurfaceHookMutableSize, com.jogamp.nativewindow.GenericUpstreamSurfacelessHook
Imports
com.jogamp.nativewindow.NativeSurface, .ProxySurface, .UpstreamSurfaceHook

Field Summary

Modifier and TypeField and Description
pack-priv int
pack-priv int

Constructor Summary

AccessConstructor and Description
public
UpstreamSurfaceHookMutableSize(final int
initial width
width
,
final int
initial height
height
)

Method Summary

Modifier and TypeMethod and Description
public void
create(final ProxySurface s)

Implements com.jogamp.nativewindow.UpstreamSurfaceHook.create.

called within ProxySurface#createNotify() within lock, before using surface.
public void
destroy(final ProxySurface s)

Implements com.jogamp.nativewindow.UpstreamSurfaceHook.destroy.

called within ProxySurface#destroyNotify() within lock, before clearing fields.
public final int
getSurfaceHeight(final ProxySurface s)

Implements com.jogamp.nativewindow.UpstreamSurfaceHook.getSurfaceHeight.

Returns the height of the upstream surface in pixels, used if ProxySurface#UPSTREAM_PROVIDES_SIZE is set.
public final int
getSurfaceWidth(final ProxySurface s)

Implements com.jogamp.nativewindow.UpstreamSurfaceHook.getSurfaceWidth.

Returns the width of the upstream surface in pixels, used if ProxySurface#UPSTREAM_PROVIDES_SIZE is set.
public final NativeSurface
getUpstreamSurface()

Implements com.jogamp.nativewindow.UpstreamSurfaceHook.getUpstreamSurface.

Returns the optional upstream NativeSurface if used by implementation, otherwise null.
public final void
setSurfaceSize(final int
new width in pixel units
width
,
final int
new height in pixel units
height
)

Implements com.jogamp.nativewindow.UpstreamSurfaceHook.MutableSize.setSurfaceSize.

Resizes the upstream surface.
public String
toString()

Overrides java.lang.Object.toString.

Returns a string representation of the object.
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAllwaitwaitwait

Field Detail

pixHeightback to summary
pack-priv int pixHeight
pixWidthback to summary
pack-priv int pixWidth

Constructor Detail

UpstreamSurfaceHookMutableSizeback to summary
public UpstreamSurfaceHookMutableSize(final int width, final int height)
Parameters
width:int

initial width

height:int

initial height

Method Detail

createback to summary
public void create(final ProxySurface s)

Implements com.jogamp.nativewindow.UpstreamSurfaceHook.create.

Doc from com.jogamp.nativewindow.UpstreamSurfaceHook.create.

called within ProxySurface#createNotify() within lock, before using surface.

Annotations
@Override
destroyback to summary
public void destroy(final ProxySurface s)

Implements com.jogamp.nativewindow.UpstreamSurfaceHook.destroy.

Doc from com.jogamp.nativewindow.UpstreamSurfaceHook.destroy.

called within ProxySurface#destroyNotify() within lock, before clearing fields.

Annotations
@Override
getSurfaceHeightback to summary
public final int getSurfaceHeight(final ProxySurface s)

Implements com.jogamp.nativewindow.UpstreamSurfaceHook.getSurfaceHeight.

Doc from com.jogamp.nativewindow.UpstreamSurfaceHook.getSurfaceHeight.

Returns the height of the upstream surface in pixels, used if ProxySurface#UPSTREAM_PROVIDES_SIZE is set.

Annotations
@Override
getSurfaceWidthback to summary
public final int getSurfaceWidth(final ProxySurface s)

Implements com.jogamp.nativewindow.UpstreamSurfaceHook.getSurfaceWidth.

Doc from com.jogamp.nativewindow.UpstreamSurfaceHook.getSurfaceWidth.

Returns the width of the upstream surface in pixels, used if ProxySurface#UPSTREAM_PROVIDES_SIZE is set.

Annotations
@Override
getUpstreamSurfaceback to summary
public final NativeSurface getUpstreamSurface()

Implements com.jogamp.nativewindow.UpstreamSurfaceHook.getUpstreamSurface.

Doc from com.jogamp.nativewindow.UpstreamSurfaceHook.getUpstreamSurface.

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

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

Returns null.

Annotations
@Override
setSurfaceSizeback to summary
public final void setSurfaceSize(final int width, final int height)

Implements com.jogamp.nativewindow.UpstreamSurfaceHook.MutableSize.setSurfaceSize.

Doc from com.jogamp.nativewindow.UpstreamSurfaceHook.MutableSize.setSurfaceSize.

Resizes the upstream surface.

Parameters
width:int

new width in pixel units

height:int

new height in pixel units

Annotations
@Override
toStringback to summary
public String toString()

Overrides java.lang.Object.toString.

Doc from java.lang.Object.toString.

Returns a string representation of the object.

Returns:String

a string representation of the object

Annotations
@Override