ImageReader.Builder.SetUsage(Int64) Method

Definition

Set the consumer usage flag.

[Android.Runtime.Register("setUsage", "(J)Landroid/media/ImageReader$Builder;", "", ApiSince=33)]
public Android.Media.ImageReader.Builder SetUsage(long usage);
[<Android.Runtime.Register("setUsage", "(J)Landroid/media/ImageReader$Builder;", "", ApiSince=33)>]
member this.SetUsage : int64 -> Android.Media.ImageReader.Builder

Parameters

usage
Int64

The intended usage of the images consumed by this ImageReader. See the usages on HardwareBuffer for a list of valid usage bits. Default value is HardwareBuffer.USAGE_CPU_READ_OFTEN. Value is either 0 or a combination of the following: HardwareBuffer.USAGE_CPU_READ_RARELY HardwareBuffer.USAGE_CPU_READ_OFTEN HardwareBuffer.USAGE_CPU_WRITE_RARELY HardwareBuffer.USAGE_CPU_WRITE_OFTEN HardwareBuffer.USAGE_GPU_SAMPLED_IMAGE HardwareBuffer.USAGE_GPU_COLOR_OUTPUT HardwareBuffer.USAGE_COMPOSER_OVERLAY HardwareBuffer.USAGE_PROTECTED_CONTENT HardwareBuffer.USAGE_VIDEO_ENCODE HardwareBuffer.USAGE_GPU_DATA_BUFFER HardwareBuffer.USAGE_SENSOR_DIRECT_DATA HardwareBuffer.USAGE_GPU_CUBE_MAP HardwareBuffer.USAGE_GPU_MIPMAP_COMPLETE HardwareBuffer.USAGE_FRONT_BUFFER

Returns

the Builder instance with customized usage value. This value cannot be null.

Attributes

Remarks

Set the consumer usage flag.

Android reference for android.media.ImageReader.Builder.setUsage.

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