I’m receiving a list of media URLs from a server and would like to compile these into a playlist dynamically. I can see that I can alter the the contents of a media playlist via blueprints, but I can’t see any way to dynamically create media source objects, particularly stream media source objects, via BP in order to populate the playlist.
Does anyone know of a way to do this? Alternatively, can this be done in C++ and could anyone point me in the right direction?
My alternative is to just have a list of re-useable, pre-created stream media source objects, but this hard-codes my maximum number of sources so I’d like to avoid that if possible.
You could try creating the media source objects with the ConstructObjectFromClass node and then add them to the playlist. I think this will be the best way until 4.18.
For Media Framework 3.0, which is now scheduled for 4.18, I added two new Blueprint functions AddFile(FilePath) and AddUrl(UrlString) to UMediaPlaylist objects that will automatically do this work for you. Furthermore, all UMediaPlayer assets will always have a playlist internally (a transient playlist is created automatically if none, or if a single media source was opened by the user).
Thanks @gmpreussner ! That was just what I was looking for. Is there anyway to have a look at what you have planned for the Media Framework 3.0 release?
Not right now - we don’t have the developer streams exposed on GitHub yet. All development is currently happening in Dev-Sequencer. I’m planning to do a Twitch stream on MF3.0 in the not too distant future (possibly end of next July).