Camera Settings
Defined in namespace Scandit.DataCapture.Core.Source
- CameraPosition
Added in version 6.16.0
- WorldFacing
Added in version 6.16.0
The camera is attached at the back of the device and is facing away from the user.
- UserFacing
Added in version 6.16.0
The camera is attached on the front of the device and facing towards the user.
- Unspecified
Added in version 6.16.0
The camera position is unspecified.
- VideoResolution
Added in version 6.16.0
- Hd
Added in version 6.16.0
Resolution is 1280x720.
- FullHd
Added in version 6.16.0
Resolution is 1920x1080.
- Uhd4k
Added in version 6.16.0
Resolution is 3840x2160. Please note: Usage of this resolution is not part of every license. If you encounter issues, please contact us at support@scandit.com.
- FocusRange
Added in version 6.16.0
Enumeration of possible focus ranges to use. This can be used to restrict the auto-focus system to only consider objects in a certain range to focus on.
- Full
Added in version 6.16.0
Use the full focus range supported by the camera.
- Near
Added in version 6.16.0
Only focus on objects that are near to the camera.
- Far
Added in version 6.16.0
Only focus on objects that are far from the camera.
- FocusGestureStrategy
Added in version 6.16.0
Enumeration of possible focus gesture strategies to use.
- None
Added in version 6.16.0
No effect when performing a focus gesture.
- Manual
Added in version 6.16.0
Focus on PoI and only change with next focus gesture.
- ManualUntilCapture
Added in version 6.16.0
Focus on PoI and reset to previous focus strategy on capture.
- AutoOnLocation
Added in version 6.16.0
Continuously focus on the location of the gesture and only change with next focus gesture.
- CameraSettings
class CameraSettings
Added in version 6.16.0
Holds camera-specific settings such as preferred resolution, maximum frame rate etc. The defaults are chosen such that they work for a wide variety of use cases. You may apply custom settings to further optimize scan performance for your particular use case. There is typically no need to customize the camera settings beyond changing the preferred resolution.
For best performance use the camera settings returned by the capture mode you are using, e.g. BarcodeCapture.RecommendedCameraSettings, or BarcodeTracking.RecommendedCameraSettings etc.
- CameraSettings()
CameraSettings()
Added in version 6.16.0
Creates new default camera settings. ZoomFactor is set to 1 and PreferredResolution is set to VideoResolution.Auto.
Holds camera related settings such as preview resolution and maximum frame rate to use.
- PreferredResolution
VideoResolution PreferredResolution { get;set; }
Added in version 6.16.0
The preferred resolution to use for the camera. The camera will use the resolution that is closests to the resolution preference. For example, if only lower resolutions than the preferred resolution are available, the highest available resolution will be used.
The resolution chosen by the camera only takes the PreferredResolution into account, it does not consider the resolution limit of your license key. When the device selects a resolution that is larger than what you have licensed, the data capture context will report a license status error.
The default value is VideoResolution.Auto.
- ZoomFactor
float
ZoomFactor { get;set; }Added in version 6.16.0
The zoom factor to use for the camera. This value is a multiplier, a value of 1.0 means no zoom, while a value of 2.0 doubles the size of the image, but halves the field of view.
Values less than 1.0 are treated as 1.0. Values greater than the maximum available zoom factor are clamped to the maximum accepted value.
The default zoom factor is 1.0.
- ShouldPreferSmoothAutoFocus
bool
ShouldPreferSmoothAutoFocus { get;set; }Added in version 6.16.0
Whether to prefer smooth auto-focus. The default settings have this turned off. Enable it to switch to a smoother (but potentially less reliable) auto-focus strategy. For some devices, this property has no effect.
- FocusRange
FocusRange FocusRange { get;set; }
Added in version 6.16.0
The focus range to primarily use, if supported by the device.
- FocusGestureStrategy
FocusGestureStrategy FocusGestureStrategy { get;set; }
Added in version 6.16.0
The focus gesture strategy to use.
- ZoomGestureZoomFactor
float
ZoomGestureZoomFactor { get;set; }Added in version 6.16.0
The zoom factor to move to when the zoom in gesture was performed. This value is a multiplier, a value of 1.0 means no zoom, while a value of 2.0 doubles the size of the image, but halves the field of view. See also ZoomFactor.
The default zoom factor for the zoom in gesture is 2.0.
- SetProperty()
void
SetProperty(string
name,object
value)Added in version 6.16.0
Set camera property to the provided value. Use this method to set properties that are not yet part of a stable API. Properties set through this method may or may not be used or change in a future release.
- GetProperty()
object
GetProperty(string
name)Added in version 6.16.0
Retrieves the value of a previously set camera property. In case the property does not exist, null is returned.
- GetProperty()
T
GetProperty<T
>(string
name)Added in version 6.16.0
Retrieves the value of a previously set property. In case the property does not exist, an ArgumentException is thrown.
- TryGetProperty()
bool
TryGetProperty<T
>(string
name, outT
result)Added in version 6.16.0
The non-throwing version of the method GetProperty(). It retrieves the value of a previously set property as the second passed argument and returns true. In case the property does not exist, false will be returned.