LukasBommes / mv-extractor

Extract frames and motion vectors from H.264 and MPEG-4 encoded video.
MIT License
279 stars 56 forks source link

how to get only I - frame #12

Closed duckaivn closed 2 years ago

duckaivn commented 2 years ago

Hi, first of all thanks for your library, it's very helpful. I'm wondering how to get only I - frames or decompress P/B via I -frames. Can you help me please?

LukasBommes commented 2 years ago

Hello Minh Duc, I guess you reached out to me via email regarding this. Maybe, let me post my answer here again, in case someone else has the same question:

"Usually, MPEG-4 will try to use as many P-frames and as few I-frames as possible, since I-frames are expensive in terms of bandwidth, whereas P-frames are cheap. So, whether you get an I- or P-frame is dictated by your video and not up to the video decoder inside mv-extractor."

Lukas