summaryrefslogtreecommitdiff
path: root/ivi-layermanagement-api
diff options
context:
space:
mode:
Diffstat (limited to 'ivi-layermanagement-api')
-rw-r--r--ivi-layermanagement-api/ilmControl/src/ilm_control_wayland_platform.c23
1 files changed, 23 insertions, 0 deletions
diff --git a/ivi-layermanagement-api/ilmControl/src/ilm_control_wayland_platform.c b/ivi-layermanagement-api/ilmControl/src/ilm_control_wayland_platform.c
index c92c272..97d9633 100644
--- a/ivi-layermanagement-api/ilmControl/src/ilm_control_wayland_platform.c
+++ b/ivi-layermanagement-api/ilmControl/src/ilm_control_wayland_platform.c
@@ -1528,6 +1528,29 @@ ilm_getScreenIDs(t_ilm_uint* pNumberOfIDs, t_ilm_uint** ppIDs)
}
ILM_EXPORT ilmErrorTypes
+ilm_getScreenResolution(t_ilm_uint screenID, t_ilm_uint* pWidth, t_ilm_uint* pHeight)
+{
+ ilmErrorTypes returnValue = ILM_FAILED;
+ struct ilm_control_context *ctx = sync_and_acquire_instance();
+
+ if ((pWidth != NULL) && (pHeight != NULL))
+ {
+ struct screen_context *ctx_scrn;
+ wl_list_for_each(ctx_scrn, &ctx->wl.list_screen, link) {
+ if (screenID == ctx_scrn->id_screen) {
+ *pWidth = ctx_scrn->prop.screenWidth;
+ *pHeight = ctx_scrn->prop.screenHeight;
+ returnValue = ILM_SUCCESS;
+ break;
+ }
+ }
+ }
+
+ release_instance();
+ return returnValue;
+}
+
+ILM_EXPORT ilmErrorTypes
ilm_getLayerIDs(t_ilm_int* pLength, t_ilm_layer** ppArray)
{
ilmErrorTypes returnValue = ILM_FAILED;