Sprache

ImageWriter.Builder.SetHardwareBufferFormat(Int32) Method

Definition

Set the hardwareBuffer format of this ImageWriter.

[Android.Runtime.Register("setHardwareBufferFormat", "(I)Landroid/media/ImageWriter$Builder;", "", ApiSince=33)]
public Android.Media.ImageWriter.Builder SetHardwareBufferFormat(int hardwareBufferFormat);
[<Android.Runtime.Register("setHardwareBufferFormat", "(I)Landroid/media/ImageWriter$Builder;", "", ApiSince=33)>]
member this.SetHardwareBufferFormat : int -> Android.Media.ImageWriter.Builder

Parameters

hardwareBufferFormat
Int32

The HardwareBuffer format of the image that this writer will produce. Value is one of the following: HardwareBuffer.RGBA_8888 HardwareBuffer.RGBA_FP16 HardwareBuffer.RGBA_1010102 HardwareBuffer.RGBX_8888 HardwareBuffer.RGB_888 HardwareBuffer.RGB_565 HardwareBuffer.BLOB HardwareBuffer.YCBCR_420_888 HardwareBuffer.D_16 HardwareBuffer.D_24 HardwareBuffer.DS_24UI8 HardwareBuffer.D_FP32 HardwareBuffer.DS_FP32UI8 HardwareBuffer.S_UI8 HardwareBuffer.YCBCR_P010 HardwareBuffer.YCBCR_P210 HardwareBuffer.R_8 HardwareBuffer.R_16 HardwareBuffer.RG_1616 HardwareBuffer.RGBA_10101010 HardwareBuffer.R_12 HardwareBuffer.R_14 HardwareBuffer.RG_1212 HardwareBuffer.RG_1414 HardwareBuffer.RGBA_12121212 HardwareBuffer.RGBA_14141414 HardwareBuffer.BGRA_1010102 HardwareBuffer.BGRX_1010102

Returns

the Builder instance with customized buffer format. This value cannot be null.

Attributes

Remarks

Set the hardwareBuffer format of this ImageWriter. The default value is HardwareBuffer.RGBA_8888. This function works together with setDataSpace(int) for an ImageWriter instance. Setting at least one of these two replaces setImageFormat(int) function.

Android reference for android.media.ImageWriter.Builder.setHardwareBufferFormat.

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.

Applies to