Recherche avancée

Médias (3)

Mot : - Tags -/collection

Autres articles (32)

  • Multilang : améliorer l’interface pour les blocs multilingues

    18 février 2011, par

    Multilang est un plugin supplémentaire qui n’est pas activé par défaut lors de l’initialisation de MediaSPIP.
    Après son activation, une préconfiguration est mise en place automatiquement par MediaSPIP init permettant à la nouvelle fonctionnalité d’être automatiquement opérationnelle. Il n’est donc pas obligatoire de passer par une étape de configuration pour cela.

  • 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 (...)

  • Liste des distributions compatibles

    26 avril 2011, par

    Le tableau ci-dessous correspond à la liste des distributions Linux compatible avec le script d’installation automatique de MediaSPIP. Nom de la distributionNom de la versionNuméro de version 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
    Si vous souhaitez nous aider à améliorer cette liste, vous pouvez nous fournir un accès à une machine dont la distribution n’est pas citée ci-dessus ou nous envoyer le (...)

Sur d’autres sites (7660)

  • Error (ERR_STREAM_DESTROYED) : Cannot call write after a stream was destroyed

    3 avril 2021, par TTT Tobi Triple Talk

    I'm getting this error when I run my discord bot on my raspberry pi. It worked everytime when I run it on my windows machine. I installed FFmpeg with sudo apt-get install ffmpeg. I don't know if I need to install something else for ffmpeg on my raspberry pi
This is the error I'm getting

    


    events.js:291
      throw er; // Unhandled 'error' event
      ^

Error [ERR_STREAM_DESTROYED]: Cannot call write after a stream was destroyed
    at doWrite (_stream_writable.js:399:19)
    at writeOrBuffer (_stream_writable.js:387:5)
    at Socket.Writable.write (_stream_writable.js:318:11)
    at PassThrough.ondata (_stream_readable.js:718:22)
    at PassThrough.emit (events.js:314:20)
    at addChunk (_stream_readable.js:297:12)
    at readableAddChunk (_stream_readable.js:272:9)
    at PassThrough.Readable.push (_stream_readable.js:213:10)
    at PassThrough.Transform.push (_stream_transform.js:152:32)
    at PassThrough.afterTransform (_stream_transform.js:96:10)
Emitted 'error' event on FFmpeg instance at:
    at errorOrDestroy (internal/streams/destroy.js:108:12)
    at FFmpeg.onerror (_stream_readable.js:754:7)
    at FFmpeg.emit (events.js:314:20)
    at Socket.processError (node_modules/prism-media/src/core/FFmpeg.js:64:40)
    at Socket.emit (events.js:314:20)
    at errorOrDestroy (internal/streams/destroy.js:108:12)
    at onwriteError (_stream_writable.js:418:5)
    at onwrite (_stream_writable.js:445:5)
    at doWrite (_stream_writable.js:399:11)
    at writeOrBuffer (_stream_writable.js:387:5) {
  code: 'ERR_STREAM_DESTROYED'
}


    


    Normally it should play an audio stream to a discord channel.
I don't think my code is wrong, because it's working on my other computer.
My code :

    


    let stream;
//Meme.url is just a youtube link, like https://www.youtube.com/watch?v=dQw4w9WgXcQ
stream = ytdl(meme.url, {
    filter: "audioonly",
    opusEncoded: true,
    encoderArgs: ['-af', "dynaudnorm=f=150"]
}).on("error", (err) => {
    console.log(err);
});
    try {
        song_queue.connection.play(stream, { type: "opus" })
        .on('finish', () => {
            
        });
    } catch (err) {
        console.log(err);
        message.channel.send("Error while the meme song");
    }


    


  • Discord FFmpegPCMAudio bad audio quality

    17 mars 2021, par Yareyare

    I'm writing a discord music bot in python and encountered some audio quality issue. When I use discord.FFmpegPCMAudio("song.mp3") to play a mp3 file downloaded using youtube_dl in a channel, there're sometimes intermittent background noice and it sounds laggy and broken.
    
I tried to pass {'vbr':5} as an argument, and also tried discord.FFmpegOpusAudio, but doesn't do any better. The file itself is not corrupted, since it sounds normal when I play it using another app. Internet connection also isn't the cause, as each time I play the same file, the exact audio quality issue occurs at the exact same time.
    
I'm quite stuck right now. What other factors may caused this audio quality loss ?

    


  • ffmpeg processes pile up until they crash

    9 mars 2021, par Ultra Cookie

    I am coding a bot which streams music using ytdl and @discordjs/opus. It uses ffmpeg for that and when I end the dispatcher the process doesn't get killed. After a while this piles up and the process list looks like this :

    


    0     0 27864 27863  20   0 120348 14380 sock_a Sl+  pts/2      0:01 /root/bot/node_modules/ffmpeg-static/ffmpeg -i - -analyzeduration 0 -loglevel 0 -f s16le -ar 48000 -ac 2 pipe:1
0     0 27887     1  20   0 120104 13496 sock_a Sl+  pts/2      0:00 /root/bot/node_modules/ffmpeg-static/ffmpeg -i - -analyzeduration 0 -loglevel 0 -f s16le -ar 48000 -ac 2 pipe:1
0     0 27893     1  20   0 120040 13676 sock_a Sl+  pts/2      0:00 /root/bot/node_modules/ffmpeg-static/ffmpeg -i - -analyzeduration 0 -loglevel 0 -f s16le -ar 48000 -ac 2 pipe:1
0     0 27900     1  20   0 120048 13676 sock_a Sl+  pts/2      0:00 /root/bot/node_modules/ffmpeg-static/ffmpeg -i - -analyzeduration 0 -loglevel 0 -f s16le -ar 48000 -ac 2 pipe:1
0     0 27906     1  20   0 120048 13676 sock_a Sl+  pts/2      0:00 /root/bot/node_modules/ffmpeg-static/ffmpeg -i - -analyzeduration 0 -loglevel 0 -f s16le -ar 48000 -ac 2 pipe:1
0     0 27913     1  20   0 103740 13792 sock_a S+   pts/2      0:00 /root/bot/node_modules/ffmpeg-static/ffmpeg -i - -analyzeduration 0 -loglevel 0 -f s16le -ar 48000 -ac 2 pipe:1



    


    This is just a preview the actual list is much longer... I don't know how I can prevent this.

    


    Code that might be helpful :

    


    Play:
connection.play(ytdl(song.url, { quality: "highestaudio", highWaterMark: 1024 * 1024 * 30, type: "opus" })).on("finish", () => {play next song});

Skip:
connection.dispatcher.end();