|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectde.lessvoid.nifty.render.ScalingRenderDevice
public class ScalingRenderDevice
Constructor Summary | |
---|---|
ScalingRenderDevice(NiftyRenderEngine renderEngine,
RenderDevice interal)
|
Method Summary | |
---|---|
void |
beginFrame()
Called every begin frame. |
void |
clear()
clear screen. |
RenderFont |
createFont(String filename)
Create a new RenderFont. |
RenderImage |
createImage(String filename,
boolean filterLinear)
Create a new RenderImage. |
MouseCursor |
createMouseCursor(String filename,
int hotspotX,
int hotspotY)
Create a new mouse cursor. |
void |
disableClip()
Disable Clipping. |
void |
disableMouseCursor()
Disable the current mouse cursor. |
void |
enableClip(int x0,
int y0,
int x1,
int y1)
Enable clipping to the given region. |
void |
enableMouseCursor(MouseCursor mouseCursor)
Enable the given mouse cursor. |
void |
endFrame()
Called every end frame. |
int |
getHeight()
Get Height. |
int |
getWidth()
Get Width. |
void |
renderFont(RenderFont font,
String text,
int x,
int y,
Color fontColor,
float sizeX,
float sizeY)
Render the given text at the given position. |
void |
renderImage(RenderImage image,
int x,
int y,
int width,
int height,
Color color,
float imageScale)
Render the image. |
void |
renderImage(RenderImage image,
int x,
int y,
int w,
int h,
int srcX,
int srcY,
int srcW,
int srcH,
Color color,
float scale,
int centerX,
int centerY)
Render a sub image of this image. |
void |
renderQuad(int x,
int y,
int width,
int height,
Color color)
Render a quad. |
void |
renderQuad(int x,
int y,
int width,
int height,
Color topLeft,
Color topRight,
Color bottomRight,
Color bottomLeft)
Render a quad with different colors at the vertices. |
void |
setBlendMode(BlendMode renderMode)
Change the RenderMode to the given Mode. |
void |
setResourceLoader(NiftyResourceLoader niftyResourceLoader)
Gives this RenderDevice access to the NiftyResourceLoader. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ScalingRenderDevice(NiftyRenderEngine renderEngine, RenderDevice interal)
Method Detail |
---|
public void setResourceLoader(NiftyResourceLoader niftyResourceLoader)
RenderDevice
setResourceLoader
in interface RenderDevice
niftyResourceLoader
- NiftyResourceLoaderpublic RenderImage createImage(String filename, boolean filterLinear)
RenderDevice
createImage
in interface RenderDevice
filename
- filenamefilterLinear
- filter
public RenderFont createFont(String filename)
RenderDevice
createFont
in interface RenderDevice
filename
- filename
public int getWidth()
RenderDevice
getWidth
in interface RenderDevice
public int getHeight()
RenderDevice
getHeight
in interface RenderDevice
public void beginFrame()
RenderDevice
beginFrame
in interface RenderDevice
public void endFrame()
RenderDevice
endFrame
in interface RenderDevice
public void clear()
RenderDevice
clear
in interface RenderDevice
public void setBlendMode(BlendMode renderMode)
RenderDevice
setBlendMode
in interface RenderDevice
renderMode
- RenderModepublic void renderQuad(int x, int y, int width, int height, Color color)
RenderDevice
renderQuad
in interface RenderDevice
x
- xy
- ywidth
- widthheight
- heightcolor
- colorpublic void renderQuad(int x, int y, int width, int height, Color topLeft, Color topRight, Color bottomRight, Color bottomLeft)
RenderDevice
renderQuad
in interface RenderDevice
public void renderImage(RenderImage image, int x, int y, int width, int height, Color color, float imageScale)
RenderDevice
renderImage
in interface RenderDevice
x
- xy
- ywidth
- wheight
- hcolor
- colorimageScale
- image scalepublic void renderImage(RenderImage image, int x, int y, int w, int h, int srcX, int srcY, int srcW, int srcH, Color color, float scale, int centerX, int centerY)
RenderDevice
renderImage
in interface RenderDevice
x
- xy
- yw
- wh
- hsrcX
- source xsrcY
- source ysrcW
- source widthsrcH
- source heightcolor
- colorpublic void renderFont(RenderFont font, String text, int x, int y, Color fontColor, float sizeX, float sizeY)
RenderDevice
renderFont
in interface RenderDevice
text
- text to renderx
- x positiony
- y positionfontColor
- font colorpublic void enableClip(int x0, int y0, int x1, int y1)
RenderDevice
enableClip
in interface RenderDevice
x0
- x0y0
- y0x1
- x1y1
- y1public void disableClip()
RenderDevice
disableClip
in interface RenderDevice
public MouseCursor createMouseCursor(String filename, int hotspotX, int hotspotY) throws IOException
RenderDevice
createMouseCursor
in interface RenderDevice
filename
- image file for the cursorhotspotX
- hotspot x with 0 being left of the screenhotspotY
- hotspot y with 0 being top of the screen
IOException
public void enableMouseCursor(MouseCursor mouseCursor)
RenderDevice
enableMouseCursor
in interface RenderDevice
mouseCursor
- the mouse cursor to enablepublic void disableMouseCursor()
RenderDevice
disableMouseCursor
in interface RenderDevice
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |