If you run the exercise of MediaPlayer for Video with un-supported video format, and monitor the LogCat report:- You will notice that error of "getFrameAtTime: videoFrame is a NULL pointer" will be thrown in MediaMetadataRetriever. This happen when VideoListFragment.java try to get Thumbnail in getView(). No Thumbnail will be returned. It's OK in this case.
BUT - problem is: after valid Thumbnail returned for supported video format, error "getFrameAtTime: videoFrame is a NULL pointer" will not be thrown again, and the old thumbnail will be returned for later un-supported video format. So the list will display a in-correct thumbnail for un-supported video format.
Currently, I have no any solution for this problem! I even don't know if it's a fault in my code, or is a bug from Android. I hope anybody can leave me comments to solve the problem.
Which device do you use?
ReplyDeleteI tested it on Nexus One.
ReplyDeletefound a solution to this ?
ReplyDeleteSame problem.
ReplyDeleteI decided to keep all loaded thumbnails in cache and not to ask them again.