title: How to get keyframes of video ffmpeg for videos created by Red5?
body: <p>I had a task of getting keyframes information of a video i.e. getting time duration of all keyframes(seeking video via rtmp url).
  To get information of all the frames of video use following command:</p>
  
  <pre><code>ffprobe -show_frames testVideo.mp4 &gt; data.txt
  </code></pre>
  
  <p>The information I get from data.txt file :</p>
  
  <pre><code>“keyframe=1” signifies that it tried to make keyframe
  “pict_type=I” signifies a keyframe or I-frame
  here I get exact time duration of keyframe.
  </code></pre>
  
  <p>actual fps of video</p>
  
  <pre><code>fps = coded_picture_number(last frame that contains coded_picture_number) / pkt_pts_time
  </code></pre>
  
  <p>Above information worked well for most of the videos.But for some videos that were created by Red5 were showing abnormal results.
  List of urls I have searched<br>
  <a href="http://sinclairmediatech.com/using-ffprobe-to-evaluate-keyframes/" rel="nofollow">http://sinclairmediatech.com/using-ffprobe-to-evaluate-keyframes/</a><br>
  <a href="http://ffmpeg-users.933282.n4.nabble.com/How-can-I-find-the-keyframe-information-for-a-mp4-video-td4349687.html" rel="nofollow">http://ffmpeg-users.933282.n4.nabble.com/How-can-I-find-the-keyframe-information-for-a-mp4-video-td4349687.html</a>  </p>
  
  <p>please help if I am wrong or need any other command.
  Thanks in advance.</p>