Bitmap.WrapHardwareBuffer(HardwareBuffer, ColorSpace) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Create a hardware bitmap backed by a HardwareBuffer.
[Android.Runtime.Register("wrapHardwareBuffer", "(Landroid/hardware/HardwareBuffer;Landroid/graphics/ColorSpace;)Landroid/graphics/Bitmap;", "", ApiSince=29)]
public static Android.Graphics.Bitmap? WrapHardwareBuffer (Android.Hardware.HardwareBuffer hardwareBuffer, Android.Graphics.ColorSpace? colorSpace);
[<Android.Runtime.Register("wrapHardwareBuffer", "(Landroid/hardware/HardwareBuffer;Landroid/graphics/ColorSpace;)Landroid/graphics/Bitmap;", "", ApiSince=29)>]
static member WrapHardwareBuffer : Android.Hardware.HardwareBuffer * Android.Graphics.ColorSpace -> Android.Graphics.Bitmap
Parameters
- hardwareBuffer
- HardwareBuffer
The HardwareBuffer to wrap.
- colorSpace
- ColorSpace
The color space of the bitmap. Must be a ColorSpace.Rgb colorspace.
If null, SRGB is assumed.
Returns
A bitmap wrapping the buffer, or null if there was a problem creating the bitmap.
- Attributes
Remarks
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.