
Recherche avancée
Autres articles (63)
-
Les tâches Cron régulières de la ferme
1er décembre 2010, parLa gestion de la ferme passe par l’exécution à intervalle régulier de plusieurs tâches répétitives dites Cron.
Le super Cron (gestion_mutu_super_cron)
Cette tâche, planifiée chaque minute, a pour simple effet d’appeler le Cron de l’ensemble des instances de la mutualisation régulièrement. Couplée avec un Cron système sur le site central de la mutualisation, cela permet de simplement générer des visites régulières sur les différents sites et éviter que les tâches des sites peu visités soient trop (...) -
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 documentation
13 avril 2011Documentation is vital to the development of improved technical capabilities.
MediaSPIP welcomes documentation by users as well as developers - including : critique of existing features and functions articles contributed by developers, administrators, content producers and editors screenshots to illustrate the above translations of existing documentation into other languages
To contribute, register to the project users’ mailing (...)
Sur d’autres sites (6731)
-
Replacing the standard Android H264 software encoder with an ffmpeg based one
10 août 2012, par rubenvbIn Android ICS and later, a new OpenMax IL API version is in use, making old binary blobs useless/unused. This leads to older devices that otherwise run ICS just fine and dandy to have broken video playback (YouTube HQ and IMBD, for example) because Androids fallback software decoder sucks when compared to what ffmpeg can do on the same device (I tested MXPlayer+arm6vfp ffmpeg and a 720p movie played back great).
I am trying to dig through the Android source code to see where and what exactly I could add/replace code to allow the ffmpeg library's awesomeness to be used. The problem is I don't know exactly what code is being used in for example the YouTube app to decode video, or how that's decided.
So I have two options as far as I can tell :
-
Figure out the current software decoder being used, and try to wrap its external interface around ffmpeg, effectively replacing the slow software decoder currently used. The end result would be a single .so I could push to the device.
-
Figure out how to trick Android into thinking an OMX library based on ffmpeg (I have built one succesfully for Android : limoa) and add this somewhere to the list of considered libraries (or better : replace the unusable hardware codec).
As an extension, I'd like to also make camcorder video encoding work through this, so a true integrated solution would be very much wanted. The question is : how, and where, and what ? Searching the Android source tree gives numerous counts of "H264" and related stuff in many different places. I need the lowest and simplest possible, so I can simply wrap the hypothetical
decode(buffer)
function call to use ffmpeg (libavcodec). -
-
How to play back a video stream on website ?
11 juillet 2012, par John SmithLets suppose I have a streaming generated from ffmpeg :
ffmpeg -f dshow -i video="UScreenCapture" -vcodec libx264 -g 30 -f mpegts tcp://127.0.0.1:1234
on the server Im catching the stuffes like this :
error_reporting(E_ALL); /* Allow the script to hang around waiting for connections. */
set_time_limit(30); /* Turn on implicit output flushing so we see what we're getting as it comes in. */
ob_implicit_flush();
$address = '127.0.0.1';
$port = 1234;
$outfile = dirname(__FILE__)."/output.flv";
$ofp = fopen($outfile, 'wb');
if (($sock = socket_create(AF_INET, SOCK_STREAM, SOL_TCP)) === false) { echo "socket_create() failed: reason: " . socket_strerror(socket_last_error()) . "\n"; sleep (5); die; }
if (socket_bind($sock, $address, $port) === false) { echo "socket_bind() failed: reason: " . socket_strerror(socket_last_error($sock)) . "\n"; sleep (5); die; }
if (socket_listen($sock, 5) === false) { echo "socket_listen() failed: reason: " . socket_strerror(socket_last_error($sock)) . "\n"; sleep (5); die; }
if (($msgsock = socket_accept($sock)) === false) { echo "socket_accept() failed: reason: " . socket_strerror(socket_last_error($sock)) . "\n"; sleep (5); break; }
do {
$a = '';
socket_recv ($msgsock, $a, 65536, MSG_WAITALL);
fwrite ($ofp, $a);
fclose ($ofp);
$ofp = fopen($outfile, 'ab');
//echo strlen($a)."\r\n";
} while (true);now Im stuck replaying this. VCL player can replay this so its got to be good, but how to put it onto a site ? I know theres HTML5 video tags, but lets not use it, because it might unsupported, and I also failed make it work every way. Is there a flash solution ? Its a dymanic stream, so no start-end !
-
How to change metadata with ffmpeg/avconv ?
14 juillet 2012, par tampisI am writing a python script for producing audio and video podcasts. There are a bunch of recorded media files (audio and video) and text files containing the meta information.
Now I want to program a function which shall add the information from the meta data text files to all media files (the original and the converted ones). Because I have to handle many different file formats (
wav
,flac
,mp3
,mp4
,ogg
,ogv
...) it would be great to have a tool which add meta data to arbitrary formats.My Question :
How can I change the metadata of a file with
ffmpeg/avconv
without changing the audio or video of it and without creating a new file ? Is there another commandline/python tool which would do the job for me ?What I tried so far :
I thought
ffmpeg/avconv
could be such a tool, because it can handle nearly all media formats. I hoped, that if I set-i input_file
and theoutput_file
to the same file,ffmpeg/avconv
will be smart enough to leave the file unchanged. Then I could set-metadata key=value
and just the metadata will be changed.But I noticed, that if I type
avconv -i test.mp3 -metadata title='Test title' test.mp3
the audiotest.mp3
will be reconverted in another bitrate.So I thought to use
-c copy
to copy all video and audio information. Unfortunately also this does not work ::~$ du -h test.wav # test.wav is 303 MB big
303M test.wav
:~$ avconv -i test.wav -c copy -metadata title='Test title' test.wav
avconv version 0.8.3-4:0.8.3-0ubuntu0.12.04.1, Copyright (c) 2000-2012 the
Libav developers
built on Jun 12 2012 16:37:58 with gcc 4.6.3
[wav @ 0x846b260] max_analyze_duration reached
Input #0, wav, from 'test.wav':
Duration: 00:29:58.74, bitrate: 1411 kb/s
Stream #0.0: Audio: pcm_s16le, 44100 Hz, 2 channels, s16, 1411 kb/s
File 'test.wav' already exists. Overwrite ? [y/N] y
Output #0, wav, to 'test.wav':
Metadata:
title : Test title
encoder : Lavf53.21.0
Stream #0.0: Audio: pcm_s16le, 44100 Hz, 2 channels, 1411 kb/s
Stream mapping:
Stream #0:0 -> #0:0 (copy)
Press ctrl-c to stop encoding
size= 896kB time=5.20 bitrate=1411.3kbits/s
video:0kB audio:896kB global headers:0kB muxing overhead 0.005014%
:~$ du -h test.wav # file size of test.wav changed dramatically
900K test.wavYou see, that I cannot use
-c copy
ifinput_file
andoutput_file
are the same. Of course I could produce a temporarily file ::-$ avconv -i test.wav -c copy -metadata title='Test title' test_temp.mp3
:-$ mv test_tmp.mp3 test.mp3But this solution would create (temporarily) a new file on the filesystem and is therefore not preferable.