Recherche avancée

Médias (91)

Autres articles (78)

  • Websites made ​​with MediaSPIP

    2 mai 2011, par

    This page lists some websites based on MediaSPIP.

  • Des sites réalisés avec MediaSPIP

    2 mai 2011, par

    Cette page présente quelques-uns des sites fonctionnant sous MediaSPIP.
    Vous pouvez bien entendu ajouter le votre grâce au formulaire en bas de page.

  • Creating farms of unique websites

    13 avril 2011, par

    MediaSPIP platforms can be installed as a farm, with a single "core" hosted on a dedicated server and used by multiple websites.
    This allows (among other things) : implementation costs to be shared between several different projects / individuals rapid deployment of multiple unique sites creation of groups of like-minded sites, making it possible to browse media in a more controlled and selective environment than the major "open" (...)

Sur d’autres sites (11935)

  • checkasm/vf_gblur : add test for horiz_slice simd

    4 juin 2019, par Ruiling Song
    checkasm/vf_gblur : add test for horiz_slice simd
    

    Signed-off-by : Ruiling Song <ruiling.song@intel.com>

    • [DH] tests/checkasm/Makefile
    • [DH] tests/checkasm/checkasm.c
    • [DH] tests/checkasm/checkasm.h
    • [DH] tests/checkasm/vf_gblur.c
    • [DH] tests/fate/checkasm.mak
  • Hosting music bot on heroku

    2 mars 2021, par itsmaxplayz

    I have made a discord bot on discord.py rewrite which plays music in a voice channel. The code is as follows :

    &#xA;

    def search(query):&#xA;&#xA;    with ytdl:&#xA;        try:&#xA;            requests.get(query)&#xA;        except:&#xA;            info = ytdl.extract_info(f"ytsearch:{query}", download=False)[&#x27;entries&#x27;][0]&#xA;        else:&#xA;            info = ytdl.extract_info(query, download=False)&#xA;    return info, info[&#x27;formats&#x27;][0][&#x27;url&#x27;]&#xA;&#xA;ydl_opts = {&#xA;    &#x27;format&#x27;: &#x27;bestaudio/best&#x27;,&#xA;    &#x27;quiet&#x27;: True,&#xA;    &#x27;postprocessors&#x27;: [{&#xA;        &#x27;key&#x27;: &#x27;FFmpegExtractAudio&#x27;,&#xA;        &#x27;preferredcodec&#x27;: &#x27;mp3&#x27;,&#xA;        &#x27;preferredquality&#x27;: &#x27;192&#x27;,&#xA;    }],&#xA;&#xA;}&#xA;&#xA;ytdl = youtube_dl.YoutubeDL(ydl_opts)&#xA;&#xA;FFMPEG_OPTS = {&#x27;before_options&#x27;: &#x27;-reconnect 1 -reconnect_streamed 1 -reconnect_delay_max 5&#x27;, &#x27;options&#x27;: &#x27;-vn&#x27;}&#xA;&#xA;@client.command(aliases=[&#x27;p&#x27;])&#xA;async def play(ctx, *, url):&#xA;    channel = ctx.message.author.voice.channel&#xA;    voice = get(client.voice_clients, guild=ctx.guild)&#xA;    if voice and voice.is_connected():&#xA;        pass&#xA;    else:&#xA;        voice = await channel.connect()&#xA;        await ctx.send(f&#x27;Successfully joined `{channel}`&#x27;)&#xA;&#xA;    if voice.is_playing():&#xA;        await ctx.send(&#x27;Already playing a song. Try using -q or -queue to queue a song &#xA;    :thumbsup:&#x27;)&#xA;    else:&#xA;        await ctx.send(f&#x27;Searching for: `{url}` :mag_right:&#x27;)&#xA;        video, source = search(url)&#xA;        voice.play(FFmpegPCMAudio(source, **FFMPEG_OPTS))&#xA;        voice.is_playing()&#xA;        await ctx.send(f&#x27;Playing: :notes: `{video["title"]}` - Now!&#x27;)&#xA;

    &#xA;

    It works locally but when I upload the code to heroku (I use github to push the code to heroku), the bot does not come online.&#xA;These are the libraries that I imported in the code :

    &#xA;

    import discord&#xA;import json&#xA;import random&#xA;import youtube_dl&#xA;import requests&#xA;import os&#xA;from discord.ext import commands&#xA;from discord.utils import get&#xA;from discord import FFmpegPCMAudio&#xA;import ctypes&#xA;import ctypes.util&#xA;

    &#xA;

    I have installed the ffmpeg buildpacks as I saw in another post on this website but the bot doesn't come online.

    &#xA;

    Contents of my requirement file :

    &#xA;

    discord.py,&#xA;discord.py[voice],&#xA;ffmpeg,&#xA;PyNaCl,&#xA;youtube_dl,&#xA;requests,&#xA;discord.py[FFmpegPCMAudio],&#xA;colorlog.

    &#xA;

  • Music bot doesn't play livestreams anymore

    31 janvier 2019, par Silvinator

    My Discord bot played YT Livestreams all the time, but it stopped working today. The only message I get (in the console) is stream. It plays normal videos, but no streams.
    The question is, why it stopped working ? I did not change any code. Anyone got a idea ?

    client.on("message", async message => {
     var args = message.content.substring(prefix.length).split(" ");
     if (!message.content.startsWith(prefix)) return;
     var searchString = args.slice(1).join(' ');
     var url = args[1] ? args[1].replace(/&lt;(.+)>/g, '$1') : '';
     var serverQueue = queue.get(message.guild.id);
     switch (args[0].toLowerCase()) {
       case "play":
         var voiceChannel = message.member.voiceChannel;
         if (!voiceChannel) return message.channel.send(`Du willst mit mir Karaoke singen? Da ich eh nichts besseres zu tun habe. Du suchst aber den Voice Channel aus!`);
         var permissions = voiceChannel.permissionsFor(message.client.user);
         if (!permissions.has('CONNECT')) {
           return message.channel.send('I cannot connect to your voice channel, make sure I have the proper permissions!');
         }
         if (!permissions.has('SPEAK')) {
           return message.channel.send('I cannot speak in this voice channel, make sure I have the proper permissions!');
         }
         if (url.match(/^https?:\/\/(www.youtube.com|youtube.com)\/playlist(.*)$/)) {
           var playlist = await youtube.getPlaylist(url);
           var videos = await playlist.getVideos();
           for (const video of Object.values(videos)) {
             var video2 = await youtube.getVideoByID(video.id); // eslint-disable-line no-await-in-loop
             await handleVideo(video2, message, voiceChannel, true); // eslint-disable-line no-await-in-loop
           }
           return message.channel.send(`Ich habe wohl keine andere wahl... Ich habe **${playlist.title}** der playlist zugefügt`);
         } else {
           try {
             var video = await youtube.getVideo(url);
           } catch (error) {
             try {
               var videos = await youtube.searchVideos(searchString, 10);
               var index = 0;
               var videoIndex = 1;
               var video = await youtube.getVideoByID(videos[videoIndex - 1].id);
             } catch (err) {
               console.error(err);
               return message.channel.send('Gibt es den Song überhaupt?');
             }
           }
           return handleVideo(video, message, voiceChannel);
         }
         break;
       case "skip":
         if (!message.member.voiceChannel) return message.channel.send('Du musst schon in den Voice Channel gehen, baka!');
         if (!serverQueue) return message.channel.send('Du musst schon ein song auswählen, baka!');
         serverQueue.connection.dispatcher.end('Skip command has been used!');
         return undefined;
         break;
       case "stop":
         if (!message.member.voiceChannel) return message.channel.send('Du musst schon in den Voice Channel gehen, baka!');
         if (!serverQueue) return message.channel.send('Du musst schon einen Song auswählen, baka');
         serverQueue.connection.dispatcher.end('Stop command has been used!');
         serverQueue.songs = [];
         return undefined;
         break;
       case "minfo":
         if (!serverQueue) return message.channel.send('Ich spiele immer noch nichts!');
         return message.channel.send(`ퟎ