Answers.Body: <p>This means although it is and I-frame, the decoder might still use/need previously sent frames for decoding. In contrast if <code>key_frame=1</code> this would be an <strong>IDR-Frame</strong> (Instantaneous Decoder Refresh).</p>
  <p>Citing from  Ian E. G. Richardson's <em>H.264 and MPEG-4 Video Compression</em>:</p>
  <blockquote>
  <p>An encoder sends an IDR (Instantaneous Decoder Refresh) coded picture
  (made up of I- or SI-slices) to clear the contents of the reference
  picture buffer. On receiving an IDR coded picture, the decoder marks
  all pictures in the reference buffer as ‘unused for reference’. All
  subsequent transmitted slices can be decoded without reference to any
  frame decoded prior to the IDR picture. The first picture in a coded
  video sequence is always an IDR picture.</p>
  </blockquote>
  <p>This may have impact on random access to a video. Simply said, IDR frames make random access more robust.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2017-05-15T08:04:18.080Z
Answers.LastActivityDate: 2021-02-23T17:25:48.600Z
Answers.LastEditDate: 2021-02-23T17:25:48.600Z
Answers.UserDisplayName: cweigel
Body: <p>I am trying to exrtact key frame information from a mp4 video using ffprobe with the command:</p>
  
  <pre><code>ffprobe -select_streams v -show_frames FILE_NAME  2&gt;/dev/null
  </code></pre>
  
  <p>I am getting the list of all frames. From these, I searched for frames with pict_type=I to recognise I-frames. However, there were about 10 of the total 700 I frames which had</p>
  
  <pre><code>media_type=video
  key_frame=0
  pict_type=I
  </code></pre>
  
  <p>What are these frames? If these are I-frames what makes them not a key_frame?</p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2015-03-14T16:24:40.470Z
Comments.Text: What is the definition of a "key frame' in this context?
Comments.UserDisplayName: Jim Mack
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2015-03-14T17:43:37.810Z
Comments.Text: I am not actually sure. From what I knew, it is the I-frame, but from the ffprobe output, there are I-frames which are not key_frames. That is what my question is.
Comments.UserDisplayName: cnvzmxcvmcx
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2015-03-16T22:46:59.967Z
Comments.Text: Without context, or a definition from the ffprobe docs, there's no way to know. But I have to ask -- if you don't know what they are, why are you looking for them?
Comments.UserDisplayName: Jim Mack
Tags: <ffmpeg><keyframes>
Title: Frames with pict_type=I yet key_frame=0
UserDisplayName: cnvzmxcvmcx
ThreadText: # Frames with pict_type=I yet key_frame=0
  
  (Asked by: username_0 on 2015-03-14)
  
  I am trying to exrtact key frame information from a mp4 video using ffprobe with the command:
  
  ```
  ffprobe -select_streams v -show_frames FILE_NAME  2>/dev/null
  
  ```
  
  I am getting the list of all frames. From these, I searched for frames with pict\_type=I to recognise I-frames. However, there were about 10 of the total 700 I frames which had
  
  ```
  media_type=video
  key_frame=0
  pict_type=I
  
  ```
  
  What are these frames? If these are I-frames what makes them not a key\_frame?
  
  **Tags:** ffmpeg, keyframes
  
  > **Comments:**
  > **username_1**: What is the definition of a "key frame' in this context?  
  > **username_0**: I am not actually sure. From what I knew, it is the I-frame, but from the ffprobe output, there are I-frames which are not key_frames. That is what my question is.  
  > **username_1**: Without context, or a definition from the ffprobe docs, there's no way to know. But I have to ask -- if you don't know what they are, why are you looking for them?  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_2 on 2017-05-15. Score: 4
  
  This means although it is and I-frame, the decoder might still use/need previously sent frames for decoding. In contrast if `key_frame=1` this would be an **IDR-Frame** (Instantaneous Decoder Refresh).
  
  Citing from Ian E. G. Richardson's *H.264 and MPEG-4 Video Compression*:
  
  > An encoder sends an IDR (Instantaneous Decoder Refresh) coded picture
  > (made up of I- or SI-slices) to clear the contents of the reference
  > picture buffer. On receiving an IDR coded picture, the decoder marks
  > all pictures in the reference buffer as ‘unused for reference’. All
  > subsequent transmitted slices can be decoded without reference to any
  > frame decoded prior to the IDR picture. The first picture in a coded
  > video sequence is always an IDR picture.
  
  This may have impact on random access to a video. Simply said, IDR frames make random access more robust.
  
  
  ---
  
  