!510 enable rk gpu

Merge pull request !510 from 李政/master
This commit is contained in:
openharmony_ci 2022-02-25 09:42:42 +00:00 committed by Gitee
commit b510cd38b4
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
3 changed files with 11 additions and 18 deletions

View File

@ -12,6 +12,7 @@
# limitations under the License.
import("//build/ohos.gni")
import("//foundation/graphic/standard/graphic_config.gni")
## Build bootanimation {{{
config("bootanimation_config") {
@ -28,13 +29,8 @@ config("bootanimation_config") {
"-g3",
]
if ("${product_name}" == "rk3566" || "${product_name}" == "rk3568" ||
"${product_name}" == "watchos" || "${product_name}" == "Hi3516DV300" ||
"${product_name}" == "ohos-arm64") {
defines = [ "ACE_DISABLE_GL" ]
} else {
defines = [ "ACE_ENABLE_GL" ]
}
defines = []
defines += gpu_defines
}
ohos_executable("bootanimation") {

View File

@ -134,7 +134,7 @@ int32_t NativeWindowFlushBuffer(struct NativeWindow *window, struct NativeWindow
BLOGD("NativeWindowFlushBuffer damage w is %{public}d, h is %{public}d, acquire fence: %{public}d",
config.damage.w, config.damage.h, fenceFd);
window->surface->FlushBuffer(buffer->sfbuffer, fenceFd, config);
window->surface->FlushBuffer(buffer->sfbuffer, -1, config);
// unreference nativewindowbuffer object
return OHOS::GSERROR_OK;

View File

@ -12,22 +12,19 @@
# limitations under the License.
import("//build/config/clang/clang.gni")
import("//build/ohos.gni")
import("//build/ohos_var.gni")
if ("${product_name}" == "rk3566" || "${product_name}" == "rk3568" ||
"${product_name}" == "watchos" || "${product_name}" == "Hi3516DV300" ||
if ("${product_name}" == "watchos" || "${product_name}" == "Hi3516DV300" ||
"${product_name}" == "ohos-arm64" ||
"${product_name}" == "qemu-arm-linux-min") {
gpu_defines = [ "ACE_DISABLE_GL" ]
ace_enable_gpu = false # temporary gpu
ace_enable_gpu = false
libgl = []
} else if ("${product_name}" == "rk3566" || "${product_name}" == "rk3568") {
gpu_defines = [ "ACE_ENABLE_GL" ]
ace_enable_gpu = true
libgl = [ "//device/hihope/hardware/gpu:mali-bifrost-g52-g2p0-ohos" ]
} else {
gpu_defines = [ "ACE_ENABLE_GL" ]
ace_enable_gpu = true
}
if (ace_enable_gpu) {
libgl = [ "//device/hisilicon/hardware/gpu:gpu_libs" ]
} else {
libgl = []
}