title: MediaMetadataRetriever getFrameAtTime: videoframe is a null pointer
body: <p>I´m trying to get a frame of a video, so I´m using MediaMetadataRetriever.getFrameAtTime() like this:</p>
  
  <pre><code>    Uri directorio = Uri.parse("android.resource://com.extremeye/" + R.raw.video);
      media = new MediaMetadataRetriever();
      media.setDataSource(this, directorio);
  
      frame = (ImageView)findViewById(R.id.frame);
      Bitmap bmFrame = media.getFrameAtTime();
      frame.setImageBitmap(bmFrame);
  </code></pre>
  
  <p>But the problem is that I get:</p>
  
  <blockquote>
    <p>MediaMetadataRetriever getFrameAtTime: videoframe is a null pointer</p>
  </blockquote>
  
  <p>in the logCat.</p>
  
  <p>I´m sure that the video is compatible with android OS and the MediaMetadataRetriever loads it because I can get its metadata description without problems in a 2.3.3 OS version.</p>
  
  <p>I don´t know why I can´t get the frame but if I use a 4.2 OS version, it works perfectly. I tried to change the codec and the format of the video but it doesn´t work... I suppose that it´s a problem of format compatibility but I don´t know what I can do...</p>
  
  <p>Thanks!!</p>