Hi,
Please download source code and run the steps:
- Execute configure command in
README.nvidia
ffmpeg-4.2.2$ ./configure --enable-nvv4l2dec --enable-libv4l2 --enable-shared --extra-libs=“-L/usr/lib/aarch64-linux-gnu/tegra -lnvbuf_utils” --extra-cflags=“-I /usr/src/jetson_multimedia_api/include/”
- Modify this line in ffbuild/config.mak
EXTRALIBS-avcodec=-pthread -lm -lz -lv4l2
- Modify this line in ffbuild/config.sh
extralibs_avcodec=“-pthread -lm -lz -lv4l2”
- Build the package: $ make -j4
- Compile the sample with self-built libavcodec.so
ffmpeg-4.2.2$ g++ ffmpeg_test.cpp -Llibavformat/ -lavformat -Llibavcodec/ -lavcodec -o ffmpeg_test