Package com.jme3.niftygui
Class RenderDeviceJme
java.lang.Object
com.jme3.niftygui.RenderDeviceJme
- All Implemented Interfaces:
de.lessvoid.nifty.spi.render.RenderDevice
-
Constructor Summary
ConstructorDescriptionRenderDeviceJme
(NiftyJmeDisplay display) Instantiates a new RenderDevice, assuming Nifty colors are in linear colorspace (no gamma correction).RenderDeviceJme
(NiftyJmeDisplay display, ColorSpace colorSpace) Instantiates a new RenderDevice using the specified ColorSpace for Nifty colors. -
Method Summary
Modifier and TypeMethodDescriptionvoid
void
clear()
de.lessvoid.nifty.spi.render.RenderFont
createFont
(String filename) de.lessvoid.nifty.spi.render.RenderImage
createImage
(String filename, boolean linear) de.lessvoid.nifty.spi.render.MouseCursor
createMouseCursor
(String str, int x, int y) void
void
void
enableClip
(int x0, int y0, int x1, int y1) void
enableMouseCursor
(de.lessvoid.nifty.spi.render.MouseCursor cursor) void
endFrame()
int
int
getWidth()
void
renderFont
(de.lessvoid.nifty.spi.render.RenderFont font, String str, int x, int y, de.lessvoid.nifty.tools.Color color, float sizeX, float sizeY) void
renderImage
(de.lessvoid.nifty.spi.render.RenderImage image, int x, int y, int w, int h, int srcX, int srcY, int srcW, int srcH, de.lessvoid.nifty.tools.Color color, float scale, int centerX, int centerY) void
renderImage
(de.lessvoid.nifty.spi.render.RenderImage image, int x, int y, int width, int height, de.lessvoid.nifty.tools.Color color, float imageScale) void
renderQuad
(int x, int y, int width, int height, de.lessvoid.nifty.tools.Color color) void
renderQuad
(int x, int y, int width, int height, de.lessvoid.nifty.tools.Color topLeft, de.lessvoid.nifty.tools.Color topRight, de.lessvoid.nifty.tools.Color bottomRight, de.lessvoid.nifty.tools.Color bottomLeft) void
setBlendMode
(de.lessvoid.nifty.render.BlendMode blendMode) void
void
setResourceLoader
(de.lessvoid.nifty.tools.resourceloader.NiftyResourceLoader niftyResourceLoader)
-
Constructor Details
-
RenderDeviceJme
Instantiates a new RenderDevice, assuming Nifty colors are in linear colorspace (no gamma correction).- Parameters:
display
- the SceneProcessor to render Nifty (not null, alias created)
-
RenderDeviceJme
Instantiates a new RenderDevice using the specified ColorSpace for Nifty colors.- Parameters:
display
- the SceneProcessor to render Nifty (not null, alias created)colorSpace
- the ColorSpace to use for Nifty colors (sRGB or Linear)
-
-
Method Details
-
setResourceLoader
public void setResourceLoader(de.lessvoid.nifty.tools.resourceloader.NiftyResourceLoader niftyResourceLoader) - Specified by:
setResourceLoader
in interfacede.lessvoid.nifty.spi.render.RenderDevice
-
setRenderManager
-
createMouseCursor
- Specified by:
createMouseCursor
in interfacede.lessvoid.nifty.spi.render.RenderDevice
-
enableMouseCursor
public void enableMouseCursor(de.lessvoid.nifty.spi.render.MouseCursor cursor) - Specified by:
enableMouseCursor
in interfacede.lessvoid.nifty.spi.render.RenderDevice
-
disableMouseCursor
public void disableMouseCursor()- Specified by:
disableMouseCursor
in interfacede.lessvoid.nifty.spi.render.RenderDevice
-
createImage
- Specified by:
createImage
in interfacede.lessvoid.nifty.spi.render.RenderDevice
-
createFont
- Specified by:
createFont
in interfacede.lessvoid.nifty.spi.render.RenderDevice
-
beginFrame
public void beginFrame()- Specified by:
beginFrame
in interfacede.lessvoid.nifty.spi.render.RenderDevice
-
endFrame
public void endFrame()- Specified by:
endFrame
in interfacede.lessvoid.nifty.spi.render.RenderDevice
-
getWidth
public int getWidth()- Specified by:
getWidth
in interfacede.lessvoid.nifty.spi.render.RenderDevice
-
getHeight
public int getHeight()- Specified by:
getHeight
in interfacede.lessvoid.nifty.spi.render.RenderDevice
-
clear
public void clear()- Specified by:
clear
in interfacede.lessvoid.nifty.spi.render.RenderDevice
-
setBlendMode
public void setBlendMode(de.lessvoid.nifty.render.BlendMode blendMode) - Specified by:
setBlendMode
in interfacede.lessvoid.nifty.spi.render.RenderDevice
-
renderFont
public void renderFont(de.lessvoid.nifty.spi.render.RenderFont font, String str, int x, int y, de.lessvoid.nifty.tools.Color color, float sizeX, float sizeY) - Specified by:
renderFont
in interfacede.lessvoid.nifty.spi.render.RenderDevice
-
renderImage
public void renderImage(de.lessvoid.nifty.spi.render.RenderImage image, int x, int y, int w, int h, int srcX, int srcY, int srcW, int srcH, de.lessvoid.nifty.tools.Color color, float scale, int centerX, int centerY) - Specified by:
renderImage
in interfacede.lessvoid.nifty.spi.render.RenderDevice
-
renderImage
public void renderImage(de.lessvoid.nifty.spi.render.RenderImage image, int x, int y, int width, int height, de.lessvoid.nifty.tools.Color color, float imageScale) - Specified by:
renderImage
in interfacede.lessvoid.nifty.spi.render.RenderDevice
-
renderQuad
public void renderQuad(int x, int y, int width, int height, de.lessvoid.nifty.tools.Color color) - Specified by:
renderQuad
in interfacede.lessvoid.nifty.spi.render.RenderDevice
-
renderQuad
public void renderQuad(int x, int y, int width, int height, de.lessvoid.nifty.tools.Color topLeft, de.lessvoid.nifty.tools.Color topRight, de.lessvoid.nifty.tools.Color bottomRight, de.lessvoid.nifty.tools.Color bottomLeft) - Specified by:
renderQuad
in interfacede.lessvoid.nifty.spi.render.RenderDevice
-
enableClip
public void enableClip(int x0, int y0, int x1, int y1) - Specified by:
enableClip
in interfacede.lessvoid.nifty.spi.render.RenderDevice
-
disableClip
public void disableClip()- Specified by:
disableClip
in interfacede.lessvoid.nifty.spi.render.RenderDevice
-