From e8dcdae14e9c15c969198db3966d9af977200246 Mon Sep 17 00:00:00 2001 From: rupakroyintel Date: Sun, 18 Dec 2022 23:48:48 -0800 Subject: [PATCH] add readme files to sample tools --- tools/legacy/sample_decode/README.md | 18 +++++++ tools/legacy/sample_encode/README.md | 47 +++++++++++++++++++ tools/legacy/sample_multi_transcode/README.md | 32 +++++++++++++ tools/legacy/sample_vpp/README.md | 25 ++++++++++ 4 files changed, 122 insertions(+) create mode 100644 tools/legacy/sample_decode/README.md create mode 100644 tools/legacy/sample_encode/README.md create mode 100644 tools/legacy/sample_multi_transcode/README.md create mode 100644 tools/legacy/sample_vpp/README.md diff --git a/tools/legacy/sample_decode/README.md b/tools/legacy/sample_decode/README.md new file mode 100644 index 00000000..6d181610 --- /dev/null +++ b/tools/legacy/sample_decode/README.md @@ -0,0 +1,18 @@ +sample_decode is an oneVPL decode application that takes a file containing an encoded video elementary stream as an argument, performs decoding of various video compression formats, and writes the decoded output to the file in raw native format (NV12 for GPU). +Command Line format: +```sample_decode h264|h265|mpeg2|mvc|jpeg -i in.bit -o out.yuv``` +Sample Command Line: +```sample_decode h265 -i ../../../content/cars_320x240.h265 -o out.yuv``` +Sample Output: +``` +Loaded Library configuration: + Version: 2.7 + ImplName: mfx-gen + Adapter number : 0 + Adapter type: integrated + DRMRenderNodeNum: 128 +Used implementation number: 0 +Decoding started +Frame number: 30, fps: 742.868, fread_fps: 0.000, fwrite_fps: 0.000358 +Decoding finished +``` diff --git a/tools/legacy/sample_encode/README.md b/tools/legacy/sample_encode/README.md new file mode 100644 index 00000000..705840cf --- /dev/null +++ b/tools/legacy/sample_encode/README.md @@ -0,0 +1,47 @@ +sample_encode is a oneVPL application that performs preprocessing and encoding of an uncompressed video stream of raw native format (NV12 for GPU) according to a specific video compression standard and can write the encoded video stream to a specified file. +Command Line format: +``` +sample_encode h264|h265|mpeg2|mvc|jpeg -i InputYUVFile -o OutputEncodedFile -w width -h height -angle 180 -opencl +``` +Sample Command Line: +``` +sample_encode h265 -hw -i ../../../content/cars_320x240.nv12 -w 320 -h 240 -o output.h265 +``` +Sample Output: +``` +Loaded Library configuration: + Version: 2.7 + ImplName: mfx-gen + Adapter number : 0 + Adapter type: integrated + DRMRenderNodeNum: 128 +Used implementation number: 0 +Loaded modules: + 0: /root/samples_test/oneVPL/lib/libvplswref64.so.1 + 1: /usr/lib/x86_64-linux-gnu/libmfx-gen.so.1.2.7 + 2: /usr/lib/x86_64-linux-gnu/libmfxhw64.so.1.35 + +Input file format YUV420 +Output video HEVC +Source picture: + Resolution 320x240 + Crop X,Y,W,H 0,0,320,240 +Destination picture: + Resolution 320x240 + Crop X,Y,W,H 0,0,320,240 +Frame rate 30.00 +Bit rate(Kbps) 432 +Gop size 0 +Ref dist 0 +Ref number 0 +Idr Interval 0 +Target usage balanced +Memory type system +Media SDK impl hw +Media SDK version 2.7 +Processing started +Frame number: 30 +Encoding fps: 994 +Processing finished +``` + diff --git a/tools/legacy/sample_multi_transcode/README.md b/tools/legacy/sample_multi_transcode/README.md new file mode 100644 index 00000000..dea3fdc8 --- /dev/null +++ b/tools/legacy/sample_multi_transcode/README.md @@ -0,0 +1,32 @@ +sample_multi_transcode performs the transcoding (decoding and encoding) of a video stream of one compressed video format to another, with optional video processing (resizing) of uncompressed video prior to encoding. The application supports multiple input and output streams meaning it can execute multiple transcoding sessions concurrently. +Command Line Format: +``` +Format-1: sample_multi_transcode [options] [--] pipeline-description +Format-2: sample_multi_transcode [options] -par ParFile +``` +ParFile is extension of what can be achieved by setting pipeline in the command line. +Sample Command Line: +``` +sample_multi_transcode -hw -i::h265 ../../../content/cars_320x240.h265 -o::mpeg2 out.mpeg2 +``` +This command line transcodes a h265 video file to mpeg2 video format and writes it to out.mpeg2. +Sample Output: +``` +Session 0: +Loaded Library configuration: + Version: 2.7 + ImplName: mfx-gen + Adapter number : 0 + Adapter type: integrated + DRMRenderNodeNum: 128 +Used implementation number: 0 +Input video: HEVC +Output video: MPG2 +Session 0 was NOT joined with other sessions +Transcoding started +Transcoding finished +Common transcoding time is 0.0288 sec +------------------------------------------------------------------------------- +*** session 0 [0x295d730] PASSED (MFX_ERR_NONE) 0.0287292 sec, 30 frames, 1044.235 fps +-hw -i::h265 ../../../content/cars_320x240.h265 -o::mpeg2 out.mpeg2 +``` diff --git a/tools/legacy/sample_vpp/README.md b/tools/legacy/sample_vpp/README.md new file mode 100644 index 00000000..f69e9d93 --- /dev/null +++ b/tools/legacy/sample_vpp/README.md @@ -0,0 +1,25 @@ +sample_vpp is a oneVPL application that performs video processing of raw video sequences. +Command Line Format: +``` +sample_vpp [Options] -i InputFile -o OutputFile +``` +Sample Command Line: +``` +sample_vpp -sw 320 -sh 240 -dw 320 -dh 240 -i out.raw -o crop.raw +``` +Sample Output: +``` +Loaded Library configuration: + Version: 2.7 + ImplName: mfx-gen + Adapter number : 0 + Adapter type: integrated + DRMRenderNodeNum: 128 +Used implementation number: 0 +VPP started +Frame number: 30 +VPP finished +Total frames 30 +Total time 0.01 sec +Frames per second 2151.000 fps +```