
Recherche avancée
Autres articles (44)
-
Supporting all media types
13 avril 2011, parUnlike most software and media-sharing platforms, MediaSPIP aims to manage as many different media types as possible. The following are just a few examples from an ever-expanding list of supported formats : images : png, gif, jpg, bmp and more audio : MP3, Ogg, Wav and more video : AVI, MP4, OGV, mpg, mov, wmv and more text, code and other data : OpenOffice, Microsoft Office (Word, PowerPoint, Excel), web (html, CSS), LaTeX, Google Earth and (...)
-
MediaSPIP v0.2
21 juin 2013, parMediaSPIP 0.2 est la première version de MediaSPIP stable.
Sa date de sortie officielle est le 21 juin 2013 et est annoncée ici.
Le fichier zip ici présent contient uniquement les sources de MediaSPIP en version standalone.
Comme pour la version précédente, il est nécessaire d’installer manuellement l’ensemble des dépendances logicielles sur le serveur.
Si vous souhaitez utiliser cette archive pour une installation en mode ferme, il vous faudra également procéder à d’autres modifications (...) -
MediaSPIP version 0.1 Beta
16 avril 2011, parMediaSPIP 0.1 beta est la première version de MediaSPIP décrétée comme "utilisable".
Le fichier zip ici présent contient uniquement les sources de MediaSPIP en version standalone.
Pour avoir une installation fonctionnelle, il est nécessaire d’installer manuellement l’ensemble des dépendances logicielles sur le serveur.
Si vous souhaitez utiliser cette archive pour une installation en mode ferme, il vous faudra également procéder à d’autres modifications (...)
Sur d’autres sites (6649)
-
voiceclient.play(discord.FFmpegPCMAudio) doesn't play any audio
23 septembre 2021, par mm3239I'm trying to create a private music bot. It joined voice channel, but no sound came out and queue didn't worked. My play function is like this :


async def play_music(self):
 if len(self.music_queue) > 0:
 self.is_playing = True

 index = self.music_queue[0][0]['index']

 #connecting to voice channel
 if not self.vc.is_connected():
 self.vc = await self.music_queue[0][1].connect()
 else:
 await self.vc.move_to(self.music_queue[0][1])

 self.music_queue.pop(0)

 self.vc.play(discord.FFmpegPCMAudio(self.music_files[index], **self.FFMPEG_OPTIONS), after=lambda e: self.play_next())



When I execute the file, it should work like this :


Me: /play abc.mp3
Bot: Song added to queue.
*abc song plays in voice channel*
Me: /play def.mp3
Bot: Song added to queue.
Me: /play ghi.mp3
Bot: Song added to queue.

Me: /queue
Bot: def.mp3
 ghi.mp3



However, in reality, Discord :


Me: /play abc.mp3
Bot: Song added to queue.
*silence*
Me: /play def.mp3
Bot: Song added to queue.
Me: /play ghi.mp3
Bot: Song added to queue.

Me: /queue
Bot: No music in queue.



Console :


music found!
[[{'index': 2, 'title': 'abc.mp3'}, <voicechannel>]]
music found!
[[{'index': 0, 'title': 'def.mp3'}, <voicechannel>]]

music found!
[[{'index': 1, 'title': 'ghi.mp3'}, <voicechannel> position=5 bitrate=64000 user_limit=10 category_id=790202432072187909>]]
</voicechannel></voicechannel></voicechannel>


I can see something's wrong(abc and def prints shorter message in console, middle part of message is skipped), but as you can see, it doesn't raise any error or exception. Could anyone please help me correct my code ? I'm completely stuck, and it would be really appreciated if someone could tell me what the problem is.


-
Revision 111238 : On ajoute des classes BEM aux menus et à leurs entrées pour se ...
31 juillet 2018, par tcharlss@… — LogOn ajoute des classes BEM aux menus et à leurs entrées pour se simplifier la vie (les anciennes classes sont conservées bien sûr).
Ce qui donne le markup suivant :
ul.menu-items
li.menu-itemsitem
a.menu-itemslien
Ajout également d’un indicateur de la profondeur des sous-menus : data-depth="N".
Ainsi plus besoin de se casser la tête lorsqu’on veut cibler un sous-menu à une profondeur particulière, par exemple pour un sous-menu de profondeur 2 :
Avant : .menu-items > .item > .menu-items > .item > .menu-items
Après : menu-items[data-depth="2"]
Il y a juste l’entrée de menu « liste ou arborescence de rubriques et d’articles » pour laquelle la profondeur n’est pas indiquée correctement, là tout de suite je n’ai pas le courage de me plonger dans ce labyrinthe lovecraftien. -
ffmpeg (fluent ffmpeg) wrong length while converting mp4 (or mp3) to wav
18 février 2019, par almarcThe code :
ytdl(URL, { quality: "18" })
.pipe(fs.createWriteStream('song.mp4')).on("finish", () => {
var mp4 = "song.mp4"
ffmpeg({ source:mp4 })
.inputFormat('mp4')
.format('wav')
.on('error', (err) => console.error(err))
.on('end', () => console.log('Finished!'))
.pipe(fs.createWriteStream('song.wav'), {
end: true
});
})First it downloads an MP4 file from YouTube, using the ytdl library. Then, when the downloading is finished (the .mp4 file’s length is correct, 5 minutes), using the fluent-ffmpeg library, it converts the .mp4 file to .wav. No errors, it’s succesfull. But the .wav file is almost 7 hours long.
The first 5 minutes are good, the content from that .mp4 file. Then, everything further is empty.I also tried to first convert it to .mp3, and then to .wav, but the results are still the same. 7 hour long track.
Using ffmpeg from the command line gives the same results.