Recherche avancée

Médias (1)

Mot : - Tags -/livre électronique

Autres articles (55)

  • Participer à sa traduction

    10 avril 2011

    Vous pouvez nous aider à améliorer les locutions utilisées dans le logiciel ou à traduire celui-ci dans n’importe qu’elle nouvelle langue permettant sa diffusion à de nouvelles communautés linguistiques.
    Pour ce faire, on utilise l’interface de traduction de SPIP où l’ensemble des modules de langue de MediaSPIP sont à disposition. ll vous suffit de vous inscrire sur la liste de discussion des traducteurs pour demander plus d’informations.
    Actuellement MediaSPIP n’est disponible qu’en français et (...)

  • Récupération d’informations sur le site maître à l’installation d’une instance

    26 novembre 2010, par

    Utilité
    Sur le site principal, une instance de mutualisation est définie par plusieurs choses : Les données dans la table spip_mutus ; Son logo ; Son auteur principal (id_admin dans la table spip_mutus correspondant à un id_auteur de la table spip_auteurs)qui sera le seul à pouvoir créer définitivement l’instance de mutualisation ;
    Il peut donc être tout à fait judicieux de vouloir récupérer certaines de ces informations afin de compléter l’installation d’une instance pour, par exemple : récupérer le (...)

  • Supporting all media types

    13 avril 2011, par

    Unlike most software and media-sharing platforms, MediaSPIP aims to manage as many different media types as possible. The following are just a few examples from an ever-expanding list of supported formats : images : png, gif, jpg, bmp and more audio : MP3, Ogg, Wav and more video : AVI, MP4, OGV, mpg, mov, wmv and more text, code and other data : OpenOffice, Microsoft Office (Word, PowerPoint, Excel), web (html, CSS), LaTeX, Google Earth and (...)

Sur d’autres sites (7498)

  • "Invalid or unexpected token" error when trying to execute ffmpeg build on lambda

    4 janvier 2019, par almarc

    I have a node.js script that uses ffmpeg to convert mp4 downloaded from YT to mp3 and save to Amazon S3. Uploading using the serverless framework. The "ffmpeg" file is included in the main directory (with .yml), downloaded from here :
    https://johnvansickle.com/ffmpeg/

    The code :

    'use strict'
    process.env.PATH = process.env.PATH + ':/tmp/'
    process.env['FFMPEG_PATH'] = '/tmp/ffmpeg';
    const BIN_PATH = process.env['LAMBDA_TASK_ROOT']
    process.env['PATH'] = process.env['PATH'] + ':' + BIN_PATH;

    module.exports.download_mp3 = function (event, context, callback)
    {
     require('child_process').exec('cp /var/task/ffmpeg /tmp/.; chmod 755
     /tmp/ffmpeg;', function (error, stdout, stderr) {
     if (error)
     {
       console.log('An error occured', error);
       callback(null, null)
     }
     else
     {
       var ffmpeg = require('ffmpeg');
       const aws = require('aws-sdk')
       const s3 = new aws.S3()
       const ytdl = require('ytdl-core');

       function uploadFromStream(s3) {
         const stream = require('stream')
         var pass = new stream.PassThrough();

         var params = {Bucket: "some-bucket", Key: "some-key", Body: pass};
         s3.upload(params, function(err, data) {
           console.log(err, data);
         });
         console.log("Should be finished")
         callback(null)
       }

       let stream = ytdl("some-video-id", {
         quality: 'highestaudio',
         filter: 'audioonly'
       });

       ffmpeg(stream)
         .audioBitrate(128)
         .format('mp3')
         .on('error', (err) => console.error(err))
         .pipe(uploadFromStream(s3), {
           end: true
       });
     }})
    }

    When triggered, the function writes an error in logs :

    2019-01-04T14:50:54.525Z    21da4d49-1030-11e9-b901-0dc32b691a16    
    /var/task/ffmpeg:1
    (function (exports, require, module, __filename, __dirname) { ELF
    ^

    SyntaxError: Invalid or unexpected token
    at createScript (vm.js:80:10)
    at Object.runInThisContext (vm.js:139:10)
    at Module._compile (module.js:616:28)
    at Object.Module._extensions..js (module.js:663:10)
    at Module.load (module.js:565:32)
    at tryModuleLoad (module.js:505:12)
    at Function.Module._load (module.js:497:3)
    at Module.require (module.js:596:17)
    at require (internal/module.js:11:18)
    at /var/task/download.js:17:18

    It’s, most definetely, an error in the "ffmpeg" file I’ve mentioned above (link provided). But I don’t know what’s the exact issue, I followed the first answer here : https://stackoverflow.com/questions/47882810/lambda-not-connecting-to-ffmpeg to include the ffmpeg build.

  • FFMPEG streaming ip cam get delay from start record to first frame

    4 janvier 2019, par Vincent Carretero

    I’m recording stream from IP CAM with FFMPEG.
    I would like to know the exact timestamp when start the output video.

    Example :
    I have an output mp4 file created at 2019/01/04 09:10:15 (file created).
    FFMpeg take few seconds to really start streaming (initialising, etc...)
    The first frame really start at 2019/01/04 09:10:19 (just supposed, I would like to get this info).

    Thanks !

  • Overlay a video on another video at specific time with FFmpeg

    4 janvier 2019, par Tina J

    I am trying to overlay a video with another video. I followed the original command OP posted here. And it works, but it overlays the video from time 0 :

    ffmpeg -i 720480.mp4 -i sdbug.mov -filter_complex "[0:0][1:0]overlay[out]" -shortest -map [out] -map 0:1 -pix_fmt yuv420p -c:a copy -c:v libx264 -crf 18  new.mp4

    I tried the correct answer to specify a time, but it is not working for me : 1) the overlay starts at around second 12, and 2) video is not played after the overlay is finished.

    ffmpeg -i 720480.mp4 -i sdbug.mov -filter_complex "[1:v]setpts=PTS+10/TB[a]; [0:v][a]overlay=enable=gte(t\,5):shortest=1[out]" -map [out] -map 0:a -c:v libx264 -crf 18 -pix_fmt yuv420p -c:a copy new.mp4

    Anything changed recently on FFmpeg ?! Why isn’t it working ?

    Here is the output of this command (it finishes very fast) :

    ffmpeg version N-92906-g54109b1d14 Copyright (c) 2000-2019 the FFmpeg developers
     built with gcc 8.2.1 (GCC) 20181201
     configuration: --enable-gpl --enable-version3 --enable-sdl2 --enable-fontconfig --enable-gnutls --enable-iconv --enable-libass --enable-libbluray --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --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-libvo-amrwbenc --enable-libmysofa --enable-libspeex --enable-libxvid --enable-libaom --enable-libmfx --enable-amf --enable-ffnvcodec --enable-cuvid --enable-d3d11va --enable-nvenc --enable-nvdec --enable-dxva2 --enable-avisynth --enable-libopenmpt
     libavutil      56. 25.100 / 56. 25.100
     libavcodec     58. 43.100 / 58. 43.100
     libavformat    58. 25.100 / 58. 25.100
     libavdevice    58.  6.101 / 58.  6.101
     libavfilter     7. 46.101 /  7. 46.101
     libswscale      5.  4.100 /  5.  4.100
     libswresample   3.  4.100 /  3.  4.100
     libpostproc    55.  4.100 / 55.  4.100
    Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '720480.mp4':
     Metadata:
       major_brand     : isom
       minor_version   : 512
       compatible_brands: isomiso2avc1mp41
       creation_time   : 2018-07-26T09:23:16.000000Z
     Duration: 00:01:50.17, start: 0.000000, bitrate: 3181 kb/s
       Stream #0:0: Video: h264 (High) (avc1 / 0x31637661), yuv420p(tv, smpte170m/smpte170m/bt709), 720x480 [SAR 8:9 DAR 4:3], 2785 kb/s, 29.97 fps, 29.97 tbr, 30k tbn, 59.94 tbc (default)
       Metadata:
         creation_time   : 2018-07-26T09:23:16.000000Z
         handler_name    : VideoHandler
         timecode        : 00:59:55:12
       Stream #0:1: Audio: aac (HE-AAC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 98 kb/s (default)
       Metadata:
         creation_time   : 2018-07-26T09:23:16.000000Z
         handler_name    : SoundHandler
       Stream #0:2: Audio: aac (HE-AAC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 98 kb/s (default)
       Metadata:
         creation_time   : 2018-07-26T09:23:16.000000Z
         handler_name    : SoundHandler
       Stream #0:3: Audio: aac (HE-AAC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 98 kb/s (default)
       Metadata:
         creation_time   : 2018-07-26T09:23:16.000000Z
         handler_name    : SoundHandler
       Stream #0:4: Audio: aac (HE-AAC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 98 kb/s (default)
       Metadata:
         creation_time   : 2018-07-26T09:23:16.000000Z
         handler_name    : SoundHandler
       Stream #0:5: Data: none (tmcd / 0x64636D74) (default)
       Metadata:
         creation_time   : 2018-07-26T09:23:16.000000Z
         handler_name    : TimecodeMediaHandler
         timecode        : 00:59:55:12
    Input #1, mov,mp4,m4a,3gp,3g2,mj2, from 'sdbug.mov':
     Metadata:
       major_brand     : qt
       minor_version   : 537199360
       compatible_brands: qt
       creation_time   : 2018-08-29T14:50:13.000000Z
     Duration: 00:00:10.01, start: 0.000000, bitrate: 10504 kb/s
       Stream #1:0(eng): Video: qtrle (rle  / 0x20656C72), bgra(progressive), 720x486, 9666 kb/s, SAR 109:120 DAR 109:81, 29.97 fps, 29.97 tbr, 30k tbn, 30k tbc (default)
       Metadata:
         creation_time   : 2018-08-29T14:50:13.000000Z
         handler_name    : Apple Video Media Handler
         encoder         : Animation
         timecode        : 00:00:00;00
       Stream #1:1(eng): Data: none (tmcd / 0x64636D74), 0 kb/s (default)
       Metadata:
         creation_time   : 2018-08-29T14:50:13.000000Z
         handler_name    : Time Code Media Handler
         timecode        : 00:00:00;00
    Stream mapping:
     Stream #0:0 (h264) -> overlay:main
     Stream #1:0 (qtrle) -> setpts
     overlay -> Stream #0:0 (libx264)
     Stream #0:1 -> #0:1 (copy)
     Stream #0:2 -> #0:2 (copy)
     Stream #0:3 -> #0:3 (copy)
     Stream #0:4 -> #0:4 (copy)
    Press [q] to stop, [?] for help
    [libx264 @ 000002b902a3f480] using SAR=8/9
    [libx264 @ 000002b902a3f480] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX FMA3 BMI2 AVX2
    [libx264 @ 000002b902a3f480] profile High, level 3.0, 4:2:0, 8-bit
    [libx264 @ 000002b902a3f480] 264 - core 157 r2935 545de2f - H.264/MPEG-4 AVC codec - Copyleft 2003-2018 - 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 lookahead_threads=2 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=18.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00
    Output #0, mp4, to 'new.mp4':
     Metadata:
       major_brand     : isom
       minor_version   : 512
       compatible_brands: isomiso2avc1mp41
       encoder         : Lavf58.25.100
       Stream #0:0: Video: h264 (libx264) (avc1 / 0x31637661), yuv420p, 720x480 [SAR 8:9 DAR 4:3], q=-1--1, 29.97 fps, 30k tbn, 29.97 tbc (default)
       Metadata:
         encoder         : Lavc58.43.100 libx264
       Side data:
         cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: -1
       Stream #0:1: Audio: aac (HE-AAC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 98 kb/s (default)
       Metadata:
         creation_time   : 2018-07-26T09:23:16.000000Z
         handler_name    : SoundHandler
       Stream #0:2: Audio: aac (HE-AAC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 98 kb/s (default)
       Metadata:
         creation_time   : 2018-07-26T09:23:16.000000Z
         handler_name    : SoundHandler
       Stream #0:3: Audio: aac (HE-AAC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 98 kb/s (default)
       Metadata:
         creation_time   : 2018-07-26T09:23:16.000000Z
         handler_name    : SoundHandler
       Stream #0:4: Audio: aac (HE-AAC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 98 kb/s (default)
       Metadata:
         creation_time   : 2018-07-26T09:23:16.000000Z
         handler_name    : SoundHandler
    frame=  599 fps= 92 q=-1.0 Lsize=   11556kB time=00:01:50.01 bitrate= 860.5kbits/s speed=16.8x
    video:6173kB audio:5288kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.828358%
    [libx264 @ 000002b902a3f480] frame I:8     Avg QP:13.24  size: 44134
    [libx264 @ 000002b902a3f480] frame P:174   Avg QP:18.62  size: 20916
    [libx264 @ 000002b902a3f480] frame B:417   Avg QP:21.31  size:  5583
    [libx264 @ 000002b902a3f480] consecutive B-frames:  6.0%  1.7%  5.5% 86.8%
    [libx264 @ 000002b902a3f480] mb I  I16..4: 15.9% 58.9% 25.2%
    [libx264 @ 000002b902a3f480] mb P  I16..4:  1.4% 13.6%  4.2%  P16..4: 36.6% 22.8% 12.3%  0.0%  0.0%    skip: 9.0%
    [libx264 @ 000002b902a3f480] mb B  I16..4:  0.1%  0.9%  0.3%  B16..8: 46.4% 10.6%  2.9%  direct: 5.5%  skip:33.3%  L0:53.4% L1:36.9% BI: 9.7%
    [libx264 @ 000002b902a3f480] 8x8 transform intra:68.5% inter:65.1%
    [libx264 @ 000002b902a3f480] coded y,uvDC,uvAC intra: 77.5% 89.5% 77.2% inter: 26.8% 48.1% 10.1%
    [libx264 @ 000002b902a3f480] i16 v,h,dc,p: 50% 13% 13% 23%
    [libx264 @ 000002b902a3f480] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 24% 12% 17%  6%  8% 10%  7%  9%  7%
    [libx264 @ 000002b902a3f480] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 21% 13% 10%  7% 12% 11%  9%  9%  7%
    [libx264 @ 000002b902a3f480] i8c dc,h,v,p: 51% 15% 24% 10%
    [libx264 @ 000002b902a3f480] Weighted P-Frames: Y:5.2% UV:2.9%
    [libx264 @ 000002b902a3f480] ref P L0: 60.1% 19.6% 15.8%  4.4%  0.1%
    [libx264 @ 000002b902a3f480] ref B L0: 91.6%  7.3%  1.1%
    [libx264 @ 000002b902a3f480] ref B L1: 97.2%  2.8%
    [libx264 @ 000002b902a3f480] kb/s:2529.97