-
Notifications
You must be signed in to change notification settings - Fork 24
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
Fix zooming out for datasets with very large scale #6304
Conversation
… the max zoom value calculation
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.
Nice fix, but I'm not sure whether the maximum iteration count is computed correctly, see my comment :)
// From that, we calculate the theoretical maximum zoom value. The dataset scale is taken into account, | ||
// because the entire scene is scaled with that. | ||
const maxSupportedZoomValue = 2 ** MAX_SUPPORTED_MAGNIFICATION_COUNT * Math.max(...datasetScale); | ||
const maximumIterationCount = Math.log(maxSupportedZoomValue) / Math.log(ZOOM_STEP_INTERVAL); |
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 would be the correct iteration count if the start zoom value were 1. However, it is 1 / ZOOM_STEP_INTERVAL ** 20
so 20 would need to be added.
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.
Very good point 👍 I adapted the code.
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.
Nice 👍
…type * 'master' of github.com:scalableminds/webknossos: Ensure unique volume layer names when changing names in frontend (#6289) X-Auth Tokens everywhere (in datastore & tracingstore) (#6312) add mapping name param for rawcuboid (#6311) Fix zooming out for datasets with very large scale (#6304) Release 22.07.0 (#6307) added Sahil's publication to list
Respect the dataset scale when calculating the maximum iteration limit for the max zoom value determination.
URL of deployed dev instance (used for testing):
Steps to test:
Issues:
(Please delete unneeded items, merge only when none are left open)