Recherche avancée

Médias (2)

Mot : - Tags -/media

Autres articles (110)

  • MediaSPIP 0.1 Beta version

    25 avril 2011, par

    MediaSPIP 0.1 beta is the first version of MediaSPIP proclaimed as "usable".
    The zip file provided here only contains the sources of MediaSPIP in its standalone version.
    To get a working installation, you must manually install all-software dependencies on the server.
    If you want to use this archive for an installation in "farm mode", you will also need to proceed to other manual (...)

  • Websites made ​​with MediaSPIP

    2 mai 2011, par

    This page lists some websites based on MediaSPIP.

  • ANNEXE : Les plugins utilisés spécifiquement pour la ferme

    5 mars 2010, par

    Le site central/maître de la ferme a besoin d’utiliser plusieurs plugins supplémentaires vis à vis des canaux pour son bon fonctionnement. le plugin Gestion de la mutualisation ; le plugin inscription3 pour gérer les inscriptions et les demandes de création d’instance de mutualisation dès l’inscription des utilisateurs ; le plugin verifier qui fournit une API de vérification des champs (utilisé par inscription3) ; le plugin champs extras v2 nécessité par inscription3 (...)

Sur d’autres sites (9426)

  • hevc : reuse edge emu buffer for coefficients

    23 septembre 2014, par Christophe Gisquet
    hevc : reuse edge emu buffer for coefficients
    

    Kind of hackish but...

    Reviewed-by : Mickael Raulet <Mickael.Raulet@insa-rennes.fr>
    Signed-off-by : Michael Niedermayer <michaelni@gmx.at>

    • [DH] libavcodec/hevc.c
    • [DH] libavcodec/hevc.h
    • [DH] libavcodec/hevc_cabac.c
  • Fix old Flash 8 onload() edge case where loading from cache might return "didLoad : false", fix by checking for duration.

    18 juin 2012, par Scott Schiller

    m script/soundmanager2-jsmin.js m script/soundmanager2-nodebug-jsmin.js m script/soundmanager2-nodebug.js m script/soundmanager2.js Fix old Flash 8 onload() edge case where loading from cache might return "didLoad : false", fix by checking for (...)

  • Discord music bot won't join Voice channel

    16 mars 2024, par Skely

    I followed a tutorial for creating a music bot in discord, but it will not join my vc no matter what. Every command works and it gives the correct responses and songs is in the queue. The bot have every permission know to man, but it still won't join. Any way to fix this issue ?&#xA;Thanks in advance !!

    &#xA;

    This is my code and files

    &#xA;

    main.py

    &#xA;

    import discord&#xA;from discord.ext import commands&#xA;import os&#xA;import asyncio&#xA;&#xA;from help_cog import help_cog&#xA;from music_cog import music_cog&#xA;&#xA;bot = commands.Bot(&#xA;    command_prefix="?", &#xA;    intents=discord.Intents.all(),&#xA;    help_command=None&#xA;)&#xA;&#xA;async def main():&#xA;    async with bot:&#xA;        await bot.add_cog(help_cog(bot))&#xA;        await bot.add_cog(music_cog(bot))&#xA;        await bot.start(os.getenv("TOKEN"))&#xA;&#xA;asyncio.run(main())&#xA;

    &#xA;

    music_cog.py

    &#xA;

    import discord&#xA;from discord.ext import commands&#xA;&#xA;from yt_dlp import YoutubeDL&#xA;&#xA;import yt_dlp as youtube_dl&#xA;&#xA;class music_cog(commands.Cog):&#xA;    def __init__(self, bot):&#xA;        self.bot = bot&#xA;&#xA;        self.is_playing = False&#xA;        self.is_paused = False&#xA;&#xA;        self.music_queue = []&#xA;        self.YDL_OPTIONS = {"format": "bestaudio", "postprocessors": [{"key": "FFmpegExtractAudio", "preferredcodec": "mp3", "preferredquality": "192",}]}&#xA;        self.FFMPEG_OPTIONS = {"before_options": "-reconnect 1 -reconnect_streamed 1 -reconnect_delay_max 5", "options": "-vn"}&#xA;&#xA;        self.vc = None&#xA;        print("Success")&#xA;&#xA;    def search_yt(self, item):&#xA;        with YoutubeDL(self.YDL_OPTIONS) as ydl:&#xA;            try:&#xA;                info = ydl.extract_info(f"ytsearch:{item}", download=False)["entries"][0]&#xA;            except Exception:&#xA;                return False&#xA;        return {"source": info["url"], "title": info["title"]}&#xA;&#xA;    def play_next(self):&#xA;        if len(self.music_queue) > 0:&#xA;            self.is_playing = True&#xA;&#xA;            m_url = self.music_queue[0][0]["source"]&#xA;&#xA;            self.music_queue.pop(0)&#xA;&#xA;            self.vc.play(discord.FFmpegPCMAudio(m_url, **self.FFMPEG_OPTIONS), after=lambda e: self.play_next())&#xA;        else:&#xA;            self.is_playing = False&#xA;&#xA;    async def play_music(self, ctx):&#xA;        if len(self.music_queue) > 0:&#xA;            self.is_playing = True&#xA;            m_url = self.music_queue[0][0]["source"]&#xA;&#xA;            if self.vc == None or not self.vc.is_connected():&#xA;                self.vc = await self.music_queue[0][1].connect()&#xA;&#xA;                if self.vc == None:&#xA;                    await ctx.send("Could not connect to the voice channel")&#xA;                    return&#xA;            else:&#xA;                await self.vc.move_to(self.music_queue[0][1])&#xA;            &#xA;            self.music_queue.pop(0)&#xA;&#xA;            self.vc.play(discord.FFmpegPCMAudio(m_url, **self.FFMPEG_OPTIONS), after=lambda e: self.play_next())&#xA;&#xA;        else:&#xA;            self.is_playing = False&#xA;&#xA;    @commands.command(name="play", aliases=["p", "playing"], help="Play the selected song from YouTube")&#xA;    async def play(self, ctx, *args):&#xA;        query = " ".join(args)&#xA;&#xA;        voice_channel = ctx.author.voice.channel&#xA;        if voice_channel is None:&#xA;            await ctx.send("Connect to a voice channel!")&#xA;        elif self.is_paused:&#xA;            self.vc.resume()&#xA;        else:&#xA;            song = self.search_yt(query)&#xA;            if type(song) == type(True):&#xA;                await ctx.send("Could not download the song. Incorrect format, try a different keyword")&#xA;            else:&#xA;                await ctx.send("Song added to queue")&#xA;                self.music_queue.append([song, voice_channel])&#xA;&#xA;                if self.is_playing == False:&#xA;                    await self.play_music(ctx)&#xA;    &#xA;    @commands.command(name="pause", help="Pauses the current song being played")&#xA;    async def pause(self, ctx, *args):&#xA;        if self.is_playing:&#xA;            self.is_playing = False&#xA;            self.is_paused = True&#xA;            self.vc.pause()&#xA;        elif self.is_paused:&#xA;            self.is_playing = True&#xA;            self.is_paused = False&#xA;            self.vc.resume()&#xA;&#xA;    @commands.command(name="resume", aliases=["r"], help="Resumes playing the current song")&#xA;    async def resume(self, ctx, *args):&#xA;        if self.is_paused:&#xA;            self.is_playing = True&#xA;            self.is_paused = False&#xA;            self.vc.resume()&#xA;        &#xA;    @commands.command(name="skip", aliases=["s"], help="Skips the currently played song")&#xA;    async def skip(self, ctx, *args):&#xA;        if self.vc != None and self.vc:&#xA;            self.vc.stop()&#xA;            await self.play_music(ctx)&#xA;&#xA;    @commands.command(name="queue", aliases=["q"], help="Displays all the songs currently in queue")&#xA;    async def queue(self, ctx):&#xA;        retval = ""&#xA;&#xA;        for i in range(0, len(self.music_queue)):&#xA;            if i > 4: break&#xA;            retval &#x2B;= self.music_queue[i][0]["title"] &#x2B; "\n"&#xA;&#xA;        if retval != "":&#xA;            await ctx.send(retval)&#xA;        else:&#xA;            await ctx.send("No music in the current queue")&#xA;    &#xA;    @commands.command(name="clear", aliases=["c", "bin"], help="Stops the current song and clears the queue")&#xA;    async def clear(self, ctx, *args):&#xA;        if self.vc != None and self.is_playing:&#xA;            self.vc.stop()&#xA;        self.music_queue = []&#xA;        await ctx.send("Music queue cleared")&#xA;&#xA;    @commands.command(name="leave", aliases=["disconnect", "l", "d"], help="Kick the bot from the voice channel")&#xA;    async def leave(self, ctx):&#xA;        self.is_playing = False&#xA;        self.is_paused = False&#xA;        await self.vc.disconnect()&#xA;

    &#xA;

    help_cog.py

    &#xA;

    import discord&#xA;from discord.ext import commands&#xA;&#xA;class help_cog(commands.Cog):&#xA;    def __init__(self, bot):&#xA;        self.bot = bot&#xA;&#xA;        self.help_message = """&#xA;        Help message&#xA;"""&#xA;&#xA;        self.text_channel_text = []&#xA;    &#xA;    @commands.Cog.listener()&#xA;    async def on_ready(self):&#xA;        for guild in self.bot.guilds:&#xA;            for channel in guild.text_channels:&#xA;                self.text_channel_text.append(channel)&#xA;&#xA;        await self.send_to_all(self.help_message)&#xA;&#xA;    async def send_to_all(self, msg):&#xA;        for text_channel in self.text_channel_text:&#xA;            await text_channel.send(msg)&#xA;        &#xA;    @commands.command(name="help", help="Displays all the available commands")&#xA;    async def help(self, ctx):&#xA;        await ctx.send(self.help_message)&#xA;

    &#xA;