
Recherche avancée
Autres articles (89)
-
Websites made with MediaSPIP
2 mai 2011, parThis page lists some websites based on MediaSPIP.
-
Les tâches Cron régulières de la ferme
1er décembre 2010, parLa gestion de la ferme passe par l’exécution à intervalle régulier de plusieurs tâches répétitives dites Cron.
Le super Cron (gestion_mutu_super_cron)
Cette tâche, planifiée chaque minute, a pour simple effet d’appeler le Cron de l’ensemble des instances de la mutualisation régulièrement. Couplée avec un Cron système sur le site central de la mutualisation, cela permet de simplement générer des visites régulières sur les différents sites et éviter que les tâches des sites peu visités soient trop (...) -
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
Sur d’autres sites (14943)
-
Cannot remove the video file created through ffmpeg save
29 juin 2022, par lightIt gives this error :
os.remove("output.mp4")
PermissionError : [WinError 32] The process cannot access the file because it is being used by another process : 'output.mp4


I am first downloading a reddit video (with separate audio and video file) by joining audio and video files together using ffmpeg


with open("video.mp4", "wb") as f:
 g = requests.get(video_url, stream=True)
 f.write(g.content)

 with open("audio.mp3", "wb") as f:
 g = requests.get(audio_url, stream=True)
 f.write(g.content)

 os.system("ffmpeg -i video.mp4 -i audio.mp3 -c copy output.mp4")
 os.remove("audio.mp3")
 os.remove("video.mp4")



After this I am uploading it to YouTube Using YouTube Api and then finally deleting it from the system. I tried everything I thought would solve this error.


os.system("exit")
 os.system("echo 'q' >stop") 
 os.system("exit()")
 os.remove("output.mp4")



But it gives me Permission Error. Please help me with this problem I have no idea what could be wrong.


This is the method I am using to upload the file to YouTube.


request_body = {
 'snippet': {
 'categoryI': 19,
 'title': f'{item.title}',
 'description': description,
 'tags': Tags
 },
 'status': {
 'privacyStatus': 'public',
 'publishAt': upload_date_time,
 'selfDeclaredMadeForKids': False, 
 },
 'notifySubscribers': False
 }


 mediaFile = MediaFileUpload(r"output.mp4")

 response_upload = service.videos().insert(
 part='snippet,status',
 body=request_body,
 media_body=mediaFile
 ).execute



-
Node merge multiple .m3u8 playlist as single stream
28 juin 2022, par jr3000I have two .m3u8 files example : file.m3u8 and file2.com. The streams are not live, I am using npm m3u8 package to possible create a dynamic playlist.




var m3u8 = require('m3u8');
var fs = require('fs');
const express = require("express")
const app = express()
const port = 8080
const cors = require("cors")
const M3U8 = require("m3u8");
app.use(cors())
const async = require("async")

app.get('/', (req, res) => {
 var playlist = M3U8.M3U.create();
 playlist.set('targetDuration', '10');
 playlist.set('playlistType', 'VOD');
 playlist.set('version', '3');
 playlist.set('mediaSequence', '0');

 var parser = m3u8.createStream();
 const arr = ['/file.m3u8', '/file2.m3u8']
 async.each(arr, (itm, next) => {
 var file = fs.createReadStream(itm);
 file.pipe(parser);
 parser.on('item', function(item) {
 playlist.addPlaylistItem(item);
 });
 next()
 }, () => {
 res.type('application/vnd.apple.mpegurl').send(playlist.toString());
 })
})
app.listen(port, () => console.log(`App started`));







Has anyone ever accomplish merging two .m3u8 urls to be sent out as a single stream. Thanks


-
avformat/movenc : Support alpha channel for AVIF
1er juin 2022, par Vignesh Venkatasubramanianavformat/movenc : Support alpha channel for AVIF
AVIF specification allows for alpha channel as an auxiliary item (in
case of still images) or as an auxiliary track (in case of animated
images). Add support for both of these. The AVIF muxer will take
exactly two streams (when alpha is present) as input (first one being
the YUV planes and the second one being the alpha plane).The input has to come from two different images (one of it color and
the other one being alpha), or it can come from a single file
source with the alpha channel extracted using the "alphaextract"
filter.Example using alphaextract :
ffmpeg -i rgba.png -filter_complex "[0:v]alphaextract[a]" -map 0 -map "[a]" -still-picture 1 avif_with_alpha.avifExample using two sources (first source can be in any pixel format and
the second source has to be in monochrome grey pixel format) :
ffmpeg -i color.avif -i grey.avif -map 0 -map 1 -c copy avif_with_alpha.avifThe generated files pass the compliance checks in Compliance Warden :
https://github.com/gpac/ComplianceWardenlibavif (the reference avif library) is able to decode the files
generated using this patch.They also play back properly (with transparent background) in :
1) Chrome
2) Firefox (only still AVIF, no animation support)Reviewed-by : James Zern <jzern@google.com>
Signed-off-by : Vignesh Venkatasubramanian <vigneshv@google.com>