Is there a way to extract number of duplicated or dropped video frames during the decoding of a .mp4 or .ts file through ffmpeg's C API?
This information is reported by ffmpeg when using the command line tool.
Not applicable.
Dup/drop with the CLI is carried out by the ffmpeg program, specifically the vsync/fps_mode code. This is not exposed or used by any of the libav* API calls.