QuickTime Player will not playback with MediaExtention

Hi Everyone!

I am writing a media extension to playback old "Amiga" ANIM files, as a test project.

I have build the following objects:

  • MEFormatReader
  • METrackReader
  • MESampleCursor

The subclassed objects seem fairly straightforward. Rather than create a Video Decoder, I followed the instructions in the SampleCursor object header, and use the function: loadSampleBufferContainingSamplesToEndCursor:completionHandler: to deliver an BGRA 8-bit image.

This works great AVPlayer object in my Swift based test app, but QuickTime Player will not actually play the movie. If I scrub on QuickTime Player's timeline, I can watch the movie just fine. But if I click on the "Play" button. Nothing happens.

For fun, I created a custom pixel type, and implemented a MEVideoDecoder object.

This also works with my AVPlayer test app, but again, same problem with QuickTime Player.

I have even generated a JPEG image in the SampleCursor, and that fails too.

I am stumped on this. I do not see any way to have QuickTime Player work properly with my MediaExtension, nor is there any documentation as to what to do.

Suggestions?

bob

Answered by Engineer in 891222022

It sounds like you have things mostly working if you are able to play using AVPlayer in your test app. You should be able to play in QuickTime Player as well.

I would suggest that you try to add some logging into your MESampleCursor methods to try to see the differences in the calls coming in from AVPlayer in your test app versus in QuickTime Player.

As a general rule, make sure you are returning the correct error codes in limit cases and follow the recommendations from the MEFormatReader.h header file about which sample buffer methods to implement and which to leave unused.

It sounds like you have things mostly working if you are able to play using AVPlayer in your test app. You should be able to play in QuickTime Player as well.

I would suggest that you try to add some logging into your MESampleCursor methods to try to see the differences in the calls coming in from AVPlayer in your test app versus in QuickTime Player.

As a general rule, make sure you are returning the correct error codes in limit cases and follow the recommendations from the MEFormatReader.h header file about which sample buffer methods to implement and which to leave unused.

QuickTime Player will not playback with MediaExtention
 
 
Q