API Reference
ImageFrame
Describes a non-owning raw image buffer supplied to the symbol scanner.
Inheritance
- Object
- ImageFrame
Remarks
The caller remains responsible for the lifetime and mutation of the underlying memory for the duration of a scan.
Usage
This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.
Returned or exposed by
- Method ImageFrame.Packed
Accepted by parameters
- Method SymbolScanner.Scan
- Method SymbolScanner.TryScan
Constructors
public ImageFrame(ReadOnlyMemory<Byte> pixels, Int32 width, Int32 height, Int32 stride, PixelFormat pixelFormat, ImageRowOrder rowOrder = TopDown) #Creates a raw image frame.
Parameters
- pixels System.ReadOnlyMemory{System.Byte}
- width System.Int32
- height System.Int32
- stride System.Int32
- pixelFormat CodeGlyphX.PixelFormat
- rowOrder CodeGlyphX.ImageRowOrder = TopDown
Methods
public static Int32 GetBytesPerPixel(PixelFormat pixelFormat) #Int32Gets the byte width of one pixel for a supported packed format.
Parameters
- pixelFormat CodeGlyphX.PixelFormat
public static Int32 GetMinimumRowBytes(Int32 width, PixelFormat pixelFormat) #Int32Gets the minimum valid row length for a packed pixel format.
Parameters
- width System.Int32
- pixelFormat CodeGlyphX.PixelFormat
public static ImageFrame Packed(ReadOnlyMemory<Byte> pixels, Int32 width, Int32 height, PixelFormat pixelFormat, ImageRowOrder rowOrder = TopDown) #ImageFrameCreates a raw image frame whose stride is the tightly packed row length for the selected format.
Parameters
- pixels System.ReadOnlyMemory{System.Byte}
- width System.Int32
- height System.Int32
- pixelFormat CodeGlyphX.PixelFormat
- rowOrder CodeGlyphX.ImageRowOrder = TopDown
Inherited Methods
Properties
public ReadOnlyMemory<Byte> Pixels { get; } #Gets the raw pixel memory.
public Int32 Width { get; } #Gets the image width in pixels.
public Int32 Height { get; } #Gets the image height in pixels.
public Int32 Stride { get; } #Gets the number of bytes between adjacent rows.
public PixelFormat PixelFormat { get; } #Gets the raw pixel format.
public ImageRowOrder RowOrder { get; } #Gets the row order in the source buffer.