Log in

View Full Version : When DirectStream Audio will be developed in Avisynth?


3ngel
6th January 2007, 15:59
Hi,
i was wandering from some time when this important function will be developed in Avisynth.
That is, now in order to do for example an ac3 avi, the video has to be done in avs, then the ac3 has to be muxed in VirtualDub, with many problems when it comes to split-join-edit the desired result.
A function like SoundSource("path") that accept many sound formats (including ac3), and when the .avs will be loaded in VirtualDub it automatically show the ac3 stream (untouched) in the "Available Stream" section, would be a very important and useful thing. So when i do Trim and + in avisynth the ac3 stream would be automatically trimmed or added.
So when this feauture will be implemented?

tebasuna51
6th January 2007, 18:17
So when i do Trim and + in avisynth the ac3 stream would be automatically trimmed or added.
Problems: for example a video 25 fps (40 ms per frame) with ac3 48 KHz (32 ms per frame)
When you trim, the cuts are per video frame, then the audio is not cut by audio frame boundaries and we have invalid frames. These ac3 streams aren't accepted by DVD authoring programs or can cause audio/video desync.

The correct way is trim the audio by their frames boundaries (not a simple job for any kind of audio and VBR formats) or cut the uncompressed audio to recompress after the result.

See SoundOut 0.9 beta - Sound Output Plugin (http://forum.doom9.org/showthread.php?t=120025) like a approach to last solution.

3ngel
6th January 2007, 19:05
I see your point, and for me it would be good to cut to audio frame ('cause it's a condition that can't be avoided in any way) also, with an algorithm that cut audio frames in order to result in the less desynch possible, in other words cut an audio frame so the audio lenght would be as near possible to the video lenght.
The soundoutput plugin is not a solution, 'cause i do the same thing externally cut/edit the audio with separate programs.
I think even a non perfect audio stream cut would be ideally, 'cause there can't be (as you rightly pointed out) a pefectly par to par A/V solution.