Recherche avancée

Médias (1)

Mot : - Tags -/MediaSPIP 0.2

Autres articles (91)

  • Websites made ​​with MediaSPIP

    2 mai 2011, par

    This page lists some websites based on MediaSPIP.

  • 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" (...)

  • Creating farms of unique websites

    13 avril 2011, par

    MediaSPIP platforms can be installed as a farm, with a single "core" hosted on a dedicated server and used by multiple websites.
    This allows (among other things) : implementation costs to be shared between several different projects / individuals rapid deployment of multiple unique sites creation of groups of like-minded sites, making it possible to browse media in a more controlled and selective environment than the major "open" (...)

Sur d’autres sites (7212)

  • webcam displayed on LAN not to the internet

    9 juin 2015, par Francois Baret

    OK, this is not due to a dumb mistake : I have forwarded the port and there is no firewall in between.
    I try to make the "live streaming" section of jsmpeg (https://github.com/phoboslab/jsmpeg) to work on the Internet. To get the webcam stream on my webpage I modify "stream-server.js"

    if( process.argv.length < 3 ) {
            console.log(
                    'Usage: \n' +
                    'node stream-server.js <secret> [ ]'
            );
            process.exit();
    }

    var STREAM_SECRET = process.argv[2],
            STREAM_PORT = process.argv[3] || 8082,
            WEBSOCKET_PORT = process.argv[4] || 8084,
            STREAM_MAGIC_BYTES = 'jsmp'; // Must be 4 bytes

    var width = 320,
            height = 240;

    // Websocket Server
    var socketServer = new (require('ws').Server)({port: WEBSOCKET_PORT});
    socketServer.on('connection', function(socket) {
            // Send magic bytes and video size to the newly connected socket
            // struct { char magic[4]; unsigned short width, height;}
            var streamHeader = new Buffer(8);
            streamHeader.write(STREAM_MAGIC_BYTES);
            streamHeader.writeUInt16BE(width, 4);
            streamHeader.writeUInt16BE(height, 6);
            socket.send(streamHeader, {binary:true});

            console.log( 'New WebSocket Connection ('+socketServer.clients.length+' total)' );
           
            socket.on('close', function(code, message){
                    console.log( 'Disconnected WebSocket ('+socketServer.clients.length+' total)' );
            });
    });

    socketServer.broadcast = function(data, opts) {
            for( var i in this.clients ) {
                    if (this.clients[i].readyState == 1) {
                            this.clients[i].send(data, opts);
                    }
                    else {
                            console.log( 'Error: Client ('+i+') not connected.' );
                    }
            }
    };


    // HTTP Server to accept incomming MPEG Stream
    var streamServer = require('http').createServer( function(request, response) {
            var params = request.url.substr(1).split('/');

            if( params[0] == STREAM_SECRET ) {
                    width = (params[1] || 320)|0;
                    height = (params[2] || 240)|0;
                   
                    console.log(
                            'Stream Connected: ' + request.socket.remoteAddress +
                            ':' + request.socket.remotePort + ' size: ' + width + 'x' + height
                    );
                    request.on('data', function(data){
                            socketServer.broadcast(data, {binary:true});
                    });
            }
            else {
                    console.log(
                            'Failed Stream Connection: '+ request.socket.remoteAddress +
                            request.socket.remotePort + ' - wrong secret.'
                    );
                    response.end();
            }
    }).listen(STREAM_PORT);

    console.log('Listening for MPEG Stream on http://127.0.0.1:'+STREAM_PORT+'/<secret>/<width>/<height>');
    console.log('Awaiting WebSocket connections on ws://127.0.0.1:'+WEBSOCKET_PORT+'/');

    var servi = require('servi'),                // include the servi library
            app = new servi(false);                // servi instance

    // configure the server's behavior:
    app.port(8080);                                                // port number to run the server on
    app.serveFiles("public");                        // serve all static HTML files from /public
    app.start();       
    console.log("Listening for new clients on port 8080");</height></width></secret></secret>
           
           
           


    <h1>
    The Canvas size specified
    </h1>
           
            <canvas width="640" height="480">
                    <p>
                            Please use a browser that supports the Canvas Element, like
                            <a href="http://www.google.com/chrome">Chrome</a>,
                            <a href="http://www.mozilla.com/firefox/">Firefox</a>,
                            <a href="http://www.apple.com/safari/">Safari</a> or Internet Explorer 10
                    </p>
            </canvas>
            <code class="echappe-js">&lt;script type=&quot;text/javascript&quot; src=&quot;http://stackoverflow.com/feeds/tag/jsmpg.js&quot;&gt;&lt;/script&gt;
    &lt;script type=&quot;text/javascript&quot;&gt;<br />
                    // Show loading notice<br />
                    var canvas = document.getElementById('videoCanvas');<br />
                    var ctx = canvas.getContext('2d');<br />
                    ctx.fillStyle = '#444';<br />
                    ctx.fillText('Loading...', canvas.width/2-30, canvas.height/3);<br />
    <br />
                    // Setup the WebSocket connection and start the player<br />
                    var client = new WebSocket( 'ws://192.168.1.15:8084/' );<br />
                    var player = new jsmpeg(client, {canvas:canvas});<br />
            &lt;/script&gt;

    The "index.html" is included in a "public" folder.

    Then I start ffmpeg with :

    `ffmpeg -s 640x480 -f video4linux2 -i /dev/video0 -f mpeg1video -b:v 800k -r 30 http://192.168.1.15:8082/1693/640/480/`

    When I open, on any station of the lan, url 192.168.1.x:8080 I get the webcam streaming on my page "jsmpeg streaming webcam" ; but if use the public ip 41.142.x.y:8080 from outside the local network (using 3G) I get the page (with the h1 line "The Canvas size specified") but no video it just says in the frame "loading".
    I do not understand why it works locally and not globally. Why the page is streaming on the internet but not the webcam ?
    Thanks for your help !

  • webcam displayed on LAN not to the internet

    6 novembre 2017, par Francois Baret

    OK, this is not due to a dumb mistake : I have forwarded the port and there is no firewall in between.
    I try to make the "live streaming" section of jsmpeg (https://github.com/phoboslab/jsmpeg) to work on the Internet. To get the webcam stream on my webpage I modify "stream-server.js"

    if( process.argv.length &lt; 3 ) {
            console.log(
                    'Usage: \n' +
                    'node stream-server.js <secret> [ ]'
            );
            process.exit();
    }

    var STREAM_SECRET = process.argv[2],
            STREAM_PORT = process.argv[3] || 8082,
            WEBSOCKET_PORT = process.argv[4] || 8084,
            STREAM_MAGIC_BYTES = 'jsmp'; // Must be 4 bytes

    var width = 320,
            height = 240;

    // Websocket Server
    var socketServer = new (require('ws').Server)({port: WEBSOCKET_PORT});
    socketServer.on('connection', function(socket) {
            // Send magic bytes and video size to the newly connected socket
            // struct { char magic[4]; unsigned short width, height;}
            var streamHeader = new Buffer(8);
            streamHeader.write(STREAM_MAGIC_BYTES);
            streamHeader.writeUInt16BE(width, 4);
            streamHeader.writeUInt16BE(height, 6);
            socket.send(streamHeader, {binary:true});

            console.log( 'New WebSocket Connection ('+socketServer.clients.length+' total)' );
           
            socket.on('close', function(code, message){
                    console.log( 'Disconnected WebSocket ('+socketServer.clients.length+' total)' );
            });
    });

    socketServer.broadcast = function(data, opts) {
            for( var i in this.clients ) {
                    if (this.clients[i].readyState == 1) {
                            this.clients[i].send(data, opts);
                    }
                    else {
                            console.log( 'Error: Client ('+i+') not connected.' );
                    }
            }
    };


    // HTTP Server to accept incomming MPEG Stream
    var streamServer = require('http').createServer( function(request, response) {
            var params = request.url.substr(1).split('/');

            if( params[0] == STREAM_SECRET ) {
                    width = (params[1] || 320)|0;
                    height = (params[2] || 240)|0;
                   
                    console.log(
                            'Stream Connected: ' + request.socket.remoteAddress +
                            ':' + request.socket.remotePort + ' size: ' + width + 'x' + height
                    );
                    request.on('data', function(data){
                            socketServer.broadcast(data, {binary:true});
                    });
            }
            else {
                    console.log(
                            'Failed Stream Connection: '+ request.socket.remoteAddress +
                            request.socket.remotePort + ' - wrong secret.'
                    );
                    response.end();
            }
    }).listen(STREAM_PORT);

    console.log('Listening for MPEG Stream on http://127.0.0.1:'+STREAM_PORT+'/<secret>/<width>/<height>');
    console.log('Awaiting WebSocket connections on ws://127.0.0.1:'+WEBSOCKET_PORT+'/');

    var servi = require('servi'),                // include the servi library
            app = new servi(false);                // servi instance

    // configure the server's behavior:
    app.port(8080);                                                // port number to run the server on
    app.serveFiles("public");                        // serve all static HTML files from /public
    app.start();       
    console.log("Listening for new clients on port 8080");</height></width></secret></secret>
           
           
           


    <h1>
    The Canvas size specified
    </h1>
           
            <canvas width="640" height="480">
                    <p>
                            Please use a browser that supports the Canvas Element, like
                            <a href="http://www.google.com/chrome">Chrome</a>,
                            <a href="http://www.mozilla.com/firefox/">Firefox</a>,
                            <a href="http://www.apple.com/safari/">Safari</a> or Internet Explorer 10
                    </p>
            </canvas>
            <code class="echappe-js">&lt;script type=&quot;text/javascript&quot; src='http://stackoverflow.com/feeds/tag/jsmpg.js'&gt;&lt;/script&gt;
    &lt;script type=&quot;text/javascript&quot;&gt;<br />
                    // Show loading notice<br />
                    var canvas = document.getElementById('videoCanvas');<br />
                    var ctx = canvas.getContext('2d');<br />
                    ctx.fillStyle = '#444';<br />
                    ctx.fillText('Loading...', canvas.width/2-30, canvas.height/3);<br />
    <br />
                    // Setup the WebSocket connection and start the player<br />
                    var client = new WebSocket( 'ws://192.168.1.15:8084/' );<br />
                    var player = new jsmpeg(client, {canvas:canvas});<br />
            &lt;/script&gt;

    The "index.html" is included in a "public" folder.

    Then I start ffmpeg with :

    `ffmpeg -s 640x480 -f video4linux2 -i /dev/video0 -f mpeg1video -b:v 800k -r 30 http://192.168.1.15:8082/1693/640/480/`

    When I open, on any station of the lan, url 192.168.1.x:8080 I get the webcam streaming on my page "jsmpeg streaming webcam" ; but if use the public ip 41.142.x.y:8080 from outside the local network (using 3G) I get the page (with the h1 line "The Canvas size specified") but no video it just says in the frame "loading".
    I do not understand why it works locally and not globally. Why the page is streaming on the internet but not the webcam ?
    Thanks for your help !

  • Revision e5fb6321a1 : give vp9 variance struct a unique name variance_vtable clashed with vp8/common/

    23 février 2013, par James Zern

    Changed Paths : Modify /vp9/common/vp9_rtcd_defs.sh Modify /vp9/encoder/vp9_variance.h give vp9 variance struct a unique name variance_vtable clashed with vp8/common/variance.h Change-Id : I09c1de44d5519f1bd13f58c01144c0de4706de6f