question

SteveWilliams-5461 avatar image
0 Votes"
SteveWilliams-5461 asked SteveWilliams-5461 commented

Media Foundation : Looping & Sequences

Got an instability performing a simple loop of one short video (provided as repro)

https://stackoverflow.com/questions/66867668/media-foundation-looping-video-unstable-on-6th-run

Also found : https://docs.microsoft.com/.../sequencer-source-example-code

Playlist .... mmkay. https://docs.microsoft.com/.../medfound/playlist-sample "this sample is no longer included"

Can I have access to the playlist sample, please. I'd rather not type it in again from what's possibly incomplete documentation.

Also any idea why simple looping is unstable ?

Thanks in advance.

windows-api-graphics-media
· 2
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Does this sample work for you?


0 Votes 0 ·

Hi SongZhu.

That's a Windows Store managed c++ app.

I need native desktop win32 API (64 bit) fully working example, please.

Which can :

  1. Play video

  2. Play looped with no gaps - a large number of times (think 1 second loop of some effect)

  3. Has the Topology exposed as I need to modify it.


  4. (optional) Play sequence (I can implement this if the rest works).


Thanks.

0 Votes 0 ·
Castorix31 avatar image
0 Votes"
Castorix31 answered Castorix31 edited

Can I have access to the playlist sample, please.

The class is in the doc CPlaylist Class


5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

SteveWilliams-5461 avatar image
0 Votes"
SteveWilliams-5461 answered SteveWilliams-5461 edited

GetDurationFromTopology defined after use in copy & paste code.

Should be a prototype up top.

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

SteveWilliams-5461 avatar image
0 Votes"
SteveWilliams-5461 answered

CPlaylist::Initialize() fails. Complains shutdown called, which is incorrect error, startup hasn't been.;

HRESULT CPlaylist::Initialize()
{
// PATCH: Added.
CPlayer::Initialize();


why is this not on github please. is there more wrong with it ?

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

SteveWilliams-5461 avatar image
0 Votes"
SteveWilliams-5461 answered

Got CPlaylist in & running with minor tweaks above. Looping as per CPlayer example screws up the same way.

Next to try looping via sequence or morph of that code. I need seamless looping for video textures so tearing down & rebuild of entire topology after each loop of something that might be a second or so long isn't ideal.

I think playback breakup after 6 simple loops is a bug. If you can do 5, you can do 6 if the code is solid.

MS: can you repro the problem, please.

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.