Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Port audioplayer delegate to use gui media service #114

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

AIIX
Copy link
Collaborator

@AIIX AIIX commented Jan 28, 2022

  • Ports audio player delegate to use the new inbuilt media service playback mechanism, This allows for displaying visualizations and better control, instead of spawning multiple media players
  • Added visualizations

Copy link
Contributor

@krisgesling krisgesling left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey, I can see what you mean - Skills need to choose to use this Delegate or they can use whatever they like.

Both comments optional

id: seekableslider
to: player.duration
//to: root.playerDuration
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems to be handled up on L106-107 is that right? Can we delete this now?

value: root.playerPosition

handle: Item {
x: seekableslider.visualPosition * (parent.width - (Kirigami.Units.largeSpacing + Kirigami.Units.smallSpacing))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've been playing with this a little as I've been seeing the positionMarker move slightly beyond the end of the seek bar at the end of tracks.

This seems to work for me:

x: seekableslider.visualPosition / (parent.width + {implicitWidth_of_hand}) * parent.width ** 2

maybe easier to reason as:

(visualPosition * parent.width) / (parent.width + hand.width) * parent.width

Does that make sense?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants