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

Time based X axis limits. Zooming. Smoothness. #66

Draft
wants to merge 6 commits into
base: devel
Choose a base branch
from

Conversation

dzid26
Copy link
Contributor

@dzid26 dzid26 commented May 17, 2024

edbd032 makes use of system clock to update time axis limit:

  • This allows for silky smooth scrolling - - removes stutter especially visible for low sampling rates - together with 605afa8 closes Renders at only 30fps (half a refresh rate) #57
  • it also allows for straightforward usage of seconds (instead of samples) for the viewport width selection. Seconds are more natural and independant from varying sampling rate.

e336bdd enables axis limits alterations during acquisition. Mouse wheel can be used to zoom in and out. Closes #54
The plot limits expansion at the beginning of the acquisition which makes zooming logic more robust.

@klonyyy
Copy link
Owner

klonyyy commented May 17, 2024

Hello, thanks for your input! Unfortunately, the maxViewportTime does not seem to work correctly. No matter what value I put the viewport width does not change. It seems to be stuck at 5s no matter what.

maxViewport.mp4

@dzid26
Copy link
Contributor Author

dzid26 commented May 17, 2024

Ok, I see the deficiency.

What is desired behavior?:

  1. Change the axis viewport width if the Default viewport time[s] acquisition setting was changed
  2. Always start new acquisition with the Default viewport time[s]
  3. Start new acquisition with the Default viewport time[s] range if the viewport range is narrower than it - to avoid too fast scrolling
  4. Update the Default viewport time[s] acquisition setting after it was modified by zooming the axis with the mouse
  5. Remove the Default viewport time[s] altogether, since it can be set directly using mouse scroll or axis setting.

I have to use it a bit more to get the feel what is best.

Side note, changing the viewport range (with the mouse) during pause is unrelated from changing it during acquisition. This was not intended, but I don't see how to save range changes during pause or even what would be desired behavior. During pause ranges don't have to be the same for different subplots so it kind of doesn't make sense to save one of them. So I think current behavior is good enough. That being said, I think X axis and should be linked by default. But I think it doesn't works if there is at least one bar plot. Let me not mud the water.

@dzid26
Copy link
Contributor Author

dzid26 commented May 18, 2024

After using it a bit more, I think it only makes to either leave it as is or remove Default viewport time[s] from acquisition settings and hardcode a default (to be used when opening the app for the first time).

Another not ideal behavior manifests itself during the STOP state. Since the subplots X axes are allowed not to be linked, only the last (bottom) plot is used for the range when starting the acquisition.

Recording.2024-05-19.002906.mp4

This could be solved by always linking all "curve" axes natively. I think they should be always linked. But first #67 needs to be solved.

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.

None yet

2 participants