org.jrabbit.base.managers.window
Class WindowUtils.DisplayModeRank

java.lang.Object
  extended by org.jrabbit.base.managers.window.WindowUtils.DisplayModeRank
Enclosing class:
WindowUtils

private static class WindowUtils.DisplayModeRank
extends java.lang.Object

An internal class used to simplify finding the closest DisplayMode to an unobtainable target resolution.

Author:
Chris Molini

Field Summary
private  org.lwjgl.opengl.DisplayMode displayMode
          The DisplayMode this ranking represents.
private  int heightRanking
          The amount the indicated DisplayMode is off the target height.
private  int widthRanking
          The amount the indicated DisplayMode is off the target width.
 
Constructor Summary
private WindowUtils.DisplayModeRank(org.lwjgl.opengl.DisplayMode dM, int width, int height)
          Calculates a DisplayModeRanking from the indicated values.
 
Method Summary
private  WindowUtils.DisplayModeRank chooseBetter(WindowUtils.DisplayModeRank dM)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

widthRanking

private int widthRanking
The amount the indicated DisplayMode is off the target width.


heightRanking

private int heightRanking
The amount the indicated DisplayMode is off the target height.


displayMode

private org.lwjgl.opengl.DisplayMode displayMode
The DisplayMode this ranking represents.

Constructor Detail

WindowUtils.DisplayModeRank

private WindowUtils.DisplayModeRank(org.lwjgl.opengl.DisplayMode dM,
                                    int width,
                                    int height)
Calculates a DisplayModeRanking from the indicated values.

Parameters:
dM - The DisplayMode to represent.
width - The target resolution width.
height - The target resolution height.
Method Detail

chooseBetter

private WindowUtils.DisplayModeRank chooseBetter(WindowUtils.DisplayModeRank dM)