1e9297d28Sopenharmony_ci# Copyright (C) 2024 Huawei Device Co., Ltd. 2e9297d28Sopenharmony_ci# Licensed under the Apache License, Version 2.0 (the "License"); 3e9297d28Sopenharmony_ci# you may not use this file except in compliance with the License. 4e9297d28Sopenharmony_ci# You may obtain a copy of the License at 5e9297d28Sopenharmony_ci# 6e9297d28Sopenharmony_ci# http://www.apache.org/licenses/LICENSE-2.0 7e9297d28Sopenharmony_ci# 8e9297d28Sopenharmony_ci# Unless required by applicable law or agreed to in writing, software 9e9297d28Sopenharmony_ci# distributed under the License is distributed on an "AS IS" BASIS, 10e9297d28Sopenharmony_ci# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 11e9297d28Sopenharmony_ci# See the License for the specific language governing permissions and 12e9297d28Sopenharmony_ci# limitations under the License. 13e9297d28Sopenharmony_ci 14e9297d28Sopenharmony_ciimport("//build/ohos.gni") 15e9297d28Sopenharmony_ciimport("//foundation/graphic/graphic_2d/graphic_config.gni") 16e9297d28Sopenharmony_ci 17e9297d28Sopenharmony_ciconfig("create_pixelmap_surface_public_config") { 18e9297d28Sopenharmony_ci include_dirs = [ 19e9297d28Sopenharmony_ci "include", 20e9297d28Sopenharmony_ci "$graphic_2d_root/rosen/modules/render_service_base/include", 21e9297d28Sopenharmony_ci "$graphic_2d_root/rosen/modules/render_service_base/src", 22e9297d28Sopenharmony_ci "$graphic_2d_root/rosen/modules/2d_graphics/src/drawing/engine_adapter", 23e9297d28Sopenharmony_ci ] 24e9297d28Sopenharmony_ci defines = gpu_defines 25e9297d28Sopenharmony_ci} 26e9297d28Sopenharmony_ci 27e9297d28Sopenharmony_ciohos_source_set("create_pixelmap_surface_src") { 28e9297d28Sopenharmony_ci sanitize = { 29e9297d28Sopenharmony_ci cfi = true 30e9297d28Sopenharmony_ci cfi_cross_dso = true 31e9297d28Sopenharmony_ci cfi_vcall_icall_only = true 32e9297d28Sopenharmony_ci debug = false 33e9297d28Sopenharmony_ci boundary_sanitize = true 34e9297d28Sopenharmony_ci integer_overflow = true 35e9297d28Sopenharmony_ci ubsan = true 36e9297d28Sopenharmony_ci } 37e9297d28Sopenharmony_ci 38e9297d28Sopenharmony_ci public_configs = [ ":create_pixelmap_surface_public_config" ] 39e9297d28Sopenharmony_ci sources = [ "src/pixel_map_from_surface.cpp" ] 40e9297d28Sopenharmony_ci 41e9297d28Sopenharmony_ci deps = [ 42e9297d28Sopenharmony_ci "$graphic_2d_root/frameworks/opengl_wrapper:EGL", 43e9297d28Sopenharmony_ci "$graphic_2d_root/frameworks/opengl_wrapper:GLESv3", 44e9297d28Sopenharmony_ci "$graphic_2d_root/rosen/modules/2d_graphics:2d_graphics", 45e9297d28Sopenharmony_ci "$graphic_2d_root/rosen/modules/render_service_base:librender_service_base", 46e9297d28Sopenharmony_ci "$graphic_2d_root/utils:scoped_bytrace", 47e9297d28Sopenharmony_ci ] 48e9297d28Sopenharmony_ci 49e9297d28Sopenharmony_ci external_deps = [ "graphic_surface:sync_fence" ] 50e9297d28Sopenharmony_ci 51e9297d28Sopenharmony_ci subsystem_name = "graphic" 52e9297d28Sopenharmony_ci part_name = "graphic_2d" 53e9297d28Sopenharmony_ci} 54e9297d28Sopenharmony_ci 55e9297d28Sopenharmony_ciohos_shared_library("create_pixelmap_surface") { 56e9297d28Sopenharmony_ci sanitize = { 57e9297d28Sopenharmony_ci cfi = true 58e9297d28Sopenharmony_ci cfi_cross_dso = true 59e9297d28Sopenharmony_ci cfi_vcall_icall_only = true 60e9297d28Sopenharmony_ci debug = false 61e9297d28Sopenharmony_ci } 62e9297d28Sopenharmony_ci 63e9297d28Sopenharmony_ci public_configs = [ ":create_pixelmap_surface_public_config" ] 64e9297d28Sopenharmony_ci 65e9297d28Sopenharmony_ci deps = [ ":create_pixelmap_surface_src" ] 66e9297d28Sopenharmony_ci 67e9297d28Sopenharmony_ci external_deps = [ 68e9297d28Sopenharmony_ci "c_utils:utils", 69e9297d28Sopenharmony_ci "graphic_surface:surface", 70e9297d28Sopenharmony_ci "hilog:libhilog", 71e9297d28Sopenharmony_ci "hitrace:hitrace_meter", 72e9297d28Sopenharmony_ci "image_framework:image_native", 73e9297d28Sopenharmony_ci ] 74e9297d28Sopenharmony_ci 75e9297d28Sopenharmony_ci subsystem_name = "graphic" 76e9297d28Sopenharmony_ci part_name = "graphic_2d" 77e9297d28Sopenharmony_ci} 78e9297d28Sopenharmony_ci 79e9297d28Sopenharmony_cigroup("test") { 80e9297d28Sopenharmony_ci testonly = true 81e9297d28Sopenharmony_ci 82e9297d28Sopenharmony_ci deps = [ "test:test" ] 83e9297d28Sopenharmony_ci} 84