CameraDevice.IsSessionConfigurationSupported(SessionConfiguration) 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.
Checks whether a particular SessionConfiguration
is supported by the camera device.
[Android.Runtime.Register("isSessionConfigurationSupported", "(Landroid/hardware/camera2/params/SessionConfiguration;)Z", "GetIsSessionConfigurationSupported_Landroid_hardware_camera2_params_SessionConfiguration_Handler", ApiSince=29)]
public virtual bool IsSessionConfigurationSupported (Android.Hardware.Camera2.Params.SessionConfiguration sessionConfig);
[<Android.Runtime.Register("isSessionConfigurationSupported", "(Landroid/hardware/camera2/params/SessionConfiguration;)Z", "GetIsSessionConfigurationSupported_Landroid_hardware_camera2_params_SessionConfiguration_Handler", ApiSince=29)>]
abstract member IsSessionConfigurationSupported : Android.Hardware.Camera2.Params.SessionConfiguration -> bool
override this.IsSessionConfigurationSupported : Android.Hardware.Camera2.Params.SessionConfiguration -> bool
Parameters
- sessionConfig
- SessionConfiguration
Returns
true
if the given session configuration is supported by the camera device
false
otherwise.
- Attributes
Remarks
Checks whether a particular SessionConfiguration
is supported by the camera device.
This method performs a runtime check of a given SessionConfiguration
. The result confirms whether or not the passed session configuration can be successfully used to create a camera capture session using CameraDevice#createCaptureSession( android.hardware.camera2.params.SessionConfiguration)
.
The method can be called at any point before, during and after active capture session. It must not impact normal camera behavior in any way and must complete significantly faster than creating a regular or constrained capture session.
Although this method is faster than creating a new capture session, it is not intended to be used for exploring the entire space of supported stream combinations. The available mandatory stream combinations android.hardware.camera2.params.MandatoryStreamCombination
are better suited for this purpose.
<b>NOTE:</b> For apps targeting android.os.Build.VERSION_CODES#VANILLA_ICE_CREAM
and above, this method will automatically delegate to CameraDeviceSetup#isSessionConfigurationSupported
whenever possible. This means that the output of this method will consider parameters set through SessionConfiguration#setSessionParameters
as well.
Session Parameters will be ignored for apps targeting <= android.os.Build.VERSION_CODES#UPSIDE_DOWN_CAKE
, or if CameraManager#isCameraDeviceSetupSupported
returns false for the camera id associated with this CameraDevice
.
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.