Commit graph

63 commits

Author SHA1 Message Date
Srujan Vandrangi
2e8e8e7d13 decoder: add "summary" before codec exit with error message
Test: avcdec

Change-Id: Ifee9140f0042f77304a1a662127bc049237987e5
2023-07-31 10:32:26 -07:00
Srujan Vandrangi
07452e198b decoder: set keep_threads_active to 1 in the testbench and fuzzer
Bug: 289097296
Test: Build
2023-07-29 16:38:34 -07:00
Srujan Vandrangi
72e8241a64 decoder: replace KEEP_THREADS_ACTIVE macro with avc decoder struct variable
Bug: 289097296
Test: Build
2023-07-22 09:51:37 -07:00
Harish Mahendrakar
a3766576c3 Format Android.bp files
Minor changes in names of defaults in order get consistency between
libraries and applications being built.

Test: builds
2023-03-08 22:14:36 -08:00
Harish Mahendrakar
a7c8d47643 Fix formatting in FGC commit 2023-02-21 12:36:55 -08:00
Shireesh Kadaramandalgi
b6b12cc5f0 libavc: Add support for FGC SEI message
- Decoder: Added support for FGC SEI parsing and exporting
2023-02-21 12:36:55 -08:00
Mallikarjun Kamble
8e41a50de4 libavc: Added support for SII SEI message
- Add SII flag and SII parameters for the encoder and decoder.
- Encoder: Added support for SII SEI
- Decoder: Added support for SII SEI parsing and exporting
2023-02-14 22:00:13 -08:00
chamarthi.kishore
e6c806df90 formatting changes 2023-02-08 07:55:47 -08:00
chamarthi.kishore
375b9b7e44 SVC decoder support 2023-02-08 07:55:47 -08:00
Ashwin Natesan
bb0f31cb6b Encoder: SVC encoding support added
Added support for encoding 'Scalable Baseline' profile, corresponding to
profile_idc of 83 in 'Rec. ITU-T H.264 (11/2007)'.

Bug: 248891908
Test: svcenc -c enc.cfg
Change-Id: Ib12ca4c4a8c0e674738ae2af01558a08cefe0929
2023-01-30 11:07:10 -08:00
Harish Mahendrakar
eb463e5aa2 cmake: Set C standard to C90 and move few macros to specific targets
- Set CMAKE_C_STANDARD to 90
  Because of this, moved some declarations to start of the block
- Move PROFILE_ENABLE and MD5_DISABLE to specific targets as these
  macros are not used when building libraries

Bug: 242076773
Test: Builds
Change-Id: Icd0b8a48f015a695185ce2220800348f7a7512f1
2022-08-30 20:00:54 +00:00
Harish Mahendrakar
a90b35eb01 avcenc: Make a separate call to encode header
This makes avcenc to be in sync with c2 plugin

Bug: 242103842
Test: avcenc -c enc.cfg

Change-Id: Ia19f8fc6d3a824a29206e3214d4c8145479ecc70
2022-08-19 12:04:30 -07:00
Harish Mahendrakar
6f403c12e3 avcenc: Set default color aspects to unspecified in VUI
In avcenc test application, when configuring VUI,
color aspects were set to 0. This causes issues when the
clips are decoded using reference decoder where this is treated
as RGB data. Set these to unspecified.

Bug: 242104405
Test: avcenc -c enc.cfg

Change-Id: I2f80250f94faccba52fe945502fc10b793def536
2022-08-17 22:41:47 +00:00
Treehugger Robot
d249d3642d Merge "Decoder: MVC decoding support added" 2022-08-08 14:53:05 +00:00
Ashwin Natesan
779bbfdb00 Decoder: MVC decoding support added
Added support for decoding 'Multiview High' profile, corresponding to
profile_idc of 118 in 'Rec. ITU-T H.264 (08/2021)'.

Bug: 232169767
Test: atest CtsMediaV2TestCases

Change-Id: I63256344a8a205e74f2bcebe555f5ba6cc3163d0
2022-08-06 05:51:31 +00:00
Shivaansh Agrawal
0033e0fe5e Decoder: add support for QP and block_type map export in library
Bug: 175179303

Test: avcdec -c dec.cfg
Test: atest CtsMediaV2TestCases:CodecDecoderTest
Test: atest VtsHalMediaC2V1_0TargetVideoDecTest

Change-Id: I68f3a85aae1f4bca2c3e1eaad69d8eb7f23481b8
2022-05-17 09:55:20 +05:30
Ashwin Natesan
ca68f61641 Builds: Modular cmake scripts added
Cmake scripts are now modular. Separate scripts now handle
build specifications for each target and dependency.

Toolchain files have been added for armv7, armv8 builds.

Bug: 213579857
Test: Builds using cmake
Test: Builds in OSS-fuzz

Change-Id: Iac62b443c0a0de09a2ce6553a660db2c3d5dc846
2022-02-02 11:14:55 +05:30
Shivaansh Agrawal
2205f2da33 Decoder: add support to use ih264d instead of ivd structures
Bug: 175759733
Test: avcdec -c dec.cfg
Change-Id: I410bb2213cb375c5eabcb3e23499d6ad43cf1c96
2021-02-25 05:31:40 +00:00
Bob Badour
c0aae295ed [LSC] Add LOCAL_LICENSE_KINDS to external/libavc
Added SPDX-license-identifier-Apache-2.0 to:
  Android.bp
  fuzzer/Android.bp
  test/Android.bp

Bug: 68860345
Bug: 151177513
Bug: 151953481

Test: m all

Exempt-From-Owner-Approval: janitorial work
Change-Id: I3ad48ae634869eb3486d5c68962c992be83b2003
2021-02-14 10:37:21 -08:00
Harish Mahendrakar
29393d25cd avcenc: Fix PSNR computation for 420 semi-planar output in test
PSNR computation for 420 Semi-planar recon was incorrect.

Bug: 173151765
Test: avcenc -i qcif.yuv -w 176 -h 144 --bitrate 512000 \
      -o out.h264 --recon_enable 1 --recon recon.yuv \
      --input_chroma_format YUV_420SP_VU --recon_chroma_format \
      YUV_420SP_VU --num_frames 4 --psnr 1

Change-Id: I8de628107894bfdef6027f865b235aa01349bc4d
2020-11-13 17:37:27 +00:00
Chamarthi Kishore
ad2eaf8c7d libavc: Add MDCV, CLL, CCV and AVE SEI messages
This commit add support for encoding and decoding of MDCV, CLL, CCV and
AVE SEI messages

Test: avcenc -c enc.cfg, avcdec -c dec.cfg
Bug: 141931623

Change-Id: Idc0b0db5291482ae2bc19cdff65669c32374b02a
2019-10-24 17:20:00 +05:30
Harish Mahendrakar
e2b463d2f8 encoder: Add host support
Test: Build libavc on host
Bug: 139379050

Change-Id: Ifcf60e2e0efd8a31df2a9741007ce6f544cdce3f
2019-09-20 22:05:26 +00:00
Harish Mahendrakar
9aefe92778 Replace memalign with posix_memalign
Bug: 140696633
Test: Build and test binaries

Change-Id: I2a00a34347732eb91f2dc3514c4fa8fa5b5c51b5
2019-09-12 16:37:45 -07:00
Elliott Hughes
724246bc74 Fix macOS build.
There's no <malloc.h> on Darwin. Normally I'd say "prefer <stdlib.h>",
but in this case it looks like the code actually uses memalign. There
is no memalign on Darwin. You'll need to switch to posix_memalign if
you actually care about building this.

For now, the easiest is to just exclude macOS.

Test: treehugger
Change-Id: Id8a11cd141f5c4bd30ce95b61ac64759e17732fc
2019-09-08 13:20:07 -07:00
Harish Mahendrakar
8718ff04c4 Merge "decoder: Add host support"
am: dcdaa5c232

Change-Id: I7c2271201499ce8b758f9cb4af470123e9ab862e
2019-08-21 17:56:18 -07:00
Harish Mahendrakar
41bd9cb168 decoder: Add host support
Test: Build libavcdec on host
Bug: 139379050
Change-Id: If81b01e3058e1ae42c8d266571a07deb39fbd603
2019-08-16 12:50:09 -07:00
Harish Mahendrakar
e321c30b3d Merge "encoder: Fix warnings in host build"
am: 9046ac2182

Change-Id: I30b498b2cd57d1d63e66e8367f8703c0a8add6e2
2019-08-16 12:20:44 -07:00
Harish Mahendrakar
753fdf150d encoder: Fix warnings in host build
Fixes a warning on unused fgets return value

Test: Build on host
Bug: 139380252
Change-Id: I80ce9359902ae5f8377e0b4e8b55300749793423
2019-08-14 20:23:28 +00:00
Harish Mahendrakar
fabba6afaf Encoder: Increased max supported bitrate
Increased max bitrate to 240mbps
Bug: 116040772
Test: CTS test

Change-Id: I87d5e2e540e72d3a41a04becf01ff13965361a23
2019-04-15 12:42:48 -07:00
Pirama Arumuga Nainar
0f1e83047c Do not pass "-pie" in cflags
Bug: http://b/111000555

It's only needed for linking and Android already passes this by default.
Passing it to a compile step causes clang to emit
-Wunused-command-line-argument.

Test: build
Change-Id: Iea608387a57f0a65cfc3e67ab19c8d812f4aef37
2018-06-29 14:59:14 -07:00
Ram Mohan
9b39261eb2 avcenc: Change default max bitrate from 20mbps to 50mbps
Test: avcenc test.cfg

Change-Id: I48b896321d6706189fee75f5245b3a388ef5b44c
2018-01-10 19:44:56 +00:00
Chih-Hung Hsieh
4852fbb62a Use -Werror in external/libavc
* Suppress unused-variable warnings.
* Keep constant-conversion warnings.

Bug: 66996870
Test: build with WITH_TIDY=1
Change-Id: Id46435816c0d671c9e03c5297810596df596c7f2
2017-09-28 13:39:11 -07:00
Colin Cross
fc442e1b02 Convert external/libavc to Android.bp
See build/soong/README.md for more information.

Test: m -j checkbuild
Change-Id: I302d98be9e99fce7284a44af329e22f38a2f066a
2017-05-02 13:55:44 -07:00
Doney Alex
87cfdf1d3d Merge \"Encoder: Added support for configuring VUI parameters.\" into nyc-mr1-dev
am: ba8f1f9ef3

Change-Id: I2a634e1e1eab71aca8816a7be2f01dc96f68910f
2016-07-13 00:35:02 +00:00
Hangyu Kuang
ba8f1f9ef3 Merge "Encoder: Added support for configuring VUI parameters." into nyc-mr1-dev 2016-07-13 00:17:37 +00:00
Doney Alex
983e1aecd4 Encoder: Added support for configuring VUI parameters.
Bug: 27442922

Change-Id: I781195e78c480e7449f49467abb1df71902e568d
2016-07-12 14:41:59 -07:00
Harish Mahendrakar
ba93b7fedb DO NOT MERGE Decoder: Added support for exporting VUI params
Bug: 27442922

Change-Id: I4bc3a9fb31ffea1e9e8ae32e5ed49fcc12fbdf42
2016-07-11 22:21:03 +00:00
Harish Mahendrakar
d5953ced23 Decoder: Added support for exporting VUI params
Bug: 27442922

Change-Id: I4bc3a9fb31ffea1e9e8ae32e5ed49fcc12fbdf42
2016-06-22 04:10:00 +00:00
Harish Mahendrakar
cfec181db4 Encoder: Added sample encoder config file to be used with avcenc
avcenc takes command line arguments and as well as supports passing arguments
through a config file

Change-Id: I106814d684bc363863b357a836e7804a65eedaec
2016-06-16 03:28:32 +00:00
Harish Mahendrakar
87cf00e061 Decoder: Added sample decoder config file to be used with avcdec
avcdec takes command line arguments and as well as supports passing arguments
through a config file

Change-Id: Icc1dec3f735f89d510f548641896b7cfac676a2b
2016-06-13 03:36:03 +00:00
Harish Mahendrakar
c59cd5d2be Moved ALOGE and android_errorWriteLog calls under #ifdef __ANDROID__
Also added shared library liblog to test\decoder.mk

Change-Id: If7793f849522dd3f93a5177bab91f4ea5ada41ad
2016-04-18 08:39:18 +05:30
Doney Alex
dfe686ad4a DO NOT MERGE Encoder: Added support for Constrained intra prediction.
Change-Id: I674746047b2b007ca4bc52fad1a2cd9b177cd7bb
2016-03-11 22:10:12 +00:00
Doney Alex
8668fbcc97 Encoder: Added support for Constrained intra prediction.
Change-Id: I674746047b2b007ca4bc52fad1a2cd9b177cd7bb
2016-02-24 16:12:19 +05:30
Harish Mahendrakar
39f8ae0a35 Decoder: Fixed an issue in handling flush
Fixed a NULL pointer reference, when flush is called before
decoding any pictures.

This was seen in following CTS test,
android.media.cts.DecoderTest#testCodecResetsH264WithSurface

Fixed code formatting issues in ih264d_set_flush_mode
Updated the testbench to call flush before decoding starts

Change-Id: Ib04e0b15573b2482c9d5b43c8bc7dd30d8f8efdd
2015-09-02 16:51:43 +05:30
Harish Mahendrakar
34b3e479f4 Decoder: Reduced memory requirements
Memory allocations are now done based on contents of SPS
API changed to move allocations inside the library

Also changed strlen to strnlen

Change-Id: I9130457f564cddb4da7ec6399cc9fe88ee871217
2015-08-04 17:50:14 +05:30
Martin Storsjo
08e68e85c3 avcenc: Initialize avg_time
This fixes valgrind warnings when encoding with b-frames.

Change-Id: I922314e5e6fd09db3ba60e60863e2611309886d5
2015-07-28 18:45:02 +00:00
Marco Nelissen
d0603c30a6 Merge "Remove the now unused stride field from the set dimensions struct" 2015-07-28 18:42:28 +00:00
Martin Storsjo
18e256879b Remove the now unused stride field from the set dimensions struct
Since 90a3904fd3 and d020be5ac7, this field doesn't have any actual
effect - the strides are taken from the input pictures.

Change-Id: I9b08cbf8ee558e038d0017a6176d7b3bd3c428bd
2015-06-27 09:28:24 +03:00
Martin Storsjo
76cdaed5fa Remove double semicolons (empty statements)
Some compilers can't handle this, and these occurrances are typos.

Change-Id: I82349f103cef1f196d1a85dae307aff83c7d6090
2015-06-27 00:42:57 +03:00
Martin Storsjo
a926c1d695 avcenc: Make sure that "avcenc --help" works as intended
The --help option is handled by the normal argument parsing loop
below, but that is only invoked if argc > 2.

Change-Id: Icff3625412c340565c062628f2657c41db73068e
2015-06-24 21:07:43 +00:00