|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.lang.Throwable java.lang.Exception org.proteinshader.graphics.exceptions.GlyphException org.proteinshader.graphics.exceptions.GlyphImageException
public class GlyphImageException
To report errors that occur while creating a Glyph.
This subclass of GlyphException is intended to be used when the
image for an individual glyph could not be copied from a larger image
that contains a set of glyphs. This error would occur if there was
a problem calculating the correct pixel index positions for extracting
the glyph image. Therefore, this exception class has data members
for storing all of the information relevant to the attempted
extraction.
Constructor Summary | |
---|---|
GlyphImageException(String name,
int x1,
int y1,
int x2,
int y2,
int bytesPerPixel,
int glyphWidth,
int glyphHeight,
int glyphSetImageWidth,
int glyphSetImageHeight)
The message given this constructor can be retrieved using getMessage(). |
Method Summary | |
---|---|
int |
getBytesPerPixel()
Returns the number of bytes per pixel for the glyph. |
int |
getGlyphHeight()
Returns the height of the Glyph in pixels. |
int |
getGlyphSetImageHeight()
Returns the height in pixels of the glyph set image. |
int |
getGlyphSetImageWidth()
Returns the width in pixels of the glyph set image. |
int |
getGlyphWidth()
Returns the width of the Glyph in pixels. |
String |
getName()
Returns the name of the glyph. |
int |
getX1()
Returns the x-coordinate of the top left corner of the glyph. |
int |
getX2()
Returns the x-coordinate of the bottom right corner of the glyph. |
int |
getY1()
Returns the y-coordinate of the top left corner of the glyph. |
int |
getY2()
Returns the y-coordinate of the bottom right corner of the glyph. |
Methods inherited from class java.lang.Throwable |
---|
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public GlyphImageException(String name, int x1, int y1, int x2, int y2, int bytesPerPixel, int glyphWidth, int glyphHeight, int glyphSetImageWidth, int glyphSetImageHeight)
name
- the name of a glyph is usually a single character.x1
- x-coordinate of upper left corner of the glyph.y1
- y-coordinate of upper left corner of the glyph.x2
- x-coordinate of lower right corner of the glyph.y2
- y-coordinate of lower right corner of the glyph.bytesPerPixel
- there can be 1 to 4 bytes per pixel.glyphWidth
- the width of the Glyph image in pixels.glyphHeight
- the height of the Glyph image in pixels.glyphSetImageWidth
- the GlyphSet image width in pixels.glyphSetImageHeight
- the GlyphSet image height in pixels.Method Detail |
---|
public String getName()
public int getX1()
public int getY1()
public int getX2()
public int getY2()
public int getBytesPerPixel()
public int getGlyphWidth()
public int getGlyphHeight()
public int getGlyphSetImageWidth()
public int getGlyphSetImageHeight()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |