/* * Copyright (C) 2025 Amlogic 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. */ #ifndef __DISPLAY_ADAPTER_LIB_WRAP_H__ #define __DISPLAY_ADAPTER_LIB_WRAP_H__ #include "display_interface.h" /* display adapter */ typedef int32_t (*dA_createLayer)(int32_t displayId, int32_t *layerId); typedef int32_t (*dA_destroyLayer)(int32_t displayId, int32_t layerId); typedef int32_t (*dA_setTunnelId)(int32_t displayId, int32_t layerId, int32_t tunnelId); typedef int32_t (*dA_setLayerZorder)(int32_t displayId, int32_t layerId, int32_t zorder); typedef int32_t (*dA_setLayerSourceCrop)(int32_t displayId, int32_t layerId, struct rect crop); typedef int32_t (*dA_setLayerDispFrame)(int32_t displayId, int32_t layerId, struct rect frame); typedef int32_t (*dA_getVsyncDelayLatency)(int32_t displayId, int32_t layerId); typedef int32_t (*dA_setVideoDisplaytoMainplane)(int32_t displayId); typedef int32_t (*dA_dispAdptGetUiSize)(int32_t displayId, int32_t *width, int32_t *height); typedef struct { void *libHandle; //displayAdapter lib handle of dlopen dA_createLayer dACreateLayer; dA_destroyLayer dADestroyLayer; dA_setTunnelId dASetTunnelId; dA_setLayerZorder dASetLayerZorder; dA_setLayerSourceCrop dASetLayerSourceCrop; dA_setLayerDispFrame dASetLayerDispFrame; dA_getVsyncDelayLatency dAGetVsyncDelayLatency; dA_setVideoDisplaytoMainplane dASetVideoDisplaytoMainplane; dA_dispAdptGetUiSize dADispAdptGetUiSize; } displayAdapterLib; displayAdapterLib * displayAdapterLoadLib(int logCategory); int displayAdapterUnloadLib(int logCategory,displayAdapterLib *dA); #endif /*__DISPLAY_ADAPTER_LIB_WRAP_H__H__*/