Class MediaVisionSource
Definition
- Namespace:
- Tizen.Multimedia.Vision
- Assembly:
- Tizen.Multimedia.Vision.dll
Represents the media vision source to keep information on the image or video frame data as raw buffer.
public class MediaVisionSource : IDisposable
- Inheritance
-
objectMediaVisionSource
- Implements
-
System.IDisposable
Constructors
View SourceMediaVisionSource(byte[], uint, uint, ColorSpace)
Initializes a new instance of the MediaVisionSource class based on the buffer and ColorSpace.
Declaration
public MediaVisionSource(byte[] buffer, uint width, uint height, ColorSpace colorSpace)
Parameters
Type | Name | Description |
---|---|---|
byte[] | buffer | The buffer of image data. |
uint | width | The width of image. |
uint | height | The height of image. |
ColorSpace | colorSpace | The image ColorSpace. |
Exceptions
Type | Condition |
---|---|
System.NotSupportedException | None of the related features are not supported. |
System.ArgumentNullException |
|
System.ArgumentException |
|
MediaVisionSource(MediaPacket)
Initializes a new instance of the MediaVisionSource class based on the MediaPacket.
Declaration
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 |
|
System.ObjectDisposedException |
|
Properties
View SourceBuffer
Gets the buffer of the media source.
Declaration
public IMediaBuffer Buffer { get; }
Property Value
Type | Description |
---|---|
IMediaBuffer |
Exceptions
Type | Condition |
---|---|
System.ObjectDisposedException | The MediaVisionSource has already been disposed of. |
Colorspace
Gets ColorSpace of the media source.
Declaration
public ColorSpace Colorspace { get; }
Property Value
Type | Description |
---|---|
ColorSpace |
Exceptions
Type | Condition |
---|---|
System.ObjectDisposedException | The MediaVisionSource has already been disposed of. |
Height
Gets the height of the media source.
Declaration
public uint Height { get; }
Property Value
Type | Description |
---|---|
uint |
Exceptions
Type | Condition |
---|---|
System.ObjectDisposedException | The MediaVisionSource has already been disposed of. |
SupportedColorSpaces
Gets the supported colorspaces for MediaVisionSource.
Declaration
public static IEnumerable<ColorSpace> SupportedColorSpaces { get; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<T><ColorSpace> |
Timestamp
Gets or sets the timestamp of the media source.
Declaration
public ulong Timestamp { get; set; }
Property Value
Type | Description |
---|---|
ulong |
Exceptions
Type | Condition |
---|---|
System.ObjectDisposedException | The MediaVisionSource has already been disposed. |
Width
Gets the width of the media source.
Declaration
public uint Width { get; }
Property Value
Type | Description |
---|---|
uint |
Exceptions
Type | Condition |
---|---|
System.ObjectDisposedException | The MediaVisionSource has already been disposed of. |
Methods
View SourceDispose()
Releases all resources used by the current instance.
Declaration
public void Dispose()
Dispose(bool)
Releases the resources used by the MediaVisionSource object.
Declaration
protected virtual void Dispose(bool disposing)
Parameters
Type | Name | Description |
---|---|---|
bool | disposing | true to release both managed and unmanaged resources; otherwise false to release only unmanaged resources. |
~MediaVisionSource()
Finalizes an instance of the MediaVisionSource class.
Declaration
protected ~MediaVisionSource()
IsSupportedColorSpace(ColorSpace)
Gets MediaVision's supported ColorSpace state. true if supported, otherwise false.
Declaration
public static bool IsSupportedColorSpace(ColorSpace colorSpace)
Parameters
Type | Name | Description |
---|---|---|
ColorSpace | colorSpace |
Returns
Type | Description |
---|---|
bool |