diff options
author | Nobuhiko Tanibata <NOBUHIKO_TANIBATA@denso.co.jp> | 2013-11-27 10:51:14 +0900 |
---|---|---|
committer | Nobuhiko Tanibata <NOBUHIKO_TANIBATA@denso.co.jp> | 2013-11-27 11:41:48 +0900 |
commit | 725c725e14b2da11d1e0bdfb822f73d8c2c2e9a3 (patch) | |
tree | 653361e0f7539b7bd575e960c3965b89b0e762bd /ivi-layermanagement-api/ilmCommon | |
parent | a018acfb7deb4d0975781c3c5492ba30fe5cfa58 (diff) | |
download | wayland-ivi-extension-725c725e14b2da11d1e0bdfb822f73d8c2c2e9a3.tar.gz |
ivi-layermanagement-api: Set-up to build ivi layer management APIs
Setting files for cmake and related headers and source of ivi-extension
protocols for wayland client.
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@denso.co.jp>
Diffstat (limited to 'ivi-layermanagement-api/ilmCommon')
5 files changed, 1283 insertions, 0 deletions
diff --git a/ivi-layermanagement-api/ilmCommon/CMakeLists.txt b/ivi-layermanagement-api/ilmCommon/CMakeLists.txt new file mode 100644 index 0000000..ac077f2 --- /dev/null +++ b/ivi-layermanagement-api/ilmCommon/CMakeLists.txt @@ -0,0 +1,95 @@ +############################################################################ +# +# Copyright 2010-2012 BMW Car IT GmbH +# Copyright (C) 2013 DENSO CORPORATION +# +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +############################################################################ + +cmake_minimum_required (VERSION 2.6) + +project(ilmCommon) +project_type(CORE) + +find_package(Threads) +find_package(Wayland REQUIRED) + +add_custom_command( + OUTPUT ivi-application-client-protocol.h + COMMAND ${CMAKE_INSTALL_PREFIX}/bin/wayland-scanner client-header <${CMAKE_SOURCE_DIR}/protocol/ivi-application.xml> ${CMAKE_SOURCE_DIR}/ivi-layermanagement-api/ilmCommon/include/ivi-application-client-protocol.h +) + +add_custom_command( + OUTPUT ivi-application-protocol.c + COMMAND ${CMAKE_INSTALL_PREFIX}/bin/wayland-scanner code <${CMAKE_SOURCE_DIR}/protocol/ivi-application.xml> ${CMAKE_SOURCE_DIR}/ivi-layermanagement-api/ilmCommon/src/ivi-application-protocol.c +) + +add_custom_command( + OUTPUT ivi-controller-client-protocol.h + COMMAND ${CMAKE_INSTALL_PREFIX}/bin/wayland-scanner client-header <${CMAKE_SOURCE_DIR}/protocol/ivi-controller.xml> ${CMAKE_SOURCE_DIR}/ivi-layermanagement-api/ilmCommon/include/ivi-controller-client-protocol.h +) + +add_custom_command( + OUTPUT ivi-controller-protocol.c + COMMAND ${CMAKE_INSTALL_PREFIX}/bin/wayland-scanner code <${CMAKE_SOURCE_DIR}/protocol/ivi-controller.xml> ${CMAKE_SOURCE_DIR}/ivi-layermanagement-api/ilmCommon/src/ivi-controller-protocol.c +) + +add_custom_target( + generate_wayland_protocol_codes_for_client + DEPENDS ivi-application-client-protocol.h ivi-application-protocol.c ivi-controller-client-protocol.h ivi-controller-protocol.c +) + +include_directories( + "include" + "${CMAKE_SOURCE_DIR}/ivi-layermanagement-api/ilmCommon/include" + ${WAYLAND_CLIENT_INCLUDE_DIR} +) + + +add_library(${PROJECT_NAME} SHARED + src/ilm_common.c + src/ilm_common_wayland_platform.c + src/ivi-application-protocol.c + src/ivi-controller-protocol.c +) + +add_dependencies(${PROJECT_NAME} + generate_wayland_protocol_codes_for_client + ${WAYLAND_CLIENT_LIBRARIES} +) + +set(LIBS + ${LIBS} + rt + dl + ${CMAKE_THREAD_LIBS_INIT} + ${WAYLAND_CLIENT_LIBRARIES} +) + +target_link_libraries(${PROJECT_NAME} ${LIBS} -ldl) + +install ( + TARGETS ${PROJECT_NAME} + LIBRARY DESTINATION lib +) + +install ( + FILES ${CMAKE_SOURCE_DIR}/ivi-layermanagement-api/ilmCommon/include/ilm_common.h + ${CMAKE_SOURCE_DIR}/ivi-layermanagement-api/ilmCommon/include/ilm_types.h + ${CMAKE_SOURCE_DIR}/ivi-layermanagement-api/ilmCommon/include/ilm_configuration.h + ${CMAKE_SOURCE_DIR}/ivi-layermanagement-api/ilmCommon/include/ilm_tools.h + ${CMAKE_SOURCE_DIR}/ivi-layermanagement-api/ilmCommon/include/ilm_platform.h + DESTINATION include/ilm +) diff --git a/ivi-layermanagement-api/ilmCommon/include/ivi-application-client-protocol.h b/ivi-layermanagement-api/ilmCommon/include/ivi-application-client-protocol.h new file mode 100644 index 0000000..3afe159 --- /dev/null +++ b/ivi-layermanagement-api/ilmCommon/include/ivi-application-client-protocol.h @@ -0,0 +1,178 @@ +/* + * Copyright (C) 2013 DENSO CORPORATION + * Copyright (c) 2013 BMW Car IT GmbH + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ + +#ifndef IVI_APPLICATION_CLIENT_PROTOCOL_H +#define IVI_APPLICATION_CLIENT_PROTOCOL_H + +#ifdef __cplusplus +extern "C" { +#endif + +#include <stdint.h> +#include <stddef.h> +#include "wayland-client.h" + +struct wl_client; +struct wl_resource; + +struct ivi_surface; +struct ivi_application; + +extern const struct wl_interface ivi_surface_interface; +extern const struct wl_interface ivi_application_interface; + +/** + * ivi_surface - Tell property change of ivi_surface to application + * @visibility: visibility of ivi_surface has changed + * + * + */ +struct ivi_surface_listener { + /** + * visibility - visibility of ivi_surface has changed + * @visibility: (none) + * + * + */ + void (*visibility)(void *data, + struct ivi_surface *ivi_surface, + int32_t visibility); +}; + +static inline int +ivi_surface_add_listener(struct ivi_surface *ivi_surface, + const struct ivi_surface_listener *listener, void *data) +{ + return wl_proxy_add_listener((struct wl_proxy *) ivi_surface, + (void (**)(void)) listener, data); +} + +#define IVI_SURFACE_DESTROY 0 + +static inline void +ivi_surface_set_user_data(struct ivi_surface *ivi_surface, void *user_data) +{ + wl_proxy_set_user_data((struct wl_proxy *) ivi_surface, user_data); +} + +static inline void * +ivi_surface_get_user_data(struct ivi_surface *ivi_surface) +{ + return wl_proxy_get_user_data((struct wl_proxy *) ivi_surface); +} + +static inline void +ivi_surface_destroy(struct ivi_surface *ivi_surface) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_surface, + IVI_SURFACE_DESTROY); + + wl_proxy_destroy((struct wl_proxy *) ivi_surface); +} + +#ifndef IVI_APPLICATION_ERROR_CODE_ENUM +#define IVI_APPLICATION_ERROR_CODE_ENUM +/** + * ivi_application_error_code - possible error codes returned in error + * event + * @IVI_APPLICATION_ERROR_CODE_UNKNOWN_ERROR: unknown error encountered + * @IVI_APPLICATION_ERROR_CODE_RESOURCE_IN_USE: resource is in use and + * can not be shared + * + * + */ +enum ivi_application_error_code { + IVI_APPLICATION_ERROR_CODE_UNKNOWN_ERROR = 1, + IVI_APPLICATION_ERROR_CODE_RESOURCE_IN_USE = 2, +}; +#endif /* IVI_APPLICATION_ERROR_CODE_ENUM */ + +/** + * ivi_application - creation of ivi_surface + * @error: request resulted in server-side error + * + * + */ +struct ivi_application_listener { + /** + * error - request resulted in server-side error + * @error_code: (none) + * @error_text: (none) + * + * + */ + void (*error)(void *data, + struct ivi_application *ivi_application, + int32_t error_code, + const char *error_text); +}; + +static inline int +ivi_application_add_listener(struct ivi_application *ivi_application, + const struct ivi_application_listener *listener, void *data) +{ + return wl_proxy_add_listener((struct wl_proxy *) ivi_application, + (void (**)(void)) listener, data); +} + +#define IVI_APPLICATION_SURFACE_CREATE 0 + +static inline void +ivi_application_set_user_data(struct ivi_application *ivi_application, void *user_data) +{ + wl_proxy_set_user_data((struct wl_proxy *) ivi_application, user_data); +} + +static inline void * +ivi_application_get_user_data(struct ivi_application *ivi_application) +{ + return wl_proxy_get_user_data((struct wl_proxy *) ivi_application); +} + +static inline void +ivi_application_destroy(struct ivi_application *ivi_application) +{ + wl_proxy_destroy((struct wl_proxy *) ivi_application); +} + +static inline struct ivi_surface * +ivi_application_surface_create(struct ivi_application *ivi_application, uint32_t id_surface, struct wl_surface *surface) +{ + struct wl_proxy *id; + + id = wl_proxy_create((struct wl_proxy *) ivi_application, + &ivi_surface_interface); + if (!id) + return NULL; + + wl_proxy_marshal((struct wl_proxy *) ivi_application, + IVI_APPLICATION_SURFACE_CREATE, id_surface, surface, id); + + return (struct ivi_surface *) id; +} + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/ivi-layermanagement-api/ilmCommon/include/ivi-controller-client-protocol.h b/ivi-layermanagement-api/ilmCommon/include/ivi-controller-client-protocol.h new file mode 100644 index 0000000..84851e0 --- /dev/null +++ b/ivi-layermanagement-api/ilmCommon/include/ivi-controller-client-protocol.h @@ -0,0 +1,793 @@ +/* + * Copyright (C) 2013 DENSO CORPORATION + * Copyright (c) 2013 BMW Car IT GmbH + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ + +#ifndef IVI_CONTROLLER_CLIENT_PROTOCOL_H +#define IVI_CONTROLLER_CLIENT_PROTOCOL_H + +#ifdef __cplusplus +extern "C" { +#endif + +#include <stdint.h> +#include <stddef.h> +#include "wayland-client.h" + +struct wl_client; +struct wl_resource; + +struct ivi_controller_surface; +struct ivi_controller_layer; +struct ivi_controller_screen; +struct ivi_controller; + +extern const struct wl_interface ivi_controller_surface_interface; +extern const struct wl_interface ivi_controller_layer_interface; +extern const struct wl_interface ivi_controller_screen_interface; +extern const struct wl_interface ivi_controller_interface; + +#ifndef IVI_CONTROLLER_SURFACE_ORIENTATION_ENUM +#define IVI_CONTROLLER_SURFACE_ORIENTATION_ENUM +/** + * ivi_controller_surface_orientation - orientation presets in degrees + * @IVI_CONTROLLER_SURFACE_ORIENTATION_0_DEGREES: not rotated + * @IVI_CONTROLLER_SURFACE_ORIENTATION_90_DEGREES: rotated 90 degrees + * clockwise + * @IVI_CONTROLLER_SURFACE_ORIENTATION_180_DEGREES: rotated 180 degrees + * clockwise + * @IVI_CONTROLLER_SURFACE_ORIENTATION_270_DEGREES: rotated 270 degrees + * clockwise + * + * + */ +enum ivi_controller_surface_orientation { + IVI_CONTROLLER_SURFACE_ORIENTATION_0_DEGREES = 0, + IVI_CONTROLLER_SURFACE_ORIENTATION_90_DEGREES = 1, + IVI_CONTROLLER_SURFACE_ORIENTATION_180_DEGREES = 2, + IVI_CONTROLLER_SURFACE_ORIENTATION_270_DEGREES = 3, +}; +#endif /* IVI_CONTROLLER_SURFACE_ORIENTATION_ENUM */ + +#ifndef IVI_CONTROLLER_SURFACE_PIXELFORMAT_ENUM +#define IVI_CONTROLLER_SURFACE_PIXELFORMAT_ENUM +/** + * ivi_controller_surface_pixelformat - pixel format values + * @IVI_CONTROLLER_SURFACE_PIXELFORMAT_R_8: 8 bit luminance surface + * @IVI_CONTROLLER_SURFACE_PIXELFORMAT_RGB_888: 24 bit rgb surface + * @IVI_CONTROLLER_SURFACE_PIXELFORMAT_RGBA_8888: 24 bit rgb surface with + * 8 bit alpha + * @IVI_CONTROLLER_SURFACE_PIXELFORMAT_RGB_565: 16 bit rgb surface + * @IVI_CONTROLLER_SURFACE_PIXELFORMAT_RGBA_5551: 16 bit rgb surface with + * binary mask + * @IVI_CONTROLLER_SURFACE_PIXELFORMAT_RGBA_6661: 18 bit rgb surface with + * binary mask + * @IVI_CONTROLLER_SURFACE_PIXELFORMAT_RGBA_4444: 12 bit rgb surface with + * 4 bit alpha + * @IVI_CONTROLLER_SURFACE_PIXELFORMAT_UNKNOWN: unknown + * + * + */ +enum ivi_controller_surface_pixelformat { + IVI_CONTROLLER_SURFACE_PIXELFORMAT_R_8 = 0, + IVI_CONTROLLER_SURFACE_PIXELFORMAT_RGB_888 = 1, + IVI_CONTROLLER_SURFACE_PIXELFORMAT_RGBA_8888 = 2, + IVI_CONTROLLER_SURFACE_PIXELFORMAT_RGB_565 = 3, + IVI_CONTROLLER_SURFACE_PIXELFORMAT_RGBA_5551 = 4, + IVI_CONTROLLER_SURFACE_PIXELFORMAT_RGBA_6661 = 5, + IVI_CONTROLLER_SURFACE_PIXELFORMAT_RGBA_4444 = 6, + IVI_CONTROLLER_SURFACE_PIXELFORMAT_UNKNOWN = 7, +}; +#endif /* IVI_CONTROLLER_SURFACE_PIXELFORMAT_ENUM */ + +#ifndef IVI_CONTROLLER_SURFACE_CONTENT_STATE_ENUM +#define IVI_CONTROLLER_SURFACE_CONTENT_STATE_ENUM +/** + * ivi_controller_surface_content_state - all possible states of content + * for a surface + * @IVI_CONTROLLER_SURFACE_CONTENT_STATE_CONTENT_AVAILABLE: application + * provided wl_surface for this surface + * @IVI_CONTROLLER_SURFACE_CONTENT_STATE_CONTENT_REMOVED: wl_surface was + * removed for this surface + * + * + */ +enum ivi_controller_surface_content_state { + IVI_CONTROLLER_SURFACE_CONTENT_STATE_CONTENT_AVAILABLE = 1, + IVI_CONTROLLER_SURFACE_CONTENT_STATE_CONTENT_REMOVED = 2, +}; +#endif /* IVI_CONTROLLER_SURFACE_CONTENT_STATE_ENUM */ + +/** + * ivi_controller_surface - Request property change of ivi_surface to + * server + * @visibility: sent in response to set_visibility + * @opacity: sent in response to set_opacity + * @source_rectangle: sent in response to set_source_rectangle + * @destination_rectangle: sent in response to set_destination_rectangle + * @configuration: sent in response to set_configuration + * @orientation: sent in response to set_orientation + * @pixelformat: pixelformat + * @layer: Receive a ivi_layer this ivi_surface belongs + * @stats: sent in response to send_stats + * @destroyed: destroyed surface event + * @content: content state for surface has changed + * + * + */ +struct ivi_controller_surface_listener { + /** + * visibility - sent in response to set_visibility + * @visibility: (none) + * + * + */ + void (*visibility)(void *data, + struct ivi_controller_surface *ivi_controller_surface, + int32_t visibility); + /** + * opacity - sent in response to set_opacity + * @opacity: (none) + * + * + */ + void (*opacity)(void *data, + struct ivi_controller_surface *ivi_controller_surface, + wl_fixed_t opacity); + /** + * source_rectangle - sent in response to set_source_rectangle + * @x: (none) + * @y: (none) + * @width: (none) + * @height: (none) + * + * + */ + void (*source_rectangle)(void *data, + struct ivi_controller_surface *ivi_controller_surface, + int32_t x, + int32_t y, + int32_t width, + int32_t height); + /** + * destination_rectangle - sent in response to + * set_destination_rectangle + * @x: (none) + * @y: (none) + * @width: (none) + * @height: (none) + * + * + */ + void (*destination_rectangle)(void *data, + struct ivi_controller_surface *ivi_controller_surface, + int32_t x, + int32_t y, + int32_t width, + int32_t height); + /** + * configuration - sent in response to set_configuration + * @width: (none) + * @height: (none) + * + * + */ + void (*configuration)(void *data, + struct ivi_controller_surface *ivi_controller_surface, + int32_t width, + int32_t height); + /** + * orientation - sent in response to set_orientation + * @orientation: (none) + * + * + */ + void (*orientation)(void *data, + struct ivi_controller_surface *ivi_controller_surface, + int32_t orientation); + /** + * pixelformat - pixelformat + * @pixelformat: (none) + * + * + */ + void (*pixelformat)(void *data, + struct ivi_controller_surface *ivi_controller_surface, + int32_t pixelformat); + /** + * layer - Receive a ivi_layer this ivi_surface belongs + * @layer: (none) + * + * + */ + void (*layer)(void *data, + struct ivi_controller_surface *ivi_controller_surface, + struct ivi_controller_layer *layer); + /** + * stats - sent in response to send_stats + * @redraw_count: (none) + * @frame_count: (none) + * @update_count: (none) + * @pid: (none) + * + * + */ + void (*stats)(void *data, + struct ivi_controller_surface *ivi_controller_surface, + uint32_t redraw_count, + uint32_t frame_count, + uint32_t update_count, + uint32_t pid); + /** + * destroyed - destroyed surface event + * + * + */ + void (*destroyed)(void *data, + struct ivi_controller_surface *ivi_controller_surface); + /** + * content - content state for surface has changed + * @content_state: (none) + * + * + */ + void (*content)(void *data, + struct ivi_controller_surface *ivi_controller_surface, + int32_t content_state); +}; + +static inline int +ivi_controller_surface_add_listener(struct ivi_controller_surface *ivi_controller_surface, + const struct ivi_controller_surface_listener *listener, void *data) +{ + return wl_proxy_add_listener((struct wl_proxy *) ivi_controller_surface, + (void (**)(void)) listener, data); +} + +#define IVI_CONTROLLER_SURFACE_SET_VISIBILITY 0 +#define IVI_CONTROLLER_SURFACE_SET_OPACITY 1 +#define IVI_CONTROLLER_SURFACE_SET_SOURCE_RECTANGLE 2 +#define IVI_CONTROLLER_SURFACE_SET_DESTINATION_RECTANGLE 3 +#define IVI_CONTROLLER_SURFACE_SET_CONFIGURATION 4 +#define IVI_CONTROLLER_SURFACE_SET_ORIENTATION 5 +#define IVI_CONTROLLER_SURFACE_SCREENSHOT 6 +#define IVI_CONTROLLER_SURFACE_SEND_STATS 7 +#define IVI_CONTROLLER_SURFACE_DESTROY 8 + +static inline void +ivi_controller_surface_set_user_data(struct ivi_controller_surface *ivi_controller_surface, void *user_data) +{ + wl_proxy_set_user_data((struct wl_proxy *) ivi_controller_surface, user_data); +} + +static inline void * +ivi_controller_surface_get_user_data(struct ivi_controller_surface *ivi_controller_surface) +{ + return wl_proxy_get_user_data((struct wl_proxy *) ivi_controller_surface); +} + +static inline void +ivi_controller_surface_set_visibility(struct ivi_controller_surface *ivi_controller_surface, uint32_t visibility) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_surface, + IVI_CONTROLLER_SURFACE_SET_VISIBILITY, visibility); +} + +static inline void +ivi_controller_surface_set_opacity(struct ivi_controller_surface *ivi_controller_surface, wl_fixed_t opacity) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_surface, + IVI_CONTROLLER_SURFACE_SET_OPACITY, opacity); +} + +static inline void +ivi_controller_surface_set_source_rectangle(struct ivi_controller_surface *ivi_controller_surface, int32_t x, int32_t y, int32_t width, int32_t height) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_surface, + IVI_CONTROLLER_SURFACE_SET_SOURCE_RECTANGLE, x, y, width, height); +} + +static inline void +ivi_controller_surface_set_destination_rectangle(struct ivi_controller_surface *ivi_controller_surface, int32_t x, int32_t y, int32_t width, int32_t height) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_surface, + IVI_CONTROLLER_SURFACE_SET_DESTINATION_RECTANGLE, x, y, width, height); +} + +static inline void +ivi_controller_surface_set_configuration(struct ivi_controller_surface *ivi_controller_surface, int32_t width, int32_t height) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_surface, + IVI_CONTROLLER_SURFACE_SET_CONFIGURATION, width, height); +} + +static inline void +ivi_controller_surface_set_orientation(struct ivi_controller_surface *ivi_controller_surface, int32_t orientation) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_surface, + IVI_CONTROLLER_SURFACE_SET_ORIENTATION, orientation); +} + +static inline void +ivi_controller_surface_screenshot(struct ivi_controller_surface *ivi_controller_surface, const char *filename) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_surface, + IVI_CONTROLLER_SURFACE_SCREENSHOT, filename); +} + +static inline void +ivi_controller_surface_send_stats(struct ivi_controller_surface *ivi_controller_surface) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_surface, + IVI_CONTROLLER_SURFACE_SEND_STATS); +} + +static inline void +ivi_controller_surface_destroy(struct ivi_controller_surface *ivi_controller_surface, int32_t destroy_scene_object) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_surface, + IVI_CONTROLLER_SURFACE_DESTROY, destroy_scene_object); + + wl_proxy_destroy((struct wl_proxy *) ivi_controller_surface); +} + +/** + * ivi_controller_layer - Request property change of ivi_layer and + * add/remove ivi_surface from ivi_layer to server + * @visibility: sent in response to set_visibility + * @opacity: sent in response to set_opacity + * @source_rectangle: sent in response to set_source_rectangle + * @destination_rectangle: sent in response to set_destination_rectangle + * @configuration: sent in response to set_configuration + * @orientation: sent in response to set_orientation + * @screen: Receive a wl_output this ivi_layer belongs + * @destroyed: destroyed layer event + * + * + */ +struct ivi_controller_layer_listener { + /** + * visibility - sent in response to set_visibility + * @visibility: (none) + * + * + */ + void (*visibility)(void *data, + struct ivi_controller_layer *ivi_controller_layer, + int32_t visibility); + /** + * opacity - sent in response to set_opacity + * @opacity: (none) + * + * + */ + void (*opacity)(void *data, + struct ivi_controller_layer *ivi_controller_layer, + wl_fixed_t opacity); + /** + * source_rectangle - sent in response to set_source_rectangle + * @x: (none) + * @y: (none) + * @width: (none) + * @height: (none) + * + * + */ + void (*source_rectangle)(void *data, + struct ivi_controller_layer *ivi_controller_layer, + int32_t x, + int32_t y, + int32_t width, + int32_t height); + /** + * destination_rectangle - sent in response to + * set_destination_rectangle + * @x: (none) + * @y: (none) + * @width: (none) + * @height: (none) + * + * + */ + void (*destination_rectangle)(void *data, + struct ivi_controller_layer *ivi_controller_layer, + int32_t x, + int32_t y, + int32_t width, + int32_t height); + /** + * configuration - sent in response to set_configuration + * @width: (none) + * @height: (none) + * + * + */ + void (*configuration)(void *data, + struct ivi_controller_layer *ivi_controller_layer, + int32_t width, + int32_t height); + /** + * orientation - sent in response to set_orientation + * @orientation: (none) + * + * + */ + void (*orientation)(void *data, + struct ivi_controller_layer *ivi_controller_layer, + int32_t orientation); + /** + * screen - Receive a wl_output this ivi_layer belongs + * @screen: (none) + * + * + */ + void (*screen)(void *data, + struct ivi_controller_layer *ivi_controller_layer, + struct wl_output *screen); + /** + * destroyed - destroyed layer event + * + * + */ + void (*destroyed)(void *data, + struct ivi_controller_layer *ivi_controller_layer); +}; + +static inline int +ivi_controller_layer_add_listener(struct ivi_controller_layer *ivi_controller_layer, + const struct ivi_controller_layer_listener *listener, void *data) +{ + return wl_proxy_add_listener((struct wl_proxy *) ivi_controller_layer, + (void (**)(void)) listener, data); +} + +#define IVI_CONTROLLER_LAYER_SET_VISIBILITY 0 +#define IVI_CONTROLLER_LAYER_SET_OPACITY 1 +#define IVI_CONTROLLER_LAYER_SET_SOURCE_RECTANGLE 2 +#define IVI_CONTROLLER_LAYER_SET_DESTINATION_RECTANGLE 3 +#define IVI_CONTROLLER_LAYER_SET_CONFIGURATION 4 +#define IVI_CONTROLLER_LAYER_SET_ORIENTATION 5 +#define IVI_CONTROLLER_LAYER_SCREENSHOT 6 +#define IVI_CONTROLLER_LAYER_CLEAR_SURFACES 7 +#define IVI_CONTROLLER_LAYER_ADD_SURFACE 8 +#define IVI_CONTROLLER_LAYER_REMOVE_SURFACE 9 +#define IVI_CONTROLLER_LAYER_SET_RENDER_ORDER 10 +#define IVI_CONTROLLER_LAYER_DESTROY 11 + +static inline void +ivi_controller_layer_set_user_data(struct ivi_controller_layer *ivi_controller_layer, void *user_data) +{ + wl_proxy_set_user_data((struct wl_proxy *) ivi_controller_layer, user_data); +} + +static inline void * +ivi_controller_layer_get_user_data(struct ivi_controller_layer *ivi_controller_layer) +{ + return wl_proxy_get_user_data((struct wl_proxy *) ivi_controller_layer); +} + +static inline void +ivi_controller_layer_set_visibility(struct ivi_controller_layer *ivi_controller_layer, uint32_t visibility) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_layer, + IVI_CONTROLLER_LAYER_SET_VISIBILITY, visibility); +} + +static inline void +ivi_controller_layer_set_opacity(struct ivi_controller_layer *ivi_controller_layer, wl_fixed_t opacity) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_layer, + IVI_CONTROLLER_LAYER_SET_OPACITY, opacity); +} + +static inline void +ivi_controller_layer_set_source_rectangle(struct ivi_controller_layer *ivi_controller_layer, int32_t x, int32_t y, int32_t width, int32_t height) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_layer, + IVI_CONTROLLER_LAYER_SET_SOURCE_RECTANGLE, x, y, width, height); +} + +static inline void +ivi_controller_layer_set_destination_rectangle(struct ivi_controller_layer *ivi_controller_layer, int32_t x, int32_t y, int32_t width, int32_t height) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_layer, + IVI_CONTROLLER_LAYER_SET_DESTINATION_RECTANGLE, x, y, width, height); +} + +static inline void +ivi_controller_layer_set_configuration(struct ivi_controller_layer *ivi_controller_layer, int32_t width, int32_t height) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_layer, + IVI_CONTROLLER_LAYER_SET_CONFIGURATION, width, height); +} + +static inline void +ivi_controller_layer_set_orientation(struct ivi_controller_layer *ivi_controller_layer, int32_t orientation) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_layer, + IVI_CONTROLLER_LAYER_SET_ORIENTATION, orientation); +} + +static inline void +ivi_controller_layer_screenshot(struct ivi_controller_layer *ivi_controller_layer, const char *filename) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_layer, + IVI_CONTROLLER_LAYER_SCREENSHOT, filename); +} + +static inline void +ivi_controller_layer_clear_surfaces(struct ivi_controller_layer *ivi_controller_layer) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_layer, + IVI_CONTROLLER_LAYER_CLEAR_SURFACES); +} + +static inline void +ivi_controller_layer_add_surface(struct ivi_controller_layer *ivi_controller_layer, struct ivi_controller_surface *surface) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_layer, + IVI_CONTROLLER_LAYER_ADD_SURFACE, surface); +} + +static inline void +ivi_controller_layer_remove_surface(struct ivi_controller_layer *ivi_controller_layer, struct ivi_controller_surface *surface) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_layer, + IVI_CONTROLLER_LAYER_REMOVE_SURFACE, surface); +} + +static inline void +ivi_controller_layer_set_render_order(struct ivi_controller_layer *ivi_controller_layer, struct wl_array *id_surfaces) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_layer, + IVI_CONTROLLER_LAYER_SET_RENDER_ORDER, id_surfaces); +} + +static inline void +ivi_controller_layer_destroy(struct ivi_controller_layer *ivi_controller_layer, int32_t destroy_scene_object) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_layer, + IVI_CONTROLLER_LAYER_DESTROY, destroy_scene_object); + + wl_proxy_destroy((struct wl_proxy *) ivi_controller_layer); +} + +#define IVI_CONTROLLER_SCREEN_DESTROY 0 +#define IVI_CONTROLLER_SCREEN_CLEAR 1 +#define IVI_CONTROLLER_SCREEN_ADD_LAYER 2 +#define IVI_CONTROLLER_SCREEN_SCREENSHOT 3 +#define IVI_CONTROLLER_SCREEN_SET_RENDER_ORDER 4 + +static inline void +ivi_controller_screen_set_user_data(struct ivi_controller_screen *ivi_controller_screen, void *user_data) +{ + wl_proxy_set_user_data((struct wl_proxy *) ivi_controller_screen, user_data); +} + +static inline void * +ivi_controller_screen_get_user_data(struct ivi_controller_screen *ivi_controller_screen) +{ + return wl_proxy_get_user_data((struct wl_proxy *) ivi_controller_screen); +} + +static inline void +ivi_controller_screen_destroy(struct ivi_controller_screen *ivi_controller_screen) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_screen, + IVI_CONTROLLER_SCREEN_DESTROY); + + wl_proxy_destroy((struct wl_proxy *) ivi_controller_screen); +} + +static inline void +ivi_controller_screen_clear(struct ivi_controller_screen *ivi_controller_screen) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_screen, + IVI_CONTROLLER_SCREEN_CLEAR); +} + +static inline void +ivi_controller_screen_add_layer(struct ivi_controller_screen *ivi_controller_screen, struct ivi_controller_layer *layer) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_screen, + IVI_CONTROLLER_SCREEN_ADD_LAYER, layer); +} + +static inline void +ivi_controller_screen_screenshot(struct ivi_controller_screen *ivi_controller_screen, const char *filename) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_screen, + IVI_CONTROLLER_SCREEN_SCREENSHOT, filename); +} + +static inline void +ivi_controller_screen_set_render_order(struct ivi_controller_screen *ivi_controller_screen, struct wl_array *id_layers) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller_screen, + IVI_CONTROLLER_SCREEN_SET_RENDER_ORDER, id_layers); +} + +#ifndef IVI_CONTROLLER_OBJECT_TYPE_ENUM +#define IVI_CONTROLLER_OBJECT_TYPE_ENUM +/** + * ivi_controller_object_type - available object types in ivi compositor + * scene + * @IVI_CONTROLLER_OBJECT_TYPE_SURFACE: surface object type + * @IVI_CONTROLLER_OBJECT_TYPE_LAYER: layer object type + * @IVI_CONTROLLER_OBJECT_TYPE_SCREEN: screen object type + * + * + */ +enum ivi_controller_object_type { + IVI_CONTROLLER_OBJECT_TYPE_SURFACE = 1, + IVI_CONTROLLER_OBJECT_TYPE_LAYER = 2, + IVI_CONTROLLER_OBJECT_TYPE_SCREEN = 3, +}; +#endif /* IVI_CONTROLLER_OBJECT_TYPE_ENUM */ + +#ifndef IVI_CONTROLLER_ERROR_CODE_ENUM +#define IVI_CONTROLLER_ERROR_CODE_ENUM +/** + * ivi_controller_error_code - possible error codes returned in error + * event + * @IVI_CONTROLLER_ERROR_CODE_UNKNOWN_ERROR: unknown error encountered + * @IVI_CONTROLLER_ERROR_CODE_FILE_ERROR: file i/o error encountered + * + * + */ +enum ivi_controller_error_code { + IVI_CONTROLLER_ERROR_CODE_UNKNOWN_ERROR = 1, + IVI_CONTROLLER_ERROR_CODE_FILE_ERROR = 2, +}; +#endif /* IVI_CONTROLLER_ERROR_CODE_ENUM */ + +/** + * ivi_controller - Interface for central controller of layers and + * surfaces + * @screen: Receive new additional screen controller + * @layer: Receive id_layer and a layer controller + * @surface: Receive id_surface and a controller to control ivi_surface + * @error: request resulted in server-side error + * + * + */ +struct ivi_controller_listener { + /** + * screen - Receive new additional screen controller + * @id_screen: (none) + * @screen: (none) + * + * + */ + void (*screen)(void *data, + struct ivi_controller *ivi_controller, + uint32_t id_screen, + struct ivi_controller_screen *screen); + /** + * layer - Receive id_layer and a layer controller + * @id_layer: (none) + * + * + */ + void (*layer)(void *data, + struct ivi_controller *ivi_controller, + uint32_t id_layer); + /** + * surface - Receive id_surface and a controller to control + * ivi_surface + * @id_surface: (none) + * + * + */ + void (*surface)(void *data, + struct ivi_controller *ivi_controller, + uint32_t id_surface); + /** + * error - request resulted in server-side error + * @object_id: (none) + * @object_type: (none) + * @error_code: (none) + * @error_text: (none) + * + * + */ + void (*error)(void *data, + struct ivi_controller *ivi_controller, + int32_t object_id, + int32_t object_type, + int32_t error_code, + const char *error_text); +}; + +static inline int +ivi_controller_add_listener(struct ivi_controller *ivi_controller, + const struct ivi_controller_listener *listener, void *data) +{ + return wl_proxy_add_listener((struct wl_proxy *) ivi_controller, + (void (**)(void)) listener, data); +} + +#define IVI_CONTROLLER_COMMIT_CHANGES 0 +#define IVI_CONTROLLER_LAYER_CREATE 1 +#define IVI_CONTROLLER_SURFACE_CREATE 2 + +static inline void +ivi_controller_set_user_data(struct ivi_controller *ivi_controller, void *user_data) +{ + wl_proxy_set_user_data((struct wl_proxy *) ivi_controller, user_data); +} + +static inline void * +ivi_controller_get_user_data(struct ivi_controller *ivi_controller) +{ + return wl_proxy_get_user_data((struct wl_proxy *) ivi_controller); +} + +static inline void +ivi_controller_destroy(struct ivi_controller *ivi_controller) +{ + wl_proxy_destroy((struct wl_proxy *) ivi_controller); +} + +static inline void +ivi_controller_commit_changes(struct ivi_controller *ivi_controller) +{ + wl_proxy_marshal((struct wl_proxy *) ivi_controller, + IVI_CONTROLLER_COMMIT_CHANGES); +} + +static inline struct ivi_controller_layer * +ivi_controller_layer_create(struct ivi_controller *ivi_controller, uint32_t id_layer, int32_t width, int32_t height) +{ + struct wl_proxy *id; + + id = wl_proxy_create((struct wl_proxy *) ivi_controller, + &ivi_controller_layer_interface); + if (!id) + return NULL; + + wl_proxy_marshal((struct wl_proxy *) ivi_controller, + IVI_CONTROLLER_LAYER_CREATE, id_layer, width, height, id); + + return (struct ivi_controller_layer *) id; +} + +static inline struct ivi_controller_surface * +ivi_controller_surface_create(struct ivi_controller *ivi_controller, uint32_t id_surface) +{ + struct wl_proxy *id; + + id = wl_proxy_create((struct wl_proxy *) ivi_controller, + &ivi_controller_surface_interface); + if (!id) + return NULL; + + wl_proxy_marshal((struct wl_proxy *) ivi_controller, + IVI_CONTROLLER_SURFACE_CREATE, id_surface, id); + + return (struct ivi_controller_surface *) id; +} + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/ivi-layermanagement-api/ilmCommon/src/ivi-application-protocol.c b/ivi-layermanagement-api/ilmCommon/src/ivi-application-protocol.c new file mode 100644 index 0000000..f7b5439 --- /dev/null +++ b/ivi-layermanagement-api/ilmCommon/src/ivi-application-protocol.c @@ -0,0 +1,65 @@ +/* + * Copyright (C) 2013 DENSO CORPORATION + * Copyright (c) 2013 BMW Car IT GmbH + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ + +#include <stdlib.h> +#include <stdint.h> +#include "wayland-util.h" + +extern const struct wl_interface wl_surface_interface; +extern const struct wl_interface ivi_surface_interface; + +static const struct wl_interface *types[] = { + NULL, + NULL, + NULL, + &wl_surface_interface, + &ivi_surface_interface, +}; + +static const struct wl_message ivi_surface_requests[] = { + { "destroy", "", types + 0 }, +}; + +static const struct wl_message ivi_surface_events[] = { + { "visibility", "i", types + 0 }, +}; + +WL_EXPORT const struct wl_interface ivi_surface_interface = { + "ivi_surface", 1, + 1, ivi_surface_requests, + 1, ivi_surface_events, +}; + +static const struct wl_message ivi_application_requests[] = { + { "surface_create", "uon", types + 2 }, +}; + +static const struct wl_message ivi_application_events[] = { + { "error", "i?s", types + 0 }, +}; + +WL_EXPORT const struct wl_interface ivi_application_interface = { + "ivi_application", 1, + 1, ivi_application_requests, + 1, ivi_application_events, +}; diff --git a/ivi-layermanagement-api/ilmCommon/src/ivi-controller-protocol.c b/ivi-layermanagement-api/ilmCommon/src/ivi-controller-protocol.c new file mode 100644 index 0000000..fa4005d --- /dev/null +++ b/ivi-layermanagement-api/ilmCommon/src/ivi-controller-protocol.c @@ -0,0 +1,152 @@ +/* + * Copyright (C) 2013 DENSO CORPORATION + * Copyright (c) 2013 BMW Car IT GmbH + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ + +#include <stdlib.h> +#include <stdint.h> +#include "wayland-util.h" + +extern const struct wl_interface ivi_controller_layer_interface; +extern const struct wl_interface ivi_controller_surface_interface; +extern const struct wl_interface ivi_controller_surface_interface; +extern const struct wl_interface wl_output_interface; +extern const struct wl_interface ivi_controller_layer_interface; +extern const struct wl_interface ivi_controller_layer_interface; +extern const struct wl_interface ivi_controller_surface_interface; +extern const struct wl_interface ivi_controller_screen_interface; + +static const struct wl_interface *types[] = { + NULL, + NULL, + NULL, + NULL, + &ivi_controller_layer_interface, + &ivi_controller_surface_interface, + &ivi_controller_surface_interface, + &wl_output_interface, + &ivi_controller_layer_interface, + NULL, + NULL, + NULL, + &ivi_controller_layer_interface, + NULL, + &ivi_controller_surface_interface, + NULL, + &ivi_controller_screen_interface, +}; + +static const struct wl_message ivi_controller_surface_requests[] = { + { "set_visibility", "u", types + 0 }, + { "set_opacity", "f", types + 0 }, + { "set_source_rectangle", "iiii", types + 0 }, + { "set_destination_rectangle", "iiii", types + 0 }, + { "set_configuration", "ii", types + 0 }, + { "set_orientation", "i", types + 0 }, + { "screenshot", "s", types + 0 }, + { "send_stats", "", types + 0 }, + { "destroy", "i", types + 0 }, +}; + +static const struct wl_message ivi_controller_surface_events[] = { + { "visibility", "i", types + 0 }, + { "opacity", "f", types + 0 }, + { "source_rectangle", "iiii", types + 0 }, + { "destination_rectangle", "iiii", types + 0 }, + { "configuration", "ii", types + 0 }, + { "orientation", "i", types + 0 }, + { "pixelformat", "i", types + 0 }, + { "layer", "?o", types + 4 }, + { "stats", "uuuu", types + 0 }, + { "destroyed", "", types + 0 }, + { "content", "i", types + 0 }, +}; + +WL_EXPORT const struct wl_interface ivi_controller_surface_interface = { + "ivi_controller_surface", 1, + 9, ivi_controller_surface_requests, + 11, ivi_controller_surface_events, +}; + +static const struct wl_message ivi_controller_layer_requests[] = { + { "set_visibility", "u", types + 0 }, + { "set_opacity", "f", types + 0 }, + { "set_source_rectangle", "iiii", types + 0 }, + { "set_destination_rectangle", "iiii", types + 0 }, + { "set_configuration", "ii", types + 0 }, + { "set_orientation", "i", types + 0 }, + { "screenshot", "s", types + 0 }, + { "clear_surfaces", "", types + 0 }, + { "add_surface", "o", types + 5 }, + { "remove_surface", "o", types + 6 }, + { "set_render_order", "a", types + 0 }, + { "destroy", "i", types + 0 }, +}; + +static const struct wl_message ivi_controller_layer_events[] = { + { "visibility", "i", types + 0 }, + { "opacity", "f", types + 0 }, + { "source_rectangle", "iiii", types + 0 }, + { "destination_rectangle", "iiii", types + 0 }, + { "configuration", "ii", types + 0 }, + { "orientation", "i", types + 0 }, + { "screen", "?o", types + 7 }, + { "destroyed", "", types + 0 }, +}; + +WL_EXPORT const struct wl_interface ivi_controller_layer_interface = { + "ivi_controller_layer", 1, + 12, ivi_controller_layer_requests, + 8, ivi_controller_layer_events, +}; + +static const struct wl_message ivi_controller_screen_requests[] = { + { "destroy", "", types + 0 }, + { "clear", "", types + 0 }, + { "add_layer", "o", types + 8 }, + { "screenshot", "s", types + 0 }, + { "set_render_order", "a", types + 0 }, +}; + +WL_EXPORT const struct wl_interface ivi_controller_screen_interface = { + "ivi_controller_screen", 1, + 5, ivi_controller_screen_requests, + 0, NULL, +}; + +static const struct wl_message ivi_controller_requests[] = { + { "commit_changes", "", types + 0 }, + { "layer_create", "uiin", types + 9 }, + { "surface_create", "un", types + 13 }, +}; + +static const struct wl_message ivi_controller_events[] = { + { "screen", "un", types + 15 }, + { "layer", "u", types + 0 }, + { "surface", "u", types + 0 }, + { "error", "iii?s", types + 0 }, +}; + +WL_EXPORT const struct wl_interface ivi_controller_interface = { + "ivi_controller", 1, + 3, ivi_controller_requests, + 4, ivi_controller_events, +}; |