diff options
9 files changed, 0 insertions, 292 deletions
diff --git a/ivi-layermanagement-api/ilmCommon/include/ilm_types.h b/ivi-layermanagement-api/ilmCommon/include/ilm_types.h index e9c84b0..ecb624e 100644 --- a/ivi-layermanagement-api/ilmCommon/include/ilm_types.h +++ b/ivi-layermanagement-api/ilmCommon/include/ilm_types.h @@ -116,28 +116,6 @@ typedef enum e_ilmObjectType } ilmObjectType; /** - * \brief Enumeration of renderer optimizations - * \ingroup ilmControl - **/ -typedef enum e_ilmOptimization -{ - ILM_OPT_MULTITEXTURE = 0, /*!< Multi-texture optimization */ - ILM_OPT_SKIP_CLEAR = 1 /*!< Skip clearing the screen */ -} ilmOptimization; - -/** - * \brief Enablement states for individual optimizations - * \ingroup ilmControl - **/ -typedef enum e_ilmOptimizationMode -{ - ILM_OPT_MODE_FORCE_OFF = 0, /*!< Disable optimization */ - ILM_OPT_MODE_FORCE_ON = 1, /*!< Enable optimization */ - ILM_OPT_MODE_HEURISTIC = 2, /*!< Let renderer choose enablement */ - ILM_OPT_MODE_TOGGLE = 3 /*!< Toggle on/and off rapidly for debugging */ -} ilmOptimizationMode; - -/** * \brief Enumeration for supported orientations of booth, surface and layer * \ingroup ilmControl **/ @@ -233,10 +211,6 @@ struct ilmSurfaceProperties t_ilm_uint pixelformat; /*!< pixel format of surface */ t_ilm_uint nativeSurface; /*!< native surface handle of surface */ ilmInputDevice inputDevicesAcceptance; /*!< bitmask of ilmInputDevice from which the surface can accept input events */ - t_ilm_bool chromaKeyEnabled; /*!< chromakey validness of the surface */ - t_ilm_uint chromaKeyRed; /*!< chromakey's red value of the surface */ - t_ilm_uint chromaKeyGreen; /*!< chromakey's green value of the surface */ - t_ilm_uint chromaKeyBlue; /*!< chromakey's blue value of the surface */ t_ilm_int creatorPid; /*!< process id of application that created this surface */ t_ilm_bool hasKeyboardFocus; /*!< whether this surface has keyboard focus */ }; @@ -261,10 +235,6 @@ struct ilmLayerProperties ilmOrientation orientation; /*!< orientation value of the layer */ t_ilm_bool visibility; /*!< visibility value of the layer */ t_ilm_uint type; /*!< type of layer */ - t_ilm_bool chromaKeyEnabled; /*!< chromakey validness of the layer */ - t_ilm_uint chromaKeyRed; /*!< chromakey's red value of the layer */ - t_ilm_uint chromaKeyGreen; /*!< chromakey's green value of the layer */ - t_ilm_uint chromaKeyBlue; /*!< chromakey's blue value of the layer */ t_ilm_int creatorPid; /*!< process id of application that created this layer */ }; diff --git a/ivi-layermanagement-api/ilmControl/include/ilm_control.h b/ivi-layermanagement-api/ilmControl/include/ilm_control.h index 32977a3..f842be6 100644 --- a/ivi-layermanagement-api/ilmControl/include/ilm_control.h +++ b/ivi-layermanagement-api/ilmControl/include/ilm_control.h @@ -287,16 +287,6 @@ ilmErrorTypes ilm_layerSetOrientation(t_ilm_layer layerId, ilmOrientation orient ilmErrorTypes ilm_layerGetOrientation(t_ilm_layer layerId, ilmOrientation *pOrientation); /** - * \brief Sets the color value which defines the transparency value. - * \ingroup ilmControl - * \param[in] layerId Id of layer. - * \param[in] pColor array of the color value which is defined in red,green, blue - * \return ILM_SUCCESS if the method call was successful - * \return ILM_FAILED if the client can not call the method on the service. - */ -ilmErrorTypes ilm_layerSetChromaKey(t_ilm_layer layerId, t_ilm_int* pColor); - -/** * \brief Sets render order of surfaces within one layer * \ingroup ilmControl * \param[in] layerId Id of layer. @@ -453,16 +443,6 @@ ilmErrorTypes ilm_surfaceGetOrientation(t_ilm_surface surfaceId, ilmOrientation ilmErrorTypes ilm_surfaceGetPixelformat(t_ilm_layer surfaceId, ilmPixelFormat *pPixelformat); /** - * \brief Sets the color value which defines the transparency value of a surface. - * \ingroup ilmControl - * \param[in] surfaceId Id of the surface to set the chromakey of. - * \param[in] pColor array of the color value which is defined in red, green, blue - * \return ILM_SUCCESS if the method call was successful - * \return ILM_FAILED if the client can not call the method on the service. - */ -ilmErrorTypes ilm_surfaceSetChromaKey(t_ilm_surface surfaceId, t_ilm_int* pColor); - -/** * \brief Sets render order of layers on a display * \ingroup ilmControl * \param[in] display Id of display to set the given order of layers. @@ -507,28 +487,6 @@ ilmErrorTypes ilm_takeLayerScreenshot(t_ilm_const_string filename, t_ilm_layer l ilmErrorTypes ilm_takeSurfaceScreenshot(t_ilm_const_string filename, t_ilm_surface surfaceid); /** - * \brief Enable or disable a rendering optimization - * - * \ingroup ilmControl - * \param[in] id which optimization to change - * \param[in] mode the mode to set on the optimzation (e.g. ON, OFF, AUTO) - * \return ILM_SUCCESS if the method call was successful - * \return ILM_FAILED if the client can not call the method on the service. - */ -ilmErrorTypes ilm_SetOptimizationMode(ilmOptimization id, ilmOptimizationMode mode); - -/** - * \brief Get the current enablement for an optimization - * - * \ingroup ilmControl - * \param[in] id which optimization to query - * \param[out] mode current optimization mode - * \return ILM_SUCCESS if the method call was successful - * \return ILM_FAILED if the client can not call the method on the service. - */ -ilmErrorTypes ilm_GetOptimizationMode(ilmOptimization id, ilmOptimizationMode* mode); - -/** * \brief register for notification on property changes of layer * \ingroup ilmControl * \param[in] layer id of layer to register for notification diff --git a/ivi-layermanagement-api/ilmControl/include/ilm_control_platform.h b/ivi-layermanagement-api/ilmControl/include/ilm_control_platform.h index 73c8815..654c70f 100644 --- a/ivi-layermanagement-api/ilmControl/include/ilm_control_platform.h +++ b/ivi-layermanagement-api/ilmControl/include/ilm_control_platform.h @@ -73,8 +73,6 @@ typedef struct _ILM_CONTROL_PLATFORM_FUNC ilmOrientation orientation); ilmErrorTypes (*layerGetOrientation)(t_ilm_layer layerId, ilmOrientation *pOrientation); - ilmErrorTypes (*layerSetChromaKey)(t_ilm_layer layerId, - t_ilm_int* pColor); ilmErrorTypes (*layerSetRenderOrder)(t_ilm_layer layerId, t_ilm_layer *pSurfaceId, t_ilm_int number); ilmErrorTypes (*layerTypeGetCapabilities)(ilmLayerType layerType, @@ -102,8 +100,6 @@ typedef struct _ILM_CONTROL_PLATFORM_FUNC ilmOrientation *pOrientation); ilmErrorTypes (*surfaceGetPixelformat)(t_ilm_layer surfaceId, ilmPixelFormat *pPixelformat); - ilmErrorTypes (*surfaceSetChromaKey)(t_ilm_surface surfaceId, - t_ilm_int* pColor); ilmErrorTypes (*displaySetRenderOrder)(t_ilm_display display, t_ilm_layer *pLayerId, const t_ilm_uint number); ilmErrorTypes (*takeScreenshot)(t_ilm_uint screen, @@ -112,10 +108,6 @@ typedef struct _ILM_CONTROL_PLATFORM_FUNC t_ilm_layer layerid); ilmErrorTypes (*takeSurfaceScreenshot)(t_ilm_const_string filename, t_ilm_surface surfaceid); - ilmErrorTypes (*SetOptimizationMode)(ilmOptimization id, - ilmOptimizationMode mode); - ilmErrorTypes (*GetOptimizationMode)(ilmOptimization id, - ilmOptimizationMode* pMode); ilmErrorTypes (*layerAddNotification)(t_ilm_layer layer, layerNotificationFunc callback); ilmErrorTypes (*layerRemoveNotification)(t_ilm_layer layer); 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 39d6dc5..e910842 100644 --- a/ivi-layermanagement-api/ilmControl/src/ilm_control_wayland_platform.c +++ b/ivi-layermanagement-api/ilmControl/src/ilm_control_wayland_platform.c @@ -2019,15 +2019,6 @@ ilm_layerGetOrientation(t_ilm_layer layerId, ilmOrientation *pOrientation) } ILM_EXPORT ilmErrorTypes -ilm_layerSetChromaKey(t_ilm_layer layerId, t_ilm_int* pColor) -{ - (void)layerId; - (void)pColor; - /* Not supported */ - return ILM_FAILED; -} - -ILM_EXPORT ilmErrorTypes ilm_layerSetRenderOrder(t_ilm_layer layerId, t_ilm_surface *pSurfaceId, t_ilm_int number) @@ -2324,15 +2315,6 @@ ilm_surfaceGetPixelformat(t_ilm_layer surfaceId, } ILM_EXPORT ilmErrorTypes -ilm_surfaceSetChromaKey(t_ilm_surface surfaceId, t_ilm_int* pColor) -{ - (void)surfaceId; - (void)pColor; - /* Not supported */ - return ILM_FAILED; -} - -ILM_EXPORT ilmErrorTypes ilm_displaySetRenderOrder(t_ilm_display display, t_ilm_layer *pLayerId, const t_ilm_uint number) { @@ -2416,24 +2398,6 @@ ilm_takeSurfaceScreenshot(t_ilm_const_string filename, } ILM_EXPORT ilmErrorTypes -ilm_SetOptimizationMode(ilmOptimization id, ilmOptimizationMode mode) -{ - (void)id; - (void)mode; - /* Not supported */ - return ILM_FAILED; -} - -ILM_EXPORT ilmErrorTypes -ilm_GetOptimizationMode(ilmOptimization id, ilmOptimizationMode* pMode) -{ - (void)id; - (void)pMode; - /* Not supported */ - return ILM_FAILED; -} - -ILM_EXPORT ilmErrorTypes ilm_layerAddNotification(t_ilm_layer layer, layerNotificationFunc callback) { diff --git a/ivi-layermanagement-api/test/ilm_control_test.cpp b/ivi-layermanagement-api/test/ilm_control_test.cpp index cf776b0..19f2722 100644 --- a/ivi-layermanagement-api/test/ilm_control_test.cpp +++ b/ivi-layermanagement-api/test/ilm_control_test.cpp @@ -985,33 +985,6 @@ TEST_F(IlmCommandTest, ilm_input_event_acceptance) { EXPECT_NE(surface1, surface); } -TEST_F(IlmCommandTest, SetGetOptimizationMode) { - ilmOptimization id; - ilmOptimizationMode mode; - ilmOptimizationMode retmode; - - id = ILM_OPT_MULTITEXTURE; - mode = ILM_OPT_MODE_FORCE_OFF; - ASSERT_EQ(ILM_SUCCESS, ilm_SetOptimizationMode(id, mode)); - ASSERT_EQ(ILM_SUCCESS, ilm_commitChanges()); - ASSERT_EQ(ILM_SUCCESS, ilm_GetOptimizationMode(id, &retmode)); - ASSERT_EQ(mode, retmode); - - id = ILM_OPT_SKIP_CLEAR; - mode = ILM_OPT_MODE_TOGGLE; - ASSERT_EQ(ILM_SUCCESS, ilm_SetOptimizationMode(id, mode)); - ASSERT_EQ(ILM_SUCCESS, ilm_commitChanges()); - ASSERT_EQ(ILM_SUCCESS, ilm_GetOptimizationMode(id, &retmode)); - ASSERT_EQ(mode, retmode); - - id = ILM_OPT_MULTITEXTURE; - mode = ILM_OPT_MODE_HEURISTIC; - ASSERT_EQ(ILM_SUCCESS, ilm_SetOptimizationMode(id, mode)); - ASSERT_EQ(ILM_SUCCESS, ilm_commitChanges()); - ASSERT_EQ(ILM_SUCCESS, ilm_GetOptimizationMode(id, &retmode)); - ASSERT_EQ(mode, retmode); -} - TEST_F(IlmCommandTest, ilm_getNumberOfHardwareLayers) { t_ilm_uint numberOfScreens = 0; t_ilm_uint* screenIDs = NULL; diff --git a/ivi-layermanagement-examples/LayerManagerControl/include/LMControl.h b/ivi-layermanagement-examples/LayerManagerControl/include/LMControl.h index 3ede657..6ac2254 100644 --- a/ivi-layermanagement-examples/LayerManagerControl/include/LMControl.h +++ b/ivi-layermanagement-examples/LayerManagerControl/include/LMControl.h @@ -257,8 +257,6 @@ void setSurfaceAcceptsInput(t_ilm_surface surfaceId, string kbdPointerTouch, t_i void testNotificationLayer(t_ilm_layer layerid); void watchLayer(unsigned int* layerids, unsigned int layeridCount); void watchSurface(unsigned int* surfaceids, unsigned int surfaceidCount); -void setOptimization(t_ilm_uint id, t_ilm_uint mode); -void getOptimization(t_ilm_uint id); //============================================================================= diff --git a/ivi-layermanagement-examples/LayerManagerControl/src/commands.cpp b/ivi-layermanagement-examples/LayerManagerControl/src/commands.cpp index f926400..61a6de8 100644 --- a/ivi-layermanagement-examples/LayerManagerControl/src/commands.cpp +++ b/ivi-layermanagement-examples/LayerManagerControl/src/commands.cpp @@ -679,61 +679,6 @@ COMMAND("set surface <surfaceid> accept <acceptance> input events from devices < } //============================================================================= -COMMAND("set layer|surface <id> chromakey <red> <green> <blue>") -//============================================================================= -{ - t_ilm_layer id = input->getUint("id"); - t_ilm_int color[3] = - { - input->getInt("red"), - input->getInt("green"), - input->getInt("blue") - }; - - if (input->contains("layer")) - { - ilmErrorTypes callResult = ilm_layerSetChromaKey(id, color); - if (ILM_SUCCESS != callResult) - { - cout << "LayerManagerService returned: " << ILM_ERROR_STRING(callResult) << "\n"; - cout << "Failed to set chroma key (" << color[0] << ", " << color[1] << ", " << color[2] << ") for layer with ID " << id << "\n"; - return; - } - - ilm_commitChanges(); - } - else if (input->contains("surface")) - { - ilmErrorTypes callResult = ilm_surfaceSetChromaKey(id, color); - if (ILM_SUCCESS != callResult) - { - cout << "LayerManagerService returned: " << ILM_ERROR_STRING(callResult) << "\n"; - cout << "Failed to set chroma key (" << color[0] << ", " << color[1] << ", " << color[2] << ") for surface with ID " << id << "\n"; - return; - } - - ilm_commitChanges(); - } -} - -//============================================================================= -COMMAND("set surface <surfaceid> chromakey disabled") -//============================================================================= -{ - t_ilm_surface surface = input->getUint("surfaceid"); - - ilmErrorTypes callResult = ilm_surfaceSetChromaKey(surface, NULL); - if (ILM_SUCCESS != callResult) - { - cout << "LayerManagerService returned: " << ILM_ERROR_STRING(callResult) << "\n"; - cout << "Failed to disable chroma key for surface with ID " << surface << "\n"; - return; - } - - ilm_commitChanges(); -} - -//============================================================================= COMMAND("test notification layer <layerid>") //============================================================================= { @@ -765,23 +710,6 @@ COMMAND("watch layer|surface <idarray>") } //============================================================================= -COMMAND("set optimization <id> mode <mode>") -//============================================================================= -{ - t_ilm_uint id = input->getUint("id"); - t_ilm_uint mode = input->getUint("mode"); - setOptimization(id, mode); -} - -//============================================================================= -COMMAND("get optimization <id>") -//============================================================================= -{ - t_ilm_uint id = input->getUint("id"); - getOptimization(id); -} - -//============================================================================= COMMAND("analyze surface <surfaceid>") //============================================================================= { diff --git a/ivi-layermanagement-examples/LayerManagerControl/src/control.cpp b/ivi-layermanagement-examples/LayerManagerControl/src/control.cpp index 7404b2a..b7efbc1 100644 --- a/ivi-layermanagement-examples/LayerManagerControl/src/control.cpp +++ b/ivi-layermanagement-examples/LayerManagerControl/src/control.cpp @@ -348,70 +348,3 @@ void watchSurface(unsigned int* surfaceids, unsigned int surfaceidCount) delete[] surfaceids; } } - -void setOptimization(t_ilm_uint id, t_ilm_uint mode) -{ - ilmErrorTypes callResult = ilm_SetOptimizationMode((ilmOptimization)id, - (ilmOptimizationMode)mode); - if (ILM_SUCCESS != callResult) - { - cout << "LayerManagerService returned: " << ILM_ERROR_STRING(callResult) << "\n"; - cout << "Failed to set optimization with ID " << id << " mode " << mode << "\n"; - return; - } - - ilm_commitChanges(); -} - -void getOptimization(t_ilm_uint id) -{ - ilmOptimization optimizationId = (ilmOptimization)id; - ilmOptimizationMode optimizationMode; - - ilmErrorTypes callResult = ilm_GetOptimizationMode(optimizationId, &optimizationMode); - if (callResult == ILM_SUCCESS) - { - switch (optimizationId) - { - case ILM_OPT_MULTITEXTURE : - cout << "Optimization " << (int)optimizationId << " (Multitexture Optimization)" << endl; - break; - - case ILM_OPT_SKIP_CLEAR : - cout << "Optimization " << (int)optimizationId << " (Skip Clear)" << endl; - break; - default: - cout << "Optimization " << "unknown" << endl; - break; - } - - switch (optimizationMode) - { - case ILM_OPT_MODE_FORCE_OFF : - cout << "Mode " << (int)optimizationMode << " (forced off)" << endl; - break; - - case ILM_OPT_MODE_FORCE_ON : - cout << "Mode " << (int)optimizationMode << " (forced on)" << endl; - break; - case ILM_OPT_MODE_HEURISTIC : - cout << "Mode " << (int)optimizationMode << " (Heuristic / Render choose the optimization)" << endl; - break; - case ILM_OPT_MODE_TOGGLE : - cout << "Mode " << (int)optimizationMode << " (Toggle on/and off rapidly for debugging)" << endl; - break; - - default: - cout << "Mode " << "unknown" << endl; - break; - } - } - else - { - cout << "LayerManagerService returned: " << ILM_ERROR_STRING(callResult) << "\n"; - cout << "Failed to get mode for optimization with ID " << optimizationId << "\n"; - return; - } - - ilm_commitChanges(); -} diff --git a/ivi-layermanagement-examples/LayerManagerControl/src/print.cpp b/ivi-layermanagement-examples/LayerManagerControl/src/print.cpp index a4d079b..c3e617e 100644 --- a/ivi-layermanagement-examples/LayerManagerControl/src/print.cpp +++ b/ivi-layermanagement-examples/LayerManagerControl/src/print.cpp @@ -177,10 +177,6 @@ void printLayerProperties(unsigned int layerid, const char* prefix) break; } - cout << prefix << "- chromakey: " - << (p.chromaKeyEnabled ? "enabled " : "disabled ") - << "(r=" << p.chromaKeyRed << ", g=" << p.chromaKeyGreen << ", b=" << p.chromaKeyBlue << ")\n"; - cout << prefix << "- surface render order: "; int surfaceCount = 0; @@ -340,10 +336,6 @@ void printSurfaceProperties(unsigned int surfaceid, const char* prefix) << (keyboardFocusSurfaceId == surfaceid ? "true" : "false") << "\n"; - cout << prefix << "- chromakey: " - << (p.chromaKeyEnabled ? "enabled " : "disabled ") - << "(r=" << p.chromaKeyRed << ", g=" << p.chromaKeyGreen << ", b=" << p.chromaKeyBlue << ")\n"; - cout << prefix << "- counters: frame=" << p.frameCounter << ", draw=" << p.drawCounter << ", update=" << p.updateCounter << "\n"; |