Recherche avancée

Médias (91)

Autres articles (53)

  • Keeping control of your media in your hands

    13 avril 2011, par

    The 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 (...)

  • Use, discuss, criticize

    13 avril 2011, par

    Talk to people directly involved in MediaSPIP’s development, or to people around you who could use MediaSPIP to share, enhance or develop their creative projects.
    The bigger the community, the more MediaSPIP’s potential will be explored and the faster the software will evolve.
    A discussion list is available for all exchanges between users.

  • Publier sur MédiaSpip

    13 juin 2013

    Puis-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

Sur d’autres sites (8264)

  • Incorrect codec parameters for webm conversion

    20 avril 2015, par peterbw321

    I am using a shared hosting server with ffmpeg installed. i have been told they cant upgrade the version I have. I am trying to convert video files to html5 formats. When I try to convert to webm, I get below error. Can anyone help with this problem ?

    exec("/usr/bin/ffmpeg -i eliza.mp4 -acodec copy -vcodec copy 2>&1 video.webm");

       array(29) { [0]=> string(67) "FFmpeg version 0.6.5, Copyright (c) 2000-2010 the FFmpeg developers"
    [1]=> string(74) " built on Jan 29 2012 23:55:02 with gcc 4.1.2 20080704 (Red Hat 4.1.2-51)" [2]=>
    string(649) " configuration: --prefix=/usr --libdir=/usr/lib64 --shlibdir=/usr/lib64
    --mandir=/usr/share/man --incdir=/usr/include --disable-avisynth --extra-cflags='-O2 -g -pipe
    -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64
    -mtune=generic -fPIC' --enable-avfilter --enable-avfilter-lavf --enable-libdirac --enable-libfaac
    --enable-libfaad --enable-libfaadbin --enable-libgsm --enable-libmp3lame --enable-libopencore-amrnb
    --enable-libopencore-amrwb --enable-libx264 --enable-gpl --enable-nonfree --enable-postproc
    --enable-pthreads --enable-shared --enable-swscale --enable-vdpau --enable-version3
    --enable-x11grab" [3]=> string(35) " libavutil 50.15. 1 / 50.15. 1" [4]=> string(35) "
    libavcodec 52.72. 2 / 52.72. 2" [5]=> string(35) " libavformat 52.64. 2 / 52.64. 2"
    [6]=> string(35) " libavdevice 52. 2. 0 / 52. 2. 0" [7]=> string(35) " libavfilter 1.19. 0 / 1.19. 0" [8]=>
    string(35) " libswscale 0.11. 0 / 0.11. 0" [9]=> string(35) " libpostproc 51. 2. 0 / 51. 2. 0" [10]=>
    string(52) "Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'eliza.mp4':" [11]=> string(11) " Metadata:" [12]=>
    string(26) " major_brand : mp42" [13]=> string(23) " minor_version : 0" [14]=> string(35) " compatible_brands:
    mp42isomavc1" [15]=> string(48) " encoder : HandBrake 0.9.4 2009112300" [16]=> string(59) " Duration:
    00:00:05.56, start: 0.000000, bitrate: 551 kb/s" [17]=> string(94) " Stream #0.0(und): Video: h264,
    yuv420p, 560x320, 465 kb/s, 30 fps, 30 tbr, 90k tbn, 60 tbc" [18]=> string(62) " Stream #0.1(eng):
    Audio: aac, 48000 Hz, mono, s16, 83 kb/s" [19]=> string(72) "[webm @ 0x7200a0]Only VP8 video and
    Vorbis audio are supported for WebM." [20]=> string(33) "Output #0, webm, to 'video.webm':"
    [21]=> string(11) " Metadata:" [22]=> string(33) " encoder : Lavf52.64.2" [23]=> string(89) "
    Stream #0.0(und): Video: libx264, yuv420p, 560x320, q=2-31, 465 kb/s, 90k tbn, 30 tbc" [24]=>
    string(61) " Stream #0.1(eng): Audio: libfaac, 48000 Hz, mono, 83 kb/s" [25]=> string(15)
    "Stream mapping:" [26]=> string(21) " Stream #0.0 -> #0.0" [27]=> string(21) " Stream #0.1 ->
    #0.1" [28]=> string(72) "Could not write header for output file #0 (incorrect codec parameters ?)" }
  • Node.js Webm live stream server : issues with tag

    10 décembre 2013, par breathe0

    I'm using Node.js as stream server to stream realtime Webm videos that is sent by FFMPEG (executed from another application, the stream is done via HTTP) and received by a webapp that uses the tag.

    This is what I'm doing : FFMPEG streams the received frames using the following command :

    ffmpeg -r 30 -f rawvideo  -pix_fmt bgra -s 640x480
    -i \\.\pipe\STREAM_PIPE -r 60
    -f segment  -s 240x160 -codec:v libvpx  -f webm
    http://my.domain.com/video_stream.webm

    (the stream comes from an application that uses the Kinect as source and communicates with FFMPEG through a pipe, sending one frame after another)

    When the webapp connects, it receives immediately this response from the server :

    HTTP/1.1 200 OK
    X-Powered-By: Express
    content-type: video/webm
    cache-control: private
    connection: close
    Date: Fri, 06 Dec 2013 14:36:31 GMT

    and a Webm header (previously stored on the server, with the same resolution and frame rate of the source stream and tested as working on VLC) is immediately appended. Then the webapp starts to receive the data streamed by FFMPEG. Here is a screenshot of Mkvinfo GUI showing the fields of the header :

    Header screenshot

    However, even if the Network tab of the Chrome console shows that there is an actual stream of data (meaning that what is streamed is not completely garbage, otherwise the connection would be dropped), the player doesn't display anything. We tried to manually prepend our header to the dumped video received by the webapp and VLC plays it just fine, but this is not happening with the tag.

    What can cause this problem ? Are we missing something about the encoding on the FFMPEG side or we stored wrong values on the header (or they're not enough) ?

    PS : I cannot rely on an extern stream server.

    PPS : We tried the following experiments :

    • substituting the video header with the one stored in the server makes the video playable on both vlc and video tag
    • if we dump the video that is already started (without an header) and we prepend the video header stored in the server or even its original header, the video is playable in VLC but not on the tag (we're carefully prepending the header just before the beggining of the cluster).
  • imageJpeg and FFMPEG in windows vs linux

    25 janvier 2020, par Tanmay Gawankar

    I have a working code for converting image to a 5 seconds video using FFMPEG.

    The problem is, The code only works for downloaded images, FFMPEG doesn’t convert image to video when image is generated programmatically ONLY IN LINUX.

    PHP code

    <?php
       $downloadedF="folder/d.jpg";
       $downloadedV="folder/d.mp4";
       $renderedF="folder/r.jpg";
       $renderedV="folder/r.mp4";

       $op_d=shell_exec("ffmpeg -r 1/5 -i ".$downloadedF." -c:v libx264 -vf fps=25 -pix_fmt yuv420p ".$downloadedV);
       $op_r=shell_exec("ffmpeg -r 1/5 -i ".$renderedF." -c:v libx264 -vf fps=25 -pix_fmt yuv420p ".$renderedV);

       echo "Errors:<br />".$op_d."<br /><br />".$op_r;
    ?>

    The d.mp4(or output for downloaded image) is getting generated for both Windows and Linux
    The r.mp4(or output for rendered image) gets generated only in Windows and 48 bytes empty file is getting created in Linux

    System :

    XAMPP on Windows 10(Development)
    Godaddy Starter plan hosting - Linux(Probably redhat)(Production)

    File Structure

    root folder
       |-index.php
       |-ffmpeg (will be ffmpeg.exe in Windows)
       |-folder
           |-d.jpg (random downloaded image from google)
           |-d.mp4 (Will be created - video converted from downloaded image)
           |-r.jpg (rendered image using php imagejpg)
           |-r.mp4 (Will be created - video converted from rendered image)

    Rendered Image Code :

    $imgFF = imagecreatetruecolor($videoWidth, $videoHeight);
    //---adding many text using imagettftext();
    imagejpeg($imgFF, $path."-000.jpg");  //for this example, I copied output to folder as r.jpg

    Edit 1 :

    The return value of shell_exec has no error/output even after adding

    error_reporting(E_ALL);
    ini_set('display_errors', 1);

    Edit 2 :

    The log for successful conversion can be found at Here
    The log for unsuccessful conversion of rendered image can be found at Here

    Note :

    • The scenario here is minimized and code is separated from long code.
    • In Linux command i add ./ for FFMPEG