CaptureResult.InfoDeviceType Property
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.
A classification of the underlying hardware and source of image data for this camera device, or for a specific camera output frame.
[Android.Runtime.Register("INFO_DEVICE_TYPE", ApiSince=37)]
public static Android.Hardware.Camera2.CaptureResult.Key InfoDeviceType { get; }
[<Android.Runtime.Register("INFO_DEVICE_TYPE", ApiSince=37)>]
static member InfoDeviceType : Android.Hardware.Camera2.CaptureResult.Key
Property Value
A classification of the underlying hardware and source of image data for this camera device, or for a specific camera output frame.
- Attributes
Remarks
A classification of the underlying hardware and source of image data for this camera device, or for a specific camera output frame.
Historically, camera devices listed by the camera2 API could be assumed to be built-in cameras on the Android device, or in the case of the EXTERNAL android.info.supportedHardwareLevel, USB webcams.
However, it is increasingly possible for camera devices to not be restricted to device-internal sensors and processing pipelines. Such devices can provide a wide range of useful capabilities to applications, but may also not be suitable for all camera use cases.
This key provides a basic classification of the type of camera this camera ID represents, so that applications may decide on the appropriate level of trust to extend to the image data produced by it.
Note that in some cases, it is possible for the user to swap the definition of a camera ID to a different one, such as when connecting a remote camera to act as the front camera of the device. This is normally transparent to the camera-using application to minimize user friction, but applications that care about this possibility should always verify the value of this key in the CameraCharacteristics before opening a camera, instead of caching it, and should also watch the value of this key in CaptureResults as well, since it may change mid-session.
This key is available on all devices.
Android reference for android.hardware.camera2.CaptureResult.INFO_DEVICE_TYPE.
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.