1 /* Copyright (c) 2009 The Khronos Group Inc. |
1 /* Copyright (c) 2009 The Khronos Group Inc. |
2 * Portions copyright (c) 2009-2010 Nokia Corporation and/or its subsidiary(-ies) |
|
3 * |
2 * |
4 * Permission is hereby granted, free of charge, to any person obtaining a |
3 * Permission is hereby granted, free of charge, to any person obtaining a |
5 * copy of this software and/or associated documentation files (the |
4 * copy of this software and/or associated documentation files (the |
6 * "Materials"), to deal in the Materials without restriction, including |
5 * "Materials"), to deal in the Materials without restriction, including |
7 * without limitation the rights to use, copy, modify, merge, publish, |
6 * without limitation the rights to use, copy, modify, merge, publish, |
77 OWF_Screen_GetDefaultNumber(); |
78 OWF_Screen_GetDefaultNumber(); |
78 |
79 |
79 /*! |
80 /*! |
80 * \brief Get screen's dimensions |
81 * \brief Get screen's dimensions |
81 * |
82 * |
82 * \param dc display context |
83 * \param screen screen number |
83 * \param header returned screen attributes |
84 * \param header returned screen attributes |
84 * |
85 * |
85 * \return OWF_TRUE if screen exists |
86 * \return OWF_TRUE if screen exists |
86 * \return OWF_FALSE if screen does not exist |
87 * \return OWF_FALSE if screen does not exist |
87 */ |
88 */ |
88 OWF_API_CALL OWFboolean |
89 OWF_API_CALL OWFboolean |
89 OWF_Screen_GetHeader(OWF_DISPCTX dc, OWF_SCREEN* header); |
90 OWF_Screen_GetHeader(OWFint screen, OWF_SCREEN* header); |
90 |
91 |
91 /*! |
92 OWF_API_CALL OWFboolean |
92 * \brief Validate a screen number |
93 OWF_Number_Of_Screens(OWFint *pNumberOfScreens); |
93 * |
94 |
94 * \param screen screen number |
|
95 * |
|
96 * \return OWF_TRUE if screen exists |
|
97 * \return OWF_FALSE if screen does not exist |
|
98 */ |
|
99 OWF_API_CALL OWFboolean |
95 OWF_API_CALL OWFboolean |
100 OWF_Screen_Valid(OWFint screen); |
96 OWF_Screen_Valid(OWFint screen); |
|
97 |
|
98 OWF_API_CALL OWFboolean |
|
99 OWF_Screen_Valid_And_Available(OWFint screen); |
101 |
100 |
102 /*! |
101 /*! |
103 * \brief Checks if the screen rotation support is enabled |
102 * \brief Checks if the screen rotation support is enabled |
104 * |
103 * |
105 * \param dc display context |
104 * \param screen screen number |
106 * |
105 * |
107 * \return OWF_TRUE if the screen rotation is enabled |
106 * \return OWF_TRUE if the screen rotation is enabled |
108 * \return OWF_FALSE if the screen rotation is enabled |
107 * \return OWF_FALSE if the screen rotation is enabled |
109 */ |
108 */ |
110 OWF_API_CALL OWFboolean |
109 OWF_API_CALL OWFboolean |
111 OWF_Screen_Rotation_Supported(OWF_DISPCTX dc); |
110 OWF_Screen_Rotation_Supported(OWFint screen); |
112 |
111 |
113 /*! |
112 /*! |
114 * \brief Create a new screen |
113 * \brief Create a new screen |
115 * |
114 * |
116 * \param dc display context |
115 * \param width |
117 * \param screen screen number |
116 * \param height |
118 * |
117 * |
119 * \return OWF_TRUE if screen exists |
118 * \return screen number |
120 * \return OWF_FALSE if screen does not exist |
|
121 */ |
119 */ |
122 OWF_API_CALL OWFboolean |
120 OWF_API_CALL OWFint |
123 OWF_Screen_Create(OWFint screen, OWF_DISPCTX dc); |
121 OWF_Screen_Create(OWFint width, OWFint height, OWF_SCREEN_CALLBACK func, void* obj); |
124 |
122 |
125 /*! |
123 /*! |
126 * \brief Destroy a screen |
124 * \brief Destroy a screen |
127 * |
125 * |
128 * \param dc display context |
126 * \param screen number |
129 * |
127 * |
130 * \return OWF_TRUE if screen exists |
128 * \return OWF_TRUE if screen exists |
131 * \return OWF_FALSE if screen does not exist |
129 * \return OWF_FALSE if screen does not exist |
132 */ |
130 */ |
133 OWF_API_CALL void |
131 OWF_API_CALL void |
134 OWF_Screen_Destroy(OWF_DISPCTX dc); |
132 OWF_Screen_Destroy(OWFint screenNumber); |
|
133 |
|
134 /*! |
|
135 * \brief Resize screen |
|
136 * |
|
137 * \param width |
|
138 * \param height |
|
139 * |
|
140 * \return OWF_TRUE if resize OK |
|
141 * \return OWF_FALSE if resize failed. |
|
142 */ |
|
143 OWF_API_CALL OWFboolean |
|
144 OWF_Screen_Resize(OWFint screen, OWFint width, OWFint height); |
135 |
145 |
136 /*! |
146 /*! |
137 * \brief Blit image to screen |
147 * \brief Blit image to screen |
138 * |
148 * |
139 * \param dc display context |
149 * \param screen screen number |
140 * \param dc stream the stream containing the buffer to be displayed |
150 * \param rotation the context rotation |
141 * rotation the current context rotation |
|
142 * |
151 * |
143 * \return OWF_TRUE if screen exists and blitting is OK |
152 * \return OWF_TRUE if screen exists and blitting is OK |
144 * \return OWF_FALSE if screen does not exist or blitting is not allowed. |
153 * \return OWF_FALSE if screen does not exist or blitting is not allowed. |
145 */ |
154 */ |
146 OWF_API_CALL OWFboolean |
155 OWF_API_CALL OWFboolean |
147 OWF_Screen_Post_Topmost_Layer(OWF_DISPCTX dc, OWFNativeStreamType stream, OWF_ROTATION rotation); |
156 OWF_Screen_Blit(OWFint screen, void* buffer, OWF_ROTATION rotation); |
|
157 |
|
158 /*! |
|
159 * \brief Notify objects |
|
160 * |
|
161 * Send data to objects associated with screens |
|
162 * |
|
163 * \param data |
|
164 * |
|
165 */ |
|
166 OWF_API_CALL void |
|
167 OWF_Screen_Notify(void* data); |
148 |
168 |
149 #ifdef __cplusplus |
169 #ifdef __cplusplus |
150 } |
170 } |
151 #endif |
171 #endif |
152 |
172 |