MarcGBeauchamp

I used the WavSource MediaSource example and I used it in topology using a tee node. When I do that, an errors occurs after starting the session (0x8000FFFF). If I dont use a tee node everything works fine. I tried setting the MF_TOPONODE_PRIMARYOUTPUT and MF_TOPONODE_DISCARDABLE but that did not change anything.

Marc



Re: Media Foundation Development Tee node and custom media source

Becky Weiss - MSFT

This is most likely just some mistake in how the topology is set up. Double-check all of the node connections to make sure they're correct... That's my first guess.

If you're completely sure that you've set up the topology correctly, then I have two more questions:

1) Does the error occur during the IMFMediaSession::SetTopology operation, or does it occur during the IMFMediaSession::Start operation

2) What exactly does your topology look like






Re: Media Foundation Development Tee node and custom media source

MarcGBeauchamp

I dont think it is a configuration error. I used that same topology using the SourceResolver with an MP3 file without any problems. I also can use the Custom WavSource Media Source WITHOUT Tee Node without any problems.

Then, using the tee node in the topology, I only change the Media Source to use the custom WavSource Media Source from the example.

IMFByteStream* pByteStream = NULL;

hr = MFCreateFile(MF_ACCESSMODE_READ, MF_OPENMODE_FAIL_IF_NOT_EXIST, MF_FILEFLAGS_NONE, sURL, &pByteStream);

hr = WavSource::CreateInstance(IID_IMFMediaSource, (void**)&m_pSource);

if (SUCCEEDED(hr))

{

hr = ((WavSource*)m_pSource)->Open(pByteStream);

}

Here are the answers to your questions:

1) It occurs after the IMFMediaSession::Start

2) Src(WavSource Custom Media Source)->Tee->Audio Renderer (Default sound card)

I modified the basic playback example to reproduce the problem. I can send it to you if you want.

Thanks!

Marc





Re: Media Foundation Development Tee node and custom media source

Becky Weiss - MSFT

Why would you want a tee with only one output

Sure, if you're willing, just send over your modified-basic-playback test application... That'll probably save us some iterations.






Re: Media Foundation Development Tee node and custom media source

MarcGBeauchamp

Yes, there is actually more than one output.



Re: Media Foundation Development Tee node and custom media source

Becky Weiss - MSFT

Just an update in case you're wondering where this is... I haven't gotten to it yet but hope to next week.

--BW






Re: Media Foundation Development Tee node and custom media source

Becky Weiss - MSFT

I just tried out your test application and, well, WAV files play just fine for me. Since you're most likely talking about RC1, and I'm running a newer build, I'd like you to try this again with the next SDK version that comes out and let me know if you're still running into this problem.

Becky






Re: Media Foundation Development Tee node and custom media source

MarcGBeauchamp

Looks like it's fixed in RC2. I just finished installing RC2 (5744) and it works now.
Thanks for looking into it.
Marc




Re: Media Foundation Development Tee node and custom media source

MarcGBeauchamp

I revisited this on RTM because I was going to implemented this feature on our product. Sadly, it is broken in RTM. I've tried both to:

1) Register the .wav ByteStreamHandlers dll and letting the source resolver do it's work

2) Create an instance of the WavSource class explicitely.

In both situation, it works if my topology does not contain a tee node. But if I insert a tee node in the topology, the topology fails to start. On the otherhand, if I just use the source resolver, I can play a WMA file with a tee node in the topology. So I definitely know that the problem is not with my topology.

Marc