4.12.3 still no sound for video, even worse

Hello community, Hello developers,

before i start my big complaint i have to to say i love working with unreal and i really respect the stability, the capabilities and the user friendly interface of the engine. I managed in a short time to realize good looking demos for my clients and implement even tricky functions by using blueprints, but…

THE AGE OF SILENT MOVIES is over.

I am still presenting my video intensive programs for training use inside the editor because the audio for videos is still not working in packaged games. In 4.12 this did not change, it even got worse because the audio is now neither working in packaged games nor in the editor. O.K., you can call this consistent, but it is very disappointing to have this issue in such a high ended program.
Here are the facts:

  • 4.11.2 - Video sound playing sync in editor, not playing in packaged
    games
  • 4.12.3 - Video sound not playing in editor and in packaged games
  • In both Versions Videos in 1080 HD
    are not possible
  • In both versions Videos with more than one Audio or Video stream are not possible

I always wait for the loaded event from the player before using the videos and everything works fine in the 4.11.2 editor, even simultaneous playback of three videos on textures with separate spawned sounds!

But the community needs this in the final product. The future of the usage of the unreal engine for corporate applications like training (that’s what i do) is directly linked to this feature. The problem is known:

the bug number associated with the issue is UE-12185

I think it is about time to raise priority for this problem and give all developpers who need “talkies” instaed of “Silent Movies” a solution which fits the media demands of 2016…

For everyone who is interested in the issue i can upload a small videoproject on my dropbox.

Best Regards,
Achim

Hi agirnth,

Thank you for your post. I have updated UE-12185 to reflect that additional developers are experiencing this error.

I can confirm that in UE 4.12.5 there is no sound with a video file (mp4) when using the “Create Media Sound Wave” as described in Media Framework | Unreal Engine Documentation

So the only way that works for me is to split the video into an image and sound manually and to play them at the same time. It looks to me as a similar approach to the MediaSoundWave but an external software is required to split them. I will briefly describe a way that uses VLC media player (2.2.4). I tried two mp4 files (from different cameras) and for one I could not even see the image in the UE4 (already known issue) so I will add a step how to convert the video as well. Anyway, 1080p worked in my case. I will also describe how I looped the video with the sound since the video file did not send the “On End Reached” event in my case. Note that all observations and described steps were only made and tested in the UE4 editor - not in a final standalone product/game.


1. Split video into image (mp4) and sound (wav) in VLC Player:

  • Install and open VLC player.
  • Click in menu: Media → Convert/Save…
  • Here, in File click on Add…, select the target video and click Open, which adds the video into the list.
  • In the right-bottom corner click on the downwards oriented arrow next to Convert/Save and select Convert.
  • Here click on the Create a new profile icon.
  • To create a separate video file without the original sound, select in Encapsulation MP4/MOV (worked for me) and in the Video Codec tab check the Video checkbox and select the codec MPEG-4. Name your profile (e.g., Video) and click Save (note that the Audio codec tab was left disabled). Back in the Convert window specify a name of the new split video file (mp4) without the sound and click Start.
  • When the video file is done, click again on Media → Convert/Save… and directly click the arrow and again Convert.
  • Click again on the Create a new profile icon.
  • In the Encapsulation tab select WAV.
  • Keep the Video codec tab disabled and go to the Audio codec tab.
  • Check the Audio checkbox, select Codec: WAV, enter Bitrate (e.g., 128 or 256 kb/s) and Sample rate (e.g., 44100 Hz).
  • Enter the Profile Name on the top and click Save button.
  • Enter the name of the split sound file in the Destination file (WAV type) and click Start.

2. Import and play video and sound in the UE4 (does not work for 4.13!)

  • Create a “Movie” folder in your project Content folder and copy both split MP4 and WAV files there.
  • Then go to your working folder for your video and sound related imports and blueprints.
  • In the content browser import the MP4 split video and then import the split WAV file. It should result in a Media Player object for MP4 and a Sound Wave for the WAV file.
  • Double click on the imported Media Player object and click the play icon. The video picture should play (if not, then something is wrong).
  • Right-click on the imported Media Player object and select Create Media Texture.
  • Right-click on the Media Texture and select Create Material.
  • Edit Material (if the video is playing, then the media texture should show the picture). I multiplied the Texture Sample node by 5 and connected it to the Emissive Color.
  • Create a “TV screen”-like object in your environment and apply the material on it. I used the Geometry Box brush and used Align Surface Fit in the Align in the box brush Geometry property.
  • Drag the split Sound Wave object onto the “TV screen”. This should create a Sound Wave instance with an AudioComponent.
  • Click on Blueprint/Add script to create a blueprint for the Sound Wave instance.
  • In the blueprint create a new variable Video as a Reference to the Media Player type. Compile and in Default Value of the Video variable select the imported Media Player video object.
  • For loop playing create StartTime float variable.
  • Click on AudioComponent and just check that the imported Sound Wave file is selected in the Sound property. When clicking play there should be the video sound.
  • Enter following nodes to play the video with sound and optionally to loop the video:

Well, that is supposed to work so let me know if it does not.

I fully agree. The workaround is time consuming when you need it frequently and moreover you need to download and install a third party freeware, which people may not like to do on their programming machines due to a potential malware threat (at least I hated to do it). Also I am not sure if there is any assurance that the picture and sound stay synchronized. I only added this workaround because the development of this issue goes clearly in the other direction during the last year. Also I was happy to find a codec conversion to fix the mp4 incompatibility that occurred for some of my files.

Anyway, if you find out that the Epic team addressed the issue one way or another, please add a comment here to conclude this topic.

Hello Vlhruska,
thank You for Your Workaround. I already tried a similar Workaround with a seperate Audio Wave and it worked. Anyway, as i am loading lots of different URLsfor different videoscreens, you can imagine how time-consuming and debug-intensive this workaround is!
I think it is really important to have a complete overhaul of the media System and
I BEG ON MY KNEES TO THE EPIC TEAM TO IMPLEMENT A WORKING MEDIA SYSTEM

Achim

The longest video i used was about 8 minutes and it stayed full sync till the end of playback, so no worries on this side.
Again, thank you for your contribution, i will keep you informed what is going on.

Achim

Just for visibility sake here is the issue on the public Jira site so you can track and vote on it.

With that said, we are aware of the issues with the Media Framework and have already begun re-working the system for improved functionality which we hope to have implemented into 4.13.

Thank you,

Andrew Hurley

Hello Andrew,
a working Media System in 4.13 would be great!
Until the i use a workaround like the one Vlhruska described. Since i load a lot of videos, i had to create a system which uses arrays for loading the videos and the audio wave files.
I think other users might be happy to use this, so i made a simple and very small project in 4.12.5 ( 92 kB ) and put it on my dropbox to make it available for the community. This is the link:

Video Workaround Project

I hope this helps,

Regards,
Achim

if your MP4 is not corrupted the biggest possible cause is that the codec compressing your MP4 is not supported by your device or media player in which case you need to use a professional video converter to convert the unsupported MP4 to your device or media player supported MP4 with the supported codec.Avdshare Video Converter is just the right video converter you will need.

If your MP4 file includes audio codec that is not accepted by your device or player you can use a professional MP4 video converter - iDealshare VideoGo to convert your MP4 file to your device or player supported one with supported audio codec.