View Full Version : problem with sound and video sinchronization
Problem with sound and video sinchronization.
I want to make video player where I can choose Language sound (english or russian), Subtitles (ON - english or russian).
I've made 3 files - video.avi, english.wav, russian.wav.
So when I choose another sound for video (video is playing) - there is no sinchronization audio with sound. I tried several codecs for audio and for video and no success.
Help me (who know) to solve this problem, or how to make such player???
THNX
yosik
04-07-2005, 09:09 AM
If you really want to make sure you remain with perfect sync, you need to interleave (make one file) of audio and video. In your case, that would be one file for english and one for russian. Then, based on the user's choice, you would play the relevant video file.
You can use a program like VirtualDub to build (mux) your audios with video.
Good luck
Yossi
Yes, I agree, but I need several video clips, with different length. If I will do 2 video files for every video clip then my program will need a lot of dick space.
yosik
04-07-2005, 09:29 AM
I don't think you have a lot of choice. With subs, you could get away with external synchronizing, but with audio, especially if you want lipsync...no way, in my opinion.
Yossi
Ok, I understood. Will try to do it in your way.
yosik
04-08-2005, 12:43 AM
Space management is crucial.
Advanced planning is the key.
How long a time do your videos total?
Based on that figure, you can calcute what codec and at what compression do you need to work.
Good luck
Yossi
Ok, what can you suggest me for subtitles. How to realise it?
rhosk
04-08-2005, 05:00 AM
Windows Media Player will do captions via SAMI file (xml file), but it's a lot of work. What are the lengths of these videos?
Info on SAMI format -
http://www.webaim.org/techniques/captions/windows/1.php
Ok, thnx for suggestion.
But how tell me please -
WHAT is SAMI ??? (could I make subtitles with this files)
How to switch Subtitles On in Windows Media Player Plugin ??? (if I will hide context menu)
THNX
I downloaded Example.wmv and Example.smi files. And in the Windows Media Player Plugin it does not work.
Now I am going to "AutoPlay 5.0 Plugins & Addons" section for answering questions.
Lets go together :)
rhosk
04-08-2005, 08:39 AM
Well, I just realized that, by default, the WMP plugin in AMS doesn't have the captions window enabled (and I don't see a way to rectifiy this), so in order for a structured xml file to work, it would have to be in a web object - I think this is beyond the scope of this topic.....
What you may want to look into and study are the video positioning actions and use if statements to populate a paragraph object. Again, would take some time, but it could be done.
Here's a quick example using the magnolia.mpg. Kind of thrown together, but you'll get the idea (I'm sure the code could be streamlined).
Captions (http://s92220213.onlinehome.us/downloads/caption.apz)
HTH
Corey
04-08-2005, 08:42 AM
Coo-wel. :yes
yosik
04-08-2005, 09:12 AM
Here is a workflow to build/use/embbed subtitles:
Tools needed:
Subtitle Workshop (free)
VobSub (free)
TmpgEncoder (partly free)
First of all, download and install these 3 apps. Then...
1. With Subtitle workshop, you can type/import your text and time it to your video file. It is a GREAT!!! tool. CHeck all functions, especially the translation ones
2. You get a subtitle file (in any of the 10s of formats available...), check that it has the same name as the video file.
3. After installing VobSub, you can see the subtitles in your media player. (VobSub acts as a DirectShow plugin).
3. Same in TMPGEnc. There, you can import your Video file (AVI, for example) and convert to mpeg while embbedding the subs. Or save as AVI again with the subs embbeded.
Works smoothly and give good results.
Good luck
Yossi
Ok thnx. I 'll do it.
Again thanx to everybody.
Br.
I wrote solution in the next posts:
http://www.indigorose.com/forums/showthread.php?t=11039&page=2&pp=15
http://www.indigorose.com/forums/showpost.php?p=53234&postcount=18
vBulletin® v3.8.4, Copyright ©2000-2009, Jelsoft Enterprises Ltd.