
Recherche avancée
Médias (2)
-
GetID3 - Bloc informations de fichiers
9 avril 2013, par
Mis à jour : Mai 2013
Langue : français
Type : Image
-
GetID3 - Boutons supplémentaires
9 avril 2013, par
Mis à jour : Avril 2013
Langue : français
Type : Image
Autres articles (94)
-
Les vidéos
21 avril 2011, parComme les documents de type "audio", Mediaspip affiche dans la mesure du possible les vidéos grâce à la balise html5 .
Un des inconvénients de cette balise est qu’elle n’est pas reconnue correctement par certains navigateurs (Internet Explorer pour ne pas le nommer) et que chaque navigateur ne gère en natif que certains formats de vidéos.
Son avantage principal quant à lui est de bénéficier de la prise en charge native de vidéos dans les navigateur et donc de se passer de l’utilisation de Flash et (...) -
Publier sur MédiaSpip
13 juin 2013Puis-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 -
Emballe médias : à quoi cela sert ?
4 février 2011, parCe plugin vise à gérer des sites de mise en ligne de documents de tous types.
Il crée des "médias", à savoir : un "média" est un article au sens SPIP créé automatiquement lors du téléversement d’un document qu’il soit audio, vidéo, image ou textuel ; un seul document ne peut être lié à un article dit "média" ;
Sur d’autres sites (5283)
-
How to create video by stitching together images (.png) where the serial on each image file increases by 6
10 avril 2024, par DataStatsExplorerI am trying to create a video (preferably mp4) from a series of png images. However, the name of each image file increases by 6 every frame. For example, I would have depthframe_0000 as the first frame, and depthframe_0001 for the next frame.


There are a few answers that have answered a similar question but I am unable to process the video when the image files are not increasing by 1.


I would like to keep the fps at 5. I am using ffmpeg as the suggested in the answers above but am open to any other suggestion.


The collab code that I have put together is as follows :


import subprocess

# Define the frame rate and the input/output paths
output_fps = 5
input_path = "/content/drive/MyDrive/depth/depthframe_%04d.png"
output_path = "/content/drive/MyDrive/depth.mp4"

# Create a list of the frames
frames = [input_path % i for i in range(0, 2671, 6)] # Update range as needed

# Write the list of frames to a temporary text file
with open('frames.txt', 'w') as f:
 for frame in frames:
 f.write(f"file '{frame}'\n")

# Create the command
command = [
 "ffmpeg",
 "-f", "concat",
 "-safe", "0",
 "-i", "frames.txt",
 "-c:v", "libx264",
 "-pix_fmt", "yuv420p",
 output_path
]

# Run the command
subprocess.run(command, check=True)



-
FFMPEG - Error during conversion : Input stream error : Status code : 403
18 août 2024, par SOURABH UPRETIconst express = require('express');
const ytdl = require('ytdl-core');
const ffmpeg = require('fluent-ffmpeg');
const ffmpegStatic = require('ffmpeg-static');

const app = express();
app.use(express.static('public'));

app.get('/videoInfo', async (req, res) => {
 const { url } = req.query;
 if (!ytdl.validateURL(url)) {
 return res.status(400).send('Invalid URL');
 }

 const requestOptions = {
 headers: {
 'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/58.0.3029.110 Safari/537.36'
 }
 };

 try {
 const info = await ytdl.getInfo(url, requestOptions);
 const audioFormats = ytdl.filterFormats(info.formats, 'audioonly');
 const highestQualityAudio = audioFormats.reduce((prev, curr) => (prev.audioBitrate > curr.audioBitrate ? prev : curr));

 res.json({
 videoTitle: info.videoDetails.title,
 videoThumbnail: info.videoDetails.thumbnails[info.videoDetails.thumbnails.length - 1].url, 
 audioFormat: highestQualityAudio
 });
 } catch (error) {
 console.error('Error fetching video info:', error);
 res.status(500).send('Failed to retrieve video info.');
 }
});

app.get('/download', (req, res) => {
 const { url } = req.query;

 function downloadAndConvertAudio(retryCount = 0) {
 const requestOptions = {
 headers: {
 'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/58.0.3029.110 Safari/537.36'
 }
 };

 res.header('Content-Disposition', 'attachment; filename="audio.mp3"');
 const videoStream = ytdl(url, { quality: 'highestaudio', requestOptions: requestOptions });

 ffmpeg(videoStream)
 .setFfmpegPath(ffmpegStatic)
 .audioBitrate(128)
 .toFormat('mp3')
 .on('error', (error) => {
 console.error('Error in ffmpeg conversion:', error);
 if (error.message.includes('403') && retryCount < 3) {
 console.log('Retrying download...');
 setTimeout(() => downloadAndConvertAudio(retryCount + 1), 2000); 
 } else {
 res.status(500).send(`Error during conversion: ${error.message}`);
 }
 })
 .pipe(res);
 }

 downloadAndConvertAudio();
});

const PORT = 3000;
app.listen(PORT, () => {
 console.log(`Server running on http://localhost:${PORT}`);
});



Getting Error during conversion on this server. I tried running it on replit but giving the error all the time. I'm new to this and can't figure out the issue. CHATGPT-4 couldn't help.
Can someone help me with this ???


ChatGPT said - The "Error during conversion : Input stream error : Status code : 410" indicates a "Gone" error, which means the resource you were trying to access is no longer available at the specified URL. This can occur in situations where YouTube content has been removed or is no longer accessible due to changes in YouTube's policy or the specific video's availability.


-
Anomalie #2133 (Nouveau) : Statut des messages de forum et statuts des documents joints
18 juin 2011, par guytarr °Lorsque l’on est en modération à posteriori (ou probablement tous les cas de figures où un message de forum n’est pas publie immediatement), le(s) document(s) joint(s) à un message de forum ne passe pas en "publie" au moment où le message est (...)