Recherche avancée

Médias (1)

Mot : - Tags -/artwork

Autres articles (34)

  • Support audio et vidéo HTML5

    10 avril 2011

    MediaSPIP utilise les balises HTML5 video et audio pour la lecture de documents multimedia en profitant des dernières innovations du W3C supportées par les navigateurs modernes.
    Pour les navigateurs plus anciens, le lecteur flash Flowplayer est utilisé.
    Le lecteur HTML5 utilisé a été spécifiquement créé pour MediaSPIP : il est complètement modifiable graphiquement pour correspondre à un thème choisi.
    Ces technologies permettent de distribuer vidéo et son à la fois sur des ordinateurs conventionnels (...)

  • Support de tous types de médias

    10 avril 2011

    Contrairement à beaucoup de logiciels et autres plate-formes modernes de partage de documents, MediaSPIP a l’ambition de gérer un maximum de formats de documents différents qu’ils soient de type : images (png, gif, jpg, bmp et autres...) ; audio (MP3, Ogg, Wav et autres...) ; vidéo (Avi, MP4, Ogv, mpg, mov, wmv et autres...) ; contenu textuel, code ou autres (open office, microsoft office (tableur, présentation), web (html, css), LaTeX, Google Earth) (...)

  • La file d’attente de SPIPmotion

    28 novembre 2010, par

    Une file d’attente stockée dans la base de donnée
    Lors de son installation, SPIPmotion crée une nouvelle table dans la base de donnée intitulée spip_spipmotion_attentes.
    Cette nouvelle table est constituée des champs suivants : id_spipmotion_attente, l’identifiant numérique unique de la tâche à traiter ; id_document, l’identifiant numérique du document original à encoder ; id_objet l’identifiant unique de l’objet auquel le document encodé devra être attaché automatiquement ; objet, le type d’objet auquel (...)

Sur d’autres sites (7519)

  • How To Make Discord Bot Play YouTube URL

    6 mars 2021, par ivFiz

    I'm new to this and I wonder if there's a way I can make my bot play specific YouTube URL
so when I type s1 the bot join the room and play that URL

    


     if (message.content == "s1") {
     if (!message.member.voice.channel) return message.reply("You have to be in a VoiceChannel");
     message.member.voice.channel.join().then(VoiceConnection => {
         VoiceConnection.play("https://youtu.be/~~~~").on("finish", () => 
         VoiceConnection.disconnect());
         message.reply("done");
     }).catch(e => console.log(e))
 };


    


  • Changing volume in an audio (mp3) file with ffmpeg

    4 août 2024, par M Pl

    I have audio of a voice lecture given by a man. I tried
ffmpeg -i in.mp3 -af volume=6 output out.mp3

    


    It seemed to process, but the output sounded the same as the input. Then I tried
ffmpeg -i in.mp3 -af volume=20dB output out.mp3

    


    with the same result. When I tried
ffmpeg -i in.mp3 -af volume=30dB output out.mp3

    


    it came out louder and there was even some distortion. Is this because the man's voice is in a low register ? What can I do to just boost the audio to double the loudness ? (volume=2 did not seem to do anything.)

    


    ffmpeg -i in.mp3 -af volume=6 output out.mp3 - had no apparent effect
ffmpeg -i in.mp3 -af volume=20dB output out.mp3 also had no apparent effect

    


  • discord.py music bot can't play next song

    6 décembre 2020, par bork

    I'm making a discord music bot using ffmpeg and youtube-dl. I have a premade playlist of urls that would play the list of songs once a user chooses it.
    
this is my code for playing the audio

    


    ydl_opts = {
            'format': 'bestaudio', 
            'noplaylist':'True',
            'youtube_include_dash_manifest': False
            }
FFMPEG_OPTIONS = {
            'before_options': '-reconnect 1 -reconnect_streamed 1 -reconnect_delay_max 5',
            'options': '-vn'
            }

songs = url[playlist]
dur_min = 0
pre_dur_sec = 0
with YoutubeDL(ydl_opts) as ydl:
    for i in songs:
        info = ydl.extract_info(i, download = False)
        dur = info['duration']
        playlist_songs.append(info)

playlist_songs_copy = playlist_songs.copy()
for i in playlist_songs_copy:
    info = playlist_songs.pop(0)
    URL = info['formats'][0]['url']
    player = FFmpegPCMAudio(URL, **FFMPEG_OPTIONS)
    q.append(player)
    q_playlist.append(playlist)

if not voice.is_playing():
    source = q.pop(0)  
    playlist = q_playlist.pop(0)
    dur_min = duration_min.pop(0)
    dur_sec = duration_sec.pop(0)  
    voice.play(source, after = lambda e: play_next(ctx, source))      
    voice.is_playing()
    await ctx.send(f'```nim\n*Now Playing:*\nplaylist {playlist}: {name[playlist]}\n\n{content[playlist]}\n\ntotal duration: {dur_min}:{dur_sec}```')


    


    and this is my code for playing the next song

    


    def play_next(ctx, source):
    voice = get(client.voice_clients, guild = ctx.guild)
    if len(q) >= 1:
        try:
            del combine_q[0]
            source = q.pop(0)
            playlist = q_playlist.pop(0)
            dur_min = duration_min.pop(0)
            dur_sec = duration_sec.pop(0)

        except:
            pass

        voice.play(source, after = lambda e: play_next(ctx, source))
        try:
            asyncio.run_coroutine_threadsafe(ctx.send(f'```nim\n*Now Playing:*\nplaylist {playlist}: {name[playlist]}\n\n{content[playlist]}\n\ntotal duration: {dur_min}:{dur_sec}```'), client.loop)
        
        except:
            asyncio.run_coroutine_threadsafe(ctx.send('```nim\nPlaying the next song...```'), client.loop)
        
    else:
        time.sleep(30) 
        if not voice.is_playing():
            asyncio.run_coroutine_threadsafe(voice.disconnect(), client.loop)
            asyncio.run_coroutine_threadsafe(ctx.send("```nim\nNo more songs in queue.```"),client.loop)
            voice.is_paused()


    


    Up till today, it's been working fine. But I was using the bot just now and instead of playing the song and sending the message "Playing the next song..." as usual, it just stopped and spammed the message for about 30 times before it disconnected. When I checked the logs, it showed
socket.send() raised exception
, which was also spammed in the terminal. When I tried making the bot reconnect, it joined my voice channel but didn't respond to any commands and would keep making the discord "connecting" noise. It wouldn't even leave with my .leave command unless I completely turned it off via the script.

    


    The same connecting problem would continue even after I reran the script and would only stop after I restarted my VS Code which is really odd...

    


    After some testing I found out that as of now, the bot is only able to play two songs before breaking. I really need help as this just happened randomly and I'm unable to find anything online about the problem.