Name | Date | Size | #Lines | LOC | ||
---|---|---|---|---|---|---|
.. | - | - | ||||
Android.bp | H A D | 25-Apr-2025 | 1.4 KiB | 55 | 47 | |
AndroidTest.xml | H A D | 25-Apr-2025 | 1.9 KiB | 38 | 23 | |
AvcEncTest.cmake | H A D | 25-Apr-2025 | 798 | 25 | 20 | |
AvcEncTest.cpp | H A D | 25-Apr-2025 | 34.9 KiB | 1,010 | 764 | |
DynamicConfig.xml | H A D | 25-Apr-2025 | 819 | 21 | 5 | |
README.md | H A D | 25-Apr-2025 | 1.8 KiB | 81 | 63 | |
TestArgs.h | H A D | 25-Apr-2025 | 1.9 KiB | 73 | 43 |
README.md
1# AvcEncTest 2The AvcEncoder Test Suite validates the Avc encoder. 3 4## Linux x86/x64 5 6### Requirements 7- cmake (3.9.1 or above) 8- make 9- clang (12.0 or above) 10 11### Steps to build 12Clone libavc repository 13``` 14$ git clone https://android.googlesource.com/platform/external/libavc 15``` 16Create a directory inside libavc and change directory 17``` 18 $ cd libavc 19 $ mkdir build 20 $ cd build 21``` 22 23Build with -DENABLE_TESTS=1. 24``` 25 $ cmake .. -DENABLE_TESTS=1 -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ \ 26 -DCMAKE_BUILD_TYPE=Debug 27 $ make 28``` 29 30Optionally, enable sanitizers by passing -DSANITIZE 31``` 32 $ cmake .. -DENABLE_TESTS=1 -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ \ 33 -DCMAKE_BUILD_TYPE=Debug -DSANITIZE=fuzzer-no-link,address,\ 34 signed-integer-overflow,unsigned-integer-overflow 35 $ make 36``` 37 38The media files for the tests are present [at](https://dl.google.com/android-unittest/media/external/libavc/tests/AvcTestRes-1.0.zip). 39Download and extract these the current folder. 40 41usage: AvcEncTest -P \<path_to_the local folder\> 42 43``` 44$./AvcEncTest -P ./ 45``` 46 47## Android 48 49Run the following steps to build the test suite: 50``` 51m AvcEncTest 52``` 53 54To test 64-bit binary push binaries from nativetest64. 55``` 56adb push ${OUT}/data/nativetest64/AvcEncTest/AvcEncTest /data/local/tmp/ 57``` 58 59To test 32-bit binary push binaries from nativetest. 60``` 61adb push ${OUT}/data/nativetest/AvcEncTest/AvcEncTest /data/local/tmp/ 62``` 63 64The resource file for the tests is taken from [here](https://dl.google.com/android-unittest/media/external/libavc/tests/AvcTestRes-1.0.zip) 65 66Download, unzip and push these files into device for testing. 67 68``` 69adb push AvcTestRes-1.0 /sdcard/test/ 70``` 71 72usage: AvcEncTest -P \<path_to_folder\> 73``` 74adb shell /data/local/tmp/AvcEncTest -P /sdcard/test/AvcTestRes-1.0/ 75``` 76Alternatively, the test can also be run using atest command. 77 78``` 79atest AvcEncTest 80``` 81