iOS Guides | Samples

CoreGraphics.CGBitmapContext.BytesPerRow Property

Gets the number of bytes per row for this CGBitmapContext object, or 0 if this object is not a bitmap context.


public nint BytesPerRow { get; }


Number of bytes per row, a number greather or equal that the number of bytes used by a row of pixels.   

Typically is the width multiplied by the number of bytes per pixel, with some extra padding.   This is called the image stride.   

While this does not affect the rendering of the image, it can improve the performance of image rendering by aligning the first pixel to the natural processor alignment.


Namespace: CoreGraphics
Assembly: Xamarin.iOS (in Xamarin.iOS.dll)
Assembly Versions: