• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2023-2023 Huawei Device Co., Ltd.
2# Licensed under the Apache License, Version 2.0 (the "License");
3# you may not use this file except in compliance with the License.
4# You may obtain a copy of the License at
5#
6#     http://www.apache.org/licenses/LICENSE-2.0
7#
8# Unless required by applicable law or agreed to in writing, software
9# distributed under the License is distributed on an "AS IS" BASIS,
10# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11# See the License for the specific language governing permissions and
12# limitations under the License.
13#
14import("//foundation/multimedia/media_foundation/config.gni")
15group("plugin_codec_adapter") {
16  deps = []
17  if (hst_is_lite_sys) {
18    print("std hdi codec adapter is not available on lite systems")
19  } else {
20    deps += [ ":histreamer_plugin_CodecAdapter" ]
21  }
22}
23
24config("plugin_codec_adapter_config") {
25  include_dirs = [ "//foundation/multimedia/media_foundation/engine/include/" ]
26}
27
28ohos_source_set("std_plugin_codec_adapter") {
29  subsystem_name = "multimedia"
30  part_name = "media_foundation"
31  sources = [
32    "codec_buffer.cpp",
33    "codec_buffer_pool.cpp",
34    "codec_cmd_executor.cpp",
35    "codec_port.cpp",
36    "codec_utils.cpp",
37    "hdi_codec_adapter.cpp",
38    "hdi_codec_manager.cpp",
39  ]
40  public_deps = [
41    "//foundation/multimedia/media_foundation/engine/foundation:histreamer_foundation",
42    "//foundation/multimedia/media_foundation/engine/plugin:histreamer_plugin_base",
43  ]
44  external_deps = [ "hdf_core:libpub_utils" ]
45  if (!hst_is_lite_sys) {
46    external_deps += [
47      "graphic_surface:surface",
48      "hdf_core:libhdi",
49      "hilog:libhilog",
50      "hitrace:hitrace_meter",
51      "ipc:ipc_core",
52    ]
53  }
54  public_configs = [
55    ":plugin_codec_adapter_config",
56    "//foundation/multimedia/media_foundation:histreamer_presets",
57  ]
58  public_external_deps = [
59    "drivers_interface_codec:libcodec_proxy_4.0",
60    "drivers_interface_display:libdisplay_composer_hdi_impl_1.2",
61    "openmax:libopenmax_static",
62  ]
63}
64
65if (hst_is_lite_sys) {
66  print("std hdi codec adapter is not available on lite systems")
67} else {
68  import("//build/ohos.gni")
69  ohos_shared_library("histreamer_plugin_CodecAdapter") {
70    sanitize = {
71      cfi = true
72      cfi_cross_dso = true
73      debug = false
74      integer_overflow = true
75    }
76    deps = [ ":std_plugin_codec_adapter" ]
77
78    external_deps = [
79      "drivers_interface_codec:libcodec_proxy_4.0",
80      "drivers_interface_display:libdisplay_composer_hdi_impl_1.2",
81      "hilog:libhilog",
82      "openmax:libopenmax_static",
83    ]
84    relative_install_dir = "media/histreamer_plugins"
85    subsystem_name = "multimedia"
86    part_name = "media_foundation"
87  }
88}
89