Class MediaVisionSource

Definition

Namespace:
Tizen.Multimedia.Vision
Assembly:
Tizen.Multimedia.Vision.dll
API Level:
4
Feature:
http://tizen.org/feature/vision.barcode_detectionhttp://tizen.org/feature/vision.barcode_generationhttp://tizen.org/feature/vision.face_recognitionhttp://tizen.org/feature/vision.image_recognition

Represents the media vision source to keep information on the image or video frame data as raw buffer.

C#
Copy
public class MediaVisionSource : IDisposable
Inheritance
System.Object
MediaVisionSource
Implements
System.IDisposable

Constructors

View Source

MediaVisionSource(Byte[], UInt32, UInt32, ColorSpace)

Initializes a new instance of the MediaVisionSource class based on the buffer and ColorSpace.

Declaration
C#
Copy
public MediaVisionSource(byte[] buffer, uint width, uint height, ColorSpace colorSpace)
Parameters
Type Name Description
System.Byte[] buffer

The buffer of image data.

System.UInt32 width

The width of image.

System.UInt32 height

The height of image.

ColorSpace colorSpace

The image ColorSpace.

Exceptions
Type Condition
System.NotSupportedException

None of the related features are not supported.
-or-
colorSpace is not supported.

System.ArgumentNullException

buffer is null.

System.ArgumentException

buffer has no element.(The length is zero.)
-or-
colorSpace is invalid.

API Level: 4
View Source

MediaVisionSource(MediaPacket)

Initializes a new instance of the MediaVisionSource class based on the MediaPacket.

Declaration
C#
Copy
public MediaVisionSource(MediaPacket mediaPacket)
Parameters
Type Name Description
MediaPacket mediaPacket

The MediaPacket from which the source will be filled.

Exceptions
Type Condition
System.NotSupportedException

None of the related features are not supported.

System.ArgumentNullException

mediaPacket is null.

ObjectDisposedException

mediaPacket has already been disposed of.

API Level: 4

Properties

View Source

Buffer

Gets the buffer of the media source.

Declaration
C#
Copy
public IMediaBuffer Buffer { get; }
Property Value
Type Description
IMediaBuffer
Exceptions
Type Condition
ObjectDisposedException

The MediaVisionSource has already been disposed of.

API Level: 4
View Source

Colorspace

Gets ColorSpace of the media source.

Declaration
C#
Copy
public ColorSpace Colorspace { get; }
Property Value
Type Description
ColorSpace
Exceptions
Type Condition
ObjectDisposedException

The MediaVisionSource has already been disposed of.

API Level: 4
View Source

Height

Gets the height of the media source.

Declaration
C#
Copy
public uint Height { get; }
Property Value
Type Description
System.UInt32
Exceptions
Type Condition
ObjectDisposedException

The MediaVisionSource has already been disposed of.

API Level: 4
View Source

SupportedColorSpaces

Gets the supported colorspaces for MediaVisionSource.

Declaration
C#
Copy
public static IEnumerable<ColorSpace> SupportedColorSpaces { get; }
Property Value
Type Description
System.Collections.Generic.IEnumerable<ColorSpace>
API Level: 4
View Source

Width

Gets the width of the media source.

Declaration
C#
Copy
public uint Width { get; }
Property Value
Type Description
System.UInt32
Exceptions
Type Condition
ObjectDisposedException

The MediaVisionSource has already been disposed of.

API Level: 4

Methods

View Source

Dispose()

Releases all resources used by the current instance.

Declaration
C#
Copy
public void Dispose()
API Level: 4
View Source

Dispose(Boolean)

Releases the resources used by the MediaVisionSource object.

Declaration
C#
Copy
protected virtual void Dispose(bool disposing)
Parameters
Type Name Description
Boolean disposing

true to release both managed and unmanaged resources; otherwise false to release only unmanaged resources.

API Level: 4
View Source

Finalize()

Finalizes an instance of the MediaVisionSource class.

Declaration
C#
Copy
protected void Finalize()
View Source

IsSupportedColorSpace(ColorSpace)

Gets MediaVision's supported ColorSpace state. true if supported, otherwise false.

Declaration
C#
Copy
public static bool IsSupportedColorSpace(ColorSpace colorSpace)
Parameters
Type Name Description
ColorSpace colorSpace
Returns
Type Description
Boolean
API Level: 4

Implements

System.IDisposable