• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (C) 2021 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("//build/ohos.gni")
15
16config("media_engine_gst_avcodec_config") {
17  visibility = [ ":*" ]
18
19  cflags = [
20    "-std=c++17",
21    "-fno-rtti",
22    "-fno-exceptions",
23    "-Wall",
24    "-fno-common",
25    "-fstack-protector-strong",
26    "-Wshadow",
27    "-FPIC",
28    "-FS",
29    "-O2",
30    "-D_FORTIFY_SOURCE=2",
31    "-fvisibility=hidden",
32    "-Wformat=2",
33    "-Wfloat-equal",
34    "-Wdate-time",
35    "-Werror",
36    "-Wextra",
37    "-Wimplicit-fallthrough",
38    "-Wsign-compare",
39    "-Wunused-parameter",
40  ]
41
42  include_dirs = [
43    ".",
44    "format_processor",
45    "sink_wrapper",
46    "src_wrapper",
47    "//drivers/peripheral/display/interfaces/include",
48    "//foundation/multimedia/player_framework/services/engine/common/avcodeclist",
49    "//foundation/multimedia/player_framework/services/engine/gstreamer/avcodec",
50    "//foundation/multimedia/player_framework/services/engine/gstreamer/plugins/sink/memsink",
51    "//foundation/multimedia/player_framework/services/engine/gstreamer/plugins/source/memsource",
52    "//foundation/multimedia/player_framework/services/engine/gstreamer/plugins/common",
53    "//foundation/multimedia/player_framework/services/utils/include",
54    "//foundation/multimedia/player_framework/interfaces/inner_api/native",
55    "//foundation/multimedia/player_framework/services/services/engine_intf",
56    "//foundation/multimedia/audio_framework/interfaces/inner_api/native/audiocommon/include",
57    "//commonlibrary/c_utils/base/include",
58    "//third_party/gstreamer/gstreamer",
59    "//third_party/gstreamer/gstreamer/libs",
60    "//third_party/gstreamer/gstplugins_base",
61    "//third_party/gstreamer/gstplugins_base/gst-libs",
62    "//third_party/gstreamer/gstplugins_bad/gst-libs",
63    "//third_party/glib/glib",
64    "//third_party/glib",
65    "//third_party/glib/gmodule",
66  ]
67}
68
69ohos_static_library("media_engine_gst_avcodec") {
70  sources = [
71    "avcodec_engine_ctrl.cpp",
72    "avcodec_engine_factory.cpp",
73    "avcodec_engine_gst_impl.cpp",
74    "codec_common.cpp",
75    "format_processor/processor_adec_impl.cpp",
76    "format_processor/processor_aenc_impl.cpp",
77    "format_processor/processor_base.cpp",
78    "format_processor/processor_vdec_impl.cpp",
79    "format_processor/processor_venc_impl.cpp",
80    "sink_wrapper/sink_bytebuffer_impl.cpp",
81    "sink_wrapper/sink_surface_impl.cpp",
82    "src_wrapper/src_bytebuffer_impl.cpp",
83    "src_wrapper/src_surface_impl.cpp",
84  ]
85
86  configs = [
87    ":media_engine_gst_avcodec_config",
88    "//foundation/graphic/graphic_2d/frameworks/surface:surface_public_config",
89    "//foundation/multimedia/player_framework/services/dfx:media_service_log_dfx_public_config",
90    "//foundation/multimedia/player_framework/services/utils:media_service_utils_public_config",
91  ]
92
93  deps = [
94    "//foundation/graphic/graphic_2d/frameworks/surface:surface",
95    "//foundation/multimedia/player_framework/services/dfx:media_service_log_dfx",
96    "//foundation/multimedia/player_framework/services/engine/common:media_engine_common",
97    "//foundation/multimedia/player_framework/services/engine/gstreamer/plugins:media_engine_gst_plugins_common",
98    "//foundation/multimedia/player_framework/services/utils:media_service_utils",
99    "//third_party/glib:glib",
100    "//third_party/glib:gmodule",
101    "//third_party/glib:gobject",
102    "//third_party/gstreamer/gstplugins_bad:gstplayer",
103    "//third_party/gstreamer/gstplugins_base:gstaudio",
104    "//third_party/gstreamer/gstplugins_base:gstvideo",
105    "//third_party/gstreamer/gstreamer:gstbase",
106    "//third_party/gstreamer/gstreamer:gstreamer",
107  ]
108
109  external_deps = [ "hiviewdfx_hilog_native:libhilog" ]
110
111  subsystem_name = "multimedia"
112  part_name = "multimedia_player_framework"
113}
114