
Recherche avancée
Autres articles (74)
-
Mise à jour de la version 0.1 vers 0.2
24 juin 2013, parExplications des différents changements notables lors du passage de la version 0.1 de MediaSPIP à la version 0.3. Quelles sont les nouveautés
Au niveau des dépendances logicielles Utilisation des dernières versions de FFMpeg (>= v1.2.1) ; Installation des dépendances pour Smush ; Installation de MediaInfo et FFprobe pour la récupération des métadonnées ; On n’utilise plus ffmpeg2theora ; On n’installe plus flvtool2 au profit de flvtool++ ; On n’installe plus ffmpeg-php qui n’est plus maintenu au (...) -
Personnaliser en ajoutant son logo, sa bannière ou son image de fond
5 septembre 2013, parCertains thèmes prennent en compte trois éléments de personnalisation : l’ajout d’un logo ; l’ajout d’une bannière l’ajout d’une image de fond ;
-
Ecrire une actualité
21 juin 2013, parPrésentez les changements dans votre MédiaSPIP ou les actualités de vos projets sur votre MédiaSPIP grâce à la rubrique actualités.
Dans le thème par défaut spipeo de MédiaSPIP, les actualités sont affichées en bas de la page principale sous les éditoriaux.
Vous pouvez personnaliser le formulaire de création d’une actualité.
Formulaire de création d’une actualité Dans le cas d’un document de type actualité, les champs proposés par défaut sont : Date de publication ( personnaliser la date de publication ) (...)
Sur d’autres sites (13369)
-
ffmpeg save mp3 file from available wss stream
11 juillet 2021, par phoenixAZIn a hello world node.js app I am succeeding in getting a feed from twilio conference and sending to the google speech to text. Concurrently I want to control recording to mp3 of the available audio stream (programmatically call start and stop). The was is subscribed to audio stream but I don't know how to attach ffmpeg to the local stream. I have tried :


// ffmpeg('rtsp://host:port/path/to/stream')
 //experimenting telling it to use the local stream
 //
 //ffmpeg(wss.addListener) //invlaid input error
 //ffmpeg(wss.stream) //thsi hits the console error below
 ffmpeg(wss.stream)
 .noVideo()
 .audioChannels(1)
 .audioBitrate(128)
 .duration('1:00')
 .on('end', function () { console.log('saved mp3'); })
 .on('error', function (err) { console.log('error mp3'); })
 .save('/path/to/output.mp3');



Any suggestions are welcomed. I am in a node.js project


-
Regarding converting Webm to Mp4 using ffmpeg and getting problem with not receiving audio from the converted video file
14 septembre 2022, par MikeElI'm using react-ffmpeg npm package for converting the webm video format to mp4 format. Like here, this is the function which is used to convert the format.


const convertFunc = async(fileurl) => {
console.log("run");
const file = fileurl
console.log("before", file);
await FFMPEG.process(
 file,
 "-f mp4 -c:v libx264 -an -profile:v baseline -level 3.0 -movflags +faststart -hide_banner",
 function (e) {
 console.log(e);
 
 const video = e.result;
 const reader = new FileReader();
 reader.readAsDataURL(video);
 reader.onload = function (e) {

 
 console.log("Process time: ",reader.result);
 };
 console.log(video);
 }
);



}




-f mp4 -c:v libx264 -an -profile:v baseline -level 3.0 -movflags +faststart -hide_banner




this line is used for convert the format. But when I received the converted file. It is muted or there is no audio in it.
In the ffmpeg command "-an" is used to remove audio from output converted video. But when I remove it from the above command then also audio is not there.


any solution ?
Thanks for you answers in advance.


-
The ffmpeg output binary stream front-end uses WebSocket to accept and cannot be played [closed]
17 novembre 2024, par KIMEOOKServer push nodejs


Use ws service to pass to the front end


ffmpegs = spawn('ffmpeg', [
 '-f', 'gdigrab', // 这是 Windows 下用于捕获屏幕的输入格式
 '-framerate', '60', // 捕获帧率
 '-i', 'desktop', // 捕获桌面(即屏幕)
 '-c:v', 'vp8', // 视频编码格式
 '-f', 'webm', // 设置输出为 mpegts 流
 '-pix_fmt', 'yuv420p',
 'pipe:1', // 输出到管道
 ]);







Front-end rendering



 let videoElement = document.getElementById('screenVideo');

 let mediaSource = new MediaSource();
 videoElement.src = URL.createObjectURL(mediaSource);

 mediaSource.addEventListener('sourceopen', () => {

 let sourceBuffer = mediaSource.addSourceBuffer('video/webm; codecs="vp8"'); 

 let ws = new WebSocket(`ws://${ip}:3000/?device=${encodeURIComponent(selectedDevice)}`);

 ws.onmessage = (event) => {
 const data = new Uint8Array(event.data);
 if (!sourceBuffer.updating) {
 try {
 sourceBuffer.appendBuffer(data);
 console.log('ok')
 } catch (error) {
 console.error('Error appending buffer:', error);
 }
 } else {
 console.log('SourceBuffer is busy');
 }
 };

 ws.onerror = (error) => {
 console.error('WebSocket error:', error);
 };

 ws.onclose = () => {
 console.log('WebSocket connection closed');
 };

 if (mediaSource.readyState === 'open') {
 videoElement.play().catch(err => {
 console.error('Error attempting to play the video:', err);
 });
 }
}



The video keeps spinning in circles and cannot be played normally.




Unable to play normally. What's the problem ?