|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.jogamp.newt.util.ScreenModeUtil
public class ScreenModeUtil
Convenient ScreenMode
utility methods,
filters etc.
Field Summary | |
---|---|
static int |
NUM_MONITOR_MODE_PROPERTIES
WARNING: must be synchronized with ScreenMode.h, native implementation 3: ScreenSizeMM[width, height], refresh-rate |
static int |
NUM_RESOLUTION_PROPERTIES
WARNING: must be synchronized with ScreenMode.h, native implementation 2: width and height |
static int |
NUM_SCREEN_MODE_PROPERTIES
WARNING: must be synchronized with ScreenMode.h, native implementation 1: rotation, native_mode_id |
static int |
NUM_SCREEN_MODE_PROPERTIES_ALL
WARNING: must be synchronized with ScreenMode.h, native implementation count + all the above |
static int |
NUM_SURFACE_SIZE_PROPERTIES
WARNING: must be synchronized with ScreenMode.h, native implementation 1: bpp |
Constructor Summary | |
---|---|
ScreenModeUtil()
|
Method Summary | |
---|---|
static List<ScreenMode> |
filterByBpp(List<ScreenMode> screenModes,
int bitsPerPixel)
|
static List<ScreenMode> |
filterByRate(List<ScreenMode> screenModes,
int refreshRate)
|
static List<ScreenMode> |
filterByResolution(List<ScreenMode> screenModes,
DimensionImmutable resolution)
|
static List<ScreenMode> |
filterByRotation(List<ScreenMode> screenModes,
int rotation)
|
static List<ScreenMode> |
filterBySurfaceSize(List<ScreenMode> screenModes,
SurfaceSize surfaceSize)
|
static List<ScreenMode> |
getHighestAvailableBpp(List<ScreenMode> screenModes)
|
static List<ScreenMode> |
getHighestAvailableRate(List<ScreenMode> screenModes)
|
static int |
getIndex(List<ScreenMode> screenModes,
ScreenMode search)
|
static int |
getIndexByHashCode(List<ScreenMode> screenModes,
ScreenMode search)
|
static int |
streamIn(com.jogamp.common.util.ArrayHashSet<DimensionImmutable> resolutionPool,
com.jogamp.common.util.ArrayHashSet<SurfaceSize> surfaceSizePool,
com.jogamp.common.util.ArrayHashSet<DimensionImmutable> screenSizeMMPool,
com.jogamp.common.util.ArrayHashSet<MonitorMode> monitorModePool,
com.jogamp.common.util.ArrayHashSet<ScreenMode> screenModePool,
int[] modeProperties,
int offset)
WARNING: must be synchronized with ScreenMode.h, native implementation |
static ScreenMode |
streamIn(int[] modeProperties,
int offset)
WARNING: must be synchronized with ScreenMode.h, native implementation |
static MonitorMode |
streamInMonitorMode(SurfaceSize surfaceSize,
DimensionImmutable screenSizeMM,
int[] monitorProperties,
int offset)
WARNING: must be synchronized with ScreenMode.h, native implementation |
static DimensionImmutable |
streamInResolution(int[] resolutionProperties,
int offset)
WARNING: must be synchronized with ScreenMode.h, native implementation |
static ScreenMode |
streamInScreenMode(MonitorMode monitorMode,
int[] modeProperties,
int offset)
WARNING: must be synchronized with ScreenMode.h, native implementation |
static SurfaceSize |
streamInSurfaceSize(DimensionImmutable resolution,
int[] sizeProperties,
int offset)
WARNING: must be synchronized with ScreenMode.h, native implementation |
static int[] |
streamOut(ScreenMode screenMode)
WARNING: must be synchronized with ScreenMode.h, native implementation |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int NUM_RESOLUTION_PROPERTIES
public static final int NUM_SURFACE_SIZE_PROPERTIES
public static final int NUM_MONITOR_MODE_PROPERTIES
public static final int NUM_SCREEN_MODE_PROPERTIES
public static final int NUM_SCREEN_MODE_PROPERTIES_ALL
Constructor Detail |
---|
public ScreenModeUtil()
Method Detail |
---|
public static int getIndex(List<ScreenMode> screenModes, ScreenMode search)
public static int getIndexByHashCode(List<ScreenMode> screenModes, ScreenMode search)
public static List<ScreenMode> filterByResolution(List<ScreenMode> screenModes, DimensionImmutable resolution)
screenModes
- resolution
-
public static List<ScreenMode> filterBySurfaceSize(List<ScreenMode> screenModes, SurfaceSize surfaceSize)
public static List<ScreenMode> filterByRotation(List<ScreenMode> screenModes, int rotation)
public static List<ScreenMode> filterByBpp(List<ScreenMode> screenModes, int bitsPerPixel)
public static List<ScreenMode> filterByRate(List<ScreenMode> screenModes, int refreshRate)
screenModes
- refreshRate
-
public static List<ScreenMode> getHighestAvailableBpp(List<ScreenMode> screenModes)
public static List<ScreenMode> getHighestAvailableRate(List<ScreenMode> screenModes)
public static DimensionImmutable streamInResolution(int[] resolutionProperties, int offset)
public static SurfaceSize streamInSurfaceSize(DimensionImmutable resolution, int[] sizeProperties, int offset)
public static MonitorMode streamInMonitorMode(SurfaceSize surfaceSize, DimensionImmutable screenSizeMM, int[] monitorProperties, int offset)
public static ScreenMode streamInScreenMode(MonitorMode monitorMode, int[] modeProperties, int offset)
public static ScreenMode streamIn(int[] modeProperties, int offset)
modeProperties
- the input dataoffset
- the offset to the input data
modeProperties
,
or null if input could not be processed.public static int streamIn(com.jogamp.common.util.ArrayHashSet<DimensionImmutable> resolutionPool, com.jogamp.common.util.ArrayHashSet<SurfaceSize> surfaceSizePool, com.jogamp.common.util.ArrayHashSet<DimensionImmutable> screenSizeMMPool, com.jogamp.common.util.ArrayHashSet<MonitorMode> monitorModePool, com.jogamp.common.util.ArrayHashSet<ScreenMode> screenModePool, int[] modeProperties, int offset)
resolutionPool
- hash array of unique resolutions, no duplicatessurfaceSizePool
- hash array of unique SurfaceSize, no duplicatesmonitorModePool
- hash array of unique MonitorMode, no duplicatesscreenModePool
- hash array of unique ScreenMode, no duplicatesmodeProperties
- the input dataoffset
- the offset to the input data
screenModePool
,
matching the input modeProperties
, or -1 if input could not be processed.public static int[] streamOut(ScreenMode screenMode)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |