// Copyright 2019 The Android Open Source Project // // 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. package { default_applicable_licenses: ["external_libgav1_license"], } // Added automatically by a large-scale-change // See: http://go/android-license-faq license { name: "external_libgav1_license", visibility: [":__subpackages__"], license_kinds: [ "SPDX-license-identifier-Apache-2.0", ], license_text: [ "libgav1/LICENSE", ], } bug_component_id = 324837 fuzz_email_cc = ["jzern@google.com"] cc_library_static { name: "libgav1", host_supported: true, vendor_available: true, export_include_dirs: [ ".", "libgav1/src", ], cflags: [ "-DLIBGAV1_MAX_BITDEPTH=10", "-DLIBGAV1_THREADPOOL_USE_STD_MUTEX", "-O2", "-Wall", "-Werror", "-Wextra", ], local_include_dirs: [ "libgav1", ], // Note: if optimizations are required for x86 the avx2 & sse4 files should // be split to their own targets to receive the correct flagging. All files // in the library can be built for any target without producing empty // object files. srcs: [ "libgav1/src/buffer_pool.cc", "libgav1/src/decoder.cc", "libgav1/src/decoder_impl.cc", "libgav1/src/decoder_settings.cc", "libgav1/src/dsp/arm/average_blend_neon.cc", "libgav1/src/dsp/arm/cdef_neon.cc", "libgav1/src/dsp/arm/convolve_neon.cc", "libgav1/src/dsp/arm/distance_weighted_blend_neon.cc", "libgav1/src/dsp/arm/film_grain_neon.cc", "libgav1/src/dsp/arm/intra_edge_neon.cc", "libgav1/src/dsp/arm/intrapred_cfl_neon.cc", "libgav1/src/dsp/arm/intrapred_directional_neon.cc", "libgav1/src/dsp/arm/intrapred_filter_neon.cc", "libgav1/src/dsp/arm/intrapred_neon.cc", "libgav1/src/dsp/arm/intrapred_smooth_neon.cc", "libgav1/src/dsp/arm/inverse_transform_10bit_neon.cc", "libgav1/src/dsp/arm/inverse_transform_neon.cc", "libgav1/src/dsp/arm/loop_filter_neon.cc", "libgav1/src/dsp/arm/loop_restoration_neon.cc", "libgav1/src/dsp/arm/mask_blend_neon.cc", "libgav1/src/dsp/arm/motion_field_projection_neon.cc", "libgav1/src/dsp/arm/motion_vector_search_neon.cc", "libgav1/src/dsp/arm/obmc_neon.cc", "libgav1/src/dsp/arm/super_res_neon.cc", "libgav1/src/dsp/arm/warp_neon.cc", "libgav1/src/dsp/arm/weight_mask_neon.cc", "libgav1/src/dsp/average_blend.cc", "libgav1/src/dsp/cdef.cc", "libgav1/src/dsp/constants.cc", "libgav1/src/dsp/convolve.cc", "libgav1/src/dsp/distance_weighted_blend.cc", "libgav1/src/dsp/dsp.cc", "libgav1/src/dsp/film_grain.cc", "libgav1/src/dsp/intra_edge.cc", "libgav1/src/dsp/intrapred.cc", "libgav1/src/dsp/intrapred_cfl.cc", "libgav1/src/dsp/intrapred_directional.cc", "libgav1/src/dsp/intrapred_filter.cc", "libgav1/src/dsp/intrapred_smooth.cc", "libgav1/src/dsp/inverse_transform.cc", "libgav1/src/dsp/loop_filter.cc", "libgav1/src/dsp/loop_restoration.cc", "libgav1/src/dsp/mask_blend.cc", "libgav1/src/dsp/motion_field_projection.cc", "libgav1/src/dsp/motion_vector_search.cc", "libgav1/src/dsp/obmc.cc", "libgav1/src/dsp/super_res.cc", "libgav1/src/dsp/warp.cc", "libgav1/src/dsp/weight_mask.cc", "libgav1/src/dsp/x86/average_blend_sse4.cc", "libgav1/src/dsp/x86/cdef_avx2.cc", "libgav1/src/dsp/x86/cdef_sse4.cc", "libgav1/src/dsp/x86/convolve_avx2.cc", "libgav1/src/dsp/x86/convolve_sse4.cc", "libgav1/src/dsp/x86/distance_weighted_blend_sse4.cc", "libgav1/src/dsp/x86/film_grain_sse4.cc", "libgav1/src/dsp/x86/intra_edge_sse4.cc", "libgav1/src/dsp/x86/intrapred_cfl_sse4.cc", "libgav1/src/dsp/x86/intrapred_directional_sse4.cc", "libgav1/src/dsp/x86/intrapred_filter_sse4.cc", "libgav1/src/dsp/x86/intrapred_smooth_sse4.cc", "libgav1/src/dsp/x86/intrapred_sse4.cc", "libgav1/src/dsp/x86/inverse_transform_sse4.cc", "libgav1/src/dsp/x86/loop_filter_sse4.cc", "libgav1/src/dsp/x86/loop_restoration_10bit_avx2.cc", "libgav1/src/dsp/x86/loop_restoration_10bit_sse4.cc", "libgav1/src/dsp/x86/loop_restoration_avx2.cc", "libgav1/src/dsp/x86/loop_restoration_sse4.cc", "libgav1/src/dsp/x86/mask_blend_sse4.cc", "libgav1/src/dsp/x86/motion_field_projection_sse4.cc", "libgav1/src/dsp/x86/motion_vector_search_sse4.cc", "libgav1/src/dsp/x86/obmc_sse4.cc", "libgav1/src/dsp/x86/super_res_sse4.cc", "libgav1/src/dsp/x86/warp_sse4.cc", "libgav1/src/dsp/x86/weight_mask_sse4.cc", "libgav1/src/film_grain.cc", "libgav1/src/frame_buffer.cc", "libgav1/src/internal_frame_buffer_list.cc", "libgav1/src/loop_restoration_info.cc", "libgav1/src/motion_vector.cc", "libgav1/src/obu_parser.cc", "libgav1/src/post_filter/cdef.cc", "libgav1/src/post_filter/deblock.cc", "libgav1/src/post_filter/loop_restoration.cc", "libgav1/src/post_filter/post_filter.cc", "libgav1/src/post_filter/super_res.cc", "libgav1/src/prediction_mask.cc", "libgav1/src/quantizer.cc", "libgav1/src/reconstruction.cc", "libgav1/src/residual_buffer_pool.cc", "libgav1/src/status_code.cc", "libgav1/src/symbol_decoder_context.cc", "libgav1/src/threading_strategy.cc", "libgav1/src/tile/bitstream/mode_info.cc", "libgav1/src/tile/bitstream/palette.cc", "libgav1/src/tile/bitstream/partition.cc", "libgav1/src/tile/bitstream/transform_size.cc", "libgav1/src/tile/prediction.cc", "libgav1/src/tile/tile.cc", "libgav1/src/tile_scratch_buffer.cc", "libgav1/src/utils/bit_reader.cc", "libgav1/src/utils/block_parameters_holder.cc", "libgav1/src/utils/constants.cc", "libgav1/src/utils/cpu.cc", "libgav1/src/utils/entropy_decoder.cc", "libgav1/src/utils/executor.cc", "libgav1/src/utils/logging.cc", "libgav1/src/utils/raw_bit_reader.cc", "libgav1/src/utils/segmentation.cc", "libgav1/src/utils/segmentation_map.cc", "libgav1/src/utils/threadpool.cc", "libgav1/src/version.cc", "libgav1/src/warp_prediction.cc", "libgav1/src/yuv_buffer.cc", ], arch: { arm: { instruction_set: "arm", }, }, min_sdk_version: "29", } cc_defaults { name: "libgav1_fuzzer_defaults", host_supported: true, native_coverage: true, cflags: [ "-DLIBGAV1_MAX_BITDEPTH=10", "-DLIBGAV1_THREADPOOL_USE_STD_MUTEX", ], local_include_dirs: [ "libgav1", ], srcs: [ "libgav1/examples/file_reader.cc", "libgav1/examples/file_reader_constants.cc", "libgav1/examples/file_reader_factory.cc", "libgav1/examples/ivf_parser.cc", ], static_libs: [ "libgav1", ], fuzz_config: { cc: fuzz_email_cc, componentid: bug_component_id, }, } cc_fuzz { name: "libgav1_decoder_fuzzer", defaults: ["libgav1_fuzzer_defaults"], srcs: [ "libgav1/tests/fuzzer/decoder_fuzzer.cc", ], } cc_fuzz { name: "libgav1_decoder_fuzzer_frame_parallel", defaults: ["libgav1_fuzzer_defaults"], srcs: [ "libgav1/tests/fuzzer/decoder_fuzzer_frame_parallel.cc", ], } cc_fuzz { name: "libgav1_obu_parser_fuzzer", defaults: ["libgav1_fuzzer_defaults"], srcs: [ "libgav1/tests/fuzzer/obu_parser_fuzzer.cc", ], }