Difference between revisions of "Video management"
Adelo Vieira (talk | contribs) (→How to create an animated GIF from MP4 video via command line) |
Adelo Vieira (talk | contribs) (→How to create an animated GIF from MP4 video via command line) |
||
| Line 108: | Line 108: | ||
gifsicle opengl-rotating-triangle.gif --loopcount=3 > opengl-rotating-triangle_3.gif | gifsicle opengl-rotating-triangle.gif --loopcount=3 > opengl-rotating-triangle_3.gif | ||
</syntaxhighlight> | </syntaxhighlight> | ||
| + | |||
| + | |||
| + | <br /> | ||
| + | =====Ejemplo de como incluir el gif en MediaWiki===== | ||
| + | <div class="mw-collapsible-content"> | ||
| + | <div style="max-width: 450pt"> | ||
| + | <img style="width: 420pt" src="http://wiki.sinfronteras.ws/images/1/11/The_big_bang.gif" onclick="this.src = this.src + 'sklfjlx;'"> | ||
| + | |||
| + | [[:File:The_big_bang.gif]] | ||
| + | |||
| + | <!-- This is how to embebe the file from the general link to the file. The problem is that this way I was not able to resize it: --> | ||
| + | <!-- [[File:The_big_bang.gif|none|frame]] --> | ||
| + | </div> | ||
Revision as of 18:33, 19 October 2020
Contents
- 1 Edición de videos en Linux
- 1.1 Aplicaciones para editar videos en Linux
- 1.2 OpenShot
- 1.3 Blender
- 1.4 Cinelarra
- 1.5 Edición de vídeos desde el terminal
Edición de videos en Linux
Aplicaciones para editar videos en Linux
http://www.linux.com/news/software/applications/693365-top-3-linux-video-editors
http://filmora.wondershare.com/video-editor/free-linux-video-editor.html
OpenShot
Blender
Cinelarra
Edición de vídeos desde el terminal
Los programas que he encontrado para este fin son: Mencoder y ffmpeg
http://www.taringa.net/posts/linux/9943347/Unir-canciones-y-convertir-audio-y-video-con-Ffmpeg.html
Dividir un video desde el terminal
http://www.atareao.es/ubuntu/dividir-un-video-desde-el-terminal-de-ubuntu/
Extracting, cleaning and re-merging audio
https://ubuntuforums.org/showthread.php?t=2074181
Use ffmpeg to separate audio and video. First check properties of videofile see if your audio is aac or mp3 and write in accordingly below.
ffmpeg -i musica_celestial.mp4
Para extraer el audio:
ffmpeg -i musica_celestial.mp4 -vn -acodec copy audio_musica_celestial.aac
ffmpeg audio format conversions
https://linuxconfig.org/ffmpeg-audio-format-conversions#h1-3-1-ac3-to-mp3
Convert aac to mp3 with ffmpeg:
ffmpeg -i audio.aac -acodec libmp3lame audio.mp3
Unir dos archivos de audio
Para unir dos archivos de audio (.mp3 por ejemplo) podemos utilizar cat. Sin embargo, la metadada del video no será creada correctamente. Por ejemplo si uno dos audios con cat y luego abro el archivo resultante un un reproductor de música, el reproductor dirá que este archivo tiene una longitud igual a la del primer archivo concatenado. Aún así el archivo será reproducido en su totalidad por el reproductor (el total de los dos archivos concatenados).
cat archivo1.mp3 archivo2.mp3 > archivo1_2.mp3
Si queremos que la longitud del archivo resultante sea mostrada correctamente en el reproductor de audio, podemos usar:
ffmpeg -i "concat:archivo1.mp3|archivo2.mp3" -acodec copy salida.mp3
Cambiar el formato de un Video
.avi" to ".flv" con ffmpeg http://forums.liveleak.com/showthread.php?t=1716
ffmpeg -i input.avi -b 2028k -s 640x480 -r 30 -acodec copy movie_2028_640_30.flv
explanation: -i input.avi the input file -b 1024k the output bitrate -s 320x240 the output resolution -r 25 the output frames per second -acodec copy the output audio codec movie_1024_320_25.flv the output file
Para que el archivo resultante presente las mismas características que el original en términos de resolución, bitrate, etc, debemos primero chequear las características del archivo original con ffmpeg -i video.avi; para luego ajustar los mismos valores en la ejecución del comando ffmpeg.
How to create an animated GIF from MP4 video via command line
https://askubuntu.com/questions/648603/how-to-create-an-animated-gif-from-mp4-video-via-command-line
sudo apt install ffmpeg
ffmpeg \
-i opengl-rotating-triangle.mp4 \
-r 15 \
-vf scale=512:-1 \
-ss 00:00:03 -to 00:00:06 \
opengl-rotating-triangle.gif
Luego, para limitar el número de loops: https://davidwalsh.name/prevent-gif-loop#comment-502961
sudo apt install gifsicle
gifsicle opengl-rotating-triangle.gif --loopcount=3 > opengl-rotating-triangle_3.gif
Ejemplo de como incluir el gif en MediaWiki
Cortar o unir mp3
sudo apt-get install mp3wrap mp3splt
Now you can merge two mp3 files (let's say 1.mp3 and 2.mp3) by typing:
mp3wrap merged.mp3 2.mp3 1.mp3
note that the merged.mp3 will start with 2.mp3 and finish with 1.mp3
You can split mp3's now by typing:
mp3splt merged.mp3 0.0 1.2 3.4
this will split file merged.mp3 into two parts:
00:00 - 01:02 01:02 - 03:04
where xx:xx represents minutes:seconds.