Log in

View Full Version : open source audio sync multiplex program


4992
14th March 2003, 17:11
I guess I wasn't too clear on what it is I want to do, so I'm going to try to rephrase it and see if I get any replies :0)

I don't know anything about the mpeg2 format so...
First of all, to see if this will even work, I want to know if I can even pull an audio packet from one place in a file and move it to the other, or does it have to be encoded in that spot? Basically when I multiplex the video and audio together can I move the audio further forward or backward in the file? Or does it have to be re-encoded or possible transcoded?

Secondly I want to see if anyone can tell me of any open source programs that does what I'm about to say, that I can modify for this program.

1.)demultiplex and multiplex
2.)mpeg2 video player

Finally I'm going to give a linear approach to what I want this program to do, so you can see what I've been thinking.

1.)Take input(mpeg2 only for now, will modify for more later) If input is a mpeg2 system file, then program will demultiplex the file when loaded. This is so the program can work with the elementary streams.

2.)Scroll through the video until you see a scene where there is alot of talking directly into the camera. (This is to judge where sound and mouth movement is off.) From here we would set a start and end value to a small clip with the mouth movement so we could work with just this clip, and not the whole file.

3.)We would start playback of the clip. The program would internally multiplex the program at a delay value specified by a textbox on our program, then make the multiplexed clip available to the player for playback. The clip keeps looping and the user keeps watching it, and adjusting the delay time, until the audio and video are in sync.

4.)At this point the user would stop playback and hit the multiplex button on the program and the program would multiplex the whole entire file at the specified delay time.

This would make it much more simple than if you had to look through a file and note when a door slammed, and then try to calculate the delay manually.

Any ideas would be greatly appreciated. Thanks.