Recherche avancée

Médias (0)

Mot : - Tags -/auteurs

Aucun média correspondant à vos critères n’est disponible sur le site.

Autres articles (31)

  • La file d’attente de SPIPmotion

    28 novembre 2010, par

    Une file d’attente stockée dans la base de donnée
    Lors de son installation, SPIPmotion crée une nouvelle table dans la base de donnée intitulée spip_spipmotion_attentes.
    Cette nouvelle table est constituée des champs suivants : id_spipmotion_attente, l’identifiant numérique unique de la tâche à traiter ; id_document, l’identifiant numérique du document original à encoder ; id_objet l’identifiant unique de l’objet auquel le document encodé devra être attaché automatiquement ; objet, le type d’objet auquel (...)

  • La sauvegarde automatique de canaux SPIP

    1er avril 2010, par

    Dans le cadre de la mise en place d’une plateforme ouverte, il est important pour les hébergeurs de pouvoir disposer de sauvegardes assez régulières pour parer à tout problème éventuel.
    Pour réaliser cette tâche on se base sur deux plugins SPIP : Saveauto qui permet une sauvegarde régulière de la base de donnée sous la forme d’un dump mysql (utilisable dans phpmyadmin) mes_fichiers_2 qui permet de réaliser une archive au format zip des données importantes du site (les documents, les éléments (...)

  • Publier sur MédiaSpip

    13 juin 2013

    Puis-je poster des contenus à partir d’une tablette Ipad ?
    Oui, si votre Médiaspip installé est à la version 0.2 ou supérieure. Contacter au besoin l’administrateur de votre MédiaSpip pour le savoir

Sur d’autres sites (5259)

  • lavc/qsvenc : add support for oneVPL string API

    29 février 2024, par Mandava, Mounika
    lavc/qsvenc : add support for oneVPL string API
    

    A new option -qsv_params <str> is added, where <str> is a :-separated
    list of key=value parameters.

    Example :
    $ ffmpeg -y -f lavfi -i testsrc -vf "format=nv12" -c:v h264_qsv -qsv_params
    "TargetUsage=1:GopPicSize=30:GopRefDist=2:TargetKbps=5000" -f null -

    Signed-off-by : Mounika Mandava <mounika.mandava@intel.com>
    Signed-off-by : Haihao Xiang <haihao.xiang@intel.com>

    • [DH] Changelog
    • [DH] configure
    • [DH] doc/encoders.texi
    • [DH] libavcodec/qsvenc.c
    • [DH] libavcodec/qsvenc.h
  • How to create video from a stream webcam and canvas ?

    1er mai 2024, par Stefdelec

    I am trying to generate a video on browser from different cut :&#xA;Slide : stream from canvas&#xA;Video : stream from webcam

    &#xA;

    I just want to allow user to download the video edit with&#xA;slide1 + video1 + slide2 + video2 + slide3 + video3.

    &#xA;

    Here is my code :

    &#xA;

    const canvas = document.getElementById(&#x27;myCanvas&#x27;);&#xA;const ctx = canvas.getContext(&#x27;2d&#x27;);&#xA;const webcam = document.getElementById(&#x27;webcam&#x27;);&#xA;const videoPlayer = document.createElement(&#x27;video&#x27;);&#xA;videoPlayer.controls = true;&#xA;document.body.appendChild(videoPlayer);&#xA;const videoWidth = 640;&#xA;const videoHeight = 480;&#xA;let keepAnimating = true;&#xA;const frameRate=30;&#xA;// Attempt to get webcam access&#xA;function setupWebcam() {&#xA; const constraints = {&#xA;        video: {&#xA;             frameRate: frameRate,&#xA;            width: videoWidth,  &#xA;            height: videoHeight &#xA;        }&#xA;    };&#xA;  navigator.mediaDevices.getUserMedia(constraints)&#xA;    .then(stream => {&#xA;      webcam.srcObject = stream;&#xA;      webcam.addEventListener(&#x27;loadedmetadata&#x27;, () => {&#xA;        recordSegments();&#xA;        console.log(&#x27;Webcam feed is now displayed&#x27;);&#xA;      });&#xA;    })&#xA;    .catch(err => {&#xA;      console.error("Error accessing webcam:", err);&#xA;      alert(&#x27;Could not access the webcam. Please ensure permissions are granted and try again.&#x27;);&#xA;    });&#xA;}&#xA;&#xA;&#xA;// Function to continuously draw on the canvas&#xA;function animateCanvas(content) {&#xA;  if (!keepAnimating) {&#xA;    console.log("keepAnimating", keepAnimating);&#xA;    return;&#xA;  }; // Stop the animation when keepAnimating is false&#xA;&#xA;  ctx.clearRect(0, 0, canvas.width, canvas.height); // Clear previous drawings&#xA;  ctx.fillStyle = `rgba(${Math.floor(Math.random() * 255)}, ${Math.floor(Math.random() * 255)}, ${Math.floor(Math.random() * 255)}, 0.5)`;&#xA;  ctx.fillRect(0, 0, canvas.width, canvas.height);&#xA;  ctx.fillStyle = &#x27;#000&#x27;;&#xA;  ctx.font = &#x27;48px serif&#x27;;&#xA;  ctx.fillText(content &#x2B; &#x27; &#x27; &#x2B; new Date().toLocaleTimeString(), 50, 100);&#xA;&#xA;  // Request the next frame&#xA;  requestAnimationFrame(() => animateCanvas(content));&#xA;}&#xA;&#xA;&#xA;// Initialize recording segments array&#xA;const recordedSegments = [];&#xA;// Modified startRecording to manage animation&#xA;function startRecording(stream, duration = 5000, content) {&#xA;  const recorder = new MediaRecorder(stream, { mimeType: &#x27;video/webm&#x27; });&#xA;  const data = [];&#xA;&#xA;  recorder.ondataavailable = e => data.push(e.data);&#xA;&#xA;&#xA;  // Start animating the canvas&#xA;  keepAnimating = true;&#xA;  animateCanvas(content);&#xA;  recorder.start();&#xA;  return new Promise((resolve) => {&#xA;    // Automatically stop recording after &#x27;duration&#x27; milliseconds&#xA;    setTimeout(() => {&#xA;      recorder.stop();&#xA;      // Stop the animation when recording stops&#xA;      keepAnimating = false;&#xA;    }, duration);&#xA;&#xA;    recorder.onstop = () => {&#xA;      const blob = new Blob(data, { type: &#x27;video/webm&#x27; });&#xA;      recordedSegments.push(blob);&#xA;       keepAnimating = true;&#xA;      resolve(blob);&#xA;    };&#xA;  });&#xA;}&#xA;&#xA;// Sequence to record segments&#xA;async function recordSegments() {&#xA;  // Record canvas with dynamic content&#xA;  await startRecording(canvas.captureStream(frameRate), 2000, &#x27;Canvas Draw 1&#x27;).then(() => console.log(&#x27;Canvas 1 recorded&#x27;));&#xA;&#xA;      await startRecording(webcam.srcObject,3000).then(() => console.log(&#x27;Webcam 1 recorded&#x27;));&#xA;&#xA;          await startRecording(webcam.srcObject).then(() => console.log(&#x27;Webcam 1 recorded&#x27;));&#xA;  mergeAndDownloadVideo();&#xA;}&#xA;&#xA;function downLoadVideo(blob){&#xA; const url = URL.createObjectURL(blob);&#xA;&#xA;  // Create an anchor element and trigger a download&#xA;  const a = document.createElement(&#x27;a&#x27;);&#xA;  a.style.display = &#x27;none&#x27;;&#xA;  a.href = url;&#xA;  a.download = &#x27;merged-video.webm&#x27;;&#xA;  document.body.appendChild(a);&#xA;  a.click();&#xA;&#xA;  // Clean up by revoking the Blob URL and removing the anchor element after the download&#xA;  setTimeout(() => {&#xA;    document.body.removeChild(a);&#xA;    window.URL.revokeObjectURL(url);&#xA;  }, 100);&#xA;}&#xA;function mergeAndDownloadVideo() {&#xA;  console.log("recordedSegments length", recordedSegments.length);&#xA;  // Create a new Blob from all recorded video segments&#xA;  const superBlob = new Blob(recordedSegments, { type: &#x27;video/webm&#x27; });&#xA;  &#xA;  downLoadVideo(superBlob)&#xA;&#xA;  // Create a URL for the superBlob&#xA; &#xA;}&#xA;&#xA;// Start the process by setting up the webcam first&#xA;setupWebcam();&#xA;

    &#xA;

    You can find it here : https://jsfiddle.net/Sulot/nmqf6wdj/25/

    &#xA;

    I am unable to have one "slide" + webcam video + "slide" + webcam video.

    &#xA;

    It merges only the first 2 segments, but not the other. I tried with ffmpeg browser side.

    &#xA;

  • Streams stop when creating a quad split Multi-viewer using FFMPEG [closed]

    6 avril 2024, par Chris Parker

    Created a FFMPEG script that takes in 4 SRT Live Streams and displays them in a quad split MV. However when I launch this script all 4 SRT streams will play but 3 will pause and 1 will play.

    &#xA;

    ffmpeg \&#xA;-re -hwaccel auto -hwaccel_output_csp videocore \&#xA;-stream_loop -1 \&#xA;-i "srt://address:5000?streamid=stream-id" \&#xA;-stream_loop -1 \&#xA;-i "srt://address:5000?streamid=stream-id" \&#xA;-stream_loop -1 \&#xA;-i "srt://address:5000?streamid=stream-id" \&#xA;-stream_loop -1 \&#xA;-i "srt://address:5000?streamid=stream-id" \&#xA;-filter_complex "\&#xA;[0]scale=1920x1080,setdar=16/9[a];\&#xA;[1]scale=1920x1080,setdar=16/9[b];\&#xA;[2]scale=1920x1080,setdar=16/9[c];\&#xA;[3]scale=1920x1080,setdar=16/9[d];\&#xA;[a][b][c][d]xstack=inputs=4:layout=0_0|w0_0|0_h0|w0_h0[v]" \&#xA;-map "[v]" \&#xA;-c:v libx264 -preset veryfast -crf 28 \&#xA;-pix_fmt yuv420p -g 48 -bf 2 -refs 4 \&#xA;-f mpegts -b:v 10M -maxrate:v 15M -bufsize:v 30M \&#xA;-fflags &#x2B;discardcorrupt -reset_timestamps 1 \&#xA;"srt://address:5000?streamid=stream-id"&#xA;

    &#xA;

    getting a lot of the below error ;

    &#xA;

    16:48:49.628704/SRT:RcvQ:w2!W:SRT.qr: @214003038:No room to store incoming packet seqno 649744568, insert offset 7190. Space avail 0/8192 pkts. (TSBPD ready in -12342ms, timespan 6093 ms). GETTIME_MONOTONIC drift 0 ms.&#xA;

    &#xA;

    I've tried smaller resolution and adjusting buffer sizes as well as the other flags but I'm not sure what else I can do.

    &#xA;