Giter Site home page Giter Site logo

Comments (4)

freyacodes avatar freyacodes commented on July 20, 2024 8

I would be willing to enable this for the patron/selfhosted version of FredBoat if lavaplayer was to allow it.

from lavaplayer.

nthmetaljustice avatar nthmetaljustice commented on July 20, 2024 2

I know, it's been some time on this issue, but I would like to +1 this. Lavaplayer should support things like replayGain information for local tracks and online sources, that carry such information.

from lavaplayer.

sedmelluq avatar sedmelluq commented on July 20, 2024 1

In theory this might be possible as YouTube provides some track loudness information. However, this would also require that the volume of all tracks is adjusted, which adds some CPU load (because then YouTube audio would have to be reencoded), which is why volume control is disabled in public FredBoat (if you're running your own instance, you could enable that though).

I might look into this (probably at some point after supporting track metadata), but I have no idea when yet. Although once metadata becomes available you could get the loudness information YouTube gives for a track and adjust volume manually based on that.

from lavaplayer.

Bendodroid avatar Bendodroid commented on July 20, 2024

I did a workaround which I only tested for hosting on Mac and Linux. (Windows might work as well)

Using youtube-dl, ffmpeg and sox (self-compiled on Mac) I'm able to download the audio, analyze it, use grep to extract the necessary information, normalize it, put it in a public file share and hand the link to the file back to lavaplayer.
It works quite well but consumes a lot of time and internet bandwidth due to the way youtube-dl downloads the audio, therefore it's not to be recommended for Bots serving a lot of servers. (Or only to be made available to Patreon supporters or sth like that)
On top, it does require some adjustments to the way the audio metadata gets passed on and make sure the file gets deleted after the song finished playing, otherwise it will eat up your hard drive space.

If you're thinking about trying this, I highly recommend using jproc https://github.com/fleipold/jproc to execute the shell commands and retrieve the output from the console.

from lavaplayer.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.