<?xml version="1.0" encoding="UTF-8"?><!-- generator="wordpress.com" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	>

<channel>
	<title>mencoder &amp;laquo; WordPress.com Tag Feed</title>
	<link>http://en.wordpress.com/tag/mencoder/</link>
	<description>Feed of posts on WordPress.com tagged "mencoder"</description>
	<pubDate>Tue, 01 Dec 2009 19:23:24 +0000</pubDate>

	<generator>http://en.wordpress.com/tags/</generator>
	<language>en</language>

<item>
<title><![CDATA[Reparar indice de un avi]]></title>
<link>http://zignux.wordpress.com/2009/11/29/reparar-indice-de-un-avi/</link>
<pubDate>Sun, 29 Nov 2009 13:23:16 +0000</pubDate>
<dc:creator>carugnom</dc:creator>
<guid>http://zignux.wordpress.com/2009/11/29/reparar-indice-de-un-avi/</guid>
<description><![CDATA[Si un archivo de video esta dañado, seguramente notaremos que no se puede adelantar o retrasar. Es p]]></description>
<content:encoded><![CDATA[Si un archivo de video esta dañado, seguramente notaremos que no se puede adelantar o retrasar. Es p]]></content:encoded>
</item>
<item>
<title><![CDATA[pobieranie materiałów z youtube.com]]></title>
<link>http://trycode.wordpress.com/2009/11/28/pobieranie-materialow-z-youtube-com/</link>
<pubDate>Sat, 28 Nov 2009 19:18:52 +0000</pubDate>
<dc:creator>trym</dc:creator>
<guid>http://trycode.wordpress.com/2009/11/28/pobieranie-materialow-z-youtube-com/</guid>
<description><![CDATA[Za pomocą skryptu youtube-dl możemy pobierać dane z portalu youtube.com. Jest on dostępny w repozyto]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>Za pomocą skryptu <em>youtube-dl</em> możemy pobierać dane z portalu <a href="http://youtube.com">youtube.com</a>. Jest on dostępny w repozytorium <em>Debiana</em>, ale wyłącznie w wersji <em>Sid</em>. Zatem jeśli mamy inną wersję tego systemu jak np. <em>Lenny</em> należy postępować zgodnie z poniższym. </p>
<p>Kopiujemy tekst skryptu z <a href="http://www.arrakis.es/~rggi3/youtube-dl/youtube-dl">tej strony</a> i zapisujemy pod nazwą <em>youtube-dl</em> lub <em>youtube-dl.py</em> (najprawdopodobniej żadna nazwa nie zawiedzie, chodzi o to aby było intuicyjnie) w katalogu do którego mamy ustawioną zmienną <em>PATH</em>.</p>
<p>Gdy nie wiemy gdzie umieścić dany skrypt wykonujemy:<br />
<code>$ $PATH</code></p>
<p>Polecenie to wylistuje katalogi do których mamy ustawioną zmienną <em>PATH</em> oddzielając je znakiem <em>:</em> (dwukropka).</p>
<blockquote><p>bash: /usr/local/bin:/usr/bin:/bin:/usr/games:</p></blockquote>
<p><!--more--></p>
<p>Ja nazwałem skrypt <em>youtube-dl.py</em> i zapisałem go w katalogu <em>/usr/local/bin</em>.<br />
Teraz co bardzo ważne należy nadać naszemu skryptowi prawa do wykonywania:<br />
<code># chmod +x youtube-dl.py</code></p>
<p>Już możemy pobierać dane z <em>youtube&#8217;a</em>!</p>
<h5>Przykłady:</h5>
<p><code>$ youtube-dl.py http://pl.youtube.com/watch?v=b24ddxV0SuI</code></p>
<p>Powyższa metoda nie zawiedzie w danym przypadku. Jednak nie ściągniemy tego co ukrywa się pod linkiem <a href="http://pl.youtube.com/watch?v=6wNLOUqVK2s">http://pl.youtube.com/watch?v=6wNLOUqVK2s</a>. Musimy się zalogować i potwierdzić datę urodzenia. </p>
<p>Zatem do dzieła:<br />
<code>$ youtube-dl.py -u TWOJ_LOGIN -p TWOJE_HASLO http://pl.youtube.com/watch?v=6wNLOUqVK2s</code></p>
<p>Pliki zostaną zapisane w katalogu bieżącym odpowiednio pod nazwą <em>b24ddxV0SuI.flv</em> i <em>6wNLOUqVK2s.flv</em>.</p>
<p>Jeśli nie odpowiadają nam formaty zapisanych plików (<em>*.flv</em>) bo chcemy np. wrzucić filmik na komórkę to polecam zapoznać się z programami <em>ffmpeg</em> lub <em>mencoder</em>, które oferują bardzo dużo jeśli chodzi o konwersję.</p>
<p>Przykładowe polecenie może wyglądać tak:<br />
<code>$ mencoder PLIK_WEJSCIOWY.flv -o PLIK_WYJSCIOWY.avi -oac mp3lame -ovc lavc</code></p>
<p>manual:<br />
<a href="http://www.digipedia.pl/man/youtube-dl.1.html">http://www.digipedia.pl/man/youtube-dl.1.html</a><br />
youtube-dl dla Windows XP:<br />
<a href="http://rg03.wordpress.com/youtube-dl-under-windows-xp/">http://rg03.wordpress.com/youtube-dl-under-windows-xp/</a></p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Soft-Telecine PAL to NTSC MPEG2]]></title>
<link>http://linuxmoc.wordpress.com/2009/11/24/soft-telecine-pal-to-ntsc-mpeg2/</link>
<pubDate>Tue, 24 Nov 2009 08:43:40 +0000</pubDate>
<dc:creator>mocharhw</dc:creator>
<guid>http://linuxmoc.wordpress.com/2009/11/24/soft-telecine-pal-to-ntsc-mpeg2/</guid>
<description><![CDATA[Thought I&#8217;d post this as I haven&#8217;t found all this information in one place.  Sometimes I]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>Thought I&#8217;d post this as I haven&#8217;t found all this information in one place.  Sometimes I like to take random movies I&#8217;ve downloaded off the net and encode and burn them to standard NTSC DVD.  The problem is a lot of the videos you find are from PAL (25 fps) source and/or they use out of the ordinary aspect ratios like 2.45:1 or 1.91:1.  These two issues can give you major headaches when trying to get them onto DVD and preserve the proper aspect ratio and smooth frame rate.</p>
<p>There&#8217;s a number of solutions to these problems which I&#8217;ll outline below.</p>
<p><strong>Convert &#8220;Any&#8221; PAL to NTSC MPEG2-PS (DVD), Soft-Telecine method<br />
</strong></p>
<p><code>mencoder INPUT_PAL.avi -vf scale=720:480,harddup -srate 48000<br />
-af lavcresample=48000 -ovc lavc -oac lavc -of mpeg -lavcopts vcodec=mpeg2video:vrc_buf_size=1835:vrc_maxrate=9800:vbitrate=5000:<br />
keyint=15:vstrict=0:acodec=ac3:abitrate=224:aspect=16/9 -mpegopts format=dvd:tsaf:tele_src=25:tele_dest=30000/1001 -o OUTPUT_NTSC.mpg</code></p>
<p>This &#8220;soft-telecine&#8221; method flags the frames for 25 fps to 29.97 fps to make the file NTSC compliant without changing the actual frame rate.</p>
<p><strong>Dealing with the Aspect Ratio problem</strong></p>
<p>The mencoder command above is incomplete because if you&#8217;ll notice it assumes you have a source already encoded at 720&#215;480 with a pixel aspect of 1:1 and a display aspect of 16:9.  Of course this is never the case, so you need to make a few modifications.  We need to do some simple math.</p>
<p>Example:  Source file has a display aspect of 2.45:1 and a resolution of 640&#215;261.</p>
<p>Desired output is NTSC-DVD with 16:9 display aspect:  (480)*(16/9)=854, and (854)/(2.45)=349, so we&#8217;ll encode to 720&#215;350 and pad/expand the remainder to 480.</p>
<p>mencoder uses the expand method, portions of the above command line would therefore be modified like this &#8220;-vf scale=720:350,expand=720:480&#8243; and make sure the -lavcopts part has &#8220;aspect=16/9&#8243; in it somewhere.</p>
<p>If you happen to prefer ffmpeg, it uses the padding method and you would achieve the same thing by having the following in the command line &#8220;-s 720:350 -padtop 65 -padbottom 65 -aspect 16:9&#8243;.</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[HowTo: convertire MKV in AVI]]></title>
<link>http://idl3.wordpress.com/2009/11/23/howto-convertire-mkv-in-avi/</link>
<pubDate>Mon, 23 Nov 2009 08:58:40 +0000</pubDate>
<dc:creator>idl3</dc:creator>
<guid>http://idl3.wordpress.com/2009/11/23/howto-convertire-mkv-in-avi/</guid>
<description><![CDATA[Non so perche&#8217; vogliate fare una cosa del genere, ma se proprio volete convertire un file Matr]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>Non so perche&#8217; vogliate fare una cosa del genere, ma se proprio volete <strong>convertire un file <a href="http://it.wikipedia.org/wiki/Matroska">Matroska</a> in un formato AVI</strong> potete usare <code>mencoder</code>. Vediamo come.</p>
<p><img src="http://idl3.wordpress.com/files/2009/11/matroska.png?w=150" alt="" title="matroska" width="150" height="150" class="alignleft size-thumbnail wp-image-1201" />Prima di tutto vediamo cosa sono questi file <a href="http://www.matroska.org/">Matroska</a>. Possiamo averne di tre tipi: <em>MKV</em> (video), <em>MKA</em> (audio) e <em>MKS</em> (sottotitoli), per crearli viene utilizzato l&#8217;<acronym title="Extensible Binary Meta Language">EBML</acronym>. Si tratta di un buon formato, anche se puo&#8217; dare <strong>qualche problemino</strong> con alcuni riproduttori di video, ma questo e&#8217; un problema dei riproduttori (o lettori) e non del formato del file. Comunque, ipotizziamo ci sia un buon motivo dietro il vostro desiderio di <strong>convertire il vostro bel video MKV in un altro formato</strong>. Per prima cosa dovete sapere in quale formato convertire, vediamone due.</p>
<p>Se volete <strong>convertire da Matroska a <a href="http://it.wikipedia.org/wiki/Xvid">Xvid</a></strong> dovete dare questo <strong>comando</strong>:<br />
<code>$ mencoder INPUT.mkv -ofps 25 -ovc xvid -oac mp3lame -lameopts abr:br=192 -srate 48000 -xvidencopts fixed_quant=4 -vf scale -zoom -xy 720 -o OUTPUT.avi</code><br />
analizzare ogni singola opzione sarebbe lungo e per voi inutile, andatevi dunque a leggere la <a href="http://www.mplayerhq.hu/DOCS/HTML-single/it/MPlayer.html">guida</a> di <code>mencoder</code>. Vi dico solo che l&#8217;opzione <code>xvidencopts fixed_quant</code> indica la <strong>qualita&#8217;</strong> (3 buona qualita&#8217; ma meno compressione, 5 bassa qualita&#8217; alta compressione), <strong>4 e&#8217; una buona via di mezzo</strong>. Se non ne siete soddisfatti potete sempre ripetere il comando cambiando i valori.</p>
<p>Potete anche <strong>convertire il vostro file MKV in formato <a href="http://it.wikipedia.org/wiki/DivX">DivX</a> 5</strong>, con questo <strong>comando</strong>:<br />
<code>$ mencoder INPUT.mkv -o OUTPUT.avi -ovc lavc -lavcopts vcodec=mpeg4:vbitrate=700:vpass=1 -ffourcc DIVX50 -oac mp3lame -vf scale -zoom -xy 720</code></p>
<p>E&#8217; comunque consigliabile, laddove possibile, il formato Xvid rispetto al DivX, per varie ragioni.</p>
<p>Se doveste avere (come accade spesso) un file MKV con <strong>due tracce audio</strong>, allora dovete aggiungere una o piu&#8217; opzioni per indicare quale utilizzare. Ma prima di tutto dovete <strong>individuare la traccia audio che vi interessa</strong>, per farlo date questo comando:<br />
<code>$ mplayer -v INPUT.mkv</code><br />
leggete e cercate qualcosa del genere:</p>
<pre>[...]
...  -aid N, -alang LNG
...  -aid N, -alang LNG
[...]</pre>
<p>dove al posto di <em>N</em> c&#8217;e&#8217; un numero e al posto di <em>LNG</em> c&#8217;e&#8217; la lingua, ad esempio <code>-aid 1, -alang ita</code> e <code>-aid 2, -alang eng</code>. Ora <strong>avete tutto quello che vi serve</strong>. Il comando per creare un file in Xvid con la <strong>traccia audio in italiano</strong> sara&#8217; dunque (stando all&#8217;esempio):<br />
<code>$ mencoder INPUT.mkv -ofps 25 -ovc xvid -oac mp3lame -lameopts abr:br=128 -srate 48000 -vf scale -zoom -xy 720 -xvidencopts fixed_quant=4  -aid 1 -alang ita -o OUTPUT.avi</code></p>
<p><img src="http://idl3.wordpress.com/files/2009/11/video.jpg?w=150" alt="" title="video" width="150" height="150" class="alignright size-thumbnail wp-image-1202" />Certe volte (a seconda del formato audio) ci potrebbero essere <strong>problemi</strong> ad utilizzare questo sistema. In questi casi ci viene in aiuto <a href="http://www.bunkus.org/videotools/mkvtoolnix/index.html">mkvtoolnix</a>. Essendo <a href="http://packages.debian.org/lenny/mkvtoolnix">pacchettizzato</a>, per installarlo sulla nostra <strong>Debian</strong> facciamo cosi&#8217;:<br />
<code># apt-get install mkvtoolnix</code><br />
il <em>tool</em> contiene <strong>varie applicazioni</strong>, tra cui <code>mkvmerge</code>, <code>mkvinfo</code> e <code>mkvextract</code>. Quella che fa al caso nostro e&#8217; <strong>mkvextract</strong>, leggiamoci dunque la <a href="http://www.bunkus.org/videotools/mkvtoolnix/doc/mkvextract.html">guida</a>, che ci suggerisce la <strong>seguente procedura</strong>.</p>
<p>Prima di tutto dobbiamo <strong>identificare le tracce audio</strong> (e gli eventuali sottotitoli):<br />
<code>$ mkvmerge -i movie.mkv</code><br />
che ad esempio ci restituisce questo <em>output</em>:</p>
<pre>File ’movie.mkv’: container: Matroska
Track ID 1: video (V_MS/VFW/FOURCC, DIV3)
Track ID 2: audio (A_MPEG/L3)
Track ID 3: audio (A_VORBIS)
Track ID 4: subtitles (S_TEXT/UTF8)
Track ID 5: subtitles (S_TEXT/UTF8)</pre>
<p>Come vedete la traccia 2 e&#8217; un <strong>formato audio MP3</strong>, la traccia 3 e&#8217; un <strong>formato audio OGG</strong> e poi abbiamo i <strong>due sottotitoli</strong>. Se vogliamo la seconda traccia audio e i secondi sottotitoli, allora diamo questo <strong>comando</strong>:<br />
<code>$ mkvextract tracks movie.mkv 2:audio.mp3 5:subtitles.srt</code></p>
<p>Ora <a href="http://idl3.wordpress.com/2009/09/25/howto-tagliare-video-e-unire-audio-e-video-con-ffmpeg-e-mencoder/">potete usare ffmpeg</a> sul file MKV per <strong>estrarre solo il video</strong>:<br />
<code>$ ffmpeg -i INPUT.mkv -an -vcodec copy -y  OUTPUT.mkv</code><br />
e poi convertite con <code>mencoder</code> usando l&#8217;opzione <code>audiofile</code> per indicargli il <strong>file audio esterno</strong> (che abbiamo estratto con mkvextract):<br />
<code>$ mencoder INPUT.mkv -ofps 25 -ovc xvid -oac mp3lame -lameopts abr:br=192 -srate 48000 -xvidencopts fixed_quant=4 -vf scale -zoom -xy 720 -audiofile audio.mp3 -o OUTPUT.avi</code></p>
<p>Adesso avete il vostro bel <strong>file video in formato AVI XviD riproducibile nei piu&#8217; normali lettori</strong>. Se siete estimatori delle lingue originali, ma non le conoscete e volete i <strong>sottotitoli</strong>, basta inserirli <strong>nella stessa directory del file video</strong>. Generalmente per far si che il lettore li legga basta che file video e sottotitoli abbiano <strong>lo stesso nome</strong> (solo l&#8217;estensione diversa). Ad esempio: <code>Filmstrepitoso.avi</code> e <code>Filmstrepitoso.srt</code>. Puo&#8217; pero&#8217; capitare che ci siano lettori che <strong>non leggono i sottotitoli</strong> . Allora dovete <a href="http://idl3.wordpress.com/2009/10/10/1-scollegamenti/">inserirli nel file video</a>, in questo modo:<br />
<code>$ mencoder -ovc xvid -xvidencopts fixed_quant=4 -oac copy -sub Filmstrepitoso.srt -subfont-text-scale 4 -o Filmstrepitosoconsottotitoli.avi Filmstrepitoso.avi</code></p>
<p>Fatto, ora potete godervi il vostro <strong>film con i sottotitoli</strong> anche nel piu&#8217; <strong>scadente</strong> dei lettori.</p>
<hr />
<p style="text-align:right;"><a href="#content" title="torna su">[^] torna su</a>&#160;&#124;&#160;<a href="http://postli.com/post?u=http://idl3.wordpress.com/2009/11/23/howto-convertire-mkv-in-avi/&#38;t=HowTo: convertire MKV in AVI" title="Post to Postli" style="color:blue;text-decoration:none;">post<span style="color:orange;">&#60;</span><span style="color:red;">li</span><span style="color:orange;">&#62;</span></a>&#160;&#124;&#160;<a href="http://www.wikio.it/vote?url=http://idl3.wordpress.com/2009/11/23/howto-convertire-mkv-in-avi/" target="_blank"><img src="http://www.wikio.it/shared/img/vote/wikio2.gif" border="0" /></a></p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Watch movies with subtitles on Xbox 360]]></title>
<link>http://scognito.wordpress.com/2009/11/19/watch-movies-with-subtitles-on-xbox-360/</link>
<pubDate>Thu, 19 Nov 2009 16:37:29 +0000</pubDate>
<dc:creator>scognito</dc:creator>
<guid>http://scognito.wordpress.com/2009/11/19/watch-movies-with-subtitles-on-xbox-360/</guid>
<description><![CDATA[Xbox 360 multimedia capabilities are very good, with streaming functions available not only for Wind]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p><a href="http://scognito.wordpress.com/files/2009/11/xbox360-movies.png"><img class="aligncenter size-full wp-image-213" title="xbox360-movies" src="http://scognito.wordpress.com/files/2009/11/xbox360-movies.png" alt="xbox 360 movies" width="391" height="391" /></a></p>
<p>Xbox 360 multimedia capabilities are very good, with streaming functions available not only for Windows systems (see <a title="stream movies on xbox360 using ubuntu" href="http://scognito.wordpress.com/2009/11/18/streaming-movies-and-music-from-ubuntu-to-xbox360/" target="_blank">here</a> for streaming movies using Ubuntu).</p>
<p>There is a caveat though, <a title="xbox support" href="http://support.xbox.com/support/en/us/nxe/gamesandmedia/movies/videofaq/viewvideoplaybackfaq.aspx" target="_blank">the lack of subtitles functionality for movies</a>, and the only way to use them is to hard-sub (encoding the movie again applying subtitles on it).</p>
<p>Several tools are available for every operating system, but the easiest one I use is <a title="mencoder manual" href="http://www.mplayerhq.hu/DOCS/HTML/en/mencoder.html" target="_blank">mencoder</a> (part of the <a title="MPlayer site" href="http://www.mplayerhq.hu" target="_blank">MPlayer</a> project), a command line tool for encoding audio and video files.</p>
<p>Mencoder is available in almost every Linux distribution, for install on Ubuntu just type:</p>
<blockquote><p>sudo apt-get install mencoder</p></blockquote>
<p>I encode each movie in Xvid format (which Xbox is capable of play), with this command:</p>
<blockquote><p>mencoder <em>mymovie.avi</em> -ovc xvid -oac mp3lame -xvidencopts fixed_quant=1 -sub <em>mymovie.srt</em> -o <em>mymovie-encoded.avi</em></p></blockquote>
<p>where obviously <em>mymovie.avi</em> is the original movie without subtitles, <em>mymovie.srt</em> is the subtitles file and <em>mymovie-encoded.avi</em> is the resultant output file.</p>
<p><a href="http://scognito.wordpress.com/files/2009/11/term-mencoder.png"><img class="aligncenter size-medium wp-image-220" title="term-mencoder" src="http://scognito.wordpress.com/files/2009/11/term-mencoder.png?w=213" alt="terminal mencoder" width="213" height="300" /></a></p>
<p>The output file will be larger than the original one because I used the <em>fixed_quant=1</em> option, that outputs larger files but with best quality (you can use 2 or 3 but the quality downgrades).</p>
<p>Encoding may be very slow on older systems, but once finished it can played as any other media&#8230;enjoy!</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Convertir video a flv + adición de subtítulos]]></title>
<link>http://panoolvidar.wordpress.com/2009/11/13/convertir-video-a-flv-adicion-de-subtitulos/</link>
<pubDate>Fri, 13 Nov 2009 16:09:05 +0000</pubDate>
<dc:creator>dfrios</dc:creator>
<guid>http://panoolvidar.wordpress.com/2009/11/13/convertir-video-a-flv-adicion-de-subtitulos/</guid>
<description><![CDATA[A pesar de que tengo &#8220;Adobe Media Converter CS4&#8243; para convertir los videos a FLV, no sop]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>A pesar de que tengo &#8220;Adobe Media Converter CS4&#8243; para convertir los videos a FLV, no soporta todos los formatos de entrada; además no es posible incluir subtítulospara estas tareas recomiendo <a target="_blank" href="http://www.mplayerhq.hu/">mencoder </a>o <a target="_blank" href="http://ffmpeg.org/">ffmpeg</a>.</p>
<p>Para mencoder la línea sería:</p>
<p><code>mencoder -forceidx -of lavf -oac mp3lame -lameopts abr:br=56 -srate 22050 -ovc lavc -lavcopts vcodec=flv:vbitrate=512:mbd=2:mv0:trell:v4mv:cbp:last_pred=3 -vf scale=640:426 -subpos 100 -font /windows/fonts/arial.ttf -sub cojin.srt -o cojin.flv cojin.mpg</code></p>
<div class="zemanta-pixie"><img class="zemanta-pixie-img" alt="" src="http://img.zemanta.com/pixy.gif?x-id=50af7093-c4dc-80fd-9b40-3376bddd251d" /></div>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[HowTo: convertire AVI in DVD]]></title>
<link>http://idl3.wordpress.com/2009/11/09/howto-convertire-avi-in-dvd/</link>
<pubDate>Mon, 09 Nov 2009 06:30:35 +0000</pubDate>
<dc:creator>idl3</dc:creator>
<guid>http://idl3.wordpress.com/2009/11/09/howto-convertire-avi-in-dvd/</guid>
<description><![CDATA[Chissa&#8217; quante volte vi sara&#8217; capitato di avere un video AVI e volerlo convertire in for]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>Chissa&#8217; quante volte vi sara&#8217; capitato di <strong>avere un video <acronym title="Audio Video Interleave">AVI</acronym></strong> e volerlo <strong>convertire in formato <acronym title="Digital Versatile Disc">DVD</acronym></strong>. Con GNU/Linux e&#8217; <strong>una passeggiata</strong>, forse il programma piu&#8217; famoso e&#8217; <strong><a href="http://www.rastersoft.com/programas/devede.html">DeVeDe</a></strong>, ma <strong>esistono anche altri metodi</strong>, si puo&#8217; fare tutto <strong>ad esempio da terminale</strong>.</p>
<p>Espongo tre metodi: il <a href="#caidpm">primo</a> con lo <strong>script Bash</strong>, il <a href="#caidsm">secondo</a> con <strong>DeVeDe</strong> e altri programmi, il <a href="#caidtm">terzo</a> con <strong>dvdauthor</strong>.</p>
<p><img src="http://idl3.wordpress.com/files/2009/09/terminale.png?w=150" alt="Terminale" title="Terminale" width="150" height="150" class="alignleft size-thumbnail wp-image-180" /><strong>PRIMO METODO</strong> <a name="caidpm">-</a> Da riga di comando pero&#8217; il procedimento e&#8217; <strong>lungo</strong>, e puo&#8217; risultare noioso. Per questo motivo esiste la possibilita&#8217; di <strong>creare uno script in Bash</strong>. Vediamo come.</p>
<p>Prima di tutto dobbiamo <strong>procurarci i programmi necessari</strong>:<br />
<code># apt-get install ffmpeg mencoder lame dvdauthor lame-extras libtwolame0 genisoimage</code><br />
e&#8217; molto probabile che gran parte di questi pacchetti siano gia&#8217; installati sul vostro computer.</p>
<p>Ora dobbiamo <strong>creare lo script</strong>:<br />
<code>$ nano /usr/bin/avi2dvd.sh</code><br />
lo creiamo nella <strong>directory</strong> <code>/usr/bin/</code> cosi&#8217; da poterlo richiamare da terminale <strong>ovunque</strong> ci troviamo.</p>
<p>Dentro il file appena creato ci <strong>copiamo</strong> questo:</p>
<pre><tt>---8&#60;---
<i><font color="#9A1900">#!/bin/bash</font></i>

<font color="#009900">output</font><font color="#990000">=</font>$<font color="#993399">1</font>
<i><font color="#9A1900">####################</font></i>
<i><font color="#9A1900"># avi     Function #</font></i>
<i><font color="#9A1900">####################</font></i>

<b><font color="#000000">function avi </font></b>{
    mencoder -oac lavc -ovc lavc -of mpeg -mpegopts <font color="#009900">format</font><font color="#990000">=</font>xvcd -vf <font color="#009900">scale</font><font color="#990000">=</font><font color="#993399">352</font><font color="#990000">:</font><font color="#993399">196</font><font color="#990000">,</font><font color="#009900">expand</font><font color="#990000">=</font><font color="#993399">352</font><font color="#990000">:</font><font color="#993399">240</font><font color="#990000">,</font>harddup -srate <font color="#993399">44100</font> -af <font color="#009900">lavcresample</font><font color="#990000">=</font><font color="#993399">44100</font> -lavcopts     <font color="#009900">vcodec</font><font color="#990000">=</font>mpeg1video<font color="#990000">:</font><font color="#009900">keyint</font><font color="#990000">=</font><font color="#993399">18</font><font color="#990000">:</font><font color="#009900">vrc_buf_size</font><font color="#990000">=</font><font color="#993399">327</font><font color="#990000">:</font><font color="#009900">vrc_minrate</font><font color="#990000">=</font><font color="#993399">1152</font><font color="#990000">:</font><font color="#009900">vbitrate</font><font color="#990000">=</font><font color="#993399">1152</font><font color="#990000">:</font><font color="#009900">vrc_maxrate</font><font color="#990000">=</font><font color="#993399">1152</font><font color="#990000">:</font><font color="#009900">acodec</font><font color="#990000">=</font>mp2<font color="#990000">:</font><font color="#009900">abitrate</font><font color="#990000">=</font><font color="#993399">224</font> -ofps <font color="#993399">30000</font>/1001 -o output<font color="#990000">.</font>mpg <font color="#FF0000">"$output"</font>
}

<i><font color="#9A1900">####################</font></i>
<i><font color="#9A1900"># vcd     Function #</font></i>
<i><font color="#9A1900">####################</font></i>

<b><font color="#000000">function vcd </font></b>{
    ffmpeg -i output<font color="#990000">.</font>mpg -target ntsc-dvd -aspect <font color="#993399">4</font><font color="#990000">:</font><font color="#993399">3</font> output2<font color="#990000">.</font>mpg
}

<i><font color="#9A1900">####################</font></i>
<i><font color="#9A1900"># rm1mpg Function #</font></i>
<i><font color="#9A1900">####################</font></i>

<b><font color="#000000">function rm1mpg </font></b>{
    rm output<font color="#990000">.</font>mpg
}

<i><font color="#9A1900">####################</font></i>
<i><font color="#9A1900"># convert Function #</font></i>
<i><font color="#9A1900">####################</font></i>

<b><font color="#000000">function convert </font></b>{
    dvdauthor -o dvd -t output2<font color="#990000">.</font>mpg
}

<i><font color="#9A1900">####################</font></i>
<i><font color="#9A1900"># rmpg     Function #</font></i>
<i><font color="#9A1900">####################</font></i>

<b><font color="#000000">function rmpg </font></b>{
    rm output2<font color="#990000">.</font>mpg
}

<i><font color="#9A1900">###################</font></i>
<i><font color="#9A1900"># Rename Function #</font></i>
<i><font color="#9A1900">###################</font></i>

<b><font color="#000000">function finalize </font></b>{

dvdauthor -o dvd -T

}

<i><font color="#9A1900">#####################</font></i>
<i><font color="#9A1900"># ISO Function      #</font></i>
<i><font color="#9A1900">#####################</font></i>

<b><font color="#000000">function image </font></b>{

mkisofs -dvd-video -o dvd<font color="#990000">.</font>iso dvd<font color="#990000">/</font>

}

<i><font color="#9A1900">#####################</font></i>
<i><font color="#9A1900"># rm2 Function      #</font></i>
<i><font color="#9A1900">#####################</font></i>

<b><font color="#000000">function rm2 </font></b>{

rm -rf dvd<font color="#990000">/</font>

}

<i><font color="#9A1900">###############</font></i>
<i><font color="#9A1900"># Script      #</font></i>
<i><font color="#9A1900">###############</font></i>

avi <font color="#990000">;</font>
vcd <font color="#990000">;</font>
rm1mpg <font color="#990000">;</font>
convert <font color="#990000">;</font>
rmpg <font color="#990000">;</font>
finalize <font color="#990000">;</font>
image <font color="#990000">;</font>
rm2 <font color="#990000">;</font>

<b><font color="#0000FF">exit</font></b>

---8&#60;---</tt></pre>
<p>salviamo <strong>[Ctrl]+[o]</strong> e chiudiamo <strong>[Ctrl]+[x]</strong>.</p>
<p>Rendiamolo <strong>eseguibile</strong>:<br />
<code># chmod 777 /usr/bin/avi2dvd.sh</code><br />
e <strong>proviamolo</strong> subito su un nostro video in AVI.</p>
<p>Se ad esempio il nostro video si trova nella directory <code>/home/UTENTE/videoavi/</code> non dobbiamo far altro che aprire un terminale, <strong>spostarci</strong> nella directory giusta:<br />
<code>$ cd /home/UTENTE/videoavi/</code><br />
e dare il <strong>comando</strong>:<br />
<code>$ avi2dvd VIDEO.avi</code></p>
<p>A tutto il resto pensera&#8217; lo <em>script</em>. Per capire cosa faccia esattamente basta leggerlo.<br />
Fonte: <a href="http://ubuntuforums.org/showpost.php?p=5878919&#38;postcount=1">Convert AVI to DVD ISO</a></p>
<p><img src="http://idl3.wordpress.com/files/2009/11/dvd.jpg?w=150" alt="dvd" title="dvd" width="150" height="120" class="alignright size-thumbnail wp-image-947" /><strong>SECONDO METODO</strong> <a name="caidsm">-</a> Ora vediamo come fare a <strong>convertire un video da AVI a DVD con DeVeDe</strong>. Prima di tutto dobbiamo installarlo:<br />
<code># apt-get install devede</code></p>
<p>Adesso abbiamo due possibilita&#8217;, o usiamo <strong>DeVeDe con la versione grafica</strong>, o facciamo da riga di comando con altri programmi. Per farlo con la versione grafica, aprite semplicemente il programma:<br />
<code>$ devede &#38;</code><br />
e seguite l&#8217;interfaccia intuitiva.</p>
<p>Se invece volete cimentarvi col terminale (bravi, cosi&#8217; vi voglio) vediamo come fare. Prima di tutto <strong>ci servono questi programmi</strong>:<br />
<code># apt-get install growisofs mkisofs dvdauthor ffmpeg mencoder</code></p>
<p>Se il file che volete convertire in DVD e&#8217; uno va tutto bene, se fossero <strong>due</strong>, e&#8217; il caso di <strong>unirli</strong>. Un metodo puo&#8217; essere questo:<br />
<code>$ cat VIDEO1.avi VIDEO2.avi &#62; VIDEOUNITO.avi</code><br />
e poi:<br />
<code>$ mencoder -o VIDEO.avi -noidx -oac copy -ovc copy VIDEOUNITO.avi</code></p>
<p>Sinceramente e&#8217; un procedimento che non mi piace, in un <a href="http://idl3.wordpress.com/2009/09/25/howto-tagliare-video-e-unire-audio-e-video-con-ffmpeg-e-mencoder/">post</a> ne avevo indicato un altro, <strong>questo</strong>:<br />
<code>$ mencoder -ovc copy -oac copy VIDEO1.avi VIDEO2.avi -o VIDEO.avi</code></p>
<p>Ora che abbiamo il nostro file <code>VIDEO.avi</code> possiamo continuare. Cambiamo <strong>l&#8217;aspetto e la codifica del video</strong> con <strong>FFmpeg</strong>:<br />
<code>$ ffmpeg -i VIDEO.avi -y -target pal-dvd -sameq -aspect 16:9 VIDEO.mpg</code><br />
lo stiamo <strong>codificando</strong> nello <a href="http://it.wikipedia.org/wiki/PAL">standard <acronym title="Phase Alternating Line">PAL</acronym></a>.</p>
<p>Ovviamente se il DVD fosse destinato al nostro zio d&#8217;<strong>America</strong> la codifica la dovremmo fare nello <a href="http://it.wikipedia.org/wiki/NTSC">standard <acronym title="National Television System Committee">NTSC</acronym></a>, e quindi il comando sarebbe:<br />
<code>$ ffmpeg -i VIDEO.avi -y -target ntsc-dvd -sameq -aspect 16:9 VIDEO.mpg</code></p>
<p>Ora non ci resta che <strong>creare i titoli</strong>:<br />
<code>$ dvdauthor --title -o dvd -f VIDEO.mpg </code><br />
e la <strong>tabella</strong> dei <strong>contenuti</strong>:<br />
<code>$ dvdauthor -o dvd -T</code></p>
<p>Infine lo <strong>masterizziamo</strong> cosi&#8217;:<br />
<code>$ growisofs -dvd-compat -dvd-video -speed=4 -Z /dev/dvd dvd/*</code></p>
<p>Anziche&#8217; masterizzarlo subito, possiamo anche <strong>creare il file ISO</strong> prima:<br />
<code>$ mkisofs -dvd-video -o DVD.iso dvd/</code><br />
e solo dopo <strong>masterizzarlo</strong> cosi&#8217;:<br />
<code>$ growisofs -dvd-compat -Z /dev/dvd=dvd.iso</code></p>
<p>Ovviamente al posto di <code>/dev/dvd</code> dovete inserire il <strong>percorso giusto</strong> del masterizzatore per DVD se non e&#8217; quello.</p>
<p><img src="http://idl3.wordpress.com/files/2009/11/masterizzatore-cd-dvd.jpg?w=150" alt="masterizzatore-cd-dvd" title="masterizzatore-cd-dvd" width="150" height="150" class="alignleft size-thumbnail wp-image-948" /><strong>TERZO MEODO</strong> <a name="caidtm">-</a> Per la gioia degli amanti della <strong>terza via</strong>, esiste anche un altro metodo, che utilizza <strong>vari programmi da terminale</strong>. Installiamoli:<br />
<code># apt-get install transcode mplayer mjpegtools ffmpeg dvd+rw-tools dvdauthor</code></p>
<p>Ipotizziamo di avere il nostro solito file <code>VIDEO.avi</code>. Con questo metodo prima di tutto dobbiamo <strong>separare l&#8217;audio dal video</strong>, e lo facciamo con questo comando:<br />
<code>$ transcode -i VIDEO.avi -y ffmpeg --export_prof dvd-ntsc --export_asr 3 -o VIDEO -D0 -s2 -m VIDEO.ac3 -J modfps=clonetype=3 --export_fps 29.97</code><br />
Se non vogliamo un <strong>output a 16:9 ma a 4:3</strong>, il comando sara&#8217;:<br />
<code>$ transcode -i VIDEO.avi -y ffmpeg --export_prof dvd-ntsc --export_asr 2 -o VIDEO -D0 -s2 -m VIDEO.ac3 -J modfps=clonetype=3 --export_fps 29.97</code></p>
<p>L&#8217;<strong>output</strong> sara&#8217; costituito dal file <code>VIDEO.m2v</code> (il video) e <code>VIDEO.ac2</code> (audio). Se vogliamo strafare, possiamo estrarre dal file <code>VIDEO.avi</code> l&#8217;<strong>audio 5.1</strong>, e lo facciamo cosi&#8217;:<br />
<code>$ tcextract -d2 -i VIDEO.avi -a0 -x ac3 &#124; tcextract -d2 -x ac3 -t raw &#62; VIDEO.ac3</code></p>
<p>Ovviamente <strong>solo se</strong> il vostro video ha l&#8217;audio 5.1. Se non siete sicuri che il vostro file video abbia l&#8217;audio in 5.1, potete facilmente <strong>scoprirlo</strong> dando questo comando:<br />
<code>mplayer -vo dummy -identify VIDEO.avi 2&#62; /dev/null &#124; grep "5.1 ("</code><br />
se c&#8217;e&#8217; il <strong>5.1</strong> l&#8217;output sara&#8217; qualcosa tipo:</p>
<pre>AC3: 5.1 (3f+2r+lfe) 48000 Hz 384.0 kbit/s</pre>
<p>A questo punto <strong>riuniamo audio e video</strong>:<br />
<code>$ mplex -f 8 -o VIDEO.mpg VIDEO.m2v VIDEO.ac3</code></p>
<p>Adesso abbiamo un bel <strong>video in formato <acronym title="Moving Pictures Experts Group">MPEG</acronym></strong> pronto per essere dato in pasto a <strong>dvdauthor</strong>. Ma prima dobbiamo creare un <strong>file di testo</strong> in cui inseriremo i <strong>tempi dei capitoli</strong>, dunque:<br />
<code>$ nano dvdauthor.xml</code></p>
<p>e inseriamo questo:</p>
<pre>---8&#60;---
&#60;dvdauthor dest="dvd"&#62;
  &#60;vmgm /&#62;
   &#60;titleset&#62;
     &#60;titles&#62;
       &#60;pgc&#62;
         &#60;vob file="VIDEO.mpg" chapters="0,15:00,30:00,45:00,1:00:00"/&#62;
       &#60;/pgc&#62;
      &#60;/titles&#62;
   &#60;/titleset&#62;
 &#60;/dvdauthor&#62;
---8&#60;---</pre>
<p>Ovviamente <strong>i tempi</strong> (<code>0,15:00,30:00,45:00,1:00:00</code>) li cambierete <strong>in base a quelli dei capitoli del vostro video</strong>. In piu&#8217; se anziche&#8217; avere un DVD ne avessimo <strong>due</strong>, il testo del file <code>dvdauthor.xml</code> dovra&#8217; essere:</p>
<pre>---8&#60;---
&#60;dvdauthor dest="dvd"&#62;
  &#60;vmgm /&#62;
   &#60;titleset&#62;
     &#60;titles&#62;
       &#60;pgc&#62;
         &#60;vob file="VIDEO1.mpg" chapters="0,15:00,30:00,45:00,1:00:00"/&#62;
       &#60;/pgc&#62;
       &#60;pgc&#62;
         &#60;vob file="VIDEO2.mpg" chapters="0,15:00,30:00,45:00,1:00:00"/&#62;
       &#60;/pgc&#62;
     &#60;/titles&#62;
   &#60;/titleset&#62;
 &#60;/dvdauthor&#62;
---8&#60;---</pre>
<p>Adesso <strong>creiamo una directory</strong>:<br />
<code>$ mkdir dvd</code><br />
spostiamoci dentro il file <code>VIDEO.mpg</code> e <code>dvdauthor.xml</code>. Col terminale spostiamoci anche noi <strong>dentro la nuova directory</strong>:<br />
<code>$ cd dvd</code></p>
<p>Adesso diamo questo <strong>comando</strong>:<br />
<code>$ dvdauthor -x dvdauthor.xml</code><br />
cosi&#8217; all&#8217;interno della directory dvd verranno create <strong>due sottodirectory</strong>: <code>AUDIO_TS</code> e <code>VIDEO_TS</code>.</p>
<p><strong>Proviamo a vedere se tutto funziona</strong>:<br />
<code>$ mplayer dvd://home/UTENTE/directory/varie/dvd/VIDEO_TS/</code></p>
<p>Se tutto funziona correttamente <strong>possiamo masterizzare</strong>:<br />
<code>$ growisofs -dvd-video -Z /dev/dvd dvd/</code></p>
<p>Ovviamente al posto di <code>/dev/dvd</code> dovete inserire il <strong>percorso giusto</strong> del masterizzatore per DVD se non e&#8217; quello.</p>
<hr />
<p style="text-align:right;"><a href="#content" title="torna su">[^] torna su</a>&#160;&#124;&#160;<a href="http://postli.com/post?u=http://idl3.wordpress.com/2009/11/09/howto-convertire-avi-in-dvd/&#38;t=HowTo: convertire AVI in DVD" title="Post to Postli" style="color:blue;text-decoration:none;">post<span style="color:orange;">&#60;</span><span style="color:red;">li</span><span style="color:orange;">&#62;</span></a>&#160;&#124;&#160;<a href="http://www.wikio.it/vote?url=http://idl3.wordpress.com/2009/11/09/howto-convertire-avi-in-dvd/" target="_blank"><img src="http://www.wikio.it/shared/img/vote/wikio2.gif" border="0" /></a></p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Core i7 encoding performance]]></title>
<link>http://marshalleq.wordpress.com/2009/10/31/core-i7-encoding-performance/</link>
<pubDate>Fri, 30 Oct 2009 22:12:59 +0000</pubDate>
<dc:creator>marshalleq</dc:creator>
<guid>http://marshalleq.wordpress.com/2009/10/31/core-i7-encoding-performance/</guid>
<description><![CDATA[I got a new core i7 820 the other day.  After reading up on all the differences between the old core]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>I got a new core i7 820 the other day.  After reading up on all the differences between the old core i7 920 and the new 820 sporting the new LGA1156 socket architecture, getting thoroughly confused then realising no single CPU today stands out above the rest for all functions only specific functions, I was quite relieved to find out that the 820 (or more specifically any i7 sporting LGA1156) turned out to be the best option for encoding.</p>
<p>I added a Gigabyte GA-P55-UD5 board (only because ASUS are way behind with this socket at the moment &#8211; 1 motherboard compared to 9 Gigabyte boards) and some Kingston HyperX 1600MHz Ram.  Also after the first encode tipping the temp over 60 degrees C with the standard Intel Heatsink, went and got a<a title="Prolimatech Megahalem" href="http://www.computerlounge.co.nz/components/componentview.asp?partid=9794" target="_blank"> Prolimatech Megahalem</a> cooler with Fan which now brings down the encoding temp to an impressive 34 degrees C with all cores/threads running at 100% CPU.  (Apparently you can overclock this board to 4GHz quite comfortably with this cooler).  I&#8217;ve also heard from someone who builds overclocked machines to order that if you want a conservative overclock to go to 3.6GHz and you could render 24&#215;7 on all cores without any CPU life expectency issues or otherwise negative impact.</p>
<p>It&#8217;s also interesting how Intel now incorporates overclocking right into the CPU from the factory (oddly named after something out of an 80&#8217;s TV show &#8211; Turbo Boost) and it&#8217;s turned on by default.</p>
<p><strong>So how has it effected my encoding?</strong></p>
<p>Well, I am getting quite a few more frames per second on the first pass, something like moving from 20-25 to about 45 which is quite impressive.  However since the first pass doesn&#8217;t maximise the CPU cores and threads the second pass is even more interesting.  I&#8217;m actually seeing the second pass running at the same number of frames per second as the first pass.  Clearly the new i7 architecture and hyperthreading performs an awful lot better than the old Q9300 chip I had.</p>
<p>While not normally an overclocker, now that I have some awesome cooling attached, I am interested to see how many more fps I get if I take it up to 3.6Ghz. <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />   Might make encoding a 1080p file quite a bit more attractive <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>Will keep you posted.</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Howto install mencoder-1.0rc1 for Adult Video Script on CentOs]]></title>
<link>http://avsmods.wordpress.com/2009/10/29/howto-install-mencoder-1-0rc1-for-adult-video-script-on-centos/</link>
<pubDate>Thu, 29 Oct 2009 15:56:44 +0000</pubDate>
<dc:creator>avsmods</dc:creator>
<guid>http://avsmods.wordpress.com/2009/10/29/howto-install-mencoder-1-0rc1-for-adult-video-script-on-centos/</guid>
<description><![CDATA[Hi, UPDATE: this howto is outdated, i will write a new one today (mencoder is not compatible with h2]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>Hi,</p>
<p>UPDATE: this howto is outdated, i will write a new one today (mencoder is not compatible with h264 from RPMforge)!</p>
<p>Follow my previous howto to install the <a href="http://dag.wieers.com/rpm/" target="_blank">RPMForge</a> release for CentOs 5.x. Once installed run the following command:</p>
<pre class="brush: plain;">yum install libjpeg-devel libpng-devel libungif-devel pkgconfig libdv-devel speex-devel libmad-devel lame-devel xvidcore-devel x264-devel libmpcdec-devel faac-devel</pre>
<p>Once the process is finished download the following archives:</p>
<pre class="brush: plain;">wget -c http://www.mplayerhq.hu/MPlayer/releases/MPlayer-1.0rc1.tar.bz2
wget -c http://www.mplayerhq.hu/MPlayer/releases/codecs/all-20071007.tar.bz2</pre>
<p>Install the codecs:</p>
<pre class="brush: plain;">tar xjf all-20071007.tar.bz2
mkdir -p /usr/local/lib/codecs
cp -a all-20071007/* /usr/local/lib/codecs/
cd ..
</pre>
<p>Install mencoder and mplayer:</p>
<pre class="brush: plain;">tar xjf MPlayer-1.0rc1.tar.bz2
cd MPlayer-1.0rc1
TMPDIR=/root ./configure --prefix=/usr/local
make
make install</pre>
<p>Once finished mencoder will be installed in /usr/local/bin/mencoder, and mplayer in /usr/local/bin/mplayer. Mencoder is compatible with the latest Adult Video Script conversion line.</p>
<p>Thats it <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Creare video ]]></title>
<link>http://kerook.wordpress.com/2009/10/28/creare-video/</link>
<pubDate>Wed, 28 Oct 2009 19:05:34 +0000</pubDate>
<dc:creator>kerook</dc:creator>
<guid>http://kerook.wordpress.com/2009/10/28/creare-video/</guid>
<description><![CDATA[Dall&#8217;ultimo post facciamo derivare questo Ecco una possibile soluzione per fare dei video part]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>Dall&#8217;ultimo post facciamo derivare questo <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /><br />
Ecco una possibile soluzione per fare dei video partendo da immagine (ma volendo anche da video).<br />
Per questa ricetta abbiamo bisogno di alcuni ingredienti:<br />
le immagini di base;<br />
una canzone o comunque un&#8217;audio per il sottofondo (sempre se vogliamo mettercela/o);<br />
ffmpeg;<br />
bash;<br />
mencoder;<br />
un briciolo di pazianza <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> .</p>
<p>1) Innanzi tutto selezioniamo le immagini che vogliamo inserire nel video (mettiamole in una stessa cartella creata appositamente)  e dopo di che guardiamo quanto dura l&#8217;audio da mettere per sottofondo così da avere un&#8217;idea di quanto far venire lungo il video.<br />
2) Ora occorre fare in modo che vi sia un numero di immagini tali che il video non duri due secondi <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> . In linea di massima per ogni secondo vi sono 25 fotogrammi, quindi dobbiamo fare in modo che per ogni secondo in cui l&#8217;immagine deve esistere nel filmato. (Teoricamente siccome in questo caso il video è costituito da immagini basterebbe impostare che per secondo ci sia solo un&#8217;immagine, ma facciamo finta di niente per generalizzare il procedimento <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  )<br />
Ecco come fare:<br />
Apriamo il terminale e utilizziamo questo semplice script:</p>
<ul>
for i in {1..50}; do cp immagine.jpg 00$i.jpg; done</ul>
<p>dove al posto del 50 mettiamo il numero di immagini che ci occorrono.<br />
(attenzione, se nella stessa cartella abbiamo più immagini e ci occorrono tutte per il video è importante una volta copiata un&#8217;immagine modificare il comando mettendo al posto di 00$i.jpg un altro nome/numero (es. 11$i.jpg) in modo tale che non si sovrascrivano e a seconda dell&#8217;ordine che si vuole nel visualizzarle poi fare il modo che con il numero o con la parola con cui abbiamo rinominato, non ci si sposti prima delle immagini copiate in precedenza)<br />
3) Una volta copiate tutte le immagini dobbiamo unirle e lo facciamo subito utilizzando mencoder:</p>
<ul>
mencoder mf://*.jpg -mf w=640:h=480:fps=25:type=jpg -ovc lavc -lavcopts vcodec=mpeg4:mbd=2:trell -oac copy -o output.avi</ul>
<p>4) Un ultimo passaggio e ci siamo <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' />  Occore ora unire l&#8217;audio al video e con ffmpeg è facilissimo! Basta aprire il terminale e scriverci:</p>
<ul>
ffmpeg -i video_input.avi, audio_input.ogg video_e_audio_output.ogg</ul>
<p>E il nostro video è terminato <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /><br />
Alcune precisazioni <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /><br />
Volendo potremmo fare però due video divisi e poi volerli unire, anche per questo la soluzione è semplicissima: utilizziamo mencoder e al comando detto in precedenza al punto 3 sostituiamo il formato dei nostri video al .jpg che si trova all&#8217;inizio.</p>
<p>Ps. Noi però potremmo anche voler utilizzare spezzoni di video che abbiamo, come fare?<br />
Una soluzione, seppur non troppo veloce, è di utilizzare <a href="http://www.avidemux.org">avidemu</a>. Con questo programma possiamo selezionare la/e sequenza/e che vogliamo tramite l&#8217;apposito sistema del programma con i pulsantini A e B e poi salavarla in jpeg File&#8211;&#62; Salva&#8211;&#62; Salva selezione in immagini jpeg. Dopo di che possiamo seguire la procedura suddetta, magari riunendo già da subito questa sequenza in un video <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> x</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Unire immagini a formare un video]]></title>
<link>http://kerook.wordpress.com/2009/10/28/unire-immagini-a-formare-un-video/</link>
<pubDate>Wed, 28 Oct 2009 14:21:07 +0000</pubDate>
<dc:creator>kerook</dc:creator>
<guid>http://kerook.wordpress.com/2009/10/28/unire-immagini-a-formare-un-video/</guid>
<description><![CDATA[Ecco un modo semplice e veloce per unire delle immagini in modo da ottenere un video Basta utilizzar]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>Ecco un modo semplice e veloce per unire delle immagini in modo da ottenere un video <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /><br />
Basta utilizzare <a href="http://www.mplayerhq.hu/">mencoder</a>.<br />
Mettiamo tutte le immagini che vogliamo nel video in una stessa cartella e diamo da linea di comando:</p>
<ul>
 mencoder mf://*.jpg -mf w=640:h=480:fps=25:type=jpg -ovc lavc -lavcopts vcodec=mpeg4:mbd=2:trell -oac copy -o output.avi</ul>
<p>In questo caso vengono prese tutte le immagini .jpg e viene prodotto un filmato .avi<br />
Facile, no? <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[How to Install FFMPEG and all its modules FFMPEG-PHP]]></title>
<link>http://amshameer.wordpress.com/2009/10/28/how-to-install-ffmpeg-and-all-its-modules-ffmpeg-php/</link>
<pubDate>Wed, 28 Oct 2009 04:45:39 +0000</pubDate>
<dc:creator>Shameer A M</dc:creator>
<guid>http://amshameer.wordpress.com/2009/10/28/how-to-install-ffmpeg-and-all-its-modules-ffmpeg-php/</guid>
<description><![CDATA[Installing FFMPEG This guide will show you step by step how to install ffmpeg. First, you will want ]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p><strong>Installing FFMPEG</p>
<p></strong>This guide will show you step by step how to install ffmpeg. First, you will want to connect to your server&#8217;s shell as root. Once you are connected, you will</p>
<p>want to ensure that your /tmp partition is writeable so you can properly compile the modules. Use this command:</p>
<p><strong>mount -o defaults,remount,rw /tmp</p>
<p></strong>Next we will begin installing the individual components that FFMPEG needs to operate properly. First, we will want to download and install libogg using the</p>
<p><strong>following commands:</p>
<p>wget http://downloads.xiph.org/releases/ogg/libogg-1.1.3.tar.gz<br />
tar -xzvf libogg-1.1.3.tar.gz<br />
cd libogg-1.1.3<br />
./configure &#8211;prefix=/usr &#38;&#38; make<br />
make install<br />
cd ../<br />
rm -rf libogg*</p>
<p></strong>Next, we will be downloading and installing libvorbis:</p>
<p><strong><br />
wget http://downloads.xiph.org/releases/vorbis/libvorbis-1.2.0.tar.gz<br />
tar -xzvf libvorbis-1.2.0.tar.gz<br />
cd libvorbis-1.2.0<br />
./configure &#8211;prefix=/usr &#38;&#38; make<br />
make install<br />
cd ../<br />
rm -rf libvorbis*</p>
<p></strong>Next we will be downloading and installing LAME, which ffmpeg uses for handling the audio components. <strong></p>
<p>wget http://internap.dl.sourceforge.net/sourceforge/lame/lame-398.tar.gz<br />
tar -xzvf lame-398.tar.gz<br />
cd lame-398<br />
./configure &#8211;enable-shared &#8211;prefix=/usr<br />
make<br />
make install<br />
cd ..<br />
rm -rf lame*</p>
<p></strong>After LAME is installed, we can install ffmpeg itself by running these commands:</p>
<p><strong>wget http://ffmpeg.mplayerhq.hu/releases/ffmpeg-export-snapshot.tar.bz2<br />
tar -xjvf ffmpeg-export-snapshot.tar.bz2<br />
cd ffmpeg-export-XXXXXXX<br />
./configure &#8211;enable-libmp3lame &#8211;enable-libvorbis &#8211;enable-shared<br />
make clean &#38;&#38; make<br />
make install<br />
mkdir /usr/local/include/ffmpeg<br />
cp libavformat/avio.h /usr/local/include/ffmpeg<br />
cp libavformat/avformat.h /usr/local/include/ffmpeg<br />
cp libavcodec/avcodec.h /usr/local/include/ffmpeg<br />
cd ..<br />
rm -rf ffmpeg*</p>
<p></strong>The base ffmpeg component is now installed, but we arent done yet! Next up is ruby, which is required for ffmpeg to function properly. Install it with these <strong></p>
<p>commands:</p>
<p>wget ftp://ftp.ruby-lang.org/pub/ruby/1.8/ruby-1.8.7.tar.gz<br />
tar -xzvf ruby-1.8.7.tar.gz<br />
cd ruby-1.8.7<br />
./configure; make; make install;<br />
cd ..<br />
rm -rf ruby*</p>
<p>After ruby we need to install FLVTool2, which lets ffmpeg interact with flash based video files.</p>
<p>wget http://rubyforge.org/frs/download.php/17497/flvtool2-1.0.6.tgz<br />
tar -xzvf flvtool2-1.0.6.tgz<br />
cd flvtool2-1.0.6<br />
ruby setup.rb config<br />
ruby setup.rb setup<br />
ruby setup.rb install<br />
cd ..<br />
rm -rf flvtool2*</p>
<p></strong>Next we have to download and install the ffmpeg-php module. Do so with these commands:<strong></p>
<p>wget http://internap.dl.sourceforge.net/sourceforge/ffmpeg-php/ffmpeg-php-0.6.0.tbz2<br />
tar -xjvf ffmpeg-php-0.6.0.tbz2<br />
cd ffmpeg-php-0.6.0<br />
phpize<br />
./configure &#38;&#38; make<br />
make install<br />
cd ..<br />
rm -rf ffmpeg*</p>
<p>!!!<span style="color:#ff0000;">IMPORTANT</span>!!! There will be a PHP extensions folder output to the screen. Save it for later. !!!IMPORTANT!!!</p>
<p>!!!<span style="color:#ff0000;">IMPORTANT</span>!!!<br />
&#8220;/usr/local/lib/php/extensions/no-debug-non-zts-20060613/&#8221; &#60;&#8212; looks something like this !!!IMPORTANT!!!</p>
<p></strong>We have one more thing to install, thats thats the MPlayer/Mencoder application. Do so with these commands:<strong></p>
<p>wget http://www4.mplayerhq.hu/MPlayer/releases/MPlayer-1.0rc2.tar.bz2<br />
tar -xjvf MPlayer-1.0rc2.tar.bz2<br />
cd MPlayer-1.0rc2<br />
./configure &#38;&#38; make; make install<br />
cd ..<br />
rm -rf MPlayer*</p>
<p></strong>Now that we have all the required components installed, we need to change /tmp back to normal with this command:<strong></p>
<p>mount -o defaults,remount /tmp</p>
<p></strong>After that, we need to open up the global php.ini file ( /usr/local/lib/php.ini ) so we can change a couple of settings. You can use whatever text editor you</p>
<p>like, but I recommend nano:<strong></p>
<p>nano /usr/local/lib/php.ini</p>
<p></strong>You will want to scroll down until you locate these lines:<strong></p>
<p>; Directory in which the loadable extensions (modules) reside.<br />
extension_dir = &#8220;/usr/local/lib/php/extensions/no-debug-non-zts-20060613&#8243;</p>
<p></strong><br />
You will want to replace the extensions_dir value with the extensions folder that we saved earlier. <strong></p>
<p>!!!<span style="color:#ff0000;">IMPORTANT</span>!!!<br />
</strong>If you are using any other custom .so modules, you will want to copy them into this folder. !!!<span style="color:#ff0000;">IMPORTANT</span>!!!<strong></p>
<p></strong>Scroll down to the &#8220;Dynamic Extensions&#8221; section, and add this line:<strong></p>
<p></strong><span style="color:#ff00ff;"><strong>extension = ffmpeg.so</p>
<p></strong></span><span style="color:#000000;"><strong><br />
</strong></span><span style="color:#000000;">Save your work, ( ctrl+O if you are using nano ) and exit. FFMPEG is now installed and ready for use.</p>
<p></span></p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[DeVeDe Error with OpenShot]]></title>
<link>http://byrd740.wordpress.com/2009/10/22/devede-error-with-openshot/</link>
<pubDate>Thu, 22 Oct 2009 13:12:34 +0000</pubDate>
<dc:creator>byrd740</dc:creator>
<guid>http://byrd740.wordpress.com/2009/10/22/devede-error-with-openshot/</guid>
<description><![CDATA[Yesterday I decided to install DeVeDe on my HP desktop.  I had it installed on Ubuntu 9.04 with no p]]></description>
<content:encoded><![CDATA[Yesterday I decided to install DeVeDe on my HP desktop.  I had it installed on Ubuntu 9.04 with no p]]></content:encoded>
</item>
<item>
<title><![CDATA[A Cool Linux Thing, Actually, A Couple of Things]]></title>
<link>http://billhensley.wordpress.com/2009/10/19/a-cool-linux-thing-actually-a-couple/</link>
<pubDate>Mon, 19 Oct 2009 05:25:11 +0000</pubDate>
<dc:creator>Bill Hensley</dc:creator>
<guid>http://billhensley.wordpress.com/2009/10/19/a-cool-linux-thing-actually-a-couple/</guid>
<description><![CDATA[I got an AVI file from a camera today, it was 235MB in size. I tried VideoLAN, it would transcode fr]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>I got an AVI file from a camera today, it was 235MB in size.  I tried VideoLAN, it would transcode from a file to a file, but it would not transcode both the video and audio (audio only).  I couldn&#8217;t find a tool on Windows to convert the file to MPEG format, but there were a couple posts on a Linux board referring to a tool in Linux called Media Encoder, or mencoder.  The posts both said that if you had Linux Media Player you had Encoder also.</p>
<p>I switched to my Fedora 10 instatllation, and found it did not have Media Player installed.  A quick &#8220;yum install mplayer&#8221; fixed that.  But the command line mencoder didn&#8217;t work.  I did a locate on the disk, not there.  So I went back to the command prompt and &#8220;yum install mencoder&#8221; and then I was converting the 236MB AVI to a 35MB MPEG that looked and sounded just as good.</p>
<p>Since Linux mounted my other XP partition just fine, i copied the file to that environment.  At first, I wanted to send the converted file to my very cute and XP using roommate, but I realized that I really wanted to upload it to the HTTP server I run on the school computer.</p>
<p>While I was playing around with the Windows Network list on the &#8220;Connect to Server&#8221; function (off the Gnome &#8220;Places&#8221; menu item), I noticed it had options for connecting to an FTP server, in both anonymous and authenticated modes.  &#8220;What the heck&#8221;, thought I, and specified the information for my server at St. John&#8217;s.</p>
<p>Now, FTP is pretty common, but in this case, instead of a command window, or a dedicated drag-and-drop GUI, a mount point appeared on my Gnome Desktop that was labelled &#8220;68.15.100.56&#8243; (the St. John&#8217;s IP address).  I double-clicked it, and it opened up a file window, just like I could see for my local filesystem!  Cool, thought I.  </p>
<p>I drilled down to the root of the webserver document directory, and there were the files I expected.  I grabbed the converted MPEG file from the Gnome Desktop and dragged it to the opened webserver directory, and a couple minutes later, the file was on the St. John&#8217;s webserver!</p>
<p>The FTP icon had an Unmount item when it was right-clicked, and when I selected it the FTP session was logged off just fine.  That was about the slickest FTP I&#8217;ve ever done.</p>
<p>So, between mencoder to convert the media file, and mplayer to verify the file was converted correctly, and finally the very cool FTP function, Linux rules!</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[MencoderProper and x64]]></title>
<link>http://mynetworkproject.wordpress.com/2009/10/16/mencoderproper-and-x64/</link>
<pubDate>Fri, 16 Oct 2009 05:20:00 +0000</pubDate>
<dc:creator>Andres</dc:creator>
<guid>http://mynetworkproject.wordpress.com/2009/10/16/mencoderproper-and-x64/</guid>
<description><![CDATA[I was just informed by one of my readers that they were able to get MencoderProper working in an x64]]></description>
<content:encoded><![CDATA[I was just informed by one of my readers that they were able to get MencoderProper working in an x64]]></content:encoded>
</item>
<item>
<title><![CDATA[#1 - (s)Collegamenti]]></title>
<link>http://idl3.wordpress.com/2009/10/10/1-scollegamenti/</link>
<pubDate>Sat, 10 Oct 2009 07:28:06 +0000</pubDate>
<dc:creator>idl3</dc:creator>
<guid>http://idl3.wordpress.com/2009/10/10/1-scollegamenti/</guid>
<description><![CDATA[Controllare la posta in arrivo su GMail da riga di comando $ curl -u USERNAME --silent "https://mail]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p><strong>Controllare la posta in arrivo su GMail da riga di comando</strong><br />
<code>$ curl -u USERNAME --silent "https://mail.google.com/mail/feed/atom" &#124; perl -ne 'print "\t" if //; print "$2\n" if /(.*)/;'</code><br />
<a href="http://linuxiana.blogspot.com/2009/10/controllare-la-posta-in-arrivo-su-gmail.html">Continua a leggere&#8230;</a></p>
<p><strong>Aggiungere sottotitoli ad un file video</strong><br />
<code>$ mencoder -ovc xvid -xvidencopts fixed_quant=3 -oac copy -sub filesottotitoli.srt -subfont-text-scale 4 -o filevideoconsottotitoli.avi filevideosenzasottotitoli.avi</code><br />
<a href="http://www.pietrodigiorgio.it/1075/sottotitoli-perfetti-con-mencoder/">Continua a leggere&#8230;</a></p>
<p><strong>wget + Google Image Ripper (script Bash)</strong><br />
Un grabber in bash che usa wget e GIR.<br />
<a href="http://niubbo.blogspot.com/2009/10/wget-google-image-ripper-script-bash.html">Continua a leggere&#8230;</a></p>
<p><strong>How to Set Up a High Performance Cluster (HPC) Using Debian Lenny and Kerrighed</strong><br />
Cluster controller or Head node: Debian Lenny or any other distribution. The single image passed on to the nodes will be Debian Lenny though.<br />
<a href="http://www.debianadmin.com/how-to-set-up-a-high-performance-cluster-hpc-using-debian-lenny-and-kerrighed.html">Continua a leggere&#8230;</a></p>
<p><strong>Make the Minimalist, Fading Google Homepage Your Default</strong></p>
<pre><tt>javascript<font color="#990000">:</font><font color="#009900">void</font><font color="#990000">(</font>document<font color="#990000">.</font>cookie<font color="#990000">=</font><font color="#FF0000">"PREF=ID=abac7a90f5a3784b:LD=en:NR=10:TM=1254990196:LM=1254990236:S=uB6F4jDnMP_DuxtT;path=/; domain=.google.com"</font><font color="#990000">);</font></tt></pre>
<p><a href="http://lifehacker.com/5377098/make-the-minimalist-fading-google-homepage-your-default">Continua a leggere&#8230;</a></p>
<hr />
<p style="text-align:right;"><a href="#content" title="torna su">[^] torna su</a>&#160;&#124;&#160;<a href="http://postli.com/post?u=http://idl3.wordpress.com/2009/10/10/1-scollegamenti/&#38;t=1 - (s)Collegamenti" title="Post to Postli" style="color:blue;text-decoration:none;">post<span style="color:orange;">&#60;</span><span style="color:red;">li</span><span style="color:orange;">&#62;</span></a>&#160;&#124;&#160;<a href="http://www.wikio.it/vote?url=http://idl3.wordpress.com/2009/10/10/1-scollegamenti/" target="_blank"><img src="http://www.wikio.it/shared/img/vote/wikio2.gif" border="0" /></a></p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Converting Images (png's and jpeg's) to movie (avi)]]></title>
<link>http://digitalvectorz.wordpress.com/2009/10/06/converting-images-pngs-and-jpegs-to-movie-avi/</link>
<pubDate>Tue, 06 Oct 2009 04:24:28 +0000</pubDate>
<dc:creator>digitalvectorz</dc:creator>
<guid>http://digitalvectorz.wordpress.com/2009/10/06/converting-images-pngs-and-jpegs-to-movie-avi/</guid>
<description><![CDATA[http://www.patrickmin.com/linux/tip.php?name=images_to_movie]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>http://www.patrickmin.com/linux/tip.php?name=images_to_movie</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Hello world!]]></title>
<link>http://doworkeasier.wordpress.com/2009/09/28/hello-world/</link>
<pubDate>Tue, 29 Sep 2009 07:42:39 +0000</pubDate>
<dc:creator>switchrodeo720</dc:creator>
<guid>http://doworkeasier.wordpress.com/2009/09/28/hello-world/</guid>
<description><![CDATA[I guess this is my first post. It&#8217;s a funny coincidence that I&#8217;m starting a blog about m]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>I guess this is my first post. It&#8217;s a funny coincidence that I&#8217;m starting a blog about my learning about programming and the default first post made on all WordPress blogs is titled Hello world!</p>
<p>I&#8217;m new to programming. My interest in programming started from a couple of places simultaneously that I won&#8217;t go into detail about. My motivation to actually start learning came from the need to motivate everyday desktop computing tasks at home. These tasks included file name management. At that time I was just getting familiar with how to properly use the command-line on my Ubuntu box, so I already knew many of the commands I would use to accomplish said tasks. My logical next step was to start with shell scripting in bash.</p>
<p>I learned the basics by watching a few video lessons I found on ThePirateBay.org (it&#8217;s not only used for downloading copyrighted content).</p>
<p>The first complete script I wrote was used for combining video files. If you download video from the webs you&#8217;ll no doubt know that many times large videos are broken in to two or more avi files. In my opinion, this is really annoying. I&#8217;d much rather have only one file to play, name, and keep track of. My day to day OS is Ubuntu Linux, which uses the Gnome desktop environment. One of my favorite features is &#8220;Nautilus Scripts&#8221;. This places custom written scripts in the right click menu, in this case, allowing me to select two or more video files, right click, select my new script and wait for the merging of the selected video files to complete.</p>
<p>The only dependency for this script is &#8216;mencoder&#8217; if you&#8217;re using linux. I you are using Windows, sorry. You&#8217;ll just have to download some bloated freeware filled with spyware. Anyway, here&#8217;s the script:</p>
<p>#####################################################</p>
<p>#!/bin/bash</p>
<p># Combines two or more avi files and prompts for the file name.</p>
<p>name=`zenity &#8211;entry &#8211;title=&#8221;Type the file name&#8221;`</p>
<p>cd &#8220;$NAUTILUS_SCRIPT_CURRENT_URI&#8221;</p>
<p>if [ "$NAUTILUS_SCRIPT_SELECTED_FILE_PATHS" = "" ]<br />
then<br />
zenity &#8211;warning &#8211;text=&#8221;No files have been selected&#8221;<br />
else<br />
cat &#8220;$NAUTILUS_SCRIPT_SELECTED_FILE_PATHS&#8221; &#62; &#8220;$name.temp.avi&#8221;;<br />
mencoder -forceidx -oac copy -ovc copy &#8220;$name.temp.avi&#8221; -o &#8220;$name.avi&#8221;;<br />
rm &#8220;$name.temp.avi&#8221;;<br />
rm &#8220;$NAUTILUS_SCRIPT_SELECTED_FILE_PATHS&#8221;;<br />
fi</p>
<p>#####################################################</p>
<p>It currently doesn&#8217;t work if there are spaces in the file path, but I will fix that eventually.</p>
<p>Feel free to use this or improve it as you see necessary.</p>
<p>Enjoy.</p>
<div id="_mcePaste" style="overflow:hidden;position:absolute;left:-10000px;top:583px;width:1px;height:1px;">##########################################################################################################</div>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[HowTo: tagliare parti di video con mplayer]]></title>
<link>http://idl3.wordpress.com/2009/09/26/howto-tagliare-parti-di-video-con-mplayer/</link>
<pubDate>Sat, 26 Sep 2009 09:17:47 +0000</pubDate>
<dc:creator>idl3</dc:creator>
<guid>http://idl3.wordpress.com/2009/09/26/howto-tagliare-parti-di-video-con-mplayer/</guid>
<description><![CDATA[Come ho gia&#8217; avuto modo di scrivere mplayer/mencoder e&#8217; uno strumento potente, si posson]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>Come ho gia&#8217; avuto modo di scrivere <strong>mplayer/mencoder</strong> e&#8217; uno strumento potente, si possono fare tante cose, <a href="http://www2.mplayerhq.hu/DOCS/HTML-single/it/MPlayer.html">leggere la guida</a> di questo strumento e&#8217; cosa buona e giusta (ma soprattutto utile). Vediamo quindi come <strong>tagliare parti di un video</strong> in modo semplice, senza doverci segnare tempi di inizio e fine delle scene da tagliare e calcolare la differenza (come <a href="http://idl3.wordpress.com/2009/09/25/howto-tagliare-video-e-unire-audio-e-video-con-ffmpeg-e-mencoder/">succede con ffmpeg</a>).</p>
<p><div id="attachment_136" class="wp-caption alignleft" style="width: 160px"><img src="http://idl3.wordpress.com/files/2009/09/ditanaso.jpg?w=150" alt="Il 96% delle persone si mette le dita nel naso in media 4 volte al giorno. Il 7% della popolazione ha la rinotillexomania e lo fa piu&#39; di 20 volte al giorno" title="Dita nel naso" width="150" height="102" class="size-thumbnail wp-image-136" /><p class="wp-caption-text">Il 96% delle persone si mette le dita nel naso in media 4 volte al giorno. Il 7% della popolazione ha la rinotillexomania e lo fa piu' di 20 volte al giorno</p></div>Semplicemente <strong>guardando un video con mplayer</strong> possiamo marcare (con una semplice pressione di un tasto) le parti da <strong>tagliare</strong> (o rendere <strong>mute</strong>). Lo si puo&#8217; fare grazie alle <strong>Edit Decision Lists (EDL)</strong> [liste di decisione di modifica <em>NdI</em>], come <a href="http://www.mplayerhq.hu/DOCS/HTML-single/it/MPlayer.html#edl">dice</a> la guida:</p>
<blockquote><p>Il sistema della lista di decisione di modifica (EDL) ti permette di saltare o di silenziare automaticamente alcune parti dei video durante la riproduzione, basandosi su un file di configurazione EDL specifico per il filmato.</p></blockquote>
<p>Per utilizzarla occorre <strong>lanciarla quando si apre il video</strong> che ci interessa con mplayer:<br />
<code>$ mplayer -edlout lista.edl video.avi</code><br />
Il file <strong>lista.edl</strong> e&#8217; un file (per ora vuoto) che diciamo di creare all&#8217;edl per metterci le sue cose (i tempi di inizio e fine degli spezzoni che gli indicheremo e le azioni da fare).</p>
<p>Ora non ci resta che <strong>guardare il video</strong> (se sappiamo piu&#8217; o meno dove si trova la scena da tagliare magari usiamo la freccia destra o quella verso l&#8217;alto per andarci in fretta) e <strong>premere</strong> il tasto <strong>i</strong> della nostra tastiera quando <strong>inizia</strong> la scena da tagliare. <strong>Ripremiamo</strong> sempre il tasto <strong>i</strong> quando <strong>finisce</strong> la scena da tagliare. <strong>Ripetiamo</strong> questa &#8220;<em>difficile</em>&#8221; operazione (calca i&#8230; calca i) per tutte le altre scene da tagliare (se ce ne sono altre).</p>
<p>Ora il nostro file <strong>lista.edl</strong> e&#8217; bello pronto e <strong>utilizzabile in due modi</strong>. Possiamo sia <strong>guardarci</strong> il video usando la lista per saltare automaticamente le scene da tagliare:<br />
<code>$ mplayer -edl lista.edl video.avi</code><br />
Sia <strong>applicare</strong> i tagli al video in modo permanente:<br />
<code>$ mencoder -oac copy -ovc copy -edl lista.edl video.avi -o videotagliato.avi</code><br />
Ed ecco pronto il nostro video senza le <strong>scene noiose</strong>, o senza la <strong>pubblicita&#8217;</strong> o comunque senza le scene che abbiamo voluto tagliare. Pensate al vostro video fatto in casa dove vi vedete voi con le <strong>dita (tutte) nel naso</strong>, <em>[i] [dita nel naso] [i]</em> ed ecco <strong>salva la vostra dignita&#8217;</strong>.</p>
<p>Puo&#8217; anche succedere che non vogliate togliere lo spezzone del video, ma solo <strong>renderlo muto</strong>. Riprendendo l&#8217;esempio di prima, dopo esservi messi le dita nel naso avete pure <strong>fatto una sonora <a href="http://old.demauroparavia.it/104586">scoreggia</a></strong>. Ma nello stesso momento la telecamera stava riprendendo qualcosa di importante. Allora <strong>non potete tagliare il video</strong>, ma neppure mantenerlo inalterato. Basta <strong>togliere il sonoro</strong>. Ma come? Il solito metodo <em>[i] [scoreggia] [i]</em> va benissimo. Dobbiamo solo <strong>aprire il file lista.edl</strong> per modificare un numeretto. Serve pero&#8217; che sappiate piu&#8217; o meno <strong>a che minuto si trova lo spezzone</strong> da rendere muto (per saperlo basta che mentre lo guardate con mplayer premiate il tasto <strong>o</strong>).</p>
<p>Apriamo ora il terminale, spostiamoci nella directory contenete il file della lista e apriamolo:<br />
<code>$ nano lista.edl</code><br />
Vedremo una cosa del genere (le tre colonne indicano rispettivamente <em>tempo di inizio &#8211; tempo di fine &#8211; azione</em>):</p>
<pre>5.3   7.1    0
15    16.7   0
420   422    0</pre>
<p>Poniamo che <strong>dal tempo 5.3 al tempo 7.1</strong> e&#8217; lo spezzone nel quale (nel nostro esempio) avevate le <strong>dita nel naso</strong>, mentre <strong>dal tempo 15 al tempo 16.7</strong> (sempre da esempio) c&#8217;era <strong>la scoreggia</strong>. Dunque <strong>lasciamo 0 nelle dita nel naso</strong> (0 indica <strong>taglia</strong>) e <strong>sostituiamo 0 con 1 nella scoreggia</strong> (1 indica <strong>silenzia</strong>). La nostra <strong>lista modificata</strong> sara&#8217; quindi cosi&#8217;:</p>
<pre>5.3   7.1    0
15    16.7   1
420   422    0</pre>
<p>Avendo una lista che e&#8217; un <strong>semplice file di testo</strong>, diventa semplicissimo <strong>correggere eventuali errori</strong>. Se l&#8217;ultimo spezzone indicato nella lista, quello che inizia al tempo <strong>420</strong>, non lo volevate tagliare, ma chissa&#8217; perche&#8217; guardando il video avete premuto il tasto i, basta <strong>cancellare quella riga</strong>, ottenendo:</p>
<pre>5.3   7.1    0
15    16.7   1</pre>
<p>Ora e&#8217; pronta la nostra lista? Se la risposta e&#8217; si possiamo <strong>guardarci il video</strong> con le modifiche:<br />
<code>$ mplayer -edl lista.edl video.avi</code><br />
O <strong>applicarle in modo permanente</strong>:<br />
<code>$ mencoder -oac copy -ovc copy -edl lista.edl video.avi -o videotagliato.avi</code></p>
<p>Se per caso non vi piace la <strong>codifica video e/o audio</strong> del vostro file video, potete modificarla mentre applicate le modifiche dei tagli. Basta non dare come codec audio e/o video l&#8217;opzione <strong><em>copy</em></strong> (lascia invariato) ma sceglierne un&#8217;altra. Ad esempio, col comando (si, lo so, e&#8217; lungo):<br />
<code>$ mencoder -of lavf -oac mp3lame -lameopts abr:br=56 -srate 22050 -ovc lavc -lavcopts vcodec=flv:vbitrate=500:mbd=2:mv0:trell:v4mv:cbp:last_pred=3<br />
 -edl lista.edl video.avi -o videotagliato.flv</code><br />
codificheremo il nostro video avi in <strong>formato Macromedia Flash</strong>. Per altre <a href="http://www2.mplayerhq.hu/DOCS/HTML-single/it/MPlayer.html#menc-feat-selecting-codec">codifiche audio e video</a> consultate la guida.</p>
<hr />
<p style="text-align:right;"><a href="#content" title="torna su">[^] torna su</a>&#160;&#124;&#160;<a href="http://postli.com/post?u=http://idl3.wordpress.com/2009/09/26/howto-tagliare-parti-di-video-con-mplayer/&#38;t=HowTo: tagliare parti di video con mplayer" title="Post to Postli" style="color:blue;text-decoration:none;">post<span style="color:orange;">&#60;</span><span style="color:red;">li</span><span style="color:orange;">&#62;</span></a>&#160;&#124;&#160;<a href="http://www.wikio.it/vote?url=http://idl3.wordpress.com/2009/09/26/howto-tagliare-parti-di-video-con-mplayer/" target="_blank"><img src="http://www.wikio.it/shared/img/vote/wikio2.gif" border="0" /></a></p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[HowTo: creare un video con le foto usando mencoder e ffmpeg]]></title>
<link>http://idl3.wordpress.com/2009/09/25/howto-creare-un-video-con-le-foto-usando-mencoder-e-ffmpeg/</link>
<pubDate>Fri, 25 Sep 2009 13:12:10 +0000</pubDate>
<dc:creator>idl3</dc:creator>
<guid>http://idl3.wordpress.com/2009/09/25/howto-creare-un-video-con-le-foto-usando-mencoder-e-ffmpeg/</guid>
<description><![CDATA[Come vi avevo promesso vedremo ora come creare un video con le foto (o altre immagini) inserendo anc]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>Come vi <a href="http://idl3.wordpress.com/2009/09/25/howto-tagliare-video-e-unire-audio-e-video-con-ffmpeg-e-mencoder/">avevo promesso</a> vedremo ora come <strong>creare un video con le foto</strong> (o altre immagini) inserendo anche l&#8217;<strong>audio</strong>. Lo faro&#8217; usando due programmi, <strong>mencoder</strong> (per creare il video dalle foto) e <strong>ffmpeg</strong> (per inserire l&#8217;audio al video).</p>
<div id="attachment_89" class="wp-caption alignleft" style="width: 160px"><img src="http://idl3.wordpress.com/files/2009/09/sequenza-eclissi.jpg?w=150" alt="Sequenza di foto di un&#39;eclissi" title="Eclissi" width="150" height="75" class="size-thumbnail wp-image-89" /><p class="wp-caption-text">Sequenza di foto di un'eclissi</p></div>Creiamo una directory e mettiamoci dentro la <strong>sequenza di foto (o immagini)</strong> che vogliamo utilizzare, ricordandoci che l&#8217;ordine alfabetico (o numerico) sara&#8217; anche l&#8217;ordine nel quale vedremo le immagini scorrere in sequenza nel video. Dunque rinominate le immagini a seconda dell&#8217;ordine che preferite. Fatto questo apriamo un terminale e spostiamoci nella directory che contiene le nostre immagini, diamo il seguente comando (se le immagini non sono in formato jpg sostituite nel comando il formato giusto):<br />
<code>$ mencoder 'mf://*.jpg' -mf type=jpg:w=300:h=200:fps=2 -ovc copy -oac copy -o video.avi</code><br />
Otteniamo cosi&#8217; un file <strong>Motion JPEG</strong> (MJPEG). Se anziche&#8217; file jpg avessimo avuto file png avremmo dovuto scrivere:<br />
<code>$ mencoder 'mf://*.png' -mf type=png:w=300:h=200:fps=2 -ovc copy -oac copy -o video.avi</code><br />
ottenendo in questo caso un file <strong>Motion PNG</strong> (MPNG).<br />
Se volessimo un semplice file video <strong>MPEG-4</strong> dovremmo scrivere:<br />
<code>$ mencoder 'mf://*.jpg' -mf type=jpg:w=300:h=200:fps=2 -ovc lavc -lavcopts vcodec=mpeg4:mbd=2:trell -oac copy -o video.avi</code></p>
<p>Stiamo dicendo a <strong>mencoder</strong> di creare un elenco di tutti i file jpg, e poi di usare queste immagini (di altezza 200 e larghezza 300 pixel [<a href="#cuvclfumef1">1</a>]<a name="cuvclfumefa">)</a> mettendone <strong>2 al secondo</strong> (<em>fps</em>) (mettete pure il tempo che piu&#8217; vi soddisfa), lasciando inalterata la codifica audio e video (o nel terzo caso usando il codec video mpeg4) e restituendo il tutto nel file video.avi.</p>
<p>Adesso apriamo il file <strong>video.avi</strong> e controlliamo se e&#8217; tutto a posto, <strong>controlliamo anche la durata</strong>. Prendiamo ora un file <strong>audio</strong>, controlliamo se la sua durata coincide con quella del file video e diamo il seguente comando da terminale:<br />
<code>$ ffmpeg -i video.avi -i audio.mp3 -map 0:0 -map 1:0 videoconaudio.avi</code><br />
Se vi restituisce qualche errore, <strong>specificate i code audio e video</strong>, ad esempio:<br />
<code>$ ffmpeg -i video.avi -i audio.mp3 -map 0:0 -map 1:0 -acodec libmp3lame -vcodec mpeg4 videoconaudio.avi</code></p>
<p>Finito, adesso abbiamo la nostra &#8220;bella&#8221; <strong>sequenza di immagini con tanto di musica</strong> in sottofondo. Le potenzialita&#8217; sono ampie.<br />
<span style='text-align:center; display: block;'><object width='425' height='350'><param name='movie' value='http://www.youtube.com/v/lrPxhtlTl30&#038;rel=1&#038;fs=1&#038;showsearch=0&#038;hd=0' /><param name='allowfullscreen' value='true' /><param name='wmode' value='transparent' /><embed src='http://www.youtube.com/v/lrPxhtlTl30&#038;rel=1&#038;fs=1&#038;showsearch=0&#038;hd=0' type='application/x-shockwave-flash' allowfullscreen='true' width='425' height='350' wmode='transparent'></embed></object></span></p>
<p>[<a name="cuvclfumef1">1</a>] State attenti nel fissare altezza e larghezza, questi valori devono essere un intero multiplo di 4 (limitazione del formato grezzo RAW RGB AVI). [<a href="#cuvclfumefa">^</a>]
<hr />
<p style="text-align:right;"><a href="#content" title="torna su">[^] torna su</a>&#160;&#124;&#160;<a href="http://postli.com/post?u=http://idl3.wordpress.com/2009/09/25/howto-creare-un-video-con-le-foto-usando-mencoder-e-ffmpeg/&#38;t=HowTo: creare un video con le foto usando mencoder e ffmpeg" title="Post to Postli" style="color:blue;text-decoration:none;">post<span style="color:orange;">&#60;</span><span style="color:red;">li</span><span style="color:orange;">&#62;</span></a>&#160;&#124;&#160;<a href="http://www.wikio.it/vote?url=http://idl3.wordpress.com/2009/09/25/howto-creare-un-video-con-le-foto-usando-mencoder-e-ffmpeg/" target="_blank"><img src="http://www.wikio.it/shared/img/vote/wikio2.gif" border="0" /></a></p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[HowTo: tagliare video e unire audio e video con ffmpeg e mencoder]]></title>
<link>http://idl3.wordpress.com/2009/09/25/howto-tagliare-video-e-unire-audio-e-video-con-ffmpeg-e-mencoder/</link>
<pubDate>Fri, 25 Sep 2009 12:30:43 +0000</pubDate>
<dc:creator>idl3</dc:creator>
<guid>http://idl3.wordpress.com/2009/09/25/howto-tagliare-video-e-unire-audio-e-video-con-ffmpeg-e-mencoder/</guid>
<description><![CDATA[Dopo aver visto come convertire in formato ogg file audio e video, adesso vedremo come tagliare un f]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>Dopo aver visto come <a href="http://idl3.wordpress.com/2009/09/25/howto-convertire-in-formato-ogg-con-ffmpeg/">convertire in formato ogg file audio e video</a>, adesso vedremo come <strong>tagliare un file video</strong> e come <strong>unire un file audio e un file video</strong> in modo da avere un nuovo file. E&#8217; piu&#8217; difficile da dire che da fare, i comandi sono semplici. Vediamoli dunque.</p>
<div id="attachment_81" class="wp-caption alignleft" style="width: 160px"><img class="size-thumbnail wp-image-81" title="Edward mani di forbice" src="http://idl3.wordpress.com/files/2009/09/mani-forbice.jpg?w=150" alt="Johnny Depp mentre aiuta Tim Burdon a tagliare alcune scene del film" width="150" height="82" /><p class="wp-caption-text">Johnny Depp mentre aiuta Tim Burdon a tagliare alcune scene del film</p></div>
<p>Poniamo che abbiate un lungo file video, non vi interessa tutto, ma solo una parte. La prima cosa da fare e&#8217; segnarvi da qualche parte l&#8217;ora, il minuto e il secondo di <strong>inizio</strong> e di <strong>fine</strong> dello spezzone che vi interessa. Poniamo inizi a 12 minuti e 34 secondi e finisca a 26 minuti e 56 secondi. Significa che <strong>la durata</strong> dello spezzone e&#8217; di 14 minuti e 22 secondi.</p>
<p>Diamo dunque il seguente comando da terminale:<br />
<code>$ ffmpeg -i videoinput.avi --ss 00:12:34 -t 00:14:22 videooutput.avi</code><br />
Stiamo dicendo a ffmpeg di usare il file video videoinput.avi, prenderlo a partire al tempo 00:12:34, per una durata di 00:14:22 e restituirci il file videooutput.avi.</p>
<p>Possiamo utilizzare il medesimo procedimento per <strong>dividere</strong> un file video lungo in piu&#8217; file video piu&#8217; piccoli, cosa che si rivela indispensabile se volete ad esempio mettere un video di mezz&#8217;ora su <a href="http://it.youtube.com/">youtube</a> (che per account normali non prende video piu&#8217; lunghi di <strong>dieci minuti</strong>). Mettiamo che il file duri <strong>34 minuti e 45 secondi</strong>, ecco come fare:<br />
<code>$ ffmpeg -i videoinput.avi --ss 00:00:00 -t 00:10:00 videooutput1.avi</code><br />
<code>$ ffmpeg -i videoinput.avi --ss 00:10:00 -t 00:10:00 videooutput2.avi</code><br />
<code>$ ffmpeg -i videoinput.avi --ss 00:20:00 -t 00:10:00 videooutput3.avi</code><br />
<code>$ ffmpeg -i videoinput.avi --ss 00:30:00 -t 00:04:45 videooutput4.avi</code><br />
Avrete <strong>quattro file</strong> video che potrete tranquillamente mettere su youtube.</p>
<p>Una cosa simile la potete ottenere anche con <strong>mencoder</strong>, in questo caso, se ad esempio volete dividere a meta&#8217; <strong>un video di 2 ore</strong>:<br />
<code>$ mencoder -endpos 01:00:00.00 -ovc copy -oac copy film.avi -o primotempo.avi</code><br />
<code>$ mencoder -ss 01:00:00.00 -ovc copy -oac copy film.avi -o secondotempo.avi</code><br />
Mettete il tempo hh:mm:ss.ms che volete, <strong>devono coincidere</strong> nei due comandi se volete che il secondo inizi dove finisce il primo. Se invece volessimo dividere come nel caso di ffmpeg un file di 34 minuti e 45 secondi in quattro parti allora:<br />
<code>$ mencoder -endpos 00:10:00.00 -ovc copy -oac copy film.avi -o primotempo.avi</code><br />
<code>$ mencoder -ss 00:10:00.00 -endpos 00:20:00.00 -ovc copy -oac copy film.avi -o secondotempo.avi</code><br />
<code>$ mencoder -ss 00:20:00.00 -endpos 00:30:00.00 -ovc copy -oac copy film.avi -o terzotempo.avi</code><br />
<code>$ mencoder -ss 00:30:00.00 -ovc copy -oac copy film.avi -o quartotempo.avi</code><br />
Ottenendo cosi&#8217; il medesimo risultato di ffmpeg.</p>
<p>Se volete riunire i video parziali in un unico video dovete dare quest&#8217;unico comando:<br />
<code>$ mencoder -ovc copy -oac copy primotempo.avi secondotempo.avi terzotempo.avi quartotempo.avi -o film.avi</code><br />
Potete anche ricodificare audio e video per sicurezza:<br />
<code>$ mencoder -ovc xvid -oac mp3lame primotempo.avi secondotempo.avi terzotempo.avi quartotempo.avi -o film.avi</code><br />
Possiamo anche usare <strong>altri codec</strong> sia audio sia video, <a href="http://www.mplayerhq.hu/DOCS/HTML-single/it/MPlayer.html#menc-feat-selecting-codec">qui</a> trovate un elenco.</p>
<p>Se invece avete un <strong>file video senza audio</strong> (o con audio che volete sostituire) e avete un <strong>file audio</strong> che volete unire al video, ci viene in aiuto sempre <strong>ffmpeg</strong>:<br />
<code>$ ffmpeg -i videoinput.avi -i audioinput.mp3 -map 0:0 -map 1:0 videooutput.avi</code><br />
State dicendo a ffmpeg di prendere il file video videoinput.avi e il file audio audioinput.mp3, usare il primo nella posizione 0:0 e il secondo 1:0 (map indica il &#8220;mappaggio&#8221;) creando cosi&#8217; il file video videooutput.avi. Se la lunghezza del file video non coincide con quella del file audio prima di dare il comando dovete tagliare il file piu&#8217; lungo in modo che coincidano (per farlo usate il comando che abbiamo visto all&#8217;inizio).<br />
S vogliamo specificare i codec audio e video:<br />
<code>$ ffmpeg -i videoinput.avi -i audioinput.mp3 -map 0:0 -map 1:0 -acodec libmp3lame -vcodec mpeg4 videooutput.avi</code><br />
Per evitare che ci dia errori in fase di codifica.</p>
<p>Poi vi faro&#8217; vedere come utilizzando <strong>ffmpeg</strong> assieme a <strong>mencoder</strong> sia possibile <strong>creare un video con le vostre foto</strong> e con la musica che volete voi in sottofondo.</p>
<hr />
<p style="text-align:right;"><a href="#content" title="torna su">[^] torna su</a>&#160;&#124;&#160;<a href="http://postli.com/post?u=http://idl3.wordpress.com/2009/09/25/howto-tagliare-video-e-unire-audio-e-video-con-ffmpeg-e-mencoder/&#38;t=HowTo: tagliare video e unire audio e video con ffmpeg e mencoder" title="Post to Postli" style="color:blue;text-decoration:none;">post<span style="color:orange;">&#60;</span><span style="color:red;">li</span><span style="color:orange;">&#62;</span></a>&#160;&#124;&#160;<a href="http://www.wikio.it/vote?url=http://idl3.wordpress.com/2009/09/25/howto-tagliare-video-e-unire-audio-e-video-con-ffmpeg-e-mencoder/" target="_blank"><img src="http://www.wikio.it/shared/img/vote/wikio2.gif" border="0" /></a></p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Mencoder Conversions Extract audio from a video ]]></title>
<link>http://nowardev.wordpress.com/2009/09/19/mencoder-conversions-extract-audio-from-a-video/</link>
<pubDate>Sat, 19 Sep 2009 08:28:54 +0000</pubDate>
<dc:creator>nowardev</dc:creator>
<guid>http://nowardev.wordpress.com/2009/09/19/mencoder-conversions-extract-audio-from-a-video/</guid>
<description><![CDATA[Avi 2-pass PAL (NTSC &#8212;&gt; 30 fps ; and 720:480) mencoder -forceidx -ofps 25 -oac mp3lame -lam]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>Avi 2-pass PAL  (NTSC &#8212;&#62; 30 fps ; and 720:480)</p>
<blockquote><p>mencoder  -forceidx  -ofps 25  -oac mp3lame   -lameopts abr:br=128  -srate 48000  -vf scale=720:576,harddup -ovc xvid -xvidencopts bitrate=900:pass=1 INPUT  -o /dev/null</p>
<p>mencoder  -forceidx  -ofps 25  -oac mp3lame   -lameopts abr:br=128  -srate 48000  -vf scale=720:576,harddup -ovc xvid -xvidencopts bitrate=900:pass=2 INPUT  -o OUTPUT.AVI</p></blockquote>
<p>Options  to add</p>
<p><strong>video options</strong></p>
<p>-aspect 16:9 or  4:3<br />
-speed   value 0.1 &#8211;&#62;1;  1&#8212;&#62;boh<br />
-ss 00:00:00 -endpos hh:mm:ss<br />
-vf pp=lb<br />
-audio-delay 2.200<br />
-vf rotate=flip<br />
-xvidencopts bitrate=900:pass=1:turbo:nochroma_me:notrellis:max_bframes=0:vhq=0:threads=2<br />
-xvidencopts bitrate=900:pass=1:turbo:vhq=0:threads=2<br />
-xvidencopts bitrate=900:pass=1:vhq=2:bvhq=1:chroma_opt:quant_type=mpeg:threads=2<br />
-xvidencopts bitrate=900:pass=1:chroma_opt:vhq=4:bvhq=1:quant_type=mpeg:threads=2</p>
<p><strong>audio options</strong></p>
<p>-lameopts vbr=4<br />
-lameopts cbr:br=128<br />
-lameopts abr:br=128<br />
-af volume=10</p>
<p>extract pictures from a video</p>
<p>ffmpeg -i Flashqaevpd -y  -an -sameq -f image2 -r 30  nome%03d.jpg</p>
<p>extract audio </p>
<p>mencoder INPUT.avi -ovc raw -oac mp3lame -of rawaudio -o OUTPUT.mp3</p>
<p>-aid 128  &#8212;-&#62; extract the 128th audio track </p>
<p>raw avi</p>
<p>ffmpeg -i yourfile.mod -vcodec rawvideo -acodec pcm_s16le -r 15 -s 720&#215;480 -aspect 4:3 yourfile.avi</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Как включить VDPAU в ubuntu]]></title>
<link>http://rostoteka.wordpress.com/2009/09/15/vdpau/</link>
<pubDate>Tue, 15 Sep 2009 11:36:44 +0000</pubDate>
<dc:creator>rostoteka</dc:creator>
<guid>http://rostoteka.wordpress.com/2009/09/15/vdpau/</guid>
<description><![CDATA[VDPAU &#8211; API от nvidia, позволяющее использовать технологию PureVideo HD в Linux. А соответстве]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p><a href="http://en.wikipedia.org/wiki/VDPAU">VDPAU</a> &#8211; API от nvidia, позволяющее использовать технологию PureVideo HD в Linux. А соответственно PureVideo HD это полностью аппаратное декодирование HD видео с кодеками H.264/X.264 и VC-1 (xvid, divx, wmv).<br />
VDPAU поддерживается на всех видеокартах nvidia серии 9000 и позже (подробный список <a href="http://en.wikipedia.org/wiki/VDPAU#Table_of_NVIDIA_GPUs">тут</a>).<br />
Правда на некоторых видеокартах, особенно Gigabyte, не написано что они поддерживают PureVideo HD, хотя запустить удалось без особых проблем.<br />
<span style="font-weight:bold;">Результат</span>: декодирование x.264, FullHD 1920&#215;1080 с 1-2% нагрузкой на процессор. Без VDPAU процессор не справляется, и видео идет рывками, 5-6 кадров в секунду.<br />
<a href="http://3.bp.blogspot.com/_981heDvOCaQ/Sq4sjXCdZFI/AAAAAAAABCo/bptELhNppEk/s1600-h/vdpau.png"><img style="display:block;text-align:center;cursor:pointer;width:320px;height:34px;margin:0 auto 10px;" src="http://3.bp.blogspot.com/_981heDvOCaQ/Sq4sjXCdZFI/AAAAAAAABCo/bptELhNppEk/s320/vdpau.png" border="0" alt="" /></a><br />
Технология довольно новая (драйвер для linux выпустили год назад), нужно иметь подходящий видеодрайвер (nvidia 180, который ставит ubuntu подходит) и пропатченый плеер.<br />
Все это можно взять из готовых <a href="https://launchpad.net/%7Envidia-vdpau/+archive/ppa">репозиториев</a>, так что поехали.</p>
<div>#Добавляем источник программ<br />
sudo -i<br />
cat &#62; /etc/apt/sources.list.d/vdpau.list &#60;&#60;&#8221;EOF&#8221;<br />
deb http://ppa.launchpad.net/nvidia-vdpau/ppa/ubuntu jaunty main<br />
deb-src http://ppa.launchpad.net/nvidia-vdpau/ppa/ubuntu jaunty main<br />
EOF<br />
#получаем открытый ключ для него<br />
apt-key adv &#8211;keyserver keyserver.ubuntu.com &#8211;recv-keys CEC06767<br />
#обновление программ<br />
apt-get update<br />
apt-get install mplayer smplayer<br />
exit</div>
<p>Дальше можно проверять. Для консольного mplayer команда следующая:</p>
<div>mplayer -vo vdpau -vc ffmpeg12vdpau,ffh264vdpau, film.mkv</div>
<p>Для графической оболочки smplayer нужно в настройках поставить видеовывод (vo) vdpau и на закладке дополнительно-настройки mplayer вписать</p>
<div>-vc ffh264vdpau,ffmpeg12vdpau,</div>
<p>И я советую тотключить &#8220;позволять выпадение кадров&#8221;, иначе будет медленно перематывать (без vdapu эффект обратный).</p>
<p>P.S. на Windows XP я не смог запустить PureVideo HD на этой же видеокарте. Как выяснилось, &#8220;обычные плееры&#8221; не умеют, только 2 платных плеера: Cyberlink PowerDVD и Nero Showtime. Но первый не понимает ничего кроме AVI, а второй вообще отказался работать. Если включить их через DirectShow, как пишут в интернете, никакого декодирования не получается. Это возможно, я не спорю, но на много сложнее чем в ubuntu <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>UPD: если при проигрывании появляются надписи типа &#8220;ffh264vdpau not found in libavcodec&#8221;, то нужно поставить полную версию кодеков:</p>
<div>sudo apt-get install libavcodec-unstripped-52 libavformat-unstripped-52</div>
<div></div>
<div>Взято отсюда &#8211; <a id="linksrcs0.22723739.788" href="http://takeworld.blogspot.com/2009/09/vdpau-ubuntu.html" target="_blank">takeworld.blogspot.com/2009/09/vdpau-ubuntu.html</a></div>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[FFCoder v0.92 Beta]]></title>
<link>http://teejee2008.wordpress.com/2009/09/12/ffcoder-v0-92-beta/</link>
<pubDate>Sat, 12 Sep 2009 15:08:43 +0000</pubDate>
<dc:creator>teejee2008</dc:creator>
<guid>http://teejee2008.wordpress.com/2009/09/12/ffcoder-v0-92-beta/</guid>
<description><![CDATA[Changes: [added] xvid_encraw encoder [added] LAME mp3 encoder [added] x264: MB-Tree options [fixed] ]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><h3>Changes:</h3>
<p>[added] xvid_encraw encoder<br />
[added] LAME mp3 encoder<br />
[added] x264: MB-Tree options<br />
[fixed] Video playback problem on WinXP systems with ATI cards<br />
[fixed] Xvid: No. of threads were not specified in command line args<br />
[fixed] FFmpeg + Xvid: Bitrate was not specified in command line string<br />
[fixed] FFmpeg: Audio codec settings were not saved in preset<br />
[fixed] All presets: Check the range before loading a value from preset file<br />
[changed] Global presets: folder structure changed<br />
[changed] Main window: Disable audio/video/subtitles groupbox if encoder does not encode audio/video/subtitles<br />
[changed] Progress window: Hide useless columns<br />
[removed] MEncoder: vp3,vp4,vp5,vp7 vfw codecs have been disabled due to problems. vp6 codec is working fine</p>
<h3><strong>Notes:</strong></h3>
<p>1) Delete the presets folder of previous version. Extract the update into the same directory as previous version.<br />
2) VP6 codec is producing upside-down video. Use the Flip video filter to fix the problem.<br />
3) Xvid_encraw supports ony AVS files as input. Non-AVS files are not supported.<br />
4) For LAME encoder the source file can be in any format supported by ffmpeg. The source files are decoded with ffmpeg and then piped to LAME.</p>
<h3><a href="http://www.mediafire.com/?nynnk4xnjm4" target="_blank">Download FFCoder v0.92 Beta Update (1 MB)</a></h3>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[FFCoder v0.91 Beta]]></title>
<link>http://teejee2008.wordpress.com/2009/09/10/ffcoder-v0-91-beta-release/</link>
<pubDate>Thu, 10 Sep 2009 11:50:29 +0000</pubDate>
<dc:creator>teejee2008</dc:creator>
<guid>http://teejee2008.wordpress.com/2009/09/10/ffcoder-v0-91-beta-release/</guid>
<description><![CDATA[FFCoder is a .NET based audio/video converter, which is capable of transcoding audio and video files]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>FFCoder is a .NET based audio/video converter, which is capable of transcoding audio and video files to various formats. It is a unified frontend for many freeware utilities such as FFmpeg, MPlayer and MEncoder.</p>
<p>See the link below for more information:</p>
<p><a href="http://teejee2008.wordpress.com/ffcoder/" target="_blank">http://teejee2008.wordpress.com/ffcoder/</a></p>
</div>]]></content:encoded>
</item>

</channel>
</rss>
