Recherche avancée

Médias (91)

Autres articles (39)

  • MediaSPIP v0.2

    21 juin 2013, par

    MediaSPIP 0.2 est la première version de MediaSPIP stable.
    Sa date de sortie officielle est le 21 juin 2013 et est annoncée ici.
    Le fichier zip ici présent contient uniquement les sources de MediaSPIP en version standalone.
    Comme pour la version précédente, il est nécessaire d’installer manuellement l’ensemble des dépendances logicielles sur le serveur.
    Si vous souhaitez utiliser cette archive pour une installation en mode ferme, il vous faudra également procéder à d’autres modifications (...)

  • Mise à disposition des fichiers

    14 avril 2011, par

    Par défaut, lors de son initialisation, MediaSPIP ne permet pas aux visiteurs de télécharger les fichiers qu’ils soient originaux ou le résultat de leur transformation ou encodage. Il permet uniquement de les visualiser.
    Cependant, il est possible et facile d’autoriser les visiteurs à avoir accès à ces documents et ce sous différentes formes.
    Tout cela se passe dans la page de configuration du squelette. Il vous faut aller dans l’espace d’administration du canal, et choisir dans la navigation (...)

  • MediaSPIP version 0.1 Beta

    16 avril 2011, par

    MediaSPIP 0.1 beta est la première version de MediaSPIP décrétée comme "utilisable".
    Le fichier zip ici présent contient uniquement les sources de MediaSPIP en version standalone.
    Pour avoir une installation fonctionnelle, il est nécessaire d’installer manuellement l’ensemble des dépendances logicielles sur le serveur.
    Si vous souhaitez utiliser cette archive pour une installation en mode ferme, il vous faudra également procéder à d’autres modifications (...)

Sur d’autres sites (4888)

  • How to optimize FFMPEG with pipe and memory reuse in Tide SDK

    7 janvier 2014, par Vincent Duprez

    Im running into an speed optimization issue. Im building a video cut tool in web technologies on desktop with TideSDK. On of the tools has a timeline with a position slider

    basically, whenever the slider moves, (using jquery UI), I get the position, translate this into a timecode and asks FFMPEG to encode to a file, when a get the finished event, I simply update the background-image attribute of the 'viewer' to this file. The file is located in some temporary folder.

    The thing is, it is just a bit too slow. Usable, but slow (approx 2 fps on a High end Computer)
    I think there are 2 bottlenecks on this strategy :
    - Writing ffmpeg output to a file & reading back in css
    - repeatedly loading the same movie file in ffmpeg

    This is the code executed on each move (var timecode is the calculated timecode based on the pointer position)

    var cmd = [FFMPEG];
    cmd.push('-y'); //overwrite existing files
    cmd.push('-ss',timecode); //CUE position
    cmd.push('-i',input); //input file
    cmd.push('-f','image2'); //output format
    cmd.push('-vframes','1'); //number of images to render
    cmd.push(Ti.API.Application.getDataPath( )+"/encoderframe.jpg"); //output file

    var makeframe = Ti.Process.createProcess(cmd);
    makeframe.setOnReadLine(function(data){ /*console.log(data);*/ });
    var time = new Date().getTime();
    makeframe.setOnExit(function(){ ffmpegrunning = false;  $('#videoframe').css('background-image','url(file://'+Ti.API.Application.getDataPath( ).replace(" ","%20")+'/encoderframe.jpg?'+time+')');     });
    makeframe.launch();

    Basically, this repeatedly asks the same Command :

    ffmpeg -y -ss 00:00:01.04 -i /somepath/somevideo.mov -f image2 -vframes 1 /path/to/output/encoderframe204.jpg

    How can I optimize this code, Pipe to output straight to css background with Base64 data, or reuse loaded memory file in ffmpeg. ?

    Thanks !

  • How can I stream mjpeg file as rtsp

    24 août 2013, par Ilya Yevlampiev

    We have an mjpeg video, obtained from the webcam and stored into *.avi file, still encoded as mjpeg.

    We need to restream this file as rtsp (and stil preserve the mjpeg there, i.e. no decoding). The goal is to emulate the webcam this video was obtained from for the software that processes the video. The file can be open with vlc/ffplay with no problems. The ffmpeg behaves like it is streaming it, however, ffplay/vlc can't open this stream.

    We tried to stream if with gstreamer.

    1) we fount no free rtsp sink element for gstreamer pipeline. So, is there a free analogue for rtspsink to launch this pipeline with gst-launch ? we need and only cast, so we don't need so advanced element as rtspsink is.

    2) we also tried to build own simple rtsp server as described in http://weeklybuild.com/2013/01/creating-an-rtsp-stream-with-gstreamer/

    replacing videotestsrc with filesrc ; but what kind of elements we should use there ? usage of an only filesrc doesn't help ; we get the same problem as if we stream with ffmpeg. But what kind of lements we need there, if we dont' wan to decode/encode it, just to stream the file (to reproduce the thing what the webcam actually does).

    $ ffplay rtsp://127.0.0.1:8554/test -loglevel debug
    avplay version 0.8.5-6:0.8.5-1, Copyright (c) 2003-2012 the Libav developers
    built on Jan 13 2013 12:05:48 with gcc 4.7.2
    configuration: --arch=amd64 --enable-pthreads --enable-runtime-cpudetect --extra-version='6:0.8.5-1' --libdir=/usr/lib/x86_64-linux-gnu --prefix=/usr --enable-bzlib --enable-libdc1394 --enable-libdirac --enable-libfreetype --enable-frei0r --enable-gnutls --enable-libgsm --enable-libmp3lame --enable-librtmp --enable-libopencv --enable-libopenjpeg --enable-libpulse --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-vaapi --enable-vdpau --enable-libvorbis --enable-libvpx --enable-zlib --enable-gpl --enable-postproc --enable-swscale --enable-libcdio --enable-x11grab --enable-libx264 --enable-libxvid --shlibdir=/usr/lib/x86_64-linux-gnu --enable-shared --disable-static
    avutil      configuration: --arch=amd64 --enable-pthreads --enable-runtime-cpudetect --extra-version='6:0.8.4-1' --libdir=/usr/lib/x86_64-linux-gnu --prefix=/usr --enable-bzlib --enable-libdc1394 --enable-libdirac --enable-libfreetype --enable-frei0r --enable-gnutls --enable-libgsm --enable-libmp3lame --enable-librtmp --enable-libopencv --enable-libopenjpeg --enable-libpulse --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-vaapi --enable-vdpau --enable-libvorbis --enable-libvpx --enable-zlib --enable-gpl --enable-postproc --enable-swscale --enable-libcdio --enable-x11grab --enable-libx264 --enable-libxvid --shlibdir=/usr/lib/x86_64-linux-gnu --enable-shared --disable-static
    avcodec     configuration: --arch=amd64 --enable-pthreads --enable-runtime-cpudetect --extra-version='6:0.8.4-1' --libdir=/usr/lib/x86_64-linux-gnu --prefix=/usr --enable-bzlib --enable-libdc1394 --enable-libdirac --enable-libfreetype --enable-frei0r --enable-gnutls --enable-libgsm --enable-libmp3lame --enable-librtmp --enable-libopencv --enable-libopenjpeg --enable-libpulse --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-vaapi --enable-vdpau --enable-libvorbis --enable-libvpx --enable-zlib --enable-gpl --enable-postproc --enable-swscale --enable-libcdio --enable-x11grab --enable-libx264 --enable-libxvid --shlibdir=/usr/lib/x86_64-linux-gnu --enable-shared --disable-static
    avformat    configuration: --arch=amd64 --enable-pthreads --enable-runtime-cpudetect --extra-version='6:0.8.4-1' --libdir=/usr/lib/x86_64-linux-gnu --prefix=/usr --enable-bzlib --enable-libdc1394 --enable-libdirac --enable-libfreetype --enable-frei0r --enable-gnutls --enable-libgsm --enable-libmp3lame --enable-librtmp --enable-libopencv --enable-libopenjpeg --enable-libpulse --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-vaapi --enable-vdpau --enable-libvorbis --enable-libvpx --enable-zlib --enable-gpl --enable-postproc --enable-swscale --enable-libcdio --enable-x11grab --enable-libx264 --enable-libxvid --shlibdir=/usr/lib/x86_64-linux-gnu --enable-shared --disable-static
    swscale     configuration: --arch=amd64 --enable-pthreads --enable-runtime-cpudetect --extra-version='6:0.8.4-1' --libdir=/usr/lib/x86_64-linux-gnu --prefix=/usr --enable-bzlib --enable-libdc1394 --enable-libdirac --enable-libfreetype --enable-frei0r --enable-gnutls --enable-libgsm --enable-libmp3lame --enable-librtmp --enable-libopencv --enable-libopenjpeg --enable-libpulse --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-vaapi --enable-vdpau --enable-libvorbis --enable-libvpx --enable-zlib --enable-gpl --enable-postproc --enable-swscale --enable-libcdio --enable-x11grab --enable-libx264 --enable-libxvid --shlibdir=/usr/lib/x86_64-linux-gnu --enable-shared --disable-static
    postproc    configuration: --arch=amd64 --enable-pthreads --enable-runtime-cpudetect --extra-version='6:0.8.4-1' --libdir=/usr/lib/x86_64-linux-gnu --prefix=/usr --enable-bzlib --enable-libdc1394 --enable-libdirac --enable-libfreetype --enable-frei0r --enable-gnutls --enable-libgsm --enable-libmp3lame --enable-librtmp --enable-libopencv --enable-libopenjpeg --enable-libpulse --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-vaapi --enable-vdpau --enable-libvorbis --enable-libvpx --enable-zlib --enable-gpl --enable-            postproc --enable-swscale --enable-libcdio --enable-x11grab --enable-libx264 --enable-libxvid --shlibdir=/usr/lib/x86_64-linux-gnu --enable-shared --disable-static
    libavutil    51. 22. 1 / 51. 22. 1
    libavcodec   53. 35. 0 / 53. 35. 0
    libavformat  53. 21. 1 / 53. 21. 0
    libavdevice  53.  2. 0 / 53.  2. 0
    libavfilter   2. 15. 0 /  2. 15. 0
    libswscale    2.  1. 0 /  2.  1. 0
    libpostproc  52.  0. 0 / 52.  0. 0
    [rtsp @ 0x7f558c0008c0] method DESCRIBE failed: 503 Service Unavailable
    [rtsp @ 0x7f558c0008c0] CSeq: 2
    Server: GStreamer RTSP server
    Date: Thu, 22 Aug 2013 07:49:30 GMT

    rtsp://127.0.0.1:8554/test: Invalid data found when processing input

    And everything is okay when I try gstreamer server built as in example, i.e. using videotestsrc

  • Record web browser with sound as a service on linux server with puppeteer

    12 septembre 2021, par NA GUY

    I'm trying to build a service on a linux server to record video a web browser with its sound.

    


    The first step I did with the source code below (using xvfb, puppeteer and ffmpeg) to record successfully.

    


    However when I do a recording with different processes at a same time (different websites) the audio gets mixed up between the processes.
I know this is happening because I used the same default audio output for all processes.

    


    The question is : how can I record the browser with sound that doesn't get mixed up between different processes ?

    


    My sample code below :

    


    var Xvfb = require('xvfb');
var puppeteer = require('puppeteer');
const { spawn, spawnSync } = require('child_process');

async function record() {

    var xvfb = new Xvfb({
        displayNum: 99,
        reuse: false,
        xvfb_args: [
            "-screen", "0", "1920x1080x24",
            "-ac",
            "-nolisten", "tcp",
            "-dpi", "96",
            "+extension", "RANDR"
        ]
    });

    xvfb.startSync();

    var browser = await puppeteer.launch({
        headless: false,
        defaultViewport: null,
        ignoreDefaultArgs: [
            "--mute-audio",
            "--enable-automation"
        ],
        args: [
            "--use-fake-ui-for-media-stream",
            "--window-size=1920,1080",
            "--start-fullscreen"
        ]
    });
    const page = await browser.newPage();

    var url = "http://www.noiseaddicts.com/free-samples-mp3/?id=2544";
    await page.goto(url);
    await page.click('span.map_play');

    var time = new Date().getTime();

    var options = [
        "-video_size", "1920x1080",
        "-framerate", "30",
        "-f", "x11grab",
        "-draw_mouse", "0",
        "-i", ":99",

        "-f", "pulse",
        "-ac", "2",
        "-i", "1",
        "./output" + time + ".mkv"
    ];

    var cmd = 'ffmpeg';

    var proc = spawn(cmd, options);

    proc.stdout.on('data', function (data) {
        console.log(data);
    });

    proc.stderr.setEncoding("utf8")
    proc.stderr.on('data', function (data) {
        console.log(data);
    });

    proc.on('close', async function () {
        console.log('finished');
        xvfb.stopSync();
    });
}

record();