View Full Version : Mixing two audio streams - Avisynth for audio / Besweet Listfiles?
E-Male
3rd December 2002, 17:45
i want to use parts from 2 mp2 files to create a new mp2 file
is it possible to do this without reencoding?
and what would be the way with the fewest steps?
thx in advance
E-Male
p.s. maybe it help if you know what i wanna do:
i got an american tv show whic his 90 minutes long
and the german dubbed version wich is cut down to 45 minutes
i want to creats a full length audio track which is german, and uses english only for the parts that where cut out of the german version
DSPguru
3rd December 2002, 18:24
use BeSplit to cut, use BeSplit to join.
in order to make your in-place task, i suggest using the very same -split() section for this cut.
cutting :
BeSplit -core( -input german.mp2 -prefix ger -type mp2 -ending ) -split( ..[timestamps].. )
BeSplit -core( -input english.mp2 -prefix eng -type mp2 -ending ) -split( ..[timestamps].. )
joining :
BeSplit -core( -input files.lst -output result.mp2 -join -type mp2 )
the 'files.lst' should look like something :
ger00.mp2
eng01.mp2
ger02.mp2
E-Male
3rd December 2002, 18:49
THX, thatīs what i meant
bond
28th December 2002, 16:53
Hello to everyone!!!
I have two different audiostreams (both ~ 1h) and i want to mix them together to one, like the first 10 min from stream 1, the next 3 min from stream 2, the following 5 min from stream 1, ...
Is there any possibility to do that?
Perhaps with besweet's listfiles (with timestamps?) or is there a frameserver-tool like avisynth for audio?
I am also happy for any advice (or software tip) which makes this possible!!!
bond
10th January 2003, 00:41
I just "reliked" the already banned idea mentioned above:
I have two audio streams
a) ac3 192kbps 2ch for 23,297fps (ntsc)
b) mp3 128kbps vbr for 25fps (pal) - 44.1khz
and i want to mux them like already said
i plan to do it that way:
1) convert the ac3 to a 128kbps vbr 44.1khz mp3 and to change the frame rate from 23,276 to 25
2) cut the two mp3 streams as necessary with besplit
3) join the two mp3 streams with besplit
so there is only one reencode from ac3 to mp3 which shouldnt cause bad quality!
now my questions:
1) i read somewhere that the pal->ntsc conversion can cause some sound quality troubles - are there also troubles with ntsc->pal conversion?
2) do the two audio streams both have
a) to be the same file format (i guess they have to..)
b) to have the same bitrate (vbr/cbr)
c) to be either vbr or cbr (is joining vbr with cbr possible?)
d) to have the same sample rate?
3) the pitches of the two streams are different. is there any possiblity to equalize them?
4) is there a possibility to add ~200ms silence in between different parts. ok for the beginning part i can set the delay but in between?
5) does there exist a gui for joining jobs with besplit? i am not a real friend of commandline :rolleyes:
6) i first wanted to reencode the whole thing with vorbis. Is that a good idea in terms of quality? (the mp3 source is already bad quality :( )
Uh many questions i hope someone can help me (dspguru i need you :D ). I am sorry if any of this questions are already mentioned in others threads but i didnt find them. as this issues are very joining related perhaps someone can also update the audio faq?
DSPguru
10th January 2003, 07:22
1. all issues i knew of, were fixed in latest beta.
2. same format, same channels mode (mono/stereo), same sample-rate.
3. i believe not.
4. create a 200ms silenece mp3 (by using BeSweet's partial encoding feature, and by setting ota gain to 0), and place it in the middle of your listfile, when joining.
5. don't know of any.
6. i wouldn't advise that.
yes, faq should be updated more frequently.
bond
10th January 2003, 09:09
thank you very much for the answers!!!
ad 3) i thought about using my ears and the gain/normalize functions to increase the volume of the first file (ac3) so it has ~ the same volume like the mp3 (which i dont want to change)
using the -g max parameter the volume of the encoded ac3 is still a little bit lower than the mp3, so i thought about trying a higher dB value - is this a bad idea in terms of quality? or is there a better solution by using post/hybridgain (which i dont really know what it is :()
two suggestions for besplit gui
1) allow import of chapterfiles (or any other file which has timestamps in it) so it is possible with the besplit gui to split at chapterpoints (i know that i can do this by using chapterxtractor)
2) allow export of the commandline parameters (or save to clipboard like in besweet) so i can use the same parameters for both files
EDIT: Just found out that it is already possible to save a project (great :))
bond
10th January 2003, 14:04
Whhhaaaa I get mad :devil:
I cant join the files with besplit:
after splitting the files i created a filelist:
"C:\BeSplit\englisch01.mp3"
"C:\BeSplit\deutsch02.mp3"
"C:\BeSplit\englisch03.mp3"
after that i opened a dos prompt:
c:\windows -> cd..
c:\ -> cd besplit
c:\besplit -> besplit -core( -input "c:\besplit\files.lst" -output "c:\besplit\test.mp3" -join -type mp3 )
and after that he shows me the 0815 besplit screen (i already hate it).
can someone find a failure? are there any alternative ways to join two audio streams (both mp3 vbr 44100 joint stereo)
I am using besplit v0.82
dspguru please help me!!!!!
DSPguru
10th January 2003, 15:52
use the latest beta and post your logfile.
bond
10th January 2003, 16:04
the latest stable release didnt create a logfile thats why i didnt post one
BeSplit v0.9b4 by DSPguru.
--------------------------
Logging start : 01/10/03 , 15:56:22.
C:\BESPLIT\BESPLIT.EXE -core( -input c:\besplit\files.lst -output c:\besplit\test.mp3 -join -type mp3 -logfile c:\besplit\besweet.log )
[00:00:00:000] +------- BeSplit -----
[00:00:00:000] | Input : c:\besplit\files.lst
[00:00:00:000] | Source Sample-Rate: 32.0KHz
[00:00:00:000] | Channels Count: 2, Bitrate: 24kbps
[00:00:00:000] | Output : c:\besplit\test.mp3
[00:00:00:000] +---------------------
Error Creating Output file : "(null)".
Quiting...thanks for your patience with me :)
ps: the two sources have both 44100hz, both vbr, joint stereo, one stream ~112kbps, one ~128kbps
DSPguru
10th January 2003, 16:23
weird...
anyway, you could also run this commandline :
copy /b C:\BeSplit\englisch01.mp3+C:\BeSplit\deutsch02.mp3+C:\BeSplit\englisch03.mp3 c:\besplit\test.mp3
btw,
if you encoded those mp3 to vbr with BeSweet, you better used the switch -lame( -t )
bond
10th January 2003, 16:33
:(
thanks anyway
what do you think about my question mentioned above:
ad 3) i thought about using my ears and the gain/normalize functions to increase the volume of the first file (ac3) so it has ~ the same volume like the mp3 (which i dont want to change)
using the -g max parameter the volume of the encoded ac3 is still a little bit lower than the mp3, so i thought about trying a higher dB value - is this a bad idea in terms of quality? or is there a better solution by using post/hybridgain (which i dont really know what it is )
where can i find the -t switch in besweet? whats is name of it?
thanks for your help again!
DSPguru
10th January 2003, 16:39
Originally posted by bond
:(
thanks anywaywhat's the problem ? the above commmandline would work!
what do you think about my question mentioned above:you could use higher gain values, or you better use dynamic compression.
where can i find the -t switch in besweet? whats is name of it?in BeSweetGUI. lame2, 'Disable writing Xing info Tag'.
but you should work from commandline, anyway.
bond
11th January 2003, 16:10
Originally posted by DSPguru
what's the problem ? the above commmandline would work!yeah works great
you could use higher gain values, or you better use dynamic compression.i now used -ota( -g max ) together with -azid( -c normal )!?
in BeSweetGUI. lame2, 'Disable writing Xing info Tag'. great, i already thought about how to solve the tag problems caused without the -t switch
Two more isues:
1) I know that this has not much to do with besweet but perhaps you can answer this question: if i'm going to do some noise reduction for example with cooledit is the file going to be reencoded when i save it or can i avoid the reencode somehow after noise reduction?
2) Seems like there is ~30ms of silence in the beginning of every filepart cutted with besplit! that's not much but sometimes it is audible (it is better to cut when there is no sound!)
DSPguru
11th January 2003, 16:54
1. reencoded. to avoid that, first decode, then process (with cooledit), then encode.
2. i need more details.
bond
11th January 2003, 17:57
Originally posted by DSPguru
1. reencoded. to avoid that, first decode, then process (with cooledit), then encode.decode? -> just to be sure: i guess you mean saving the file as (uncompressed) wav (windows pcm?) - (doesnt this cause a loss in quality?)
excuse my dumbness :rolleyes:
hm the same way it should be possible to encode the file with vorbis without the loss of quality:
first decoding the mp3 (save as wav) -> then encoding the wav with vorbis (with besweet)
is cooledit2000 a good tool for such tasks (saving as wav and noise filtering)?
2. i need more details. hm i opened the already cutted fileparts with cool edit, and every file has ~30ms of silence at the beginning, after joining the files again it seems that this silence is gone but only if i join files from the same source, while after joining different sources the result still has some silence in it
you can download the files here (http://www.8ung.at/gammelstudent/files.zip) which show what i wrote (~1.4mb)
after using the -t switch it seems that the files dont have the same filelength anymore (winamp and cooledit tell me two different values, both different to the ones that should be right) and in winamp there are also only very low bitrates shown up (~30-90kbps + 33kbps as average bitrate for the file) although the besweet logfile says "Conversion Completed ! Actual Avg. Bitrate: 106kbps" which should be right (--alt-preset 112)!
i guess thats because of the lack of the xing info tab as it is written in the besweet-lame-help???
Is there any tool which can show me the real values of the files just to be sure?
I also hope that besplit doesnt need these tags for cutting?
(btw. now i also used error protection -p)
DSPguru
17th January 2003, 16:29
Originally posted by bond
decode? -> just to be sure: i guess you mean saving the file as (uncompressed) wav (windows pcm?) - (doesnt this cause a loss in quality?)
excuse my dumbness :rolleyes: I have two audio streams
a) ac3 192kbps 2ch for 23,297fps (ntsc)
b) mp3 128kbps vbr for 25fps (pal) - 44.1khz
and i want to mux them like already said
when doing ac3->mp3 conversion, you must first decode the ac3.
is cooledit2000 a good tool for such tasks (saving as wav and noise filtering)?i hardly know cooledit. sorry.
hm i opened the already cutted fileparts with cool edit, and every file has ~30ms of silence at the beginning, after joining the files again it seems that this silence is gone but only if i join files from the same source, while after joining different sources the result still has some silence in itdid you use the '-t' switch ?
bond
18th January 2003, 00:02
Thanks for your answer!
Originally posted by DSPguru
when doing ac3->mp3 conversion, you must first decode the ac3. :confused:
by using besweet how can i only decode the ac3 (no mp3 conversion)?
ac3->wave-stereo?
did you use the '-t' switch ?yes i think so, why is this important?
bond
18th January 2003, 18:22
even if nobody is interested in this i will write it down anyway (perhaps for the following generations...):
1) seems like besplit doesnt only add ~30ms of silence at the beginning of the splitted files, sometimes it also causes noise at the beginning.
an sample file which shows the 30ms and the noise can be downloaded here (http://www.8ung.at/gammelstudent/english04.mp3) (14.3kb)!
2) there is a bug in the besplit-wbias-gui together with winamp: it doesnt always cut at the same times as shown in winamp
in both cases (1 and 2) i didnt use the -t switch.
DSPguru
18th January 2003, 19:35
Originally posted by bond
by using besweet how can i only decode the ac3 (no mp3 conversion)?
ac3->wave-stereo?find the 'Wave-Stereo' option in the output frame in BeSweetGUI.
i created a stereo wave from your file and there were no problems with it, while when openned it with cooledit - there were.
so, please, blame cooledit, not me.
1) seems like besplit doesnt only add ~30ms of silence at the beginning of the splitted files, sometimes it also causes noise at the beginning.again, this is a cooledit bug, not ignoring the vbrtag header. (your file DOES have vbr headers).
[2) there is a bug in the besplit-wbias-gui together with winamp: it doesnt always cut at the same times as shown in winampBeSplit can cut only between mp3-frames. each frame is 32ms.
bond
18th January 2003, 20:17
Originally posted by DSPguru
find the 'Wave-Stereo' option in the output frame in BeSweetGUI.
i created a stereo wave from your file and there were no problems with it, while when openned it with cooledit - there were.
so, please, blame cooledit, not me.you mean there were problems with the wave file in cooledit?
hm not in my case:
after decoding the english04.mp3 (mp3->wave-stereo) in my case (and i think also in your case) there is no longer the noise and the 30ms of silence in the beginning (the wave is as it should be, although its source is the shitty mp3)!!!
the problems only occur in the mp3!!!
in winamp i hear the noise at the beginning and i guess there are also 30ms of silence which i cant hear because it is too short.
i have to say that i never used cooledit for anything but to "look" at the files!!!
can you hear what i described as silence and noise in the english04.mp3?
can you hear these things also in the english04.wav?
what do you think is the reason of the noise and silence in the mp3? it cant be cooledit because i never edited any file with it!
DSPguru
18th January 2003, 22:04
the flaw is in cooledit's mp3 decoder.
bond
18th January 2003, 22:32
Originally posted by DSPguru
the flaw is in cooledit's mp3 decoder.
is the cooledit decoder also used by winamp? as i said i also hear the flaws in winamp!
do you also hear them?
how can i fix that?
DSPguru
18th January 2003, 22:47
there's nothing to fix in your file!
bond
18th January 2003, 22:55
Originally posted by DSPguru
there's nothing to fix in your file!
so what can i do to be able to hear the file without problems?
uninstall cooledit? install another decoder? if yes which would you suggest? anything else that i can do...
DSPguru
18th January 2003, 22:58
1. download the decoder from the audio faq.
2. remove the vbrtag header using the tool i linked you to.
bond
18th January 2003, 23:11
Originally posted by DSPguru
1. download the decoder from the audio faq.
2. remove the vbrtag header using the tool i linked you to. i am really sorry for my dumbness but i cant find an decoder in the audio faq i also dont know which tool you mean to remove the vbrtag header (do you mean the -t switch?)
EDIT: I downloaded the mad-plugin for mp3 and now there are no problems anymore with the file but only in winamp!
for example playing back the file in bsplayer still has the failures.
DSPguru
19th January 2003, 08:03
Originally posted by bond
i also dont know which tool you mean to remove the vbrtag header (do you mean the -t switch?)http://www.willwap.co.uk/Programs/vbrfix.html
performance->on finding xing vbr tag->delete it and don't make another one.
DIT: I downloaded the mad-plugin for mp3 and now there are no problems anymore with the file but only in winamp!
for example playing back the file in bsplayer still has the failures. the file is ok. i have nothing to add.
bond
19th January 2003, 12:04
Originally posted by DSPguru
http://www.willwap.co.uk/Programs/vbrfix.html
performance->on finding xing vbr tag->delete it and don't make another one.works great!!! now the noise in the beginning is gone.
the 30ms of silence are still there
1) i joined the fixed mp3-splits again, there is still silence in between the splits
2a) if i run vbrfix again with the joined mp3 it tells me 4 times: "change in mpeg version found at frame pos ..." -> this fixed file has no more problems!
2b) i did a mp3->wave-stereo conversion with the joined file and besweet gives me the following log file:
BeSweet v1.5b11 by DSPguru.
--------------------------
Using hip.dll v1.18 by Myers Carpenter <myers@users.sf.net>
Logging start : 01/19/03 , 11:33:03.
C:\Programme\BeSweet.exe -core( -input C:\test.mp3 -output C:\test.wav -2ch -logfile C:\BeSweet.log )
[00:00:00:000] +------- BeSweet -----
[00:00:00:000] | Input : C:\test.mp3
[00:00:00:000] | Output: C:\test.wav
[00:00:00:000] | Floating-Point Process: No
[00:00:00:000] | Source Sample-Rate: 44.1KHz
[00:00:00:000] +---------------------
[00:02:59:026] Stream error : Sync found after 128 bytes
[00:03:04:016] Stream error : Sync found after 128 bytes
[00:04:33:024] Stream error : Sync found after 128 bytes
[00:04:40:034] Conversion Completed !
[00:04:40:034] Actual Avg. Bitrate : 1411kbps
[00:00:17:000] <-- Transcoding Duration
Logging ends : 01/19/03 , 11:33:20.
the stream errors are exact at the points where the cuts were made!
hm i guess the mp3 decoder is the problem as you already said, what can i do against that, which decoder should i use?
[i am using MPEG Layer-3 Audio Decoder 1.9 (build 311) at the moment]
bond
20th January 2003, 07:28
Originally posted by DSPguru
1. download the decoder from the audio faq.which decoder? :(
DSPguru
20th January 2003, 07:59
use BeSplit to fix the joint stream.
bond
20th January 2003, 20:09
Originally posted by DSPguru
use BeSplit to fix the joint stream. :( is there no other way to prevent this, i fear that there may be sync issues if i am not able to cut exactly at the points i want?
[btw i now used madplayer from the rarewares site for playback and this player plays the english04.mp3 without any problems (like the mad winamp plugin) but it tells me: "error: frame 2: huffman data overrun", perhaps this helps you?]
DSPguru
20th January 2003, 22:55
Originally posted by DSPguru
use BeSplit to fix the joint stream.
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.