
Recherche avancée
Médias (1)
-
Publier une image simplement
13 avril 2011, par ,
Mis à jour : Février 2012
Langue : français
Type : Video
Autres articles (99)
-
MediaSPIP 0.1 Beta version
25 avril 2011, parMediaSPIP 0.1 beta is the first version of MediaSPIP proclaimed as "usable".
The zip file provided here only contains the sources of MediaSPIP in its standalone version.
To get a working installation, you must manually install all-software dependencies on the server.
If you want to use this archive for an installation in "farm mode", you will also need to proceed to other manual (...) -
Multilang : améliorer l’interface pour les blocs multilingues
18 février 2011, parMultilang est un plugin supplémentaire qui n’est pas activé par défaut lors de l’initialisation de MediaSPIP.
Après son activation, une préconfiguration est mise en place automatiquement par MediaSPIP init permettant à la nouvelle fonctionnalité d’être automatiquement opérationnelle. Il n’est donc pas obligatoire de passer par une étape de configuration pour cela. -
Organiser par catégorie
17 mai 2013, parDans MédiaSPIP, une rubrique a 2 noms : catégorie et rubrique.
Les différents documents stockés dans MédiaSPIP peuvent être rangés dans différentes catégories. On peut créer une catégorie en cliquant sur "publier une catégorie" dans le menu publier en haut à droite ( après authentification ). Une catégorie peut être rangée dans une autre catégorie aussi ce qui fait qu’on peut construire une arborescence de catégories.
Lors de la publication prochaine d’un document, la nouvelle catégorie créée sera proposée (...)
Sur d’autres sites (10938)
-
avformat/Makefile : Add entries for CRI, GEM and PGX image pipe demuxers
6 janvier 2022, par Andreas Rheinhardt -
NodeJS - How to pipe same video stream to multiple clients ?
30 août 2013, par SergioBRWe have a situation trying to serve a video stream.
Since HTML5 video tag does not support udp to multicast, we are trying to re-use an already converted ffmpeg stream and send it to more than one response. But that does not work.
The first response gets the stream alright, but the second one does not.
It seems that the stream cannot be piped out to another response, neither can it be cloned.Has anyone done that before ? Any ideas ?
Thanks in advance !
Here's the code :
var request = require('request');
var http = require('http');
var child_process = require("child_process");
var n = 1;
var stdouts = {};
http.createServer(function (req, resp) {
console.log("***** url ["+req.url+"], call "+n);
if (req.url != "/favicon.ico" && req.url != "/")
{
var params = req.url.substring(1).split("/");
switch (params[0])
{
case "VIEW":
if (params[1] == "C2FLOOR1" || params[1] == "C2FLOOR2" || params[1] == "C2PORFUN" || params[1] == "C2TESTCAM")
var camera = "rtsp://192.168.16.19:554/Inter/Cameras/Stream?Camera="+params[1];
else
var camera = "http://192.168.16.19:8609/Inter/Cameras/GetStream?Camera="+params[1];
// Write header
resp.writeHead(200, {'Content-Type': 'video/ogg', 'Connection': 'keep-alive'});
if (stdouts.hasOwnProperty(params[1]))
{
console.log("Getting stream already created for camera "+params[1]);
var newStdout = Object.create(stdouts[params[1]]);
newStdout.pipe(resp);
}
else
{
// Start ffmpeg
var ffmpeg = child_process.spawn("ffmpeg",[
"-i",camera,
"-vcodec","libtheora",
"-qscale:v","7", // video quality
"-f","ogg", // File format
"-g","1", // GOP (Group Of Pictures) size
"-" // Output to STDOUT
]);
stdouts[params[1]] = ffmpeg.stdout;
// Pipe the video output to the client response
ffmpeg.stdout.pipe(resp);
console.log("Initializing camera at "+camera);
}
// Kill the subprocesses when client disconnects
/*
resp.on("close",function(){
ffmpegs[params[1]].kill();
console.log("FIM!");
});
*/
break;
}
}
else
{
resp.writeHeader(200, {"Content-Type": "text/html"});
resp.write("WRONG CALL");
resp.end();
}
n++;
}).listen(8088);
console.log('Server running at port 8088'); -
NodeJS - How to pipe same video stream to multiple clients ?
6 mai 2019, par SergioBRWe have a situation trying to serve a video stream.
Since HTML5 video tag does not support udp to multicast, we are trying to re-use an already converted ffmpeg stream and send it to more than one response. But that does not work.
The first response gets the stream alright, but the second one does not.
It seems that the stream cannot be piped out to another response, neither can it be cloned.Has anyone done that before ? Any ideas ?
Thanks in advance !
Here’s the code :
var request = require('request');
var http = require('http');
var child_process = require("child_process");
var n = 1;
var stdouts = {};
http.createServer(function (req, resp) {
console.log("***** url ["+req.url+"], call "+n);
if (req.url != "/favicon.ico" && req.url != "/")
{
var params = req.url.substring(1).split("/");
switch (params[0])
{
case "VIEW":
if (params[1] == "C2FLOOR1" || params[1] == "C2FLOOR2" || params[1] == "C2PORFUN" || params[1] == "C2TESTCAM")
var camera = "rtsp://192.168.16.19:554/Inter/Cameras/Stream?Camera="+params[1];
else
var camera = "http://192.168.16.19:8609/Inter/Cameras/GetStream?Camera="+params[1];
// Write header
resp.writeHead(200, {'Content-Type': 'video/ogg', 'Connection': 'keep-alive'});
if (stdouts.hasOwnProperty(params[1]))
{
console.log("Getting stream already created for camera "+params[1]);
var newStdout = Object.create(stdouts[params[1]]);
newStdout.pipe(resp);
}
else
{
// Start ffmpeg
var ffmpeg = child_process.spawn("ffmpeg",[
"-i",camera,
"-vcodec","libtheora",
"-qscale:v","7", // video quality
"-f","ogg", // File format
"-g","1", // GOP (Group Of Pictures) size
"-" // Output to STDOUT
]);
stdouts[params[1]] = ffmpeg.stdout;
// Pipe the video output to the client response
ffmpeg.stdout.pipe(resp);
console.log("Initializing camera at "+camera);
}
// Kill the subprocesses when client disconnects
/*
resp.on("close",function(){
ffmpegs[params[1]].kill();
console.log("FIM!");
});
*/
break;
}
}
else
{
resp.writeHeader(200, {"Content-Type": "text/html"});
resp.write("WRONG CALL");
resp.end();
}
n++;
}).listen(8088);
console.log('Server running at port 8088');