Recherche avancée

Médias (0)

Mot : - Tags -/metadatas

Aucun média correspondant à vos critères n’est disponible sur le site.

Autres articles (47)

  • Encodage et transformation en formats lisibles sur Internet

    10 avril 2011

    MediaSPIP transforme et ré-encode les documents mis en ligne afin de les rendre lisibles sur Internet et automatiquement utilisables sans intervention du créateur de contenu.
    Les vidéos sont automatiquement encodées dans les formats supportés par HTML5 : MP4, Ogv et WebM. La version "MP4" est également utilisée pour le lecteur flash de secours nécessaire aux anciens navigateurs.
    Les documents audios sont également ré-encodés dans les deux formats utilisables par HTML5 :MP3 et Ogg. La version "MP3" (...)

  • Les autorisations surchargées par les plugins

    27 avril 2010, par

    Mediaspip core
    autoriser_auteur_modifier() afin que les visiteurs soient capables de modifier leurs informations sur la page d’auteurs

  • 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 (9544)

  • Update Database After shell_exec() Using FFMPEG/Laravel

    25 avril 2020, par Mike

    I want to update a database record (MySQL) after the FFMPEG process is complete. Normally I would just call a function just after the FFMPEG command, but I needed to add > /dev/null 2>/dev/null & so I didn't have to wait for the FFMPEG process to complete which would mean the REST call would hang for a LONG time and that would cause bad UX for the front-end.

    



    I'm not sure where to begin with it. My first thought is to make a REST request, but maybe calling the method in Laravel directly would be better.

    



    Can I do a curl call after the FFMPEG command ? Or can I call a PHP method ? Or is there a better way ?

    



    PHP FFMPEG Method

    



    private function transcode($movie)
{
    try {
        $name       = 'master.' . $movie->extension;
        $this->path = storage_path('app/public/movies/') . $movie->id . '/';
        $fps        = $this->getFrameRate($name);
        $width      = $this->getVideoWidth($name);
        $height     = $this->getVideoHeight($name);

        // ffmpeg commands
        $c = $this->buildCommand($width, $height, $fps);

        // ffmpeg -  added '> /dev/null 2>/dev/null &' so it will not wait to finish
        $ffmpeg = shell_exec('ffmpeg -i ' . $this->path . $name . ' -progress ' . $this->path . 'transcode.log' . $c . ' > /dev/null 2>/dev/null &');

        return response()->json(['message' => 'transcode initiated'], 200); 

    }
    catch(\Exception $e)
    {
        return response()->json(['error' => $e->getMessage()], 500);
    }
}


    



    Here is the bash curl post idea

    



    $curl = 'curl --data "param1=value1&param2=value2" http://hostname/transcode/complete';

$ffmpeg = shell_exec('ffmpeg -i ' . $this->path . $name . ' -progress ' . $this->path . 'transcode.log' . $c . '; $curl > /dev/null 2>/dev/null &');


    



    I could be going down the wrong path with the above, but I'm trying to move forward with something.

    


  • 3 Hours video opens as 3 minutes [ffmpeg][vegas][Windows]

    20 avril 2018, par CrazyFrog

    I have a mp4 video that is 3:55:00 long. However, when I try to edit it with Vegas 13 or ffmpeg, the softwares only find the first 00:03:16 part.

    I tried to search for similar questions, but did not find any answers.

    Video details(Windows explorer) :
    Length : 03:55:00
    Res : 1280x720
    Data rate:1342 kbps
    Total bitrate : 1408 kbps
    Frame rate : 25 f/s

    Audio
    Bit rate:65 kbps
    Channels : 2(stereo)
    Audio sample rate : 44.1 kHz

    Video details(Vegas, ffmpeg) :
    Format : AVC
    ffmpeg compatible_brands : isomiso2avc1mp41

    I tried using ffmpeg to convert it to a regular mp4. Unfortunately it only finds the first 3:16 minutes too.

    UPDATE

    .\ffmpeg.exe -i origin.mp4 -c copy test.mp4

    ffmpeg version N-88514-gd5995c531d Copyright (c) 2000-2017 the FFmpeg developers
    built with gcc 7.2.0 (GCC)
     configuration: --enable-gpl --enable-version3 --enable-sdl2 --enable-bzlib --enable-fontconfig --enable-gnutls --enable-iconv --enable-libass --enable-libbluray --enable-libfreetype --enable-libmp3lame --enable-libopenjpeg --enable-libopus --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libtheora --enable-libtwolame --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libzimg --enable-lzma --enable-zlib --enable-gmp --enable-libvidstab --enable-libvorbis --enable-cuda --enable-cuvid --enable-d3d11va --enable-nvenc --enable-dxva2 --enable-avisynth --enable-libmfx
     libavutil      56.  0.100 / 56.  0.100
     libavcodec     58.  1.100 / 58.  1.100
     libavformat    58.  0.102 / 58.  0.102
     libavdevice    58.  0.100 / 58.  0.100
     libavfilter     7.  0.101 /  7.  0.101
     libswscale      5.  0.101 /  5.  0.101
     libswresample   3.  0.101 /  3.  0.101
     libpostproc    55.  0.100 / 55.  0.100
    Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'origin.mp4':
     Metadata:
       major_brand     : isom
       minor_version   : 512
       compatible_brands: isomiso2avc1mp41
     Duration: 03:55:00.64, start: 0.000000, bitrate: 1414 kb/s
       Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p(tv, bt709), 1280x720, 1343 kb/s, 25 fps, 25 tbr, 12800 tbn, 50 tbc (default)
       Metadata:
         handler_name    : VideoHandler
       Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 44100 Hz, stereo, fltp, 65 kb/s (default)
       Metadata:
         handler_name    : SoundHandler
    Output #0, mp4, to 'test.mp4':
     Metadata:
       major_brand     : isom
       minor_version   : 512
       compatible_brands: isomiso2avc1mp41
       encoder         : Lavf58.0.102
       Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p(tv, bt709), 1280x720, q=2-31, 1343 kb/s, 25 fps, 25 tbr, 12800 tbn, 12800 tbc (default)
       Metadata:
         handler_name    : VideoHandler
       Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 44100 Hz, stereo, fltp, 65 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 help
    frame= 4921 fps=0.0 q=-1.0 Lsize=   26141kB time=00:03:16.72 bitrate=1088.6kbits/s speed=1.68e+003x
    video:24412kB audio:1569kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.619153%
  • Create and update HLS playlist programmatically

    26 février 2018, par Pierre P.

    I have a C++ application that records audio from my default input device, encodes it in AAC format and writes to a .aac file. I want to use HTTP Live Streaming to live stream this AAC file. According to this question, I have to create a FFMPEG script to split my audio file into several .ts files.

    # bitrate, width, and height, you may want to change this
    BR=512k
    WIDTH=432
    HEIGHT=240
    input=${1}

    # strip off the file extension
    output=$(echo ${input} | sed 's/\..*//' )

    # works for most videos
    ffmpeg -y -i ${input} -f mpegts -acodec libmp3lame -ar 48000 -ab 64k -s ${WIDTH}x${HEIGHT} -vcodec libx264 -b ${BR} -flags +loop -cmp +chroma -partitions +parti4x4+partp8x8+partb8x8 -subq 7 -trellis 0 -refs 0 -coder 0 -me_range 16 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -bt 200k -maxrate ${BR} -bufsize ${BR} -rc_eq 'blurCplx^(1-qComp)' -qcomp 0.6 -qmin 30 -qmax 51 -qdiff 4 -level 30 -aspect ${WIDTH}:${HEIGHT} -g 30 -async 2 ${output}-iphone.ts

    (It is slightly different in my case because I only work with audio)

    Can I do so programmatically in C++ and if so, do I have to use a third-part library or does macOS provide native functions to do so ?