# Media Framework Video Works in Editor But Not In Build

**URL:** <https://forums.unrealengine.com/t/media-framework-video-works-in-editor-but-not-in-build/308483>\
**Category:** UI\
**Tags:** image, movie, unreal-engine, question, UMG\
**Created:** [February 28, 2015, 7:07am UTC](https://forums.unrealengine.com/t/media-framework-video-works-in-editor-but-not-in-build/308483 "2015-02-28T07:07:33Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![sleeplessheartair](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@sleeplessheartair](https://forums.unrealengine.com/u/sleeplessheartair)\
**Post date:** [February 28, 2015, 7:07am UTC](https://forums.unrealengine.com/t/media-framework-video-works-in-editor-but-not-in-build/308483/1 "2015-02-28T07:07:33Z")

</div>

I created a MediaPlayer asset from a .wmv file that exists in my Content/Movies folder. I have this set to AutoPlay = true, AutoPlayRate = 1.0, and Looping = true. The source is a relative file path, and the StreamMode is fromUrl.

I then created a media texture from my MediaPlayer file, and then created a material from that. I then set that material’s properties to emissive, and break the link to BaseColor.

When I use this MediaPlayer asset in an image widget in the UMG editor, it plays fine, and it works even in PIE. It also works in Standalone Game.

PROBLEM: When we create our baked builds, all images referencing the material from the MediaPlayer asset’s texture just show black instead of playing the video. I checked the files inside of our baked build, and all the .wmv files are in the right places.

Is there something I’m missing?

---

<div class="post-metadata">

**Author:** ![MasterOfShapes](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@MasterOfShapes](https://forums.unrealengine.com/u/MasterOfShapes)\
**Post date:** [March 11, 2015, 3:30am UTC](https://forums.unrealengine.com/t/media-framework-video-works-in-editor-but-not-in-build/308483/2 "2015-03-11T03:30:52Z")

</div>

I have the same issue, were you able to resolve?

---

<div class="post-metadata">

**Author:** ![sleeplessheartair](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@sleeplessheartair](https://forums.unrealengine.com/u/sleeplessheartair)\
**Post date:** [March 13, 2015, 3:44am UTC](https://forums.unrealengine.com/t/media-framework-video-works-in-editor-but-not-in-build/308483/3 "2015-03-13T03:44:17Z")

</div>

Yes, but I found another error detailed here:

> **[MediaPlayer Play Bad Exit Code of 1](https://forums.unrealengine.com/questions/191062/mediaplayer-play-bad-exit-code-of-1.html)**
>
> Whenever I call play on a mediaplayer asset through blueprint (running the editor from VS2013), I get the following in my console log: The thread 0x4200 has exited with code 1 (0x1). The thread ID isn’t always 0x4200, of course. But this message...

This error will randomly crash your game after a while of the video playing. Pretty sure it’s memory leaks somewhere.

The fix is to call OpenURL with the correct URL on the mediaplayer variable when you initialize the widget. For some reason, in baked builds this never gets called on constructing a mediplayer, but it does get called in PIE.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_c2dbf5b7](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_c2dbf5b7](https://forums.unrealengine.com/u/anonymous_user_c2dbf5b7)\
**Post date:** [April 15, 2015, 2:22pm UTC](https://forums.unrealengine.com/t/media-framework-video-works-in-editor-but-not-in-build/308483/4 "2015-04-15T14:22:19Z")

</div>

I have the same issue and the fix with OpenURL didn’t work for me.  
Could you give me an image perhaps showing the node and the path?

---

<div class="post-metadata">

**Author:** ![NoobsDeSroobs](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@NoobsDeSroobs](https://forums.unrealengine.com/u/NoobsDeSroobs)\
**Post date:** [September 30, 2015, 10:04am UTC](https://forums.unrealengine.com/t/media-framework-video-works-in-editor-but-not-in-build/308483/5 "2015-09-30T10:04:15Z")

</div>

Did you set the Media Framework component to stream from memory?

---

<div class="post-metadata">

**Author:** ![sleeplessheartair](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@sleeplessheartair](https://forums.unrealengine.com/u/sleeplessheartair)\
**Post date:** [September 30, 2015, 5:08pm UTC](https://forums.unrealengine.com/t/media-framework-video-works-in-editor-but-not-in-build/308483/6 "2015-09-30T17:08:07Z")

</div>

Not sure; this was for an old project that will likely be upgraded to 4.9 so hopefully that’ll fix things.

---

<div class="post-metadata">

**Author:** ![VSZ](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@VSZ](https://forums.unrealengine.com/u/VSZ)\
**Post date:** [May 2, 2016, 6:53pm UTC](https://forums.unrealengine.com/t/media-framework-video-works-in-editor-but-not-in-build/308483/7 "2016-05-02T18:53:07Z")

</div>

Thank you for sharing the OpenURL trick!

My issue was different (random crashes in shipping builds when OpenLevel was called subsequent to any MediaPlayer activity) and so far, calling OpenURL on the movie asset before playing seems to have helped.

For reference, the URL format is “./Movies/YourMovieName.wmv”. Also remember to place your _raw_ movie file inside Content/Movies for it to be included in the packaging process, otherwise you’ll get a black image.
