
Recherche avancée
Médias (91)
-
Les Miserables
9 décembre 2019, par
Mis à jour : Décembre 2019
Langue : français
Type : Textuel
-
VideoHandle
8 novembre 2019, par
Mis à jour : Novembre 2019
Langue : français
Type : Video
-
Somos millones 1
21 juillet 2014, par
Mis à jour : Juin 2015
Langue : français
Type : Video
-
Un test - mauritanie
3 avril 2014, par
Mis à jour : Avril 2014
Langue : français
Type : Textuel
-
Pourquoi Obama lit il mes mails ?
4 février 2014, par
Mis à jour : Février 2014
Langue : français
-
IMG 0222
6 octobre 2013, par
Mis à jour : Octobre 2013
Langue : français
Type : Image
Autres articles (28)
-
Publier sur MédiaSpip
13 juin 2013Puis-je poster des contenus à partir d’une tablette Ipad ?
Oui, si votre Médiaspip installé est à la version 0.2 ou supérieure. Contacter au besoin l’administrateur de votre MédiaSpip pour le savoir -
Contribute to a better visual interface
13 avril 2011MediaSPIP is based on a system of themes and templates. Templates define the placement of information on the page, and can be adapted to a wide range of uses. Themes define the overall graphic appearance of the site.
Anyone can submit a new graphic theme or template and make it available to the MediaSPIP community. -
Des sites réalisés avec MediaSPIP
2 mai 2011, parCette page présente quelques-uns des sites fonctionnant sous MediaSPIP.
Vous pouvez bien entendu ajouter le votre grâce au formulaire en bas de page.
Sur d’autres sites (7108)
-
Encode videos to send with WhatsApp
28 avril 2017, par piegamesI have a series of PNG images of a video I rendered and now I want so send it via WhatsApp. I used to encode my videos with the command from this answer, but apparently the videos can only be played from WhatsApp web ; on the phone I still get an error message. How do I convert them so that they can also be played on phone ?
Command used :
%PATH_TO_FFMPEG%\ffmpeg.exe -i paint\out%04d.png -c:v libx264 -c:a aac ./videos/out7.mp4
Log :
ffmpeg version 3.2.4 Copyright (c) 2000-2017 the FFmpeg developers
built with gcc 6.3.0 (GCC)
configuration: --enable-gpl --enable-version3 --enable-d3d11va --enable-dxva2 --enable-libmfx --enable-nvenc --enable-avisynth --enable-bzlib --enable-fontconfig --enable-frei0r --enable-gnutls --enable-iconv --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libfreetype --enable-libgme --enable-libgsm --enable-libilbc --enable-libmodplug --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenh264 --enable-libopenjpeg --enable-libopus --enable-librtmp --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxavs --enable-libxvid --enable-libzimg --enable-lzma --enable-zlib
libavutil 55. 34.101 / 55. 34.101
libavcodec 57. 64.101 / 57. 64.101
libavformat 57. 56.101 / 57. 56.101
libavdevice 57. 1.100 / 57. 1.100
libavfilter 6. 65.100 / 6. 65.100
libswscale 4. 2.100 / 4. 2.100
libswresample 2. 3.100 / 2. 3.100
libpostproc 54. 1.100 / 54. 1.100
Input #0, image2, from 'paint2\out%04d.png':
Duration: 00:00:45.00, start: 0.000000, bitrate: N/A
Stream #0:0: Video: png, rgba(pc), 384x240 [SAR 2835:2835 DAR 8:5], 25 fps, 25 tbr, 25 tbn, 25 tbc
No pixel format specified, yuv444p for H.264 encoding chosen.
Use -pix_fmt yuv420p for compatibility with outdated media players.
[libx264 @ 000000000061a660] using SAR=1/1
[libx264 @ 000000000061a660] using cpu capabilities: MMX2 SSE2Fast LZCNT
[libx264 @ 000000000061a660] profile High 4:4:4 Predictive, level 1.3, 4:4:4 8-bit
[libx264 @ 000000000061a660] 264 - core 148 r2762 90a61ec - H.264/MPEG-4 AVC codec - Copyleft 2003-2017 - http://www.videolan.org/x264.html - options: cabac=1 ref=3 deblock=1:0:0 analyse=0x3:0x113 me=hex subme=7 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=4 threads=6 lookahead_threads=1 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=3 b_pyramid=2 b_adapt=1 b_bias=0 direct=1 weightb=1 open_gop=0 weightp=2 keyint=250 keyint_min=25 scenecut=40 intra_refresh=0 rc_lookahead=40 rc=crf mbtree=1 crf=23.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00
Output #0, mp4, to './videos/out6.mp4':
Metadata:
encoder : Lavf57.56.101
Stream #0:0: Video: h264 (libx264) ([33][0][0][0] / 0x0021), yuv444p, 384x240 [SAR 1:1 DAR 8:5], q=-1--1, 25 fps, 12800 tbn, 25 tbc
Metadata:
encoder : Lavc57.64.101 libx264
Side data:
cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: -1
Stream mapping:
Stream #0:0 -> #0:0 (png (native) -> h264 (libx264))
Press [q] to stop, [?] for help
frame= 79 fps=0.0 q=28.0 size= 19kB time=00:00:01.04 bitrate= 152.5kbits/frame= 171 fps=168 q=28.0 size= 21kB time=00:00:04.72 bitrate= 36.4kbits/frame= 255 fps=168 q=28.0 size= 24kB time=00:00:08.08 bitrate= 24.1kbits/frame= 309 fps=153 q=28.0 size= 48kB time=00:00:10.24 bitrate= 38.6kbits/frame= 383 fps=151 q=28.0 size= 51kB time=00:00:13.20 bitrate= 31.7kbits/frame= 452 fps=148 q=28.0 size= 54kB time=00:00:15.96 bitrate= 27.7kbits/frame= 534 fps=151 q=28.0 size= 59kB time=00:00:19.24 bitrate= 25.1kbits/frame= 622 fps=154 q=28.0 size= 85kB time=00:00:22.76 bitrate= 30.7kbits/frame= 706 fps=155 q=28.0 size= 90kB time=00:00:26.12 bitrate= 28.1kbits/frame= 795 fps=157 q=28.0 size= 94kB time=00:00:29.68 bitrate= 25.9kbits/frame= 893 fps=161 q=28.0 size= 121kB time=00:00:33.60 bitrate= 29.5kbits/frame= 985 fps=162 q=28.0 size= 126kB time=00:00:37.28 bitrate= 27.6kbits/frame= 1084 fps=165 q=28.0 size= 153kB time=00:00:41.24 bitrate= 30.3kbits/frame= 1125 fps=163 q=-1.0 Lsize= 168kB time=00:00:44.88 bitrate= 30.6kbits/s speed=6.52x
video:154kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 8.859178%
[libx264 @ 000000000061a660] frame I:5 Avg QP:14.73 size: 22873
[libx264 @ 000000000061a660] frame P:384 Avg QP:14.24 size: 65
[libx264 @ 000000000061a660] frame B:736 Avg QP:16.11 size: 24
[libx264 @ 000000000061a660] consecutive B-frames: 7.3% 13.7% 8.3% 70.8%
[libx264 @ 000000000061a660] mb I I16..4: 35.6% 47.1% 17.3%
[libx264 @ 000000000061a660] mb P I16..4: 0.0% 0.0% 0.0% P16..4: 1.2% 0.1% 0.0% 0.0% 0.0% skip:98.6%
[libx264 @ 000000000061a660] mb B I16..4: 0.0% 0.0% 0.0% B16..8: 0.4% 0.0% 0.0% direct: 0.0% skip:99.6% L0:53.1% L1:46.0% BI: 0.9%
[libx264 @ 000000000061a660] 8x8 transform intra:47.2% inter:15.9%
[libx264 @ 000000000061a660] coded y,u,v intra: 80.7% 29.5% 0.9% inter: 0.1% 0.0% 0.0%
[libx264 @ 000000000061a660] i16 v,h,dc,p: 24% 15% 55% 6%
[libx264 @ 000000000061a660] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 5% 7% 62% 14% 6% 1% 2% 1% 2%
[libx264 @ 000000000061a660] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 10% 9% 29% 11% 8% 5% 14% 5% 9%
[libx264 @ 000000000061a660] Weighted P-Frames: Y:0.0% UV:0.0%
[libx264 @ 000000000061a660] ref P L0: 27.3% 0.7% 36.5% 35.6%
[libx264 @ 000000000061a660] ref B L0: 59.9% 29.7% 10.4%
[libx264 @ 000000000061a660] ref B L1: 96.7% 3.3%
[libx264 @ 000000000061a660] kb/s:27.91Error on my Phone : "Dieses Video kann leider nicht wiedergegeben werden"
-
Converting RGB to YUV, + ffmpeg
10 juillet 2012, par TheSHEEEPI am trying the following to record a live video from my Flash/AIR application :
- I take a "screenshot" (BitmapData from stage) each frame.
-
I convert each pixel to yuv format like this (V2) :
var file :File = new File(_appUrl + "/creation/output.raw");
var fs :FileStream = new FileStream();
fs.open(file, FileMode.WRITE);
var finalY :ByteArray = new ByteArray();
var finalU :ByteArray = new ByteArray();
var finalV :ByteArray = new ByteArray();
var rect :Rectangle = new Rectangle(0, 0, 600, 700);
var pixels :ByteArray;
var pixel :uint;
var r :uint;
var g :uint;
var b :uint;
_screenBuffer = _screenBuffer.reverse();
while (_screenBuffer.length > 0)
{
pixels = BitmapData(_screenBuffer.pop()).getPixels(rect);
pixels.position = 0;
// Convert and save each pixel
for (var x:int = 0; x < 600; x++)
{
for (var y:int = 0; y < 700; y++)
{
// Convert to yuv
pixel = pixels.readUnsignedInt();
r = pixel >> 16 & 0xff;
g = pixel >> 8 & 0xff;
b = pixel & 0xff;
// Y' is written for each pixel
finalY.writeByte(0.257 * r + 0.504 * g + 0.098 * b + 128);
// U and V are written once per 2x2 pixel block
if (x % 2 == 0 && y % 2 == 0)
{
finalU.writeByte(-0.148 * r - 0.291 * g + 0.439 * b + 128);
finalV.writeByte(0.439 * r - 0.368 * g - 0.071 * b + 128);
}
}
}
}
// Write the converted bytes to the file
finalY.position = 0;
finalU.position = 0;
finalV.position = 0;
fs.writeBytes(finalY, 0, finalY.length);
fs.writeBytes(finalU, 0, finalU.length);
fs.writeBytes(finalV, 0, finalV.length);
fs.close(); -
I use the following line of ffmpeg to convert the raw file to a video :
ffmpeg -r 30 -pix_fmt yuv420p -s 600x700 -vcodec rawvideo -f rawvideo -i output.raw -y test.mp4
A video is created, but it is simply a mess, barely resembling what was recorded. I know that the capturing process works, as I have tried the same BitmapData "screenshots" with the SimpleFlvWriter.
So, either something is wrong with my conversion or with the ffmpeg line, but I have no idea.
This is what ffmpeg outputs when creating the video, maybe it can help someone :
libavutil 51. 39.100 / 51. 39.100
libavcodec 54. 3.101 / 54. 3.101
libavformat 54. 1.100 / 54. 1.100
libavdevice 53. 4.100 / 53. 4.100
libavfilter 2. 62.101 / 2. 62.101
libswscale 2. 1.100 / 2. 1.100
libswresample 0. 7.100 / 0. 7.100
libpostproc 52. 0.100 / 52. 0.100
[rawvideo @ 01D39FC0] Estimating duration from bitrate, this may be inaccurate
Input #0, rawvideo, from 'output.raw':
Duration: N/A, start: 0.000000, bitrate: N/A
Stream #0:0: Video: rawvideo (I420 / 0x30323449), yuv420p, 600x700, 30 tbr,
30 tbn, 30 tbc
[buffer @ 01D3FEC0] w:600 h:700 pixfmt:yuv420p tb:1/1000000 sar:0/1 sws_param:
[libx264 @ 0375DB80] using cpu capabilities: MMX2 SSE2Fast SSSE3 FastShuffle SSE 4.2 AVX
[libx264 @ 0375DB80] profile High, level 3.1
[libx264 @ 0375DB80] 264 - core 120 r2146 bcd41db - H.264/MPEG-4 AVC codec - Copyleft 2003-2011 - http://www.videolan.org/x264.html - options: cabac=1 ref=3 deblock=1:0:0 analyse=0x3:0x113 me=hex subme=7 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=12 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=3 b_pyramid=2 b_adapt=1 b_bias=0 direct=1 weightb=1 open_gop=0 weightp=2 keyint=250 keyint_min=25 scenecut=40 intra_refresh=0rc_lookahead=40 rc=crf mbtree=1 crf=23.0 qcomp=0.60 qpmin=0 qpmax=69qpstep=4 ip_ratio=1.40 aq=1:1.00
Output #0, mp4, to 'test.mp4':
Metadata:
encoder : Lavf54.1.100
Stream #0:0: Video: h264 (![0][0][0] / 0x0021), yuv420p, 600x700, q=-1--1, 30 tbn, 30 tbc
Stream mapping:
Stream #0:0 -> #0:0 (rawvideo -> libx264)
Press [q] to stop, [?] for help
Truncating packet of size 630000 to 1
frame= 48 fps= 0 q=-1.0 Lsize= 157kB time=00:00:01.53 bitrate= 837.3kbits/s
video:156kB audio:0kB global headers:0kB muxing overhead 0.687626%
[libx264 @ 0375DB80] frame I:3 Avg QP:23.15 size: 23480
[libx264 @ 0375DB80] frame P:38 Avg QP:28.80 size: 2169
[libx264 @ 0375DB80] frame B:7 Avg QP:29.61 size: 833
[libx264 @ 0375DB80] consecutive B-frames: 79.2% 4.2% 0.0% 16.7%
[libx264 @ 0375DB80] mb I I16..4: 41.4% 6.2% 52.4%
[libx264 @ 0375DB80] mb P I16..4: 10.6% 3.3% 0.9% P16..4: 68.4% 1.3% 1.2% 0.0% 0.0% skip:14.2%
[libx264 @ 0375DB80] mb B I16..4: 0.0% 0.0% 0.0% B16..8: 13.3% 2.2% 0.7% direct: 1.9% skip:81.9% L0:51.6% L1:47.4% BI: 1.0%
[libx264 @ 0375DB80] 8x8 transform intra:16.7% inter:31.2%
[libx264 @ 0375DB80] coded y,uvDC,uvAC intra: 14.7% 25.5% 22.3% inter: 1.0% 4.1% 3.4%
[libx264 @ 0375DB80] i16 v,h,dc,p: 87% 11% 2% 0%
[libx264 @ 0375DB80] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 3% 18% 75% 1% 0% 1% 1% 0% 0%
[libx264 @ 0375DB80] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 6% 74% 12% 1% 1% 1% 2% 1% 2%
[libx264 @ 0375DB80] i8c dc,h,v,p: 51% 45% 4% 1%
[libx264 @ 0375DB80] Weighted P-Frames: Y:0.0% UV:0.0%
[libx264 @ 0375DB80] ref P L0: 4.6% 0.4% 94.6% 0.3%
[libx264 @ 0375DB80] ref B L0: 96.0% 4.0%
[libx264 @ 0375DB80] ref B L1: 96.5% 3.5%
[libx264 @ 0375DB80] kb/s:793.39I'm not really a codec expert (just starting ;)), so I don't know what to make of most of that.
Here is a zip that contains one of the frames and the video output. What should be visible is a green smiling pear, without any artifacts. Remember the size is 600x700 and the format yuv420. Best to view such raw image files with irfanview, IMO. Don't mind the noise, its from pushing against my microphone ;)
-
FFMpeg Combine wav and avi to mp4
15 avril 2016, par krisphI am trying to combine a wav file and a avi in to a single mp4.
I can do this with the following via php :
$command = 'start /B convertvid\bin\ffmpeg -nostdin -i Temp\\temp.avi -i Temp\\temp.wav -y -filter:v scale=1920:-1 -c:v libx264 -preset ultrafast -movflags faststart -crf 31 -c:a libvo_aacenc -b:a 64k Temp\\output.mp4';
However it takes an age to complete and i need to speed it up, i was just wondering is there anything that could be done to optimize the commands to make it faster ?
I have tried the command using just the command line and it still takes ages...
C:\inetpub\wwwroot\Update\>convertvid\bin\ffmpeg -i Temp\temp.
avi -i Temp\temp.wav -y -c:v libx264 -preset ultrafast -movflags faststart -crf
31 -c:a libvo_aacenc -b:a 64k Temp\testhis.mp4
ffmpeg version N-74645-g4c39892 Copyright (c) 2000-2015 the FFmpeg developers
built with gcc 4.9.3 (GCC)
configuration: --enable-gpl --enable-version3 --disable-w32threads --enable-av
isynth --enable-bzlib --enable-fontconfig --enable-frei0r --enable-gnutls --enab
le-iconv --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --
enable-libdcadec --enable-libfreetype --enable-libgme --enable-libgsm --enable-l
ibilbc --enable-libmodplug --enable-libmp3lame --enable-libopencore-amrnb --enab
le-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-librtmp --en
able-libschroedinger --enable-libsoxr --enable-libspeex --enable-libtheora --ena
ble-libtwolame --enable-libvidstab --enable-libvo-aacenc --enable-libvo-amrwbenc
--enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enabl
e-libx264 --enable-libx265 --enable-libxavs --enable-libxvid --enable-lzma --ena
ble-decklink --enable-zlib
libavutil 54. 31.100 / 54. 31.100
libavcodec 56. 58.100 / 56. 58.100
libavformat 56. 40.101 / 56. 40.101
libavdevice 56. 4.100 / 56. 4.100
libavfilter 5. 37.100 / 5. 37.100
libswscale 3. 1.101 / 3. 1.101
libswresample 1. 2.101 / 1. 2.101
libpostproc 53. 3.100 / 53. 3.100
Input #0, avi, from 'Temp\temp.avi':
Duration: 00:01:27.00, start: 0.000000, bitrate: 97 kb/s
Stream #0:0: Video: mpeg4 (Simple Profile) (XVID / 0x44495658), yuv420p, 256
0x1024 [SAR 1:1 DAR 5:2], 98 kb/s, 0.99 fps, 0.99 tbr, 0.99 tbn, 25 tbc
Metadata:
title : Esa-XVID
Input #1, wav, from 'Temp\temp.wav':
Duration: 00:01:25.00, bitrate: 13 kb/s
Stream #1:0: Audio: gsm_ms (1[0][0][0] / 0x0031), 8000 Hz, mono, s16, 13 kb/
s
[libx264 @ 03b9d3e0] using SAR=1/1
[libx264 @ 03b9d3e0] using cpu capabilities: MMX2 SSE2Fast SSSE3 Cache64 SlowShu
ffle
[libx264 @ 03b9d3e0] profile Constrained Baseline, level 5.0
[libx264 @ 03b9d3e0] 264 - core 148 r2597 e86f3a1 - H.264/MPEG-4 AVC codec - Cop
yleft 2003-2015 - http://www.videolan.org/x264.html - options: cabac=0 ref=1 deb
lock=0:0:0 analyse=0:0 me=dia subme=0 psy=1 psy_rd=1.00:0.00 mixed_ref=0 me_rang
e=16 chroma_me=1 trellis=0 8x8dct=0 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_
offset=0 threads=3 lookahead_threads=1 sliced_threads=0 nr=0 decimate=1 interlac
ed=0 bluray_compat=0 constrained_intra=0 bframes=0 weightp=0 keyint=250 keyint_m
in=1 scenecut=0 intra_refresh=0 rc=crf mbtree=0 crf=31.0 qcomp=0.60 qpmin=0 qpma
x=69 qpstep=4 ip_ratio=1.40 aq=0
Output #0, mp4, to 'Temp\testhis.mp4':
Metadata:
encoder : Lavf56.40.101
Stream #0:0: Video: h264 (libx264) ([33][0][0][0] / 0x0021), yuv420p, 2560x1
024 [SAR 1:1 DAR 5:2], q=-1--1, 0.99 fps, 1000k tbn, 0.99 tbc
Metadata:
title : Esa-XVID
encoder : Lavc56.58.100 libx264
Stream #0:1: Audio: aac (libvo_aacenc) ([64][0][0][0] / 0x0040), 8000 Hz, mo
no, s16, 64 kb/s
Metadata:
encoder : Lavc56.58.100 libvo_aacenc
Stream mapping:
Stream #0:0 -> #0:0 (mpeg4 (native) -> h264 (libx264))
Stream #1:0 -> #0:1 (gsm_ms (native) -> aac (libvo_aacenc))
Press [q] to stop, [?] for help
frame= 9 fps=0.0 q=11.0 size= 528kB time=00:00:05.05 bitrate= 855.4kbits/
frame= 17 fps= 16 q=9.0 size= 791kB time=00:00:13.15 bitrate= 492.9kbits/s
frame= 25 fps= 16 q=10.0 size= 844kB time=00:00:21.24 bitrate= 325.6kbits/
frame= 35 fps= 17 q=9.0 size= 870kB time=00:00:31.36 bitrate= 227.2kbits/s
frame= 45 fps= 17 q=10.0 size= 890kB time=00:00:41.47 bitrate= 175.8kbits/
frame= 56 fps= 18 q=9.0 size= 924kB time=00:00:52.60 bitrate= 143.9kbits/s
frame= 67 fps= 18 q=10.0 size= 948kB time=00:01:03.73 bitrate= 121.8kbits/
frame= 78 fps= 19 q=10.0 size= 989kB time=00:01:14.86 bitrate= 108.2kbits/
[mp4 @ 03b9c8e0] Starting second pass: moving the moov atom to the beginning of
the file
frame= 85 fps= 18 q=-1.0 Lsize= 1028kB time=00:01:25.98 bitrate= 97.9kbits
/s dup=9 drop=0
video:912kB audio:111kB subtitle:0kB other streams:0kB global headers:0kB muxing
overhead: 0.497861%
[libx264 @ 03b9d3e0] frame I:1 Avg QP:28.00 size:245528
[libx264 @ 03b9d3e0] frame P:84 Avg QP: 9.98 size: 8182
[libx264 @ 03b9d3e0] mb I I16..4: 100.0% 0.0% 0.0%
[libx264 @ 03b9d3e0] mb P I16..4: 4.1% 0.0% 0.0% P16..4: 4.9% 0.0% 0.0%
0.0% 0.0% skip:90.9%
[libx264 @ 03b9d3e0] coded y,uvDC,uvAC intra: 10.3% 8.6% 6.3% inter: 2.4% 1.8% 0
.9%
[libx264 @ 03b9d3e0] i16 v,h,dc,p: 80% 18% 1% 1%
[libx264 @ 03b9d3e0] i8c dc,h,v,p: 64% 26% 10% 1%
[libx264 @ 03b9d3e0] kb/s:86.79