sync with tizen_2.0
[platform/framework/native/appfw.git] / inc / FGrpBitmapCommon.h
1 //
2 // Open Service Platform
3 // Copyright (c) 2012 Samsung Electronics Co., Ltd.
4 //
5 // Licensed under the Apache License, Version 2.0 (the License);
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
8 //
9 //     http://www.apache.org/licenses/LICENSE-2.0
10 //
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an "AS IS" BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
16 //
17
18 /**
19  * @file        FGrpBitmapCommon.h
20  * @brief       This is the header file for the %Bitmap class.
21  *
22  * This header file contains the definitions of the enumerations of the %Bitmap class.
23  */
24
25 #ifndef _FGRP_BITMAP_COMMON_H_
26 #define _FGRP_BITMAP_COMMON_H_
27
28 namespace Tizen { namespace Graphics
29 {
30
31 /**
32  * @enum        BitmapPixelFormat
33  *
34  * Defines the bitmap pixel format.
35  *
36  * @since       2.0
37  */
38 enum BitmapPixelFormat
39 {
40         BITMAP_PIXEL_FORMAT_RGB565 = 1, /**< The RGB565 pixel format */
41         BITMAP_PIXEL_FORMAT_ARGB8888, /**< The ARGB8888 pixel format */
42         BITMAP_PIXEL_FORMAT_R8G8B8A8, /**< The R8G8B8A8 pixel format, the order of the color component is guaranteed by the byte unit */
43         BITMAP_PIXEL_FORMAT_MAX, // This enum value is for internal use only. Using this enum value can cause behavioral, security-related, and consistency-related issues in the application.
44         BITMAP_PIXEL_FORMAT_MIN = 0 // This enum value is for internal use only. Using this enum value can cause behavioral, security-related, and consistency-related issues in the application.
45 };
46
47 /**
48  * @enum        BufferScaling
49  *
50  * Defines the bitmap buffer scaling type.
51  *
52  * @since       2.0
53  *
54  */
55 enum BufferScaling
56 {
57         BUFFER_SCALING_NONE = 1, /**< The bitmap buffer is created without scaling */
58         BUFFER_SCALING_AUTO, /**< The bitmap buffer is created according to the auto scaling rule */
59         BUFFER_SCALING_MAX, // This enum value is for internal use only. Using this enum value can cause behavioral, security-related, and consistency-related issues in the application.
60         BUFFER_SCALING_MIN = 0 // This enum value is for internal use only. Using this enum value can cause behavioral, security-related, and consistency-related issues in the application.
61 };
62
63 /**
64  * @enum        BitmapScalingQuality
65  *
66  * Defines the bitmap scaling quality.
67  *
68  * @since 2.0
69  *
70  * @remarks Bitmap::Scale() function performs the operation according to the given BitmapScalingQuality value. \n
71  *          Bitmap scaling with BITMAP_SCALING_QUALITY_HIGH provides better results than others, but it takes longer.
72  *          On the other hand, bitmap scaling with BITMAP_SCALING_QUALITY_LOW runs faster than others, but the results are poorer.
73  *          When you scale bitmaps with a masking color then you have to select BITMAP_SCALING_QUALITY_LOW,
74  *          because that algorithm does not harm the masking color (by sampling the pixels instead of interpolating).
75  */
76 enum BitmapScalingQuality
77 {
78         BITMAP_SCALING_QUALITY_LOW, /**< Low-quality but high-performance */
79         BITMAP_SCALING_QUALITY_MID, /**< Mid-quality */
80         BITMAP_SCALING_QUALITY_HIGH /**< High-quality but low-performance */
81 };
82
83 } } // Tizen::Graphics
84
85 #endif