
Recherche avancée
Autres articles (44)
-
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 (...) -
Submit bugs and patches
13 avril 2011Unfortunately a software is never perfect.
If you think you have found a bug, report it using our ticket system. Please to help us to fix it by providing the following information : the browser you are using, including the exact version as precise an explanation as possible of the problem if possible, the steps taken resulting in the problem a link to the site / page in question
If you think you have solved the bug, fill in a ticket and attach to it a corrective patch.
You may also (...) -
HTML5 audio and video support
13 avril 2011, parMediaSPIP uses HTML5 video and audio tags to play multimedia files, taking advantage of the latest W3C innovations supported by modern browsers.
The MediaSPIP player used has been created specifically for MediaSPIP and can be easily adapted to fit in with a specific theme.
For older browsers the Flowplayer flash fallback is used.
MediaSPIP allows for media playback on major mobile platforms with the above (...)
Sur d’autres sites (8221)
-
FFMPEG rtsp stream add timestamp to output file
14 octobre 2015, par kernel252I’m trying add timestamp to output file from FFMPEG but I’m getting this error.
Filtergraph 'drawtext=fontfile=/usr/share/fonts/truetype/ttf-dejavu/DejaVuSans-Bold.ttf:text='\%T': fontcolor=white@0.8: x=7: y=460' was defined for video output stream 0:0 but codec copy was selected.
Filtering and streamcopy cannot be used togetherAnd my command is :
ffmpeg -i rtsp://admin:password@192.168.1.52:554/11 -vf "drawtext=fontfile=/usr/share/fonts/truetype/ttf-dejavu/DejaVuSans-Bold.ttf:text='\%T': fontcolor=white@0.8: x=7: y=460" -acodec copy -vcodec copy test.avi
And the output :
ffmpeg version N-75939-g6eaf97c Copyright (c) 2000-2015 the FFmpeg
developers built with gcc 4.9.2 (Raspbian 4.9.2-10) configuration :
—arch=armel —target-os=linux —enable-gpl —enable-libx264 —enable-nonfree —enable-libfreetype
libavutil 55. 3.100 / 55. 3.100
libavcodec 57. 5.100 / 57. 5.100
libavformat 57. 3.100 / 57. 3.100
libavdevice 57. 0.100 / 57. 0.100
libavfilter 6. 11.100 / 6. 11.100
libswscale 4. 0.100 /
4. 0.100
libswresample 2. 0.100 / 2. 0.100
libpostproc 54. 0.100 / 54. 0.100 Input #0, rtsp, from ’rtsp ://user :@192.168.1.52:554/11’ :
Metadata :
title : 10 Duration : N/A, start : 0.159000, bitrate : N/A
Stream #0:0 : Video : h264 (Main), yuv420p, 1280x720, 25.08 tbr, 90k tbn, 180k tbc
Stream #0:1 : Audio : adpcm_g726, 8000 Hz, mono, s16, 16 kb/s Filtergraph
’drawtext=fontfile=/usr/share/fonts/truetype/ttf-dejavu/DejaVuSans-Bold.ttf:text=’\%T’ :
fontcolor=white@0.8 : x=7 : y=460’ was defined for video output stream
0:0 but codec copy was selected. Filtering and streamcopy cannot be
used together.Where I’m doing a mistake ?
Thank you for all reply :)
-
Realtime output from ffmpeg and livestreamer using subprocess.Popen
6 mars 2016, par Roger BIn ffmpeg and livestreamer i only get a few lines in realtime then i get the rest of them when the process is done...
I have tried two codes :
from subprocess import *
p = Popen('ffmpeg -i infile.mp4 outfile.mp4', stderr=STDOUT, stdout=PIPE)
for line in iter(p.stdout.readline(), b'')
print line.rstrip()and
from subprocess import *
p = Popen('ffmpeg -i infile.mp4 outfile.mp4', stderr=STDOUT, stdout=PIPE)
while p.poll is None:
line = p.stdout.readline()
print line.rstrip()Both of them prints first :
ffmpeg version N-72805-g913685f Copyright (c) 2000-2015 the FFmpeg developers
built with gcc 4.9.2 (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-libmfx --enable-libmp3lame --enable-libopenc
ore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --ena
ble-librtmp --enable-libschroedinger --enable-libsoxr --enable-libspeex --enable
-libtheora --enable-libtwolame --enable-libvidstab --enable-libvo-aacenc --enabl
e-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwavpack --enable
-libwebp --enable-libx264 --enable-libx265 --enable-libxavs --enable-libxvid --e
nable-lzma --enable-decklink --enable-zlib
libavutil 54. 27.100 / 54. 27.100
libavcodec 56. 41.100 / 56. 41.100
libavformat 56. 36.100 / 56. 36.100
libavdevice 56. 4.100 / 56. 4.100
libavfilter 5. 16.101 / 5. 16.101
libswscale 3. 1.101 / 3. 1.101
libswresample 1. 2.100 / 1. 2.100
libpostproc 53. 3.100 / 53. 3.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'a.mp4':
Metadata:
major_brand : isom
minor_version : 512
compatible_brands: isomiso2avc1mp41
encoder : Lavf56.10.100
Duration: 01:34:36.14, start: 0.021333, bitrate: 6205 kb/s
Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 1280x720,
5938 kb/s, 30 fps, 30 tbr, 15360 tbn, 60 tbc (default)
Metadata:
handler_name : VideoHandler
Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, flt
p, 256 kb/s (default)
Metadata:
handler_name : SoundHandler
[mp4 @ 05013ce0] Codec for stream 0 does not use global headers but container fo
rmat requires global headers
[mp4 @ 05013ce0] Codec for stream 1 does not use global headers but container fo
rmat requires global headers
Output #0, mp4, to 'b.mp4':
Metadata:
major_brand : isom
minor_version : 512
compatible_brands: isomiso2avc1mp41
encoder : Lavf56.36.100
Stream #0:0(und): Video: h264 ([33][0][0][0] / 0x0021), yuv420p, 1280x720, q
=2-31, 5938 kb/s, 30 fps, 30 tbr, 15360 tbn, 15360 tbc (default)
Metadata:
handler_name : VideoHandler
Stream #0:1(und): Audio: aac ([64][0][0][0] / 0x0040), 48000 Hz, stereo, 256
kb/s (default)
Metadata:
handler_name : SoundHandler
Stream mapping:
Stream #0:0 -> #0:0 (copy)
Stream #0:1 -> #0:1 (copy)
Press [q] to stop, [?] for helpThen when the convert process is done the rest of the log turns up...
How can i get all stdout in realtime ??
EDIT :
If i use a text file to write to it get all in realtime.
from subprocess import *
out_file = open('stdout.txt','a')
Popen('ffmpeg -i infile.mp4 outfile.mp4', stderr=STDOUT, stdout=out_file)But i want it print out stdout in realtime..
Why does it work in realtime to a file but not direct print ?
-
Creating exact replica of video file[ffmpeg]
13 octobre 2015, par gauravI have written some code using ffmpeg’s library which decodes every frame of video file, does some manipulation on it and finally encode and mux the frame to new container.this all works.
The problem i am trying to solve here is how to make the output file have exact stream settings as input file.if i run ffmpeg -i on my files i get following -
1)Input File -
Duration : 00:00:30.95, start : 0.000000, bitrate : 1195 kb/s
Stream #0:0(eng) : Video : h264 (Main) (avc1 / 0x31637661), yuv420p(tv), 1280x720 [SAR 1:1 DAR 16:9], 996 kb/s, 25 fps, 25 tbr, 25k tbn, 50 tbc (default)
Metadata :
creation_time : 2015-09-30 06:33:24
handler_name : Mainconcept MP4 Video Media Handler
encoder : AVC Coding2)Output file -
Duration : 00:00:30.96, start : 0.000000, bitrate : 1225 kb/s
Stream #0:0(und) : Video : h264 (Main) (avc1 / 0x31637661), yuv420p, 1280x720 [SAR 1:1 DAR 16:9], 1032 kb/s, 25.03 fps, 25 tbr, 25k tbn, 100 tbc (default)
Metadata :
handler_name : VideoHandler3)If i run my code again on above output file to generate another output file then that file looks like this-
Duration : 00:00:30.96, start : 0.000000, bitrate : 1264 kb/s
Stream #0:0(und) : Video : h264 (Main) (avc1 / 0x31637661), yuv420p, 1280x720 [SAR 1:1 DAR 16:9], 1071 kb/s, 25.03 fps, 25 tbr, 25k tbn, 200 tbc (default)Notice the bitrate and TBC is changing everytime i run my code.
How should i configure my encoder to make the output file identical to input file ? the current code for configuring encoder looks like this -c = out_stream->codec;
c->codec_id = inputStream->codec->codec_id;
c->bit_rate = inputStream->codec->bit_rate;
/* Resolution must be a multiple of two. */
c->width = inputStream->codec->width;
c->height = inputStream->codec->height;
c->gop_size = inputStream->codec->gop_size;
c->time_base = inputStream->codec->time_base;
out_stream->time_base = inputStream->time_base;
av_stream_set_r_frame_rate(out_stream,av_stream_get_r_frame_rate(inputStream));
out_stream->avg_frame_rate = inputStream->avg_frame_rate;
c->pix_fmt = AV_PIX_FMT_YUV420P;
c->sample_aspect_ratio.num = inputStream->codec->sample_aspect_ratio.num;
c->sample_aspect_ratio.den = inputStream->codec->sample_aspect_ratio.den;
c->ticks_per_frame = inputStream->codec->ticks_per_frame;
c->profile = inputStream->codec->profile;
out_stream->duration = inputStream->duration;