Package org.jzy3d.plot3d.text.renderers
Class TextBillboardRenderer
- java.lang.Object
- 
- org.jzy3d.plot3d.text.AbstractTextRenderer
- 
- org.jzy3d.plot3d.text.renderers.TextBillboardRenderer
 
 
- 
- All Implemented Interfaces:
- ITextRenderer
 
 @Deprecated public class TextBillboardRenderer extends AbstractTextRenderer implements ITextRenderer Deprecated.Use insteadTextRenderer. ATextBillboardRendererallows writing 2d text always facing the Camera of a 3d Scene.
 TextBillboard provides the pixel definition of all characters of the ASCII alphabet. A default bitmap (plain rectangle) is provided for unrecognized characters (those that do not have an ASCII code). The bitmap library is static, and thus no overhead is generated by the use of several instances of TextBillboard. It is however not necessary to have an instance of TextBillboard for each drawn string.
 Layout constants As demonstrated in the previous example, theString s = new String("2d text in 3d Scene"); TextBillboard txt = new TextBillboard(); BoundingBox3d box; txt.drawText(gl, s, Coord3d.ORIGIN, Halign.LEFT, Valign.GROUND, Color.BLACK); box = txt.drawText(gl, glu, cam, s, Coord3d.ORIGIN, Halign.LEFT, Valign.GROUND, Color.BLACK);TextBillboardRendererhandles vertical and horizontal layout of text according to the given text coordinate.- Author:
- Martin Pernollet
 
- 
- 
Field Summary- 
Fields inherited from class org.jzy3d.plot3d.text.AbstractTextRendererNO_ROTATION, NO_SCENE_OFFSET, NO_SCREEN_OFFSET, spaceTransformer
 
- 
 - 
Constructor SummaryConstructors Constructor Description TextBillboardRenderer()Deprecated.The TextBillboard class provides support for drawing ASCII characters Any non ascii caracter will be replaced by a square.
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description protected BoundingBox3dcomputeTextBounds(IPainter painter, Coord3d position, org.jzy3d.plot3d.text.renderers.TextBillboardRenderer.BillBoardSize dims)Deprecated.BoundingBox3ddrawText(IPainter painter, Font font, String s, Coord3d position, float rotation, Horizontal halign, Vertical valign, Color color, Coord2d screenOffset, Coord3d sceneOffset)Deprecated.Draw a string at the specified position and compute the 3d volume occupied by the string according to the current Camera configuration.protected voidglRaster(IPainter painter, Coord3d position, Color color)Deprecated.protected org.jzy3d.plot3d.text.renderers.TextBillboardRenderer.BillBoardSizeprintString(IPainter painter, String s, Horizontal halign, Vertical valign)Deprecated.Performs actual display of the string.- 
Methods inherited from class org.jzy3d.plot3d.text.AbstractTextRendererdrawText, drawText, drawText, drawText, drawText, drawText, getSpaceTransformer, setSpaceTransformer
 - 
Methods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 - 
Methods inherited from interface org.jzy3d.plot3d.text.ITextRendererdrawText, drawText, drawText, drawText, drawText, drawText, getSpaceTransformer, setSpaceTransformer
 
- 
 
- 
- 
- 
Method Detail- 
drawTextpublic BoundingBox3d drawText(IPainter painter, Font font, String s, Coord3d position, float rotation, Horizontal halign, Vertical valign, Color color, Coord2d screenOffset, Coord3d sceneOffset) Deprecated.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 interface- ITextRenderer
 
 - 
computeTextBoundsprotected BoundingBox3d computeTextBounds(IPainter painter, Coord3d position, org.jzy3d.plot3d.text.renderers.TextBillboardRenderer.BillBoardSize dims) Deprecated.
 - 
printStringprotected org.jzy3d.plot3d.text.renderers.TextBillboardRenderer.BillBoardSize printString(IPainter painter, String s, Horizontal halign, Vertical valign) Deprecated.Performs actual display of the string.- Parameters:
- painter- TODO
- s- the String that must be displayed.
- halign- the horizontal alignment constant.
- valign- the vertical alignment constant.
- gl- GL2 context.
- Throws:
- an- IllegalArgumentException if the vertical or horizontal alignment constant value is unknown.
 
 
- 
 
-