5 votes
Accepted

Call FFmpeg filter from source code (C API)

You can't just call a filter, You must instantiate a filter graph. First you need to create a buffer and buffersink via: AVFilterContext* source = 0; AVFilterContext* sink = 0; AVFilterGraph *graph =...
SlimSCSI's user avatar
  • 1,060
4 votes

How to extract each video scene with FFmpeg

Using the encoder's scenecut to detect scenes is not advisable, since its purpose is efficient GOP splitting taking into account other encoding parameters. It is not a "pure" scene detector. Its ...
Gyan's user avatar
  • 32.3k
3 votes
Accepted

Print to file: Details of every NAL unit in raw H.264 file

You can use the trace_headers bitstream filter in ffmpeg ffmpeg -i in.264 -c copy -bsf:v trace_headers -f null - 2> NALUS.txt The text file will have data like this, [AVBSFContext @ ...
Gyan's user avatar
  • 32.3k
3 votes
Accepted

hardware cuda decoding error

Stream 0 is Stream #0:0[0x1006]: Video: mpeg2video for which you need -c:v mpeg2_cuvid
Gyan's user avatar
  • 32.3k
2 votes
Accepted

Please Explain the Codecs in my Example

So codecs compress and decompress videos, right? COmpress DECompress. Yep. Just like with text encoding, e.g. ascii or unicode, but with video you take a raster (grid of pixels) and turn that into a ...
stib's user avatar
  • 13.6k
2 votes
Accepted

FFMPEG 4.0 skipping frames

Y4M has no timestamps, only framerate in its header. So, if your source has any variability in its framerate, you'll see a shift in apparent timestamp in the Y4M. e.g. n src y4m 0 0 ...
Gyan's user avatar
  • 32.3k
2 votes
Accepted

Retrieve and decode V-Chip data from an aired digital TV stream

V-Chip is encoded in the Extended Data Services (XDS) that is part EIA-608 captions. How it is actually transported in/with the video depends the signal type and medium. Analog: Encoded with the ...
Michael Liebman's user avatar
1 vote
Accepted

What happens when a compressed video is played back?

In most common compression schemes, there isn't a 1::1 correspondence between "video" frames and "file" (or stream) frames **. Any particular video frame may require the contents of several file ...
Jim Mack's user avatar
  • 4,674
1 vote
Accepted

Parallel throughput of Intel QuickSync (QSV) for real time streams

It depends on a lot of factors, but mainly the codec, bitrate and resolution of the source and output files. Unfortunately, I don't know of any websites that catalog the performance of quicksync, but ...
D34DC3N73R's user avatar
1 vote

What actually happens to footage that is upscaled or downscaled?

... Depends... There are many concepts that need to be differentiated. Let me explore a bit. Information The first one is that we need to think about an image as information. So we need to ask first. ...
Rafael's user avatar
  • 1,152
1 vote

Why doesn't FFMPEG output frames as jpg? How can I fix my code?

Your build doesn't have the image2 muxer enabled, which is required for image sequences.
Gyan's user avatar
  • 32.3k
1 vote
Accepted

Efficient decoding of 10-bit 4k h264 from GH5S?

Nvdec and qsv do not have support for 10 bit AVC. And if there was a more “efficient” software decoder available, it would already be in ffmpeg.
SlimSCSI's user avatar
  • 1,060
1 vote

How to extract each video scene with FFmpeg

This script makes it simple, better results than other posts around town: https://gist.github.com/achesco/4dc2ebf13378a0a61fc26c7fe01f539e Splits file.mp4 file to scenes with change more than 0.5 and ...
dtmland's user avatar
  • 111
1 vote

Good codec for embedded system video decoding

While I haven't implemented this myself I would suspect Google's VP9 (or VP10) to be a good option. Considering Android phones use an ARM CPU, the codecs and libraries supporting it should be ...
TravisO's user avatar
  • 153
1 vote

FFmpeg run multiple filters in parallel from C API

Filters cant really run in parallel because they can modify frames, and you can’t modify a frame in two threads at the same time. You can make a copy of the frame and run two filter graphs.
SlimSCSI's user avatar
  • 1,060
1 vote
Accepted

Compile FFmpeg example code

It does not produce any output file. After filtering, display_frame() is called, which simply outputs to the console. /* Trivial ASCII grayscale display. */ p0 = frame->data[0]; puts("\033c"); ...
Gyan's user avatar
  • 32.3k
1 vote

Objective video quality assessment

What you are looking for is called “no-reference quality assessment”. Google can give you specific examples.
SlimSCSI's user avatar
  • 1,060
1 vote
Accepted

FFmpeg. CUDA decode. Past duration too large. Variable FPS

The key -drop_second_field 1 fixed this issue. And result command looks as follow: ffmpeg -y -hwaccel cuvid -c:v h264_cuvid -deint 2 -drop_second_field 1 -i "udp://IP:PORT" -vcodec h264_nvenc -...
Ivan Kolesnikov's user avatar
1 vote

hardware cuda decoding error

It's a bug in ffmpeg. When you explicitly specify a type of the HW acceleration (i.e. cuvid), ffmpeg assigns 0 to CUVIDDECODECREATEINFO::ulNumDecodeSurfaces and to CUVIDDECODECREATEINFO::...
facetus's user avatar
  • 111

Only top scored, non community-wiki answers of a minimum length are eligible