Recherche avancée

Médias (1)

Mot : - Tags -/belgique

Autres articles (79)

  • List of compatible distributions

    26 avril 2011, par

    The table below is the list of Linux distributions compatible with the automated installation script of MediaSPIP. Distribution nameVersion nameVersion number Debian Squeeze 6.x.x Debian Weezy 7.x.x Debian Jessie 8.x.x Ubuntu The Precise Pangolin 12.04 LTS Ubuntu The Trusty Tahr 14.04
    If you want to help us improve this list, you can provide us access to a machine whose distribution is not mentioned above or send the necessary fixes to add (...)

  • MediaSPIP Core : La Configuration

    9 novembre 2010, par

    MediaSPIP Core fournit par défaut trois pages différentes de configuration (ces pages utilisent le plugin de configuration CFG pour fonctionner) : une page spécifique à la configuration générale du squelettes ; une page spécifique à la configuration de la page d’accueil du site ; une page spécifique à la configuration des secteurs ;
    Il fournit également une page supplémentaire qui n’apparait que lorsque certains plugins sont activés permettant de contrôler l’affichage et les fonctionnalités spécifiques (...)

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

Sur d’autres sites (10080)

  • I have a problem with node js rtsp streaming server

    11 décembre 2022, par sangeun jo

    I made rtsp cctv streaming server with nodjs.

    


    But it is not stable.

    


    Some cctvs works well but others are not.

    


    First I thought rtsp url has its own problem, but it may not.
Because the url worked well in vlc player.

    


    I don't know what I'm missing.

    


    below is my whole code related cctv streaming.

    


    

    

    var express = require('express');
var router = express.Router();
var kill  = require('tree-kill');
var fs = require('fs');
var path = require('path');

var ffmpeg = require('fluent-ffmpeg');
var ffmpegInstaller = require('@ffmpeg-installer/ffmpeg');
ffmpeg.setFfmpegPath(ffmpegInstaller.path)

var streams = {};

//start cctv
router.post('/', (req, res) => {

  var cname = req.body.cname;
  var url = req.body.url;

  //if there is same cctv name
  if(streams[cname] != null) {
    res.status(409).send("duplicate name");
    return;
  };

  //create dir as given cctv name;
  mkdir(cname);

  stream = ffmpeg(url).addOptions([
    '-hls_time 5', 
    '-hls_list_size 10',
    '-hls_flags delete_segments',
    '-f hls' 
  ]).output('./public/video/' + cname + '/'  + cname + '.m3u8'); //save path

  console.log("Start cctv streaming");
  stream.on('error', function(err, stdout, stderr) {
    console.log("cctv has been stoped");
    console.log(err);
  });

  stream.run(); 

  streams[cname] = stream;
  res.status(201).send("OK");
});

//bring cctv pid by cctv name
router.get('/:cname', (req, res) => {
  var cname = req.params.cname;

  if(streams[cname] == null) {
    res.status(404).send("not found such a cctv");
    return;
  };

  var pid = streams[cname].ffmpegProc.pid;
  res.send({"pid": pid});
});


//stop cctv by pid 
router.delete('/:cname', async (req, res) => {
  var cname = req.params.cname;
  
  //no cctv
  if(streams[cname] == null) {
    res.status(404).send("not found such a cctv");
    return;
  };


  //del dir
  var filePath = './public/video/' +  cname;
  fs.rmdir(filePath, { recursive: true }, (err) => {
    if (err) {
      console.log(err)
    } else {
      console.log('dir is deleted.');
    }
  });

  //var pid = streams[cname].ffmpegProc.pid;
  streams[cname].kill();
  res.status(204).send("OK");
});

const mkdir = (name) => {
  var root = './public/video/';
  if(!fs.existsSync(root + name)){
    fs.mkdirSync(root + name);
  }
}

    


    


    



    And this is ts file save folder.
cctv1 dosen't work well but cctv2 works well.
(cctv1 started first but created less ts file than cctv2.)
enter image description here

    


  • How to fix Ffmpeg cut video in nextjs ?

    27 juillet 2023, par Duy Tịnh

    I'm currently working on a Next.js project where I need to use ffmpeg to cut video files. However, I've encountered an error that occurs specifically when I navigate from one page to another using ffmpeg. Strangely, I don't encounter this error when I use an element or directly redirect to the page without involving ffmpeg.
The error message I'm receiving is as follows :

    


    ReferenceError: SharedArrayBuffer is not defined

Source
Views\EditVideo\index.tsx (264:4) @ async handleEditVideo

  262 | const ffmpegInstance = createFFmpeg({ log: true });
  263 | // error
> 264 | await ffmpegInstance.load();
      |    ^
  265 | // if (srcVideoEdit) {
  266 | //   ffmpegInstance.FS(
  267 | //     "writeFile",


    


    you can see more details at : https://i.stack.imgur.com/Z1OBx.png
This is my code in page have using ffmpeg :

    


      const handleEditVideo = async () => {&#xA;    const { createFFmpeg, fetchFile } = ffmpeg;&#xA;    const ffmpegInstance = createFFmpeg({ log: true });&#xA;    // error&#xA;    await ffmpegInstance.load();&#xA;  };&#xA;&#xA;  return (&#xA;    &lt;>&#xA;      <button>Test</button>&#xA;

    &#xA;

    code the page navigation to it

    &#xA;

     import { useRouter } from &#x27;next/router&#x27;&#xA;&#xA;export default function Upload() {&#xA;    const route = useRouter();&#xA;    const onOk = () => {&#xA;        route.push("/editvideo");&#xA;        setIsLoading(false);&#xA;    }&#xA;}&#xA;

    &#xA;

  • Opencv VideoCapture not streaming RTSP link and returns "no frame !"

    6 septembre 2023, par Asadullah Naeem

    I am trying to stream my HikVision IP camera throough python. I am using cv2.VideoCapture("rtsp_link") which works fine on my Laptop but when I try to run the same python script with same Opencv and FFmpeg version it gives me following error :

    &#xA;

    Error :

    &#xA;

    [h264 @ 000002124c7f9a40] missing picture in access unit with size 47&#xA;[h264 @ 000002124c7f9a40]&#xA0;no&#xA0;frame!&#xA;

    &#xA;

    I have so far tried to run this script on 5 computer devices but it gives the same error. I am using the following python script and my Opencv version is 4.6.0.66 and ffmpeg version 2022-06-20-git-56419428a8-essentials_build-www.gyan.dev :

    &#xA;

    Python Script :

    &#xA;

    import cv2&#xA;&#xA;# RTSP stream URL&#xA;rtsp_url = "rtsp://username:password@ip_address:port/Streaming/Channels/501"&#xA;&#xA;# Open the RTSP stream&#xA;cap = cv2.VideoCapture(rtsp_url)&#xA;&#xA;# Check if the stream was successfully opened&#xA;if not cap.isOpened():&#xA;    print("Failed to open RTSP stream.")&#xA;    exit()&#xA;&#xA;# Read and display frames from the stream&#xA;while True:&#xA;    # Read a frame from the stream&#xA;    ret, frame = cap.read()&#xA;&#xA;    # Check if the frame was successfully read&#xA;    if not ret:&#xA;        print("Failed to read frame from RTSP stream.")&#xA;        break&#xA;&#xA;    # Display the frame&#xA;    cv2.imshow("RTSP Stream", frame)&#xA;&#xA;    # Exit if &#x27;q&#x27; is pressed&#xA;    if cv2.waitKey(1) &amp; 0xFF == ord(&#x27;q&#x27;):&#xA;        break&#xA;&#xA;# Release the resources&#xA;cap.release()&#xA;cv2.destroyAllWindows()&#xA;&#xA;

    &#xA;

    Update :

    &#xA;

    Code runs on a laptop on both wifi and mobile internet (4G) but on other devices rtsp link is accessible only with mobile internet (4G).

    &#xA;