IPixelRowOperation<TPixel> Interface
A custom image processor that edits each row of pixels in place, applied to every frame of an image by ImageProcessingExtensions.ApplyRowOperation.
public interface IPixelRowOperation<TPixel> where TPixel : unmanagedType parameters
TPixel- The pixel type of the rows: the pixel type of the image, or a wider working type.
Remarks
Implement the operation as a struct: the processing loop is then compiled for it, without an interface call per row. IPixelRowOperation<TPixel>.Invoke is called from several threads at once when ImageConfiguration.MaxDegreeOfParallelism is greater than 1, for different rows of the same instance: it must not change the state of the operation.
Methods
| Name | Description |
|---|---|
| Invoke(int, Span<TPixel>) | Edits one row. |
Invoke(int, Span<TPixel>)
Edits one row.
Parameters
yint- The index of the row in the frame.
rowSpan<TPixel>- The pixels of the row, read and written in place. Valid until the method returns.