I have two questions regarding the Group-of-Pictures (GOP) in MPEG4 Video (both for MPEG4 Part2 and H.264):
How can I extract the GOP structure and size of a video sequence using FFmpeg? I know that the
av_get_picture_type_char
function of theAVPicture
struct yields picture types for each frame, but I wonder if there is a more direct method to obtain the GOP information?How can I detect whether the sequence has open GOPs or closed GOPs, i.e. whether B frames from one GOP are allowed to refer to the I and P frames in an adjacent GOP?