
Recherche avancée
Autres articles (112)
-
Keeping control of your media in your hands
13 avril 2011, parThe vocabulary used on this site and around MediaSPIP in general, aims to avoid reference to Web 2.0 and the companies that profit from media-sharing.
While using MediaSPIP, you are invited to avoid using words like "Brand", "Cloud" and "Market".
MediaSPIP is designed to facilitate the sharing of creative media online, while allowing authors to retain complete control of their work.
MediaSPIP aims to be accessible to as many people as possible and development is based on expanding the (...) -
Les formats acceptés
28 janvier 2010, parLes commandes suivantes permettent d’avoir des informations sur les formats et codecs gérés par l’installation local de ffmpeg :
ffmpeg -codecs ffmpeg -formats
Les format videos acceptés en entrée
Cette liste est non exhaustive, elle met en exergue les principaux formats utilisés : h264 : H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10 m4v : raw MPEG-4 video format flv : Flash Video (FLV) / Sorenson Spark / Sorenson H.263 Theora wmv :
Les formats vidéos de sortie possibles
Dans un premier temps on (...) -
Ajouter notes et légendes aux images
7 février 2011, parPour pouvoir ajouter notes et légendes aux images, la première étape est d’installer le plugin "Légendes".
Une fois le plugin activé, vous pouvez le configurer dans l’espace de configuration afin de modifier les droits de création / modification et de suppression des notes. Par défaut seuls les administrateurs du site peuvent ajouter des notes aux images.
Modification lors de l’ajout d’un média
Lors de l’ajout d’un média de type "image" un nouveau bouton apparait au dessus de la prévisualisation (...)
Sur d’autres sites (7921)
-
How to properly abort av_seek_frame on FFmpeg ?
5 mars 2021, par SuRGeoNixNormally, you wouldn't care aborting av_seek_frame as it would be really fast on a local file. However, in my case I use a custom AVIOContext for torrent streaming with custom read/seek functions and I'm not able to abort a single seek request !


I've already tried interrupt callbacks (they will not be called at all), some timeouts (rw_timeout/timeout etc.) but by checking FFmpeg's code didn't find anything at all. My last chance was to try to return on read/seek functions an error (I've tried AVERROR_EXIT) which causes even more problems (memory leaks).


The main issue is with Matroska formats that they need to resync (level-1) and they are trying to scan the whole file.


Unfortunately, I'm using C# .NET with FFmpeg.Autogen bindings which means that I don't have low-level access to play around. My workaround is to re-open the whole format context in case on seek abort (to ensure that the player will continues to play at least)


Hope you have a tip for me !


(By the way for some http/hls web formats interrupt callbacks are supported)


-
Have 2 blocking scripts interact with each other in linux
18 novembre 2014, par OrtixxI have 2 blocking shell scripts which I want to have interact with each other. The scripts in question are peerflix (nodejs script) and ffmpeg (a simple bash script).
What happens : Peerflix fires up, feeds data to ffmpeg bash scrip which terminates peerflix on completion.
So once peerflix starts it outputs 2 lines and blocks immediately :
[08:15 PM]-[vagrant@packer-virtualbox-iso]-[/var/www/test]-[git master]
$ node /var/www/test/node/node_modules/peerflix/app.js /var/www/test/flexget/torrents/test.torrent -r -q
listening: http://10.0.2.15:38339/
process: 9601I have to feed the listening address to the ffmpeg bash script :
#!/bin/sh
ffmpeg -ss 00:05:00 -i {THE_LISTENING_PORT} -frames:v 1 out1.jpg
ffmpeg -ss 00:10:00 -i {THE_LISTENING_PORT} -frames:v 1 out2.jpgAfter the bash script is done I have to kill the peerflix script (hence me outputting the PID).
My question is how do I achieve this ?
-
FFmpeg mosaic video creation, Why it doesn't work ?
3 mai 2019, par Ege DarçınI am trying to build a mosaic from multiple videos in an android application using FFmpeg, I have found the wiki on how to do it. The link explains the process well but I am getting this error while processing it :
I/Videokit : start run in main.
register_exit
term_init & parse options.
D/Videokit : ERROR OCCURED
The library that I’m using is WritingMinds, which is FFmpeg for Android compiled with x264, libass, fontconfig, freetype, fribidi and lame (Supports Android 4.1+). Basically, you write a string array of code which is passed to FFmpeg and it runs FFmpeg for you.
Clearly, it is a parsing error but I believe that I have put the command in order. I have tested the files, locations and FFmpeg with other commands like trim, mute audio etc and only mosaic doesn’t work. I have tried different options, string manipulations but that didn’t work, Furthermore, I’ve seen OpenGl error if I put a big typo error.
Here is the code on the wiki :-i 1.avi -i 2.avi -i 3.avi -i 4.avi
-filter_complex "
nullsrc=size=640x480 [base];
[0:v] setpts=PTS-STARTPTS, scale=320x240 [upperleft];
[1:v] setpts=PTS-STARTPTS, scale=320x240 [upperright];
[2:v] setpts=PTS-STARTPTS, scale=320x240 [lowerleft];
[3:v] setpts=PTS-STARTPTS, scale=320x240 [lowerright];
[base][upperleft] overlay=shortest=1 [tmp1];
[tmp1][upperright] overlay=shortest=1:x=320 [tmp2];
[tmp2][lowerleft] overlay=shortest=1:y=240 [tmp3];
[tmp3][lowerright] overlay=shortest=1:x=320:y=240
"
-c:v libx264 output.mkvThis is the code which is on the wiki
String[] m =new String[]{"-i",
DestPath1.toString(),
"-i",
DestPath2.toString(),
"-i",
DestPath3.toString(),
"-i",
DestPath4.toString(),
"-filter_complex",
"\"",
"nullsrc=size=640x480 [base];",
"[0:v] setpts=PTS-STARTPTS, scale=320x240 [upperleft];",
"[1:v] setpts=PTS-STARTPTS, scale=320x240 [upperright];",
"[2:v] setpts=PTS-STARTPTS, scale=320x240 [lowerleft];",
"[3:v] setpts=PTS-STARTPTS, scale=320x240 [lowerright];",
"[base][upperleft], overlay=shortest=1", "[tmp1];",
"[tmp1][upperright] overlay=shortest=1:x=320 [tmp2];",
"[tmp2][lowerleft] overlay=shortest=1:y=240 [tmp3];",
"[tmp3][lowerright] overlay=shortest=1:x=320:y=240",
"\"",
" -c:v",
"libx264",
FinalPath.toString()};
execFFmpegBinary(m);This is the string that I send to the FFmpeg.
The expected result would be a video created on the "FinalPath" which is on the external storage. However, I am getting an error message and nothing else. I have a tight deadline so it would be hard for me to switch to another system and learn it, I’m already new to FFmpeg stuff. Any suggestions ?
Update : I’ve implemented error handlers of the library, not just FFmpeg part, and it points reports as (’"nullsrc’ is not a filter) . However, I need to put (") into there to run the code and I use it as (\"), which does not solve the problem. Removing them is not an option because the statement after the filter needs the quotation marks.
Update2 : Here is the current log :
D/FileLog: Started command : ffmpeg [Ljava.lang.String;@7931693
FAILED with output : ffmpeg version n3.0.1 Copyright (c) 2000-2016 the FFmpeg developers
built with gcc 4.8 (GCC)
configuration: --target-os=linux --cross-prefix=/home/vagrant/SourceCode/ffmpeg-android/toolchain-android/bin/arm-linux-androideabi- --arch=arm --cpu=cortex-a8 --enable-runtime-cpudetect --sysroot=/home/vagrant/SourceCode/ffmpeg-android/toolchain-android/sysroot --enable-pic --enable-libx264 --enable-libass --enable-libfreetype --enable-libfribidi --enable-libmp3lame --enable-fontconfig --enable-pthreads --disable-debug --disable-ffserver --enable-version3 --enable-hardcoded-tables --disable-ffplay --disable-ffprobe --enable-gpl --enable-yasm --disable-doc --disable-shared --enable-static --pkg-config=/home/vagrant/SourceCode/ffmpeg-android/ffmpeg-pkg-config --prefix=/home/vagrant/SourceCode/ffmpeg-android/build/armeabi-v7a --extra-cflags='-I/home/vagrant/SourceCode/ffmpeg-android/toolchain-android/include -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -fno-strict-overflow -fstack-protector-all' --extra-ldflags='-L/home/vagrant/SourceCode/ffmpeg-android/toolchain-android/lib -Wl,-z,relro -Wl,-z,now -pie' --extra-libs='-lpng -lexpat -lm' --extra-cxxflags=
libavutil 55. 17.103 / 55. 17.103
libavcodec 57. 24.102 / 57. 24.102
libavformat 57. 25.100 / 57. 25.100
libavdevice 57. 0.101 / 57. 0.101
libavfilter 6. 31.100 / 6. 31.100
libswscale 4. 0.100 / 4. 0.100
libswresample 2. 0.101 / 2. 0.101
libpostproc 54. 0.100 / 54. 0.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '/storage/emulated/0/Pictures/appName/Vid1.mp4':
Metadata:
major_brand : isom
minor_version : 512
compatible_brands: isomiso2avc1mp41
encoder : Lavf56.25.101
Duration: 00:00:45.05, start: 0.033333, bitrate: 694 kb/s
Stream #0:0(und): Video: h264 (Constrained Baseline) (avc1 / 0x31637661), yuv420p, 460x258 [SAR 1:1 DAR 230:129], 562 kb/s, 25 fps, 25 tbr, 12800 tbn, 50 tbc (default)
Metadata:
handler_name : VideoHandler
Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 128 kb/s (default)
Metadata:
handler_name : SoundHandler
Input #1, mov,mp4,m4a,3gp,3g2,mj2, from '/storage/emulated/0/Pictures/appName/Vid2.mp4':
Metadata:
major_brand : mp42
minor_version : 0
compatible_brands: isommp42
creation_time : 2017-01-15 09:57:32
Duration: 00:00:40.82, start: 0.000000, bitrate: 352 kb/s
Stream #1:0(und): Video: h264 (Constrained Baseline) (avc1 / 0x31637661), yuv420p(tv, bt709), 360x360 [SAR 1:1 DAR 1:1], 253 kb/s, 28.90 fps, 29 tbr, 29 tbn, 58 tbc (default)
Metadata:
handler_name : VideoHandler
Stream #1:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 44100 Hz, stereo, fltp, 95 kb/s (default)
Metadata:
creation_time : 2017-01-15 09:57:32
handler_name : IsoMedia File Produced by Google, 5-11-2011
Input #2, mov,mp4,m4a,3gp,3g2,mj2, from '/storage/emulated/0/Pictures/appName/Vid3.mp4':
Metadata:
major_brand : mp42
minor_version : 1
compatible_brands: mp41mp42isom
creation_time : 2017-12-15 12:10:56
Duration: 00:00:47.26, start: 0.000000, bitrate: 775 kb/s
Stream #2:0(und): Video: h264 (Baseline) (avc1 / 0x31637661), yuv420p(tv, smpte170m/smpte170m/bt709), 480x480, 706 kb/s, 26.98 fps, 27 tbr, 600 tbn, 1200 tbc (default)
Metadata:
creation_time : 2017-12-15 12:10:56
handler_name : Core Media Video
Stream #2:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 44100 Hz, stereo, fltp, 65 kb/s (default)
Metadata:
creation_time : 2017-12-15 12:10:56
handler_name : Core Media Audio
Input #3, mov,mp4,m4a,3gp,3g2,mj2, from '/storage/emulated/0/Pictures/appName/Vid4.mp4':
Metadata:
major_brand : mp42
minor_version : 19529854
compatible_brands: mp42isom
creation_time : 2017-12-17 10:05:07
Duration: 00:00:14.33, start: 0.000000, bitrate: 803 kb/s
Stream #3:0(eng): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 96 k
D/FileLog: Finished command : ffmpeg [Ljava.lang.String;@7931693
V/FA: Inactivity, disconnecting from the service