Pt::Gfx Namespace Reference

Graphics and imaging services. More...

Classes

class  Argb32
 ARGB-32 image format. More...
class  Argb32ConstPixel
 Read-only cursor to one ARGB-32 pixel. More...
class  Argb32Image
 ARGB-32 image. More...
class  Argb32Pixel
 Cursor to one ARGB-32 pixel. More...
class  BasicConstImage
 Read-only wrap of pixel data. More...
class  BasicConstView
 Read-only image region. More...
class  BasicImage
 Image that owns or wraps pixel data. More...
class  BasicView
 Non-owning image region. More...
class  Bitmap
 Off-screen image that can be painted. More...
class  Brush
 Fill color, gradient or texture. More...
class  Canvas
 Backend that executes drawing commands. More...
class  Color
 8-bit ARGB color. More...
struct  ColorConverter
 Converts between public color types. More...
class  ColorF
 Floating-point RGBA color. More...
class  ColorStop
 Color stop for a gradient brush. More...
class  ColorStops
 Ordered collection of gradient color stops. More...
class  CompositionMode
 How new pixels combine with existing pixels. More...
class  ConstPixel
 Read-only cursor to one pixel. More...
class  Font
 Font family, size and style. More...
class  FontFace
 Resolved font family and style. More...
class  FontMetrics
 Ascent, descent and line height of a font. More...
class  FontProvider
 Backend that loads font files. More...
class  FontRegistry
 Registry of font files. More...
class  ImageFormat
 Runtime pixel format. More...
struct  ImageTraits
 Image traits. More...
class  JpegReader
 JPEG image reader. More...
class  Paint
 Pen, brush, font and composition mode. More...
class  PaintContext
 Active painting session on a surface. More...
class  Painter
 Painter for a surface or a paint context. More...
class  PainterBase
 Drawing commands and paint state. More...
class  PaintSurface
 Target for drawing operations. More...
class  Path
 Sequence of lines and curves. More...
class  PathElement
 Read-only view of a path element. More...
class  PathIterator
 Forward iterator over path elements. More...
class  Pen
 Outline color, width and style. More...
class  Pixel
 Cursor to one pixel. More...
class  PixelBase
 Pixel base class. More...
class  PngReader
 PNG image reader. More...
class  PngWriter
 PNG image writer. More...
class  Point
 Floating-point X and Y coordinates. More...
class  PointI
 Integer X and Y coordinates. More...
class  Rect
 Floating-point rectangle. More...
class  RectI
 Integer rectangle. More...
class  Rgb16
 RGB-565 image format. More...
class  Rgb16Color
 Native RGB-565 color type. More...
class  Rgb16ConstPixel
 RGB-565 const pixel. More...
class  Rgb16Pixel
 RGB-565 pixel. More...
class  Rgb32
 Premultiplied ARGB-32 image format. More...
class  Rgb32Color
 Premultiplied standard color type. More...
class  Rgb32ConstPixel
 Premultiplied ARGB-32 const pixel. More...
class  Rgb32Image
 Premultiplied ARGB-32 image. More...
class  Rgb32Pixel
 RGB-32 pixel as premultiplied ARGB-32. More...
class  Scaling
 Conversion between logical units and pixels. More...
class  Size
 Floating-point width and height. More...
class  SizeI
 Integer width and height. More...
class  TextMetrics
 Width and bounds of a text run. More...
class  Transform
 2D affine transform. More...
class  ViewBase
 Width, height and stride of an image or view. More...
class  Yuv12
 YV-12 image format. More...
class  Yuv12ConstPixel
 YV12 const pixel. More...
class  Yuv12Pixel
 YV-12 pixel. More...

Typedefs

typedef BasicConstImage< Argb32Argb32ConstImage
 ARGB-32 const image.
typedef BasicView< Argb32Argb32View
 ARGB-32 view.
typedef BasicConstView< Argb32Argb32ConstView
 ARGB-32 const view.
typedef BasicPixelView< Argb32Argb32PixelView
 ARGB-32 pixel view.
typedef BasicConstPixelView< Argb32Argb32ConstPixelView
 ARGB-32 const pixel view.
typedef BasicLineView< Argb32Argb32LineView
 ARGB-32 line view.
typedef BasicConstLineView< Argb32Argb32ConstLineView
 ARGB-32 const line view.
typedef Span< Argb32Argb32Span
 ARGB-32 span.
typedef ConstSpan< Argb32Argb32ConstSpan
 ARGB-32 const span.
typedef BasicImage< Rgb16Rgb16Image
 RGB-16 image.
typedef BasicConstImage< Rgb16Rgb16ConstImage
 RGB-16 const image.
typedef BasicView< Rgb16Rgb16View
 RGB-16 view.
typedef BasicConstView< Rgb16Rgb16ConstView
 RGB-16 const view.
typedef BasicPixelView< Rgb16Rgb16PixelView
 RGB-16 pixel view.
typedef BasicConstPixelView< Rgb16Rgb16ConstPixelView
 RGB-16 const pixel view.
typedef BasicLineView< Rgb16Rgb16LineView
 RGB-16 line view.
typedef BasicConstLineView< Rgb16Rgb16ConstLineView
 RGB-16 const line view.
typedef Span< Rgb16Rgb16Span
 RGB-16 span.
typedef ConstSpan< Rgb16Rgb16ConstSpan
 RGB-16 const span.
typedef BasicConstImage< Rgb32Rgb32ConstImage
 RGB-32 const image.
typedef BasicView< Rgb32Rgb32View
 RGB-32 view.
typedef BasicConstView< Rgb32Rgb32ConstView
 RGB-32 const view.
typedef BasicPixelView< Rgb32Rgb32PixelView
 RGB-32 pixel view.
typedef BasicConstPixelView< Rgb32Rgb32ConstPixelView
 RGB-32 const pixel view.
typedef BasicLineView< Rgb32Rgb32LineView
 RGB-32 line view.
typedef BasicConstLineView< Rgb32Rgb32ConstLineView
 RGB-32 const line view.
typedef Span< Rgb32Rgb32Span
 RGB-32 span.
typedef ConstSpan< Rgb32Rgb32ConstSpan
 RGB-32 const span.
typedef BasicImage< Yuv12Yuv12Image
 YUV-12 image.
typedef BasicConstImage< Yuv12Yuv12ConstImage
 YUV-12 const image.
typedef BasicView< Yuv12Yuv12View
 YUV-12 view.
typedef BasicView< Yuv12Yuv12ConstView
 YUV-12 conmst view.
typedef BasicPixelView< Yuv12Yuv12PixelView
 YUV-12 pixel view.
typedef BasicConstPixelView< Yuv12Yuv12ConstPixelView
 YUV-12 const pixel view.
typedef BasicLineView< Yuv12Yuv12LineView
 YUV-12 line view.
typedef BasicConstLineView< Yuv12Yuv12ConstLineView
 YUV-12 const line view.
typedef Span< Yuv12Yuv12Span
 YUV-12 span.
typedef ConstSpan< Yuv12Yuv12ConstSpan
 YUV-12 const span.

Enumerations

enum class  FillRule {
  NonZero ,
  EvenOdd
}
 Determines how overlapping subpaths of a filled shape are painted. More...

Functions

void sourceCopy (Argb32Pixel &to, std::size_t length, const Color &from)
 Copies one color to N destination pixels.
void sourceOver (Argb32Pixel &to, std::size_t length, const Color &from)
 Blends one color over N destination pixels.
void sourceCopy (Argb32Pixel &to, const Argb32ConstPixel &from, std::size_t length)
 Copies N source pixels to N destination pixels.
void sourceOver (Argb32Pixel &to, const Argb32ConstPixel &from, std::size_t length)
 Blends N source pixels over N destination pixels.
template<typename FromView, typename ToView>
void blockScale (const FromView &from, ToView &to)
 Block scale from a source view to a target view.
template<typename P1, typename P2>
void copyPixel (const P1 &from, P2 &to)
 Copies a single pixel.
template<typename P1, typename P2>
void copyPixel (const P1 &from, P2 &to, std::size_t length)
 Copies a span of pixels.
void sourceCopy (Rgb32Pixel &to, std::size_t length, const Rgb32Color &from)
 Copies one color to N destination pixels.
void sourceOver (Rgb32Pixel &to, std::size_t length, const Rgb32Color &from)
 Blends one color over N destination pixels.
void sourceCopy (Rgb32Pixel &to, const Rgb32ConstPixel &from, std::size_t length)
 Copies N source pixels to N destination pixels.
void sourceOver (Rgb32Pixel &to, const Rgb32ConstPixel &from, std::size_t length)
 Blends N source pixels over N destination pixels.
template<typename SpanT, typename P>
void copySpanTo (const SpanT &from, P &to)
 Copies the pixels of a span to a pixel position.
template<typename FromSpanT, typename ToSpanT>
void copySpan (const FromSpanT &from, ToSpanT &to)
 Copies the pixels of a span to another span.
template<typename From, typename P>
void copyViewTo (const From &from, P &to)
 Copies the pixels of a view to a pixel position.
template<typename From, typename To>
void copyView (const From &from, To &to)
 Copies the pixels of a view to another one.
bool operator== (const Font &a, const Font &b)
 Returns true if two font requests are equal.
bool operator!= (const Font &a, const Font &b)
 Returns true if two font requests are different.
bool operator< (const Font &a, const Font &b)
 Returns true if one font request sorts before another.
bool operator== (const Scaling &a, const Scaling &b)
 Returns true if both scalings are equal.
bool operator!= (const Scaling &a, const Scaling &b)
 Returns true if both scalings are different.
bool operator< (const Scaling &a, const Scaling &b)
 Returns true if one scaling sorts before another.

Detailed Description

Portable 2D images, pixel access, and drawing of shapes and text on paint surfaces.

Function Documentation

◆ copySpanTo()

template<typename SpanT, typename P>
void copySpanTo ( const SpanT & from,
P & to )

Copies from.length() pixels without bounds checking. The caller must ensure that enough space is available at 'to'.

◆ copySpan()

template<typename FromSpanT, typename ToSpanT>
void copySpan ( const FromSpanT & from,
ToSpanT & to )

Copies min(from.length(), to.length()) pixels.

◆ copyViewTo()

template<typename From, typename P>
void copyViewTo ( const From & from,
P & to )

Copies from.width() x from.height() pixels without bounds checking. The caller must ensure that enough space is available at 'to'.

◆ copyView()

template<typename From, typename To>
void copyView ( const From & from,
To & to )

Copies min(widths) x min(heights) pixels.