isSeek true when pausing #1935
Replies: 7 comments 19 replies
-
Yes the behavior is correct due to this behavior: When you pause alphaTab will actually seek back to the "start" of the current beat. e.g. if you have a full note, and press pause on half of it. the cursor and time jumps back to the start of the full note and it will be played as a whole again.
There is no differenciation "what" triggered a seek. From a player perspective it is simply a seek to a different position. If you share more insights on what you plan to do I might be able to give some better hints how to achieve it. |
Beta Was this translation helpful? Give feedback.
-
I want to detect user is actively seeking and give chosen time in seconds and not when a position change occurs due to pause or score load.
|
Beta Was this translation helpful? Give feedback.
-
To explain better: songPosition.innerText = // Added by me to detect when seeking is being done by the user I want to detect user is actively seeking and give chosen time in seconds and not when a position change occurs due to pause or score load. }); |
Beta Was this translation helpful? Give feedback.
-
I am using the Web Audio Api coupled with buffering because audio tag alone is a nightmare when syncing multiple audio files. As for isSeek you are right that it should really work and its kinda working but feel it will add precision to know that the change came directly from the user not the script (not a big problem though). As for your points: b) If the synth should be active, we need to define who is defining the "correct" time axis: the synth or the external audio/video. This is a new approach I haven't considered yet. Now after I wrote all this I saw you mentioning Web Audio :) but with "Mix" as you suggested I am not sure how it will work with Alphatab Context as they might not be accessible via Api easily for me to sync which my own code, but if you do it internally in your code it will be more tightly integrated. Currently I don't use a single audio context as destination as I need each audio track to be outputted to a different audio device vis SetSinkId. I would love for each AlphaTab tracks to also be outputted to a different audio deice but you told me it's very hard, so now I can select one output device for entire Alphatab output. I do have a version where I merge destination gains, so it offers better syncing but that's when user doesn't select any non-default audio device. I hope I make sense. |
Beta Was this translation helpful? Give feedback.
-
Here's my website, just so you understand what I mean with all my questions: Please don’t judge too harshly 😅 — this is something I put together in about a month and a half. It’s still a work in progress and hasn’t been fully tested yet. |
Beta Was this translation helpful? Give feedback.
-
@serenity81 The audio export is also done now. https://next.alphatab.net/docs/guides/audio-export With this you might be able to build your app in the way you want. |
Beta Was this translation helpful? Give feedback.
-
Thanks for the update :)
…On Sun, Jun 15, 2025 at 2:47 AM Daniel Kuschny ***@***.***> wrote:
@serenity81 <https://github.com/serenity81> The audio export is also done
now.
#2160 <#2160>
https://next.alphatab.net/docs/guides/audio-export
With this you might be able to build your app in the way you want.
—
Reply to this email directly, view it on GitHub
<#1935 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AQT4GPV7FF25ATXSXR5MC4T3DSYA3AVCNFSM6AAAAABYSX6PTKVHI2DSMVQWIX3LMV43URDJONRXK43TNFXW4Q3PNVWWK3TUHMYTGNBXGE3TOMI>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi,
The isSeek is returning true when pause button is pressed and no actual seeking is done. It also occurs when we first load without any user interaction. Is this behaviour correct?
https://alphatab.net/docs/reference/api/playerpositionchanged#positionchangedeventargs-properties
I also tried to couple it with playerstatechanged to get stopped parameter but didn't help!
My question is how can I only getting if seeking (both while playing or being paused) without pause or score load triggering it initially?
Beta Was this translation helpful? Give feedback.
All reactions