_tiltRange = GetRange(Interop.CameraSettings.GetTiltRange);
}
- private delegate int GetRangeDelegate(IntPtr handle, out int min, out int max);
+ private delegate CameraError GetRangeDelegate(IntPtr handle, out int min, out int max);
private Range? GetRange(GetRangeDelegate func)
{
int min = 0;
/// <summary>
/// Sets auto focus area.
/// </summary>
+ /// <remarks>
+ /// <see cref="CameraAutoFocusMode"/> should not be the <see cref="CameraAutoFocusMode.None"/>.
+ /// </remarks>
/// <privilege>
/// http://tizen.org/privilege/camera
/// </privilege>
/// <param name="x">X position</param>
/// <param name="y">Y position</param>
- /// <exception cref="ArgumentException">In case of invalid parameters</exception>
+ /// <exception cref="ArgumentException">In case of invalid parameters.</exception>
+ /// <exception cref="InvalidOperationException">In case of any invalid operations.</exception>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public void SetAutoFocusArea(int x, int y)
{
CameraErrorFactory.ThrowIfError(Interop.CameraSettings.SetAutoFocusArea(_camera.GetHandle(), x, y),
"Failed to set the autofocus area.");
}
+ /// <summary>
+ /// Sets auto focus area.
+ /// </summary>
+ /// <remarks>
+ /// <see cref="CameraAutoFocusMode"/> should not be the <see cref="CameraAutoFocusMode.None"/>.
+ /// </remarks>
+ /// <privilege>
+ /// http://tizen.org/privilege/camera
+ /// </privilege>
+ /// <param name="pos"><see cref="Point"/> structure including X, Y position</param>
+ /// <exception cref="ArgumentException">In case of invalid parameters.</exception>
+ /// <exception cref="InvalidOperationException">In case of any invalid operations.</exception>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public void SetAutoFocusArea(Point pos)
{
CameraErrorFactory.ThrowIfError(Interop.CameraSettings.SetAutoFocusArea(_camera.GetHandle(), pos.X, pos.Y),
/// <privilege>
/// http://tizen.org/privilege/camera
/// </privilege>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public void ClearFocusArea()
{
CameraErrorFactory.ThrowIfError(Interop.CameraSettings.ClearAutoFocusArea(_camera.GetHandle()),
/// <summary>
/// The auto focus mode.
/// </summary>
+ /// <value>A <see cref="CameraAutoFocusMode"/> that specifies the auto focus mode.</value>
/// <privilege>
/// http://tizen.org/privilege/camera
/// </privilege>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public CameraAutoFocusMode AutoFocusMode
{
get
"Failed to set camera autofocus mode.");
}
}
- #endregion Auto Focus
+#endregion Auto Focus
#region Contrast
/// <summary>
/// <privilege>
/// http://tizen.org/privilege/camera
/// </privilege>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public int Contrast
{
get
/// <privilege>
/// http://tizen.org/privilege/camera
/// </privilege>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public bool AutoContrast
{
get
/// <remarks>
/// If min value is greater than the max value, it means this feature is not supported.
/// </remarks>
+ /// <exception cref="NotSupportedException">In case of this feature is not supported.</exception>
public Range ContrastRange
{
get
{
- if (_contrastRange.HasValue == false)
+ if (!_contrastRange.HasValue)
{
throw new NotSupportedException("Contrast is not supported.");
}
/// <privilege>
/// http://tizen.org/privilege/camera
/// </privilege>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public int Brightness
{
get
/// <remarks>
/// If min value is greater than the max value, it means this feature is not supported.
/// </remarks>
+ /// <exception cref="NotSupportedException">In case of this feature is not supported.</exception>
public Range BrightnessRange
{
get
{
- if (_brightnessRange.HasValue == false)
+ if (!_brightnessRange.HasValue)
{
throw new NotSupportedException("Brightness is not supported.");
}
/// <privilege>
/// http://tizen.org/privilege/camera
/// </privilege>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public int Exposure
{
get
/// <summary>
/// The exposure mode.
/// </summary>
+ /// <value>A <see cref="CameraExposureMode"/> that specifies the exposure mode.</value>
/// <privilege>
/// http://tizen.org/privilege/camera
/// </privilege>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public CameraExposureMode ExposureMode
{
get
/// <remarks>
/// If min value is greater than the max value, it means this feature is not supported.
/// </remarks>
+ /// <exception cref="NotSupportedException">In case of this feature is not supported.</exception>
public Range ExposureRange
{
get
{
- if (_exposureRange.HasValue == false)
+ if (!_exposureRange.HasValue)
{
throw new NotSupportedException("Exposure is not supported.");
}
return _exposureRange.Value;
}
}
- #endregion Exposure
+#endregion Exposure
#region Zoom
/// <summary>
/// <privilege>
/// http://tizen.org/privilege/camera.
/// </privilege>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public int ZoomLevel
{
get
/// <remarks>
/// If min value is greater than the max value, it means this feature is not supported.
/// </remarks>
+ /// <exception cref="NotSupportedException">In case of this feature is not supported.</exception>
public Range ZoomRange
{
get
{
- if (_zoomRange.HasValue == false)
+ if (!_zoomRange.HasValue)
{
throw new NotSupportedException("Zoom is not supported.");
}
/// <summary>
/// The whitebalance mode.
/// </summary>
+ /// <value>A <see cref="CameraWhiteBalance"/> that specifies the white balance mode.</value>
/// <privilege>
/// http://tizen.org/privilege/camera
/// </privilege>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public CameraWhiteBalance WhiteBalance
{
get
/// <summary>
/// The ISO level.
/// </summary>
+ /// <value>A <see cref="CameraIsoLevel"/> that specifies ISO level.</value>
/// <privilege>
/// http://tizen.org/privilege/camera
/// </privilege>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public CameraIsoLevel IsoLevel
{
get
/// <privilege>
/// http://tizen.org/privilege/camera.
/// </privilege>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public int ImageQuality
{
get
/// <summary>
/// The preview frame rate.
/// </summary>
+ /// <value>A <see cref="CameraFps"/> that specifies preview frame rate.</value>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public CameraFps PreviewFps
{
get
/// <privilege>
/// http://tizen.org/privilege/camera
/// </privilege>
- /// <exception cref="ArgumentException">In case of invalid parameters</exception>
+ /// <exception cref="ArgumentException">In case of invalid parameters.</exception>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public Size PreviewResolution
{
get
/// Depending on the capture resolution aspect ratio and display resolution,
/// the recommended preview resolution is determined.
/// </remarks>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public Size RecommendedPreviewResolution
{
get
/// <summary>
/// The preview data format.
/// </summary>
- /// <exception cref="ArgumentException">In case of invalid parameters</exception>
+ /// <value>A <see cref="CameraPixelFormat"/> that specifies the pixel format of preview data.</value>
+ /// <exception cref="ArgumentException">In case of invalid parameters.</exception>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public CameraPixelFormat PreviewPixelFormat
{
get
/// http://tizen.org/privilege/camera
/// </privilege>
/// <exception cref="ArgumentException">In case of invalid parameters</exception>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public Size CaptureResolution
{
get
/// <summary>
/// Format of an image to be captured.
/// </summary>
+ /// <value>A <see cref="CameraPixelFormat"/> that specifies the pixel format of captured image.</value>
/// <exception cref="ArgumentException">In case of invalid parameters</exception>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public CameraPixelFormat CapturePixelFormat
{
get
/// <summary>
/// The bit rate of encoded preview.
/// </summary>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public int EncodedPreviewBitrate
{
get
/// <summary>
/// GOP(Group Of Pictures) interval of encoded preview.
/// </summary>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public int EncodedPreviewGopInterval
{
get
/// <summary>
/// The theater mode.
/// </summary>
+ /// <value>A <see cref="CameraTheaterMode"/> that specifies theater mode.</value>
/// <privilege>
/// http://tizen.org/privilege/camera
/// </privilege>
/// If you want to display the preview image on the external display with the full screen mode,
/// use this property.
/// </remarks>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public CameraTheaterMode TheaterMode
{
get
/// <summary>
/// The camera effect mode.
/// </summary>
+ /// <value>A <see cref="CameraEffectMode"/> that specifies effect mode.</value>
/// <privilege>
/// http://tizen.org/privilege/camera
/// </privilege>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public CameraEffectMode Effect
{
get
/// <summary>
/// The scene mode.
/// </summary>
+ /// <value>A <see cref="CameraSceneMode"/> that specifies scene mode.</value>
/// <privilege>
/// http://tizen.org/privilege/camera
/// </privilege>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public CameraSceneMode SceneMode
{
get
/// <summary>
/// The camera's flash mode.
/// </summary>
+ /// <value>A <see cref="CameraFlashMode"/> that specifies flash mode.</value>
/// <privilege>
/// http://tizen.org/privilege/camera
/// </privilege>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public CameraFlashMode FlashMode
{
get
/// <summary>
/// Gets the camera lens orientation angle.
/// </summary>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public int LensOrientation
{
get
/// <summary>
/// The stream rotation.
/// </summary>
+ /// <value>A <see cref="CameraRotation"/> that specifies the rotation of camera device.</value>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public CameraRotation StreamRotation
{
get
/// <summary>
/// The stream flip.
/// </summary>
+ /// <value>A <see cref="CameraFlip"/> that specifies camera flip type.</value>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public CameraFlip StreamFlip
{
get
/// <summary>
/// The mode of HDR(High dynamic range) capture.
/// </summary>
+ /// <value>A <see cref="CameraHdrMode"/> that specifies the HDR mode.</value>
/// <privilege>
/// http://tizen.org/privilege/camera
/// </privilege>
/// so that we eventually arrive at a picture that is representative in both dark and bright areas.
/// If this attribute is set, then eventhandler set for HdrCaptureProgress event is invoked.
/// </remarks>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public CameraHdrMode HdrMode
{
get
/// The anti shake feature.
/// If true the antishake feature is enabled, otherwise false.
/// </summary>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public bool AntiShake
{
get
/// If video stabilization is enabled, zero shutter lag is disabled.
/// This feature is used to record a video.
/// </remarks>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public bool VideoStabilization
{
get
/// <remarks>
/// In some countries, this operation is not permitted.
/// </remarks>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public bool DisableShutterSound
{
set
/// <summary>
/// Sets the type of PTZ(Pan Tilt Zoom). Mechanical or Electronic.
/// </summary>
+ /// <value>A <see cref="CameraPtzType"/> that specifies the type of PTZ.</value>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public CameraPtzType PtzType
{
set
/// <privilege>
/// http://tizen.org/privilege/camera
/// </privilege>
- /// <param name="type">ptz move type.</param>
+ /// <param name="type">ptz move type. <seealso cref="CameraPtzMoveType"/></param>
/// <param name="panStep">pan step</param>
/// <exception cref="ArgumentException">In case of invalid parameters</exception>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public void SetPan(CameraPtzMoveType type, int panStep)
{
CameraErrorFactory.ThrowIfError(Interop.CameraSettings.SetPan(_camera.GetHandle(), type, panStep),
/// http://tizen.org/privilege/camera
/// </privilege>
/// <returns>Returns the camera's horizontal position</returns>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public int GetPan()
{
int val = 0;
/// <param name="type">ptz move type</param>
/// <param name="tiltStep">tilt step</param>
/// <exception cref="ArgumentException">In case of invalid parameters</exception>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public void SetTilt(CameraPtzMoveType type, int tiltStep)
{
CameraErrorFactory.ThrowIfError(Interop.CameraSettings.SetTilt(_camera.GetHandle(), type, tiltStep),
/// http://tizen.org/privilege/camera
/// </privilege>
/// <returns>Returns the current vertical position</returns>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public int GetTilt()
{
int val = 0;
/// <remarks>
/// If min value is greater than the max value, it means this feature is not supported.
/// </remarks>
+ /// <exception cref="NotSupportedException">In case of this feature is not supported.</exception>
public Range PanRange
{
get
{
- if (_panRange.HasValue == false)
+ if (!_panRange.HasValue)
{
throw new NotSupportedException("Pan is not supported.");
}
/// <remarks>
/// If min value is greater than the max value, it means this feature is not supported.
/// </remarks>
+ /// <exception cref="NotSupportedException">In case of this feature is not supported.</exception>
public Range TiltRange
{
get
{
- if (_tiltRange.HasValue == false)
+ if (!_tiltRange.HasValue)
{
throw new NotSupportedException("Tilt is not supported.");
}
/// The scene mode.
/// true if EXIF tags are enabled in JPEG file, otherwise false.
/// </summary>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public bool EnableTag
{
get
/// <summary>
/// The camera image description in the EXIF tag.
/// </summary>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public string ImageDescriptionTag
{
get
/// <summary>
/// The software information in the EXIF tag.
/// </summary>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public string SoftwareTag
{
get
/// <summary>
/// The geotag(GPS data) in the EXIF tag.
/// </summary>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public Location GeoTag
{
get
/// <privilege>
/// http://tizen.org/privilege/camera
/// </privilege>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public void RemoveGeoTag()
{
CameraErrorFactory.ThrowIfError(Interop.CameraSettings.RemoveGeotag(_camera.GetHandle()),
/// <summary>
/// The camera orientation in the tag.
/// </summary>
+ /// <exception cref="ObjectDisposedException">The camera already has been disposed.</exception>
public CameraTagOrientation OrientationTag
{
get