mirror of
https://github.com/librespot-org/librespot.git
synced 2026-04-27 08:15:50 +03:00
[GH-ISSUE #410] Feature request: PlayerEvents for VolUp and VolDown #262
Labels
No labels
A-Alsa
SpotifyAPI
Tokio 1.0
audio
bug
can't reproduce
compilation
dependencies
duplicate
enhancement
good first issue
help wanted
high priority
imported
imported
invalid
new api
pull-request
question
reverse engineering
wiki
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/librespot#262
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @Muffexx on GitHub (Dec 12, 2019).
Original GitHub issue: https://github.com/librespot-org/librespot/issues/410
Hi,
since there are PlayerEvents (player.rs) for started, changed and stopped, would it be possible to add events for VolUp and VolDown? This way I could control the volume of my receiver by running scripts that use HDMI-CEC (https://github.com/Pulse-Eight/libcec).
Even better would be to directly integrate HDMI-CEC-support, but I assume this would consume too much time.
Thanks for your reply.
Kind regards
@michaelherger commented on GitHub (Dec 13, 2019):
I have something similar added to my branch:
github.com/michaelherger/librespot@fb7b8d7230. It would trigger a volume change event with the actual value sent to the event handler. Ignore theself.lms.is_configuredcondition - that's specific to my application. And thelms.rsis my custom event handler implementation. That change would belong inplayer_event_handler.rs.@delMar43 commented on GitHub (Jan 29, 2020):
I like the idea of just exposing the event. That leaves me with the possibility to either change volume of the AVR via HDMI-CEC, or via API (in case I decide to connect via TOS-Link or analog, instead of HDMI)
Alongside the new volume-change events, we'd probably also need a way to suppress volume changes of the internal player, as that volume should stay at eg 75 or 100%.
In case it's relevant, I'd like to vote for merging this.
@Muffexx commented on GitHub (Jan 29, 2020):
This would be even better.