Share via


CamcorderProfile.HasProfile Method

Definition

Overloads

HasProfile(CamcorderQuality)

Returns true if a camcorder profile exists for the first back-facing camera at the given quality level.

HasProfile(Int32, CamcorderQuality)

Returns true if a camcorder profile exists for the given camera at the given quality level.

HasProfile(CamcorderQuality)

Returns true if a camcorder profile exists for the first back-facing camera at the given quality level.

[Android.Runtime.Register("hasProfile", "(I)Z", "")]
public static bool HasProfile (Android.Media.CamcorderQuality quality);
[<Android.Runtime.Register("hasProfile", "(I)Z", "")>]
static member HasProfile : Android.Media.CamcorderQuality -> bool

Parameters

quality
CamcorderQuality

the target quality level for the camcorder profile

Returns

Attributes

Remarks

Returns true if a camcorder profile exists for the first back-facing camera at the given quality level.

When using the Camera 2 API in LEGACY mode (i.e. when android.hardware.camera2.CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL is set to android.hardware.camera2.CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL_LEGACY), #hasProfile may return true for unsupported resolutions. To ensure a a given resolution is supported in LEGACY mode, the configuration given in android.hardware.camera2.CameraCharacteristics#SCALER_STREAM_CONFIGURATION_MAP must contain the the resolution in the supported output sizes. The recommended way to check this is with android.hardware.camera2.params.StreamConfigurationMap#getOutputSizes(Class) with the class of the desired recording endpoint, and check that the desired resolution is contained in the list returned.

Java documentation for android.media.CamcorderProfile.hasProfile(int).

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.

See also

Applies to

HasProfile(Int32, CamcorderQuality)

Returns true if a camcorder profile exists for the given camera at the given quality level.

[Android.Runtime.Register("hasProfile", "(II)Z", "")]
public static bool HasProfile (int cameraId, Android.Media.CamcorderQuality quality);
[<Android.Runtime.Register("hasProfile", "(II)Z", "")>]
static member HasProfile : int * Android.Media.CamcorderQuality -> bool

Parameters

cameraId
Int32

the id for the camera. Integer camera ids parsed from the list received by invoking CameraManager#getCameraIdList can be used as long as they are CameraMetadata#REQUEST_AVAILABLE_CAPABILITIES_BACKWARD_COMPATIBLE and not CameraMetadata#INFO_SUPPORTED_HARDWARE_LEVEL_EXTERNAL EXTERNAL.

quality
CamcorderQuality

the target quality level for the camcorder profile

Returns

Attributes

Remarks

Returns true if a camcorder profile exists for the given camera at the given quality level.

When using the Camera 2 API in LEGACY mode (i.e. when android.hardware.camera2.CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL is set to android.hardware.camera2.CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL_LEGACY), #hasProfile may return true for unsupported resolutions. To ensure a a given resolution is supported in LEGACY mode, the configuration given in android.hardware.camera2.CameraCharacteristics#SCALER_STREAM_CONFIGURATION_MAP must contain the the resolution in the supported output sizes. The recommended way to check this is with android.hardware.camera2.params.StreamConfigurationMap#getOutputSizes(Class) with the class of the desired recording endpoint, and check that the desired resolution is contained in the list returned.

Java documentation for android.media.CamcorderProfile.hasProfile(int, int).

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.

See also

Applies to