Why this ASF can be played by WMP but failed to be rendered by GraphEdit RRS feed

  • Question

  • Hi, 

    My program uses Windows Media Foundation WMV/WMA MFTs to encode to ASF format (mux is done by ffmpeg). Generated file can be played perfectly by Windows Media Player on Win10 but failed to be rendered by GraphEdit, error code == NS_E_INVALID_DATA (0xC00D002FL). Same error happens when IWMSyncReader->GetNextSample is used to read audio sample. 

    A sample broken video is here: https://www.dropbox.com/s/x8uyaqbclq93u5d/big_buck_bunny.wmv?dl=0

    Could anyone take a look to check the cause?


    • Edited by azzurro1994 Tuesday, November 28, 2017 11:21 PM
    Friday, February 3, 2017 1:30 AM

All replies

  • Can anyone have a look at it?



    By the way, I used the SimplePlay sample program on Win7 and Win10, the video can be played on both platform perfectly.

    Could it caused by some limitation of Windows Media API?

    • Edited by azzurro1994 Wednesday, November 29, 2017 12:26 AM
    Tuesday, November 28, 2017 11:21 PM
  • Tools like PowerDirector report the same error on this file when it is added (then it can read it)

    SDK samples which use Media Foundation (like WMP) can read it while samples using IGraphBuilder report the same error on IMediaEvent::GetEvent()

    Wednesday, November 29, 2017 1:27 AM
  • The comment here in your cross-post perhaps gives a hint:

    The broken video doesn't contain Extended Stream Properties objects for video and audio. You can examine it with a tool like Microsoft Windows Media ASF Viewer 9. It seems that you need to configure the ASF media sink properly in order to make it create the Extended stream properties.

    FFmpeg's multiplexer is presumably out of date compared to Windows 10 ASF reader implementation. A small problem is ignored on some systems and is an obstacle on other, esp. with stricter checking of some internal parameter in newer OS.

    FFmpeg's multiplexer looks like a guesswork in attempt to produce compatible file, so it's pretty much possible that once in a while you see an incompatibility. 


    Wednesday, November 29, 2017 7:39 AM
  • Hi Roman,

    We use Windows Media Foundation encoder + ffmpeg as a way to lower memory consumption. If use Window Media Foundation encoders + muxer or Windows Media API, encoding a high resolution video on 32 bit Windows fails quickly because of out of memory.

    Thursday, November 30, 2017 11:34 PM
  • Thanks friend,

    As I said in my reply to Roman, our program has to use ffmpeg to mux. The thing is, our program uses Windows Media API to open asf so it's funny that the asf generated by our program can be played by ffmpeg, WMP, but can't be played in our own program.

    Maybe use Windows Media Foundation to decode is an option for us.


    Thursday, November 30, 2017 11:39 PM
  • Hi Roman,

    Can you assure missing of the Extended Stream Property is the root cause of the issue? If so I may check ffmpeg code and try to fix it.


    Thursday, November 30, 2017 11:44 PM
  • I read above that you multiplex with FFmpeg. And I believe this is exactly the source of the problem, FFmpeg's output is different from Microsoft's. I am not sure about Extended Stream Property exactly, there might be something else different.


    Friday, December 1, 2017 7:05 AM