Files
rocm-systems/projects/rocdecode/samples/videoDecode
Kiriti Gowda 7f64bb0b61 FFMPEG - Updates (#33)
* FFMPEG - Updates

* Readme - Updates

* Sample - Install

* Install Sample Deps

* Samples - Updates

* Sample - Added missing header

[ROCm/rocdecode commit: d34d85027c]
2023-11-06 11:51:47 -05:00
..
2023-11-06 11:51:47 -05:00
2023-11-06 11:51:47 -05:00
2023-11-06 11:51:47 -05:00

Video Decode Sample

This sample illustrates the FFMPEG demuxer to get the individual frames which are then decoded on AMD hardware using VAAPI.

This sample supports both YUV420 8-bit and 10-bit streams.

Prerequisites:

  • Linux distribution

    • Ubuntu - 20.04 / 22.04
  • ROCm supported hardware

  • Install ROCm 5.5 or later with --usecase=graphics,rocm --no-32

  • rocDecode

  • CMake 3.5 or later

  • FFMPEG

    sudo apt install ffmpeg libavcodec-dev libavformat-dev libswscale-dev
    

Build

mkdir build
cd build
cmake ../
make -j

Run

./videodecode -i <input video file [required]> 
              -o <output path to save decoded YUV frames [optional]> 
              -d <GPU device ID - 0:device 0 / 1:device 1/ ... [optional - default:0]>