Class ImageUtil
Definition
- Namespace:
- Tizen.Multimedia.Util
- Assembly:
- Tizen.Multimedia.Util.dll
- API Level:
- 4
Provides utilities for images.
C#Copypublic static class ImageUtil
- Inheritance
-
System.ObjectImageUtil
Methods
CalculateBufferSize(Size, ColorSpace)
Calculates the size of the image buffer for the specified resolution and color-space.
Declaration
C#Copy[Obsolete("Please do not use! This will be deprecated in level 6.")] public static int CalculateBufferSize(Size resolution, ColorSpace colorSpace)
Parameters
Type | Name | Description |
---|---|---|
Size | resolution | The resolution of the image. |
ColorSpace | colorSpace | ColorSpace of the image. |
Returns
Type | Description |
---|---|
System.Int32 | The buffer size. |
Exceptions
Type | Condition |
---|---|
System.ArgumentOutOfRangeException | width of |
System.ArgumentException |
|
API Level: 4
Declaration
C#Copypublic static Color GetColor(byte[] buffer, Size size)
Parameters
Type | Name | Description |
---|---|---|
Byte[] | buffer | Raw image buffer. |
Size | size | Resolution of the image. |
Returns
Type | Description |
---|---|
Color | The representative color of the image. |
Remarks
The image should be Rgb888.
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
System.ArgumentException |
|
System.ArgumentOutOfRangeException | width of |
API Level: 4
GetSupportedColorSpaces(ImageFormat)
Retrieves supported colorspaces for a ImageFormat that represents formats for ImageEncoder and ImageDecoder.
Declaration
C#Copypublic static IEnumerable<ColorSpace> GetSupportedColorSpaces(ImageFormat format)
Parameters
Type | Name | Description |
---|---|---|
ImageFormat | format | The ImageFormat. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<ColorSpace> | An IEnumerable of ColorSpace representing the supported color-spaces. |
Exceptions
Type | Condition |
---|---|
System.ArgumentException |
|