Recherche avancée

Médias (1)

Mot : - Tags -/école

Autres articles (65)

  • List of compatible distributions

    26 avril 2011, par

    The table below is the list of Linux distributions compatible with the automated installation script of MediaSPIP. Distribution nameVersion nameVersion number Debian Squeeze 6.x.x Debian Weezy 7.x.x Debian Jessie 8.x.x Ubuntu The Precise Pangolin 12.04 LTS Ubuntu The Trusty Tahr 14.04
    If you want to help us improve this list, you can provide us access to a machine whose distribution is not mentioned above or send the necessary fixes to add (...)

  • Le profil des utilisateurs

    12 avril 2011, par

    Chaque utilisateur dispose d’une page de profil lui permettant de modifier ses informations personnelle. Dans le menu de haut de page par défaut, un élément de menu est automatiquement créé à l’initialisation de MediaSPIP, visible uniquement si le visiteur est identifié sur le site.
    L’utilisateur a accès à la modification de profil depuis sa page auteur, un lien dans la navigation "Modifier votre profil" est (...)

  • Configurer la prise en compte des langues

    15 novembre 2010, par

    Accéder à la configuration et ajouter des langues prises en compte
    Afin de configurer la prise en compte de nouvelles langues, il est nécessaire de se rendre dans la partie "Administrer" du site.
    De là, dans le menu de navigation, vous pouvez accéder à une partie "Gestion des langues" permettant d’activer la prise en compte de nouvelles langues.
    Chaque nouvelle langue ajoutée reste désactivable tant qu’aucun objet n’est créé dans cette langue. Dans ce cas, elle devient grisée dans la configuration et (...)

Sur d’autres sites (3450)

  • ffmpeg - how can I get a specific channel using channel masks (e.g. : get only surround left channel)

    26 novembre 2013, par awfulcode

    I'm trying to build a mixer that allows users to toggle specific channels on and off. I know that different codecs encode those channels in different orders (it's not as simple as getting channel #3 as the center channel every time), so the challenge is to properly identify the channel position in surround audio tracks.

    ffmpeg does list the in the beginning of libavutil/channel_layout.h :

    #define AV_CH_FRONT_LEFT             0x00000001
    #define AV_CH_FRONT_RIGHT            0x00000002
    #define AV_CH_FRONT_CENTER           0x00000004
    #define AV_CH_LOW_FREQUENCY          0x00000008
    #define AV_CH_BACK_LEFT              0x00000010
    #define AV_CH_BACK_RIGHT             0x00000020
    #define AV_CH_FRONT_LEFT_OF_CENTER   0x00000040
    #define AV_CH_FRONT_RIGHT_OF_CENTER  0x00000080
    #define AV_CH_BACK_CENTER            0x00000100
    #define AV_CH_SIDE_LEFT              0x00000200
    #define AV_CH_SIDE_RIGHT             0x00000400
    #define AV_CH_TOP_CENTER             0x00000800
    #define AV_CH_TOP_FRONT_LEFT         0x00001000
    #define AV_CH_TOP_FRONT_CENTER       0x00002000
    #define AV_CH_TOP_FRONT_RIGHT        0x00004000
    #define AV_CH_TOP_BACK_LEFT          0x00008000
    #define AV_CH_TOP_BACK_CENTER        0x00010000
    #define AV_CH_TOP_BACK_RIGHT         0x00020000
    #define AV_CH_STEREO_LEFT            0x20000000  ///< Stereo downmix.
    #define AV_CH_STEREO_RIGHT           0x40000000  ///< See AV_CH_STEREO_LEFT.
    #define AV_CH_WIDE_LEFT              0x0000000080000000ULL
    #define AV_CH_WIDE_RIGHT             0x0000000100000000ULL
    #define AV_CH_SURROUND_DIRECT_LEFT   0x0000000200000000ULL
    #define AV_CH_SURROUND_DIRECT_RIGHT  0x0000000400000000ULL
    #define AV_CH_LOW_FREQUENCY_2        0x0000000800000000ULL

    But looking over the header files and whatever little documentation about ffmpeg I couldn't find anything that tells me how to assign a specific channel position (or mask, as it's described in the header file) to a specific bus in a mixer audio unit.

    Do you know how to do that ? Please let me know if you want to look at the code I'm using right now.

    And as always, thank you so much.

  • Youtube Dlp returns with error code of 400 [closed]

    10 mars 2024, par nikita goncharov

    I have a python discord bot that can play music and uses discord.py https://discordpy.readthedocs.io/en/stable/. To play get the music I use yt_dlp or youtube_dl. But when requesting a video it returns with a 400 error code.

    


    This is the error with yt_dlp :

    


    WARNING: [youtube] YouTube said: ERROR - Precondition check failed.

    


    WARNING: [youtube] HTTP Error 400: Bad Request. Retrying (1/3)...

    


    WARNING: [youtube] YouTube said: ERROR - Precondition check failed.

    


    WARNING: [youtube] HTTP Error 400: Bad Request. Retrying (2/3)...

    


    WARNING: [youtube] YouTube said: ERROR - Precondition check failed.

    


    WARNING: [youtube] HTTP Error 400: Bad Request. Retrying (3/3)...

    


    WARNING: [youtube] YouTube said: ERROR - Precondition check failed.

    


    WARNING: [youtube] Unable to download API page: HTTP Error 400: Bad Request (caused by <httperror>)</httperror>

    &#xA;

    I will leave some of the code that I use for my bot... The youtube setup settings :

    &#xA;

    import youtube_dl

    &#xA;

    or

    &#xA;

    import yt_dlp as youtube_dl

    &#xA;

    youtube_dl.utils.bug_reports_message = lambda: &#x27;&#x27;&#xA;&#xA;&#xA;ytdl_format_options = {&#xA;    &#x27;format&#x27;: &#x27;bestaudio/best&#x27;,&#xA;    &#x27;outtmpl&#x27;: &#x27;%(extractor)s-%(id)s-%(title)s.%(ext)s&#x27;,&#xA;    &#x27;restrictfilenames&#x27;: True,&#xA;    &#x27;noplaylist&#x27;: True,&#xA;    &#x27;nocheckcertificate&#x27;: True,&#xA;    &#x27;ignoreerrors&#x27;: False,&#xA;    &#x27;logtostderr&#x27;: False,&#xA;    &#x27;quiet&#x27;: True,&#xA;    &#x27;no_warnings&#x27;: True,&#xA;    &#x27;default_search&#x27;: &#x27;auto&#x27;,&#xA;    &#x27;source_address&#x27;: &#x27;0.0.0.0&#x27;,  # bind to ipv4 since ipv6 addresses cause issues sometimes&#xA;}&#xA;&#xA;ffmpeg_options = {&#xA;    &#x27;options&#x27;: &#x27;-vn&#x27;,&#xA;}&#xA;&#xA;ytdl = youtube_dl.YoutubeDL(ytdl_format_options)&#xA;&#xA;&#xA;class YTDLSource(discord.PCMVolumeTransformer):&#xA;    def __init__(self, source, *, data, volume=0.5):&#xA;        super().__init__(source, volume)&#xA;&#xA;        self.data = data&#xA;&#xA;        self.title = data.get(&#x27;title&#x27;)&#xA;        self.url = data.get(&#x27;url&#x27;)&#xA;        self.duration = data.get(&#x27;duration&#x27;)&#xA;        self.image = data.get("thumbnails")[0]["url"]&#xA;    @classmethod&#xA;    async def from_url(cls, url, *, loop=None, stream=False):&#xA;        loop = loop or asyncio.get_event_loop()&#xA;        data = await loop.run_in_executor(None, lambda: ytdl.extract_info(url, download=not stream))&#xA;        #print(data)&#xA;&#xA;        if &#x27;entries&#x27; in data:&#xA;            # take first item from a playlist&#xA;            data = data[&#x27;entries&#x27;][0]&#xA;        #print(data["thumbnails"][0]["url"])&#xA;        #print(data["duration"])&#xA;        filename = data[&#x27;url&#x27;] if stream else ytdl.prepare_filename(data)&#xA;        return cls(discord.FFmpegPCMAudio(filename, **ffmpeg_options), data=data)&#xA;

    &#xA;

    Approximately the command to run the audio (from my bot) :

    &#xA;

    sessionChanel = message.author.voice.channel await sessionChannel.connect() url = matched.group(1) player = await YTDLSource.from_url(url, loop=client.loop, stream=True) sessionChannel.guild.voice_client.play(player, after=lambda e: print(                                        f&#x27;Player error: {e}&#x27;) if e else None) &#xA;

    &#xA;

    I searched for posts with the same error and they where either old or didn't solve my problem.

    &#xA;

    I tried importing instead of yt_dlp, I tried importing youtube_dl. But when I make the request it does not answer, no exception and no warning it just does not answer, as if the funcion is empty

    &#xA;

    I will link my other post that I asked. It might be usefull : Error : Unable to extract uploader id - Youtube, Discord.py

    &#xA;

  • Revision 97268 : Ne pas se tromper sur le nombre d’erreurs dans le joli message.

    7 mai 2016, par marcimat@… — Log

    Ne pas se tromper sur le nombre d’erreurs dans le joli message.