morgen... werd's mir heut abend anschauen...
zur ffmpegversion...
ich meine die kopmpelierte ffmpeg-version vom mplayer-projekt
(hast mir ja selbst den link zukommen lassen)
morgen... werd's mir heut abend anschauen...
zur ffmpegversion...
ich meine die kopmpelierte ffmpeg-version vom mplayer-projekt
(hast mir ja selbst den link zukommen lassen)
Ahso.
Nehme ffmpeg meist von dort oder auch von http://ffmpeg.arrozcru.org/autobuilds/,.. oder halt selber kompilieren. (ist mir unter Windows aber meist zu stressig)
hey super, klappt wunderbar...
hate es natürlich auch schonmal mit raw in ffmpeg versucht
hatte aber nicht so geklappt
ich stell jetzt grad fest das an meiner musik ca. 100ms stille am anfang sind
ok das währe jetzt nicht so tragisch und grenzt an meckern auf hohem niveau
aber wenn man jetzt grapless sich ein konzert anhören will,
dann fällt sowas leider schon auf...
das geht auch irgendwie mit sox (hab ich schon mal gemacht, aber leider keinerlei Erinnerung mehr daran wie :))
ZitatAlles anzeigen
<dl compact="compact"><dt>silence above_periods [ duration threshold[ d | % ] </dt><dt>[ below_periods duration </dt><dt>threshold[ d | % ]] </dt><dd>Removes silence from the beginning, middle, or end of a sound file. Silence is anything below a specified threshold. The above_periods value is used to indicate if sound should be trimmed at the beginning of the audio file. A value of zero indicates no silence should be trimmed from the beginning. When specifing an non-zero above_periods, it trims audio up until it finds non-silence. Normally, when trimming silence from beginning of audio the above_periods will be 1 but it can be increased to higher values to trim all data up to a specific count of non-silence periods. For example, if you had an audio file with two songs that each contained 2 seconds of silence before the song, you could specify an above_period of 2 to strip out both silence periods and the first song.
When above_periods is non-zero, you must also specify a duration and threshold. Duration indications the amount of time that non-silence must be detected before it stops trimming data. By increasing the duration, burst of noise can be treated as silence and trimmed off.
Threshold is used to indicate what sample value you should treat as silence. For digital audio, a value of 0 may be fine but for audio recorded from analog, you may wish to increase ths value to account for background noise.
When optionally trimming silence from the end of a sound file, you specify a below_periods count. In this case, below_period means to remove all audio data after silence is detected. Normally, this will be a value 1 of but it can be increased to skip over periods of silence that are wanted. For example, if you have a song with 2 seconds of silence in the middle and 2 second at the end, you could set below_period to a value of 2 to skip over the silence in the middle of the audio file.
For below_periods, duration specifies a period of silence that must exist before data is not copied any more. By specifying a higher duration, silence that is wanted can be left in the audio. For example, if you have a song with an expected 1 second of silence in the middle and 2 seconds of silence at the end, a duration of 2 seconds could be used to skip over the middle silence.
Unfortunetly, you must know the length of the silence at the end of your audio file to trim off silence reliably. A work around is to use the silence effect in combination with the reverse effect. By first reversing the audio, you can use the above_periods to reliably trim all audio from what looks like the front of the file. Then reverse the file again to get back to normal.
To remove silence from the middle of a file, specify a below_periods that is negative. This value is then treated as a positive value and is also used to indicate the effect should restart processing as specified by the above_periods, making it suitable for removing periods of silence in the middle of the sound file.
The period counts are in units of samples. Duration counts may be in the format of hh:mm:ss.frac, or the exact count of samples. Threshold numbers may be suffixed iwth d, or % to indicate the value is in decibels or a percentage of maximum value of the sample value (0% specifies pure digital silence).
</dd><dt>Quelle: http://linux.die.net/man/1/sox</dt></dl>Guck auch mal: http://www.justlinux.com/forum/showthread.php?t=136678
uff... schwere kost...
da muss man sich erstmal duchfuxen...
So ist die komplette Sox Dokumentation!!!!
Ist zwar echt nicht schlecht und kann wirklich viel, man muss nur mal rausbekommen wie. (nach dem ich die ganzen UpMix Routinen zusammen hatte konnte ich mich bis heute auch nicht aufraffen DownMix Routinen zusammen zu basteln)
In dem verlinkten Thread waren meine ich auch ein paar Beispiele.
jo... werd's mir mal anschauen...
solltest du je sox komplett erforscht haben...
vielleicht kannst du ne manual darüber schreiben... XD (nicht ernst nehmen )
[edit:]
ein weiteres problem ist das code-schnipsel von ein linux system kommen
aber wie sehen die richtigen windows befehle aus
die fangen ja mit -x bzw. --ix an
und dann steht da im befehl -40d
na super, da freut sich gleich die windows-eingabe...
so, konnte schnell noch ne codezeile zusammenzimmern...
"%xAppDir%\ffmpeg\ffmpeg.exe" -i "%xI%" -ac 2 -ar 44100 -acodec pcm_s16le -f u16le - 2>nul| "%xAppDir%\sox\sox.exe" -s -b 16 -c 2 -r 44100 --norm -t raw - -t wav - silence 1 1 -96d | "%xAppDir%\LAME\lame.exe" --silent -V5 - "%xO%.out.mp3"
mein problem ist, das nur am anfang die stille erkannt&entfernt wird...
auch gibs während der verarbeitung eine warnmeldung...
... /sox WARN wav: Length in output .wav header will be wrong since can't seek to fix it
Drücken Sie eine beliebige Taste . . .
ich würde gern auch am ende was entfernen...
Die Warnmeldung ist okay und nicht zu vermeiden bei nem RAW Stream der per Pipe kommt, da ja kein Header vorhanden ist, der sagt wie lang der Stream ist.
Zitatich würde gern auch am ende was entfernen...
Guck mal hier:
http://digitalcardboard.com/blog/2009/08/2…sox-of-silence/
Was die machen ist: den Stream 2mal durch sox jagen.
Bi jedem Durchlauf entfernen sie die Stille am Anfang und drehen den Stream um, wodurch sie beim zweiten durchlauf die Stille wieder am Ende entfernen,... müsste man testen ob das auch mit Pipes geht.
Cu Selur
wird wohl schlecht in einem rutsch verarbeitbar sein... (multi-pipe...)
das war ja der sinn warum ich alles weitesgehend auf pipe umstelle...
[edit:]
habs hinbekommen...
ffmpeg.exe -i "%~1" -ac 2 -ar 44100 -acodec pcm_s16le -f u16le - 2>nul| sox.exe -s -b 16 -c 2 -r 44100 -t raw - -t raw - silence 1 0 -96d reverse | sox.exe -s -b 16 -c 2 -r 44100 --norm -t raw - -t wav - silence 1 0 -96d reverse | lame.exe --silent -V5 - "%~dpn1.out.mp3"
der link war sehr hilfreich...
Nice!
He, he, falls Du jetzt sox-motiviert bist kannst ja mal drüber nachdenken wie ein 5.1->stereo DownMix aussehen müsste. (im Anhang wie es in BeHappy gemacht wird ;))
Cu Selur
simmt... meine 5.1 ac3's muss ich auch noch verarbeiten können...
hmmm... ffmpeg frisst eigendlich meine 5.1 dateien
und da handys/mp3-player/iSchrott's noch kein 5.1-system an board haben
wüsste ich nicht, warum ich das format beibehalten sollte...
um zu schauen ob ffmpeg zufriedenstellend downmixt, brauche ich testfiles
und zwar nicht aus irgend welchen filmen oder dvb-rips,
sondern wo auf jeden kanal was anderes ist, bzw. wo sich die kanäle abwechseln
-sowas um seine boxen im raum richtig zu positioniereb/kalibrieren...
7.1-testfiles währen auch nicht schlecht...
achja welche (typischen) formate außer DTS, AC3, WMA, AAC, MP3, OGG
unterstützen auch mehrkanal (welche aber auch genutzt werden)
sollte mal ein format fehlen,
einfach melden ich werde es schon mit rein machen
Mit ffmpeg downmixen hab ich seit: http://forum.gleitz.info/showthread.php?t=37049 aufgegeben.
Im Anhang ein avi mit ac3 Ton welches ich gerne zum Testen verwende.
Cu Selur
hmmm...
der ffmpeg downmix geht eigendlich wunderbar...
was mich stört ist, dass er den LFE-kanal verwirft...
in deinem beitrag kahm zum schluss mencoder zur sprache...
hast du damit erfolg gehabt?
also damit es klar ist,
ich will mich nicht mit den kanälen überwerfen
ein einfacher downmix auf stereo (2.0) reicht völlig
das ziel ist ja handy/mp3-player
und thx für die testfile, die ist sehr hilfreich...
Da mencoder eigentlich nicht gedacht ist um raw audio only files zu konvertieren, geht das Konvertieren damit nur sehr umständlich. -> würde davon abraten, aber wenn Du mit Ffmpegs DownMix happy bist passt ja.
Cu Selur
nunja an ffmpeg stört mich dass der LFE-kanal verworfen wird,
man kann ja nicht davon ausgehen das in einem 5.1 musikstück
der bass mit in den anderen kanälen vorhanden ist...
ich wette da kocht jeder sein eigenes süppchen (musikpoduzenten)
nunja wenn sox das kann, dann würde ich es gern damit machen,
aber bei den nummernkolonnen, da blick ich nicht durch...
da währe ich auf hilfe angewiesen...
UpMix routinen: -> k.A. aber hier mal die DownMixRoutinen wie ich sie in Hybrid verwende:
(hatte vorher verwechselt brauche UpMix, habe DownMix :))
ZitatAlles anzeigen
UpMix
//1toStereo
remix -m 1,1 normDownMix
//XtoMono
remix -m - norm//3toStero
remix -m 1v0.5858,3v0.4142 2v0.5858,3v0.4142 norm
//3toStereo (dpl)
remix -m 1v0.5858,3v0.4142 2v0.5858,3v-0.4142 norm//4toStereo
remix -m 1v0.5,3v0.5 2v0.5,4v0.5 norm//4toStereo (dpl)
remix -m 1v0.4142,3v0.2929,4v0.2929 2v0.4142,3v-0.2929,4v-0.2929 norm//4toStereo (dpl2)
remix -m 1v0.4142,3v0.3714,4v0.2144*SR 2v0.4142,3v-0.2144,4v-0.3714 norm//5toStero
remix -m 1v0.3694,3v0.2612,4v0.3694 2v0.3694,3v0.2612,5v0.3694 norm//5toStereo (dpl)
remix -m 1v0.3205,3v0.2265,4v0.2265,5v0.2265 1v0.3205,3v-0.2265,4v0.2265,5v-0.2265 norm//5toStereo (dpl2)
remix -m 1v0.3254,3v0.2301,4v0.2818,5v0.1627 2v0.3254,3v0.2301,4v-0.2818,5v-0.1627 norm//6toStereo
remix -m 1v0.3694,3v0.2612,4v0.3694 2v0.3694,3v0.2612,5v0.3694 norm//6toStereo (dpl)
remix -m 1v0.3205,3v0.2265,4v0.2265,5v0.2265 2v0.3205,3v0.2265,4v-0.2265,5v-0.2265 norm//6toStereo (dpl2)
remix -m 1v0.3254,3v0.2301,5v0.2818,6v0.1627 2v0.3254,3v0.2301,5v-0.1627,6v-0.2818 norm//6toStereo (lfe)
remix -m 1v0.2929,3v0.2071,4v0.2071,5v0.2929 2v0.2929,3v0.2071,4v0.2071,6v0.2929 norm//6toStereo (dpllfe)
remix -m 1v0.2613,3v0.1847,4v0.1847,5v0.1847,6v0.1847 2v0.2613,3v0.1847,4v0.1847,5v-0.1847,6v-0.1847 norm//6toStereo (dpl2lfe)
remix -m 1v0.2646,3v0.1870,4v0.1870,5v0.2291,6v0.1323 2v0.2646,3v0.1870,4v0.1870,5v-0.1323,6v-0.2291 norm
Falls einer noch X->Y Upmix Routinen haben sollte bitte posten!!
Cu Selur
interressant...
sind die zahlen als "gegeben" anzusehen
oder wie ist man darauf gekommen bzw. wie kann man sie deuten?
[edit:]
hab es mal versucht einzubauen...
leider klappt es nicht so, da ist wohl irgendwo ein fehler
@echo off
cd /d "%~dp0"
set xAppDir=%CD%\tools
set xI=%~1
set xOd=%~d0
set xOp=%~p0
set xOn=zz_%~n1
set xOx=%~x1
set xO=%xOd%%xOp%%xOn%%xOx%
set xPff="%xAppDir%\ffmpeg\ffmpeg.exe" -i "%xI%" -ac 6 -ar 48000 -acodec pcm_s16le -f u16le - 2>nul
set XPsox1="%xAppDir%\sox\sox.exe" -s -b 16 -c 6 -r 48000 -t raw - -t raw - remix -m 1v0.3694,3v0.2612,4v0.3694 2v0.3694,3v0.2612,5v0.3694 -r 32000
set xPsox2="%xAppDir%\sox\sox.exe" -s -b 16 -c 2 -r 32000 -t raw - -t raw - silence 1 0 -96d reverse
set xPsox3="%xAppDir%\sox\sox.exe" -s -b 16 -c 2 -r 32000 --norm -t raw - -t wav - silence 1 0 -96d reverse
set xPenc="%xAppDir%\LAME\lame.exe" --silent -V5 - "%xO%.out.mp3"
%xPff% | %xPsox1% | %xPenc%
::%xPff% | %xPsox1% | %xPsox2% | %xPsox3% | %xPenc%
echo.
pause
Alles anzeigen
oh man, schon ne 5-fach pipe, wird langsam unübersichtlich...
Zitatsind die zahlen als "gegeben" anzusehen
oder wie ist man darauf gekommen bzw. wie kann man sie deuten?
lies http://forum.doom9.org/showthread.php?t=152034 und die dort verknüpften Links
Was mit auffällt:
1. '--norm ' <- Steht das nicht an der falschen Position, dachte das gehört direkt vor den input,....
2. zumindest beim Verbinden der sox calls würde ich eher "-t sox -" bzw. "-p" anstatt dem "-s -b 16 ... -t raw -" Teil nehmen. (macht die Sache kürzer und weniger Fehleranfällig)
3. bin mir nicht sicher ob die Resampleoption "-r 32000" die Du verwendest auch hinter dem remix stehen darf oder ob die nicht davor muss.
Cu Selur
Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!