
Recherche avancée
Autres articles (24)
-
Modifier la date de publication
21 juin 2013, parComment changer la date de publication d’un média ?
Il faut au préalable rajouter un champ "Date de publication" dans le masque de formulaire adéquat :
Administrer > Configuration des masques de formulaires > Sélectionner "Un média"
Dans la rubrique "Champs à ajouter, cocher "Date de publication "
Cliquer en bas de la page sur Enregistrer -
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 (...) -
Déploiements possibles
31 janvier 2010, parDeux types de déploiements sont envisageable dépendant de deux aspects : La méthode d’installation envisagée (en standalone ou en ferme) ; Le nombre d’encodages journaliers et la fréquentation envisagés ;
L’encodage de vidéos est un processus lourd consommant énormément de ressources système (CPU et RAM), il est nécessaire de prendre tout cela en considération. Ce système n’est donc possible que sur un ou plusieurs serveurs dédiés.
Version mono serveur
La version mono serveur consiste à n’utiliser qu’une (...)
Sur d’autres sites (2119)
-
Problem with FFmpeg breaking when streaming the entire screen and switching tabs
2 octobre 2024, par Ibad AhmadI'm working on a screen recording and streaming setup where the user records their entire screen and streams it to Twitch. The setup works fine initially, but when I switch tabs during recording, the stream breaks on the backend, and I get the following FFmpeg errors :


FFmpeg STDERR: [matroska,webm @ 0x7f9dcb904580] EBML header parsing failed
[in#0 @ 0x7f9dcb904380] Error opening input: Invalid data found when processing input
Error opening input file -.
Error opening input files: Invalid data found when processing input



My frontend code captures the screen and microphone and streams it via a WebSocket to the backend, where FFmpeg processes the stream. Below is my relevant frontend code :


const startRecording = async () => {
 try {
 const screenStream = await navigator.mediaDevices.getDisplayMedia({
 preferCurrentTab: true,
 systemAudio: 'include',
 surfaceSwitching: 'include',
 monitorTypeSurfaces: 'include',
 video: {
 displaySurface: 'browser',
 height: 720,
 width: 1280,
 frameRate: { ideal: 24, max: 30 },
 },
 });

 screenStream.getVideoTracks()[0].onended = () => {
 console.log('Screen sharing ended. Stopping the recorder.');
 stopRecording();
 };

 const micStream = await navigator.mediaDevices.getUserMedia({
 audio: true,
 });

 const combinedStream = new MediaStream([
 ...screenStream.getVideoTracks(),
 ...micStream.getAudioTracks(),
 ]);

 const recorder = new MediaRecorder(combinedStream, {
 mimeType: 'video/webm; codecs=vp8,opus',
 videoBitsPerSecond: 3 * 1024 * 1024,
 });

 const timeslice = 1000;

 recorder.ondataavailable = async (event) => {
 if (socket?.current?.connected && event.data.size > 0) {
 console.log('Sending chunk data:', socket.current.id);
 socket?.current.send(event.data);
 recordedChunks.current.push(event.data);
 } else if (!socket?.current?.connected) {
 handleSocketDisconnection();
 }
 };

 mediaRecorder.current = recorder;
 recorder.start(timeslice);
 setIsRecording(true);
 } catch (error) {
 console.log('Error starting screen recording:', error);
 toast.error('Failed to start screen recording: ' + error);
 }
};

const stopRecording = () => {
 if (socket?.current && mediaRecorder) {
 mediaRecorder?.current?.stop();
 socket.current.close();
 setIsRecording(false);
 downloadRecordedVideo();
 }
};




And here’s my backend code with FFmpeg settings for Twitch streaming :


const inputSettings = [
 '-f', 'webm', '-i', '-', '-v', 'error', '-analyzeduration', '1000000', '-probesize', '5000000',
];

const twitchSettings = (twitch) => {
 return [
 '-c:v', 'libx264', '-preset', 'veryfast', '-tune', 'zerolatency',
 '-g', '60', '-b:v', '2500k', '-maxrate', '3000k', '-bufsize', '8000k',
 '-r', '30', '-vf', 'tpad=stop_mode=clone:stop_duration=2',
 '-c:a', 'aac', '-ar', '44100', '-b:a', '96k',
 '-use_wallclock_as_timestamps', '1', '-async', '1',
 '-err_detect', 'ignore_err', '-reconnect', '1',
 '-reconnect_streamed', '1', '-reconnect_delay_max', '5',
 '-y', '-f', 'flv', twitch,
 ];
};




Problem : When switching tabs during screen sharing, it seems like the frame rate drops or the stream gets interrupted, leading to FFmpeg errors like
EBML header parsing failed
andInvalid data found when processing input
. I suspect this happens because the browser deprioritizes resources when the tab is not active, which might lead to corrupt chunks being sent to FFmpeg.

Questions :


- 

- Could switching tabs during screen capture be causing the issue by disrupting the frame rate or dropping frames ?
- Is there a way to ensure FFmpeg doesn’t break due to these interruptions ?
- Any suggestions on handling the stream more reliably when switching tabs or optimizing the FFmpeg setup for this scenario ?








I tried adjusting the bitrate, frame rate, and buffer size but still experienced the same issue. I'm trying to figure out if the issue is related to how browsers handle screen capture when tab switching or something specific with FFmpeg handling the video stream.


Any insights would be greatly appreciated.
Thanks in advance !


-
Unable to 'make' android ndk project - build fails : [build-openh264-x86] Error 2
18 décembre 2015, par NoobNinjaI’ve attempted these two fixes I’ve found while researching the issue :
android update project --23 --/Users/ajswann/Downloads/android-sdk-macosx
make OS=android NDKROOT=/Users/ajswann/Downloads/android-sdk-macosx TARGET=android-19 ARCH=x86 clean...however neither seems to resolve the issue.
Any input/suggestions are appreciated.
P.S.
I’m running OSX - could this be an issue with attempting to run an x86 architecture on a 64 bit machine ?
Error Message :
chris-mini-mac:linphone-android ajswann$ sudo make
ls: /opt/local/etc/openssl/certs: No such file or directory
/Users/ajswann/Downloads/android-sdk-macosx/tools/android update project --path . --target android-23
Updated project.properties
Updated local.properties
build.xml: Found version-tag: custom. File will not be updated.
Updated file ./proguard-project.txt
It seems that there are sub-projects. If you want to update them
please use the --subprojects parameter.
/Users/ajswann/Downloads/android-sdk-macosx/tools/android update test-project --path tests -m .
Resolved location of main project to: /groupchat/linphone-android/tests
Updated project.properties
Updated local.properties
Updated file tests/proguard-project.txt
Updated ant.properties
/Users/ajswann/Downloads/android-sdk-macosx/tools/android update project --path liblinphone_tester --target android-23
Updated project.properties
Updated local.properties
Updated file liblinphone_tester/proguard-project.txt
ant -e -S clean
Buildfile: /groupchat/linphone-android/build.xml
No sub-builds to iterate on
mkdir -p /groupchat/linphone-android/submodules/externals/openh264/include/wels
rsync -rvLpgoc --exclude ".git" /groupchat/linphone-android/submodules/externals/openh264/codec/api/svc/* /groupchat/linphone-android/submodules/externals/openh264/include/wels/.
building file list ... done
sent 156 bytes received 20 bytes 352.00 bytes/sec
total size is 56216 speedup is 319.41
mkdir -p /groupchat/linphone-android/submodules/externals/build/openh264
mkdir -p /groupchat/linphone-android/submodules/externals/build/openh264/arm
cd /groupchat/linphone-android/submodules/externals/build/openh264/arm \
&& rsync -rvLpgoc --exclude ".git" /groupchat/linphone-android/submodules/externals/openh264/* .
building file list ... done
sent 18841 bytes received 20 bytes 37722.00 bytes/sec
total size is 48272799 speedup is 2559.40
cd /groupchat/linphone-android/submodules/externals/build/openh264/arm && \
make libraries -j4 OS=android ARCH=arm NDKROOT=/Users/ajswann/Downloads/android-ndk-r10e TARGET=android-19
cd ./ && sh ./codec/common/generate_version.sh
Keeping existing codec/common/inc/version_gen.h
mkdir -p /groupchat/linphone-android/submodules/externals/build/openh264
mkdir -p /groupchat/linphone-android/submodules/externals/build/openh264/x86
cd /groupchat/linphone-android/submodules/externals/build/openh264/x86 \
&& rsync -rvLpgoc --exclude ".git" /groupchat/linphone-android/submodules/externals/openh264/* .
building file list ... done
sent 18841 bytes received 20 bytes 12574.00 bytes/sec
total size is 48272799 speedup is 2559.40
cd /groupchat/linphone-android/submodules/externals/build/openh264/x86 && \
make libraries -j4 OS=android ARCH=x86 NDKROOT=/Users/ajswann/Downloads/android-ndk-r10e TARGET=android-19
cd ./ && sh ./codec/common/generate_version.sh
nasm -DX86_32 -f elf -I./codec/common/x86/ -o codec/decoder/core/x86/dct.o codec/decoder/core/x86/dct.asm
codec/decoder/core/x86/dct.asm:1: error: label or instruction expected at start of line
codec/decoder/core/x86/dct.asm:144: error: label or instruction expected at start of line
codec/decoder/core/x86/dct.asm:234: error: symbol `IdctResAddPred_mmx' redefined
codec/decoder/core/x86/dct.asm:262: error: symbol `WelsBlockZero16x16_sse2' redefined
codec/decoder/core/x86/dct.asm:276: error: symbol `WelsBlockZero8x8_sse2' redefined
codec/decoder/core/x86/dct.asm:287: error: label or instruction expected at start of line
make[1]: *** [codec/decoder/core/x86/dct.o] Error 1
make[1]: *** Waiting for unfinished jobs....
Keeping existing codec/common/inc/version_gen.h
make[1]: *** wait: No child processes. Stop.
make: *** [build-openh264-x86] Error 2Source Repository (I simply clone it, add the platform-tools and tools folder from my android-sdk and run ’make’ and I get this error) :
-
How to install this nodejs Application
15 février 2016, par metalbughttps://github.com/hexator/live4chan
i have VMware run ubuntu-14.10-server and 15.10-server
sudo apt-get install -y
git mongodb imagemagick libcairo2-dev libjpeg8-dev
libpango1.0-dev libgif-dev build-essential g++ ffmpeg curlinstall success
git clone https://github.com/hexator/live4chan.git;
cd live4chan;
npm installbut have errors
test@ubuntu:~/live4chan$ npm start
LiveChan@0.0.1 start /home/test/live4chan
node lib/index.js
Missing certificate or private key
Running with insecure server
info - socket.io started
connect.limit() will be removed in connect 3.0
connect.multipart() will be removed in connect 3.0
visit https://github.com/senchalabs/connect/wiki/Connect-3.0 for alternatives
connect.limit() will be removed in connect 3.0
module.js:340
throw err;
^
Error: Cannot find module 'carrier'
at Function.Module._resolveFilename (module.js:338:15)
at Function.Module._load (module.js:280:25)
at Module.require (module.js:364:17)
at require (module.js:380:17)
at Object. (/home/test/ircd.js/lib/server.js:24:15)
at Module._compile (module.js:456:26)
at Object.Module._extensions..js (module.js:474:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Module.require (module.js:364:17)
npm ERR! Linux 4.2.0-16-generic
npm ERR! argv "node" "/usr/local/bin/npm" "start"
npm ERR! node v0.10.42
npm ERR! npm v3.7.2
npm ERR! code ELIFECYCLE
npm ERR! LiveChan@0.0.1 start: node lib/index.js
npm ERR! Exit status 8
npm ERR!
npm ERR! Failed at the LiveChan@0.0.1 start script 'node lib/index.js'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the LiveChan package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node lib/index.js
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs LiveChan
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls LiveChan
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /home/test/live4chan/npm-debug.log
==========================================================
/home/test/live4chan/npm-debug.log
0 info it worked if it ends with ok
1 verbose cli [ 'node', '/usr/local/bin/npm', 'start' ]
2 info using npm@3.7.2
3 info using node@v0.10.42
4 verbose run-script [ 'prestart', 'start', 'poststart' ]
5 info lifecycle LiveChan@0.0.1~prestart: LiveChan@0.0.1
6 silly lifecycle LiveChan@0.0.1~prestart: no script for prestart, continuing
7 info lifecycle LiveChan@0.0.1~start: LiveChan@0.0.1
8 verbose lifecycle LiveChan@0.0.1~start: unsafe-perm in lifecycle true
9 verbose lifecycle LiveChan@0.0.1~start: PATH: /usr/local/lib/node_modules/npm/bin/node-gyp-bin:/home/test/live4chan/node_modules/.bin:/usr/local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games
10 verbose lifecycle LiveChan@0.0.1~start: CWD: /home/test/live4chan
11 silly lifecycle LiveChan@0.0.1~start: Args: [ '-c', 'node lib/index.js' ]
12 silly lifecycle LiveChan@0.0.1~start: Returned: code: 8 signal: null
13 info lifecycle LiveChan@0.0.1~start: Failed to exec start script
14 verbose stack Error: LiveChan@0.0.1 start: node lib/index.js
14 verbose stack Exit status 8
14 verbose stack at EventEmitter. (/usr/local/lib/node_modules/npm/lib/utils/lifecycle.js:239:16)
14 verbose stack at EventEmitter.emit (events.js:98:17)
14 verbose stack at ChildProcess. (/usr/local/lib/node_modules/npm/lib/utils/spawn.js:24:14)
14 verbose stack at ChildProcess.emit (events.js:98:17)
14 verbose stack at maybeClose (child_process.js:766:16)
14 verbose stack at Process.ChildProcess._handle.onexit (child_process.js:833:5)
15 verbose pkgid LiveChan@0.0.1
16 verbose cwd /home/test/live4chan
17 error Linux 4.2.0-16-generic
18 error argv "node" "/usr/local/bin/npm" "start"
19 error node v0.10.42
20 error npm v3.7.2
21 error code ELIFECYCLE
22 error LiveChan@0.0.1 start: node lib/index.js
22 error Exit status 8
23 error Failed at the LiveChan@0.0.1 start script 'node lib/index.js'.
23 error Make sure you have the latest version of node.js and npm installed.
23 error If you do, this is most likely a problem with the LiveChan package,
23 error not with npm itself.
23 error Tell the author that this fails on your system:
23 error node lib/index.js
23 error You can get information on how to open an issue for this project with:
23 error npm bugs LiveChan
23 error Or if that isn't available, you can get their info via:
23 error npm owner ls LiveChan
23 error There is likely additional logging output above.
24 verbose exit [ 1, true ]I tried this :
npm install carrierOr an error.
and install Other versions of nodejs
wget http://nodejs.org/dist/latest-v0.10.x/node-v0.10.42.tar.gz
wget http://nodejs.org/dist/latest-v0.12.x/node-v0.12.10.tar.gz
wget http://nodejs.org/dist/latest-v4.x/node-v4.3.0.tar.gz
wget http://nodejs.org/dist/latest-v5.x/node-v5.6.0.tar.gz
tar zxvf node-v4.3.0.tar.gz
cd node-v4.3.0
./configure
make
sudo make installNothing happened
please help me
Or you can tell me how to install, detailed, thank you very much !