acm-uiuc / beats

Beats by ACM
11 stars 19 forks source link

Equalizer support + improved playback shuffle #56

Closed logiconcepts819 closed 9 years ago

logiconcepts819 commented 9 years ago

Hello,

I present to you two improvements that I made to Beats. One of the two improvements is equalizer support for LibVLC 2.2.0 or newer. In the web interface, if Beats is using a compatible version of LibVLC, he or she should see a button to the left of the volume control containing a gears icon that opens a dialog showing the equalizer controls when clicked. (Of course, if the user is not logged in and the user clicks the button, a login prompt will appear.)

The other improvement is a modified (psuedo-)random sampler to help prevent Beats from playing the same song back-to-back. In the beats.cfg.sample file, you will see two new settings: 'dont_repeat_for' and 'max_dont_repeat_for'. The setting value for 'max_dont_repeat_for' is a non-negative integer representing the maximum number of most recently played songs to prevent Beats from playing back. The setting value for 'dont_repeat_for' is a real number greater than or equal to 0 and less than 1 representing a fraction (or percentage) of the total number of songs in the database, which is the number of songs to prevent Beats from playing back, provided that number doesn't exceed 'max_dont_repeat_for'. Both settings are optional, so Beats will run even with one or both of these settings omitted from the config file. If 'max_dont_repeat_for' is omitted, then there is no restriction on 'dont_repeat_for'. The default setting value for 'dont_repeat_for' is 0, so if 'dont_repeat_for' is omitted, then songs are (psuedo-)randomly selected like how they are now.

milanocookies93 commented 9 years ago

@kevinwang

kevinwang commented 9 years ago

Awesome! Could you separate this into two independent PRs?

logiconcepts819 commented 9 years ago

I just created three new PRs: https://github.com/acm-uiuc/beats/pull/57, https://github.com/acm-uiuc/beats/pull/58, and https://github.com/acm-uiuc/beats/pull/59.