-
Notifications
You must be signed in to change notification settings - Fork 548
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
dockfft: zoom slider uses log scale with max 100000x #1248
dockfft: zoom slider uses log scale with max 100000x #1248
Conversation
After this change, it's no longer possible to zoom all the way out using the slider, because its minimum value is 1, which corresponds to a zoom level of 1.12x: Lines 300 to 302 in 996737c
Changing that to 0 seems to solve the problem. |
124b033
to
015cc10
Compare
This PR implements the suggestion I made in #1235 (comment), but it doesn't solve the bugs described in #1235; I verified that they're still present. |
I'll take a look. |
1eb2691
to
0597b35
Compare
src/qtgui/plotter.cpp
Outdated
@@ -1525,6 +1502,7 @@ void CPlotter::draw(bool newData) | |||
{ | |||
m_2DPixmap.fill(PLOTTER_BGD_COLOR); | |||
QPainter painter2(&m_2DPixmap); | |||
painter2.translate(QPointF(0.5, 0.5)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this change (and the corresponding change in drawOverlay
) deserves to be in its own PR, since it's unrelated to zooming.
0597b35
to
7b19b67
Compare
PRs split. I'll take a look at zoom/pan limits. |
7b19b67
to
db873d4
Compare
Zoom and pan are now limited to avoid blank space. This does make it a bit difficult to zoom in on something at the very low/high end of the scale, especially the low end. Given that there's generally no useful information in the margins, this works for me. There's no good way to allow pan but not zoom outside the valid area. |
db873d4
to
95ecd36
Compare
There are still some problems with this ... still working ... |
95ecd36
to
95c92e4
Compare
OK, ready for you to try out. |
36eb586
to
5f91743
Compare
5f91743
to
41404fe
Compare
Sorry for the long delay in getting to this. I noticed another bug: if you're fully zoomed out, then try to zoom in one step using the mouse wheel, the zoom is not centred around the mouse position. I think that's a side effect of the change to |
The same behaviour also happens if you're zoomed in and are close to the upper or lower frequency limit. |
Isn't that just a side effect of not wanting any blank space? |
No, it's not. It should always be possible to zoom in around the mouse cursor, regardless of its position, because the frequency limits are moving towards the cursor frequency. The problem here is that |
OK, I was looking at a different effect ... will fix. |
Also, zoom and pan are constrained so no "empty space" is shown at the sides of the plot. Signed-off-by: Jeff Long <[email protected]>
41404fe
to
3ebb051
Compare
Your update looks like it should fix it. Taking it for a spin now. |
It was inadvertently removed in #1248.
It was inadvertently removed in gqrx-sdr#1248.
A log scale is more sensible for the zoom slider, and it was difficult to make it work at all with a linear scale.
Fixes #1235
Also: