org.jzy3d.plot3d.text.renderers
Class TextBitmapRenderer
- java.lang.Object
-
- org.jzy3d.plot3d.text.AbstractTextRenderer
-
- org.jzy3d.plot3d.text.renderers.TextBitmapRenderer
-
- All Implemented Interfaces:
- ITextRenderer
- Direct Known Subclasses:
- AxeBox2d.RotatedTextBitmapRenderer
public class TextBitmapRenderer extends AbstractTextRenderer implements ITextRenderer
Could enhance using http://www.angelcode.com/products/bmfont/ This class was improved. It uses 2 different-sized fonts, one for lables and one for ticks.
-
-
Constructor Summary
Constructors Constructor and Description TextBitmapRenderer()TextBitmapRenderer(int font1, int font2)The TextBitmap class provides support for drawing ASCII characters Any non ascii character will be replaced by a square.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description voidcolor(com.jogamp.opengl.GL gl, Color color)BoundingBox3dcomputeTextBounds(com.jogamp.opengl.GL gl, com.jogamp.opengl.glu.GLU glu, Camera cam, Coord3d posScreenShifted, float strlen)floatcomputeXWithAlign(Halign halign, Coord3d posScreen, float strlen, float x)floatcomputeYWithAlign(Valign valign, Coord3d posScreen, float y)voiddrawSimpleText(com.jogamp.opengl.GL gl, com.jogamp.opengl.glu.GLU glu, Camera cam, java.lang.String s, Coord3d position, Color color, int type)BoundingBox3ddrawText(com.jogamp.opengl.GL gl, com.jogamp.opengl.glu.GLU glu, Camera cam, java.lang.String text, Coord3d position, Halign halign, Valign valign, Color color, Coord2d screenOffset, Coord3d sceneOffset, int type)Draw a string at the specified position and compute the 3d volume occupied by the string according to the current Camera configuration.intgetFontAxisLabels()intgetFontAxisTicks()voidglRasterPos(com.jogamp.opengl.GL gl, Coord3d sceneOffset, Coord3d posReal)voidsetFontAxisLabels(int font)voidsetFontAxisTicks(int font)-
Methods inherited from class org.jzy3d.plot3d.text.AbstractTextRenderer
drawText, drawText, drawText
-
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.jzy3d.plot3d.text.ITextRenderer
drawText, drawText, drawText
-
-
-
-
Constructor Detail
-
TextBitmapRenderer
public TextBitmapRenderer(int font1, int font2)The TextBitmap class provides support for drawing ASCII characters Any non ascii character will be replaced by a square.
-
TextBitmapRenderer
public TextBitmapRenderer()
-
-
Method Detail
-
setFontAxisTicks
public void setFontAxisTicks(int font)
-
setFontAxisLabels
public void setFontAxisLabels(int font)
-
getFontAxisTicks
public int getFontAxisTicks()
-
getFontAxisLabels
public int getFontAxisLabels()
-
drawSimpleText
public void drawSimpleText(com.jogamp.opengl.GL gl, com.jogamp.opengl.glu.GLU glu, Camera cam, java.lang.String s, Coord3d position, Color color, int type)- Specified by:
drawSimpleTextin interfaceITextRenderer
-
drawText
public BoundingBox3d drawText(com.jogamp.opengl.GL gl, com.jogamp.opengl.glu.GLU glu, Camera cam, java.lang.String text, Coord3d position, Halign halign, Valign valign, Color color, Coord2d screenOffset, Coord3d sceneOffset, int type)
Draw a string at the specified position and compute the 3d volume occupied by the string according to the current Camera configuration.- Specified by:
drawTextin interfaceITextRenderer
-
computeTextBounds
public BoundingBox3d computeTextBounds(com.jogamp.opengl.GL gl, com.jogamp.opengl.glu.GLU glu, Camera cam, Coord3d posScreenShifted, float strlen)
-
color
public void color(com.jogamp.opengl.GL gl, Color color)
-
-
DMelt 3.0 © DataMelt by jWork.ORG