PNMTextGlyph
from panda3d.core import PNMTextGlyph
- class PNMTextGlyph
Bases:
A single glyph in a
PNMTextMaker
.Inheritance diagram
- __init__(param0: PNMTextGlyph)
- __init__(advance: float)
- get_advance() int
Returns the number of pixels by which the pen should be advanced after rendering this glyph.
- get_interior_flag(x: int, y: int) bool
Returns true if the indicated pixel represents a pixel in the interior of a hollow font, false otherwise.
- get_value(x: int, y: int) float
Returns the value of the indicated pixel of the glyph. The result is in the range [0, 1], where 0 indicates the pixel is not part of the glyph, and 1 indicates it is. Intermediate values are used to represent antialiasing.
- place(dest_image: PNMImage, xp: int, yp: int, fg: LColor)
Copies the glyph to the indicated destination image at the indicated origin. It colors the glyph pixels the indicated foreground color, blends antialiased pixels with the appropriate amount of the foreground color and the existing background color, and leaves other pixels alone.