# FFmpeg decoder

## V-Nova LCEVC FFmpeg decoder commands

The V-Nova LCEVC decoder can be used similarly to other codecs in FFmpeg or FFplay, with one important difference. The enhancement layer is embedded as metadata in a fully compliant and backward compatible H.264/AVC or H.265/HEVC elementary stream. Therefore, the decoder must be instructed to extract and decode LCEVC data.

The command line to enable V-Nova LCEVC decoding of an LCEVC-enhanced transport stream or MP4 file, is as follows:

`ffmpeg.exe -vcodec lcevc_h264 -i stream.ts -vcodec rawvideo output.yuv`

`ffmpeg.exe -vcodec lcevc_h264 -i stream.mp4 -vcodec rawvideo output.yuv`

The equivalent command line for HEVC is:

`ffmpeg.exe -vcodec lcevc_hevc -i stream.ts -vcodec rawvideo output.yuv`

`ffmpeg.exe -vcodec lcevc_hevc -i stream.mp4 -vcodec rawvideo output.yuv`

And for FFplay, h.264 and HEVC respectively:

`ffplay.exe -vcodec lcevc_h264 -i stream.mp4`

`ffplay.exe -vcodec lcevc_hevc -i stream.mp4`

### Decoding to perform Objective evaluation

To perform objective metric calculations when dithering is enabled in LCEVC encoding, dithering **must** be disabled as follows:

`ffmpeg.exe -vcodec lcevc_h264 -disable_dithering 1 -i stream.mp4 -vcodec rawvideo output.yuv`

To calculate metrics, the command line is similar to that of other codecs in FFmpeg, in line with guidelines included at the following link, and as shown in the following command line:

<https://github.com/Netflix/vmaf/blob/master/resource/doc/libvmaf.md>

`ffmpeg.exe -vcodec lcevc_h264 –i input_stream.ts -vcodec rawvideo -s 1920x1080 -i reference_yuv.yuv -filter_complex " [0:v]scale=1920x1080:flags=bicubic[main];[main][1:v]libvmaf" -f null`


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.v-nova.com/technologies/mpeg-5.lcevc/integrations/ffmpeg/ffmpeg-decoder.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
