Slider for a Video Player Widget

http://i.imgur.com/uZHi9gQ.png

So I managed to create a video player with a slider. The video works just fine. As the video plays, the slider plays from beginning to end, and back to the beginning when it loops. There’s one more thing that needs to be done for now, though, and that’s being able to move the slider to “seek” through the video. How would I go about doing this?

Take a look at the sample media widget in the ContentExamples project (/Content/Maps/Media.umap). It has a slider just like that. The UMG widget is located in /Content/UMG/MediaPlayerWidget. Here is a screenshot of the relevant part of the Blueprint graph:

Note that there is some logic to remember and restore the playback rate during scrubbing. Also remember that scrubbing will work more or less well depending on the video format. Highly compressed video formats usually do not work very well, because frames cannot be uncompressed fast enough. Uncompressed AVI will give the best scrubbing experience (the images will update instantaneously), but will also generate the largest video files.

1 Like

The version of the Content Examples I downloaded through the launcher doesn’t seem to have it…? How do I get the version that does?

Doesn’t have the map, or the widget, or the Blueprint?

All three, I think. There’s nothing when I search for Media in the assets. And no Map called Media.

I found it! But the example itself doesn’t work! The widget just pops up a black screen, and the in-level media texture is black, too.

Hi robosaur! Have you downloaded the 4.6 version of the Content Example project from the Learn tab? There should be a dropdown on the details page that allows you to select which version you would like to download.

I can confirm that this is broken. This is a regression we haven’t caught. I’ll take a look at it as soon as I can. The Blueprint functionality should still work, so you can start duplicating it. It just looks like playback in general is broken.

I went an imported this into my document, and it still doesn’t entirely work; it plays, but the pause button is grayed out, the fast forward and rewind buttons don’t work, the slider doesn’t work, and the elapsed time is always shown as 0:00.

EDIT: Nevermind, figured that part out, it was cuz I changed the media texture in one place but not the other.

Sorry, forgot to update this thread. Playback was fixed a while back. It should certainly work in 4.7 now.