- Home /
How to get perfect sync between audio and video?
Hello! I am almost finished with a game I am making, and as a last touch I am having an intro movie. Unfortunately, my editing software isn't very good so it won't export the movie at the same aspect ratio it was imported at, so my video file and my audio file are 2 separate files. Ok, fine, I import them both into Unity. I have a plane with an audio event and this code: public class PlayMovie : MonoBehaviour { public MovieTexture movTexture; // Use this for initialization void Start () { renderer.material.mainTexture = movTexture; movTexture.Play (); audio.Play (); // this line of code will make the Movie Texture begin playing } }
When I start the scene in the inspector however, the audio is almost a second ahead of the video! Why is this happening? I've looked around here for similar problems and solutions, but none of them work for me. I exported the movie and sound together at the aspect ratio the editing software made me and watched it, so I know the audio and video should sync up. One of the solutions I've tried is starting audio and video on start, then pausing, then playing in update. This just causes the audio not to be played.
Your answer
Follow this Question
Related Questions
Syncing separate video and audio 0 Answers
AVPro QuickTime Plugin A-V Not in Sync Problem 2 Answers
Video is not playing Audio 4 Answers
Sample-precise sync on multiple audio sources ? 1 Answer
How do I sync up the video and audio from my movie? 1 Answer