-
-
Notifications
You must be signed in to change notification settings - Fork 370
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
[Feature] Allow bypassing range calculations for Volume Mapper #3110
Comments
@bruyeret worked with half-float lately. Maybe he has some ideas... |
You can use |
Are you suggesting I create a "fake" setRange to prevent fallback to half float? Perhaps something above 2048? I want to avoid a I believe at the end of streaming, I just need to call the |
The method So something equivalent to having "no range" would be to have an "infinite range", which means that you could try setting the range to |
@bruyeret Thanks for your comment, |
I have a PR to skip those calculations by directly using |
Feature Request
For the volume mapper, there is an intrinsic assumption that the full volume is available with the current usage of
halfFloat
texture is as follows:preferSizeOverAccuracy
, it will override it for the sake of memory and use half float.Here is the relevant code:
The issue lies with
hasExactHalfFloat
, which requires the full volume data to calculate the range.There are many situations where the full volume is not available, and it is not desirable to wait until it becomes available to calculate this range. This assumption currently causes issues since it is presumed to be available. At present, vtk.js falls back to halfFloat even if the volume is empty at start (all 0) and the range is 0, which might later be filled with data that is out of range later. Essentially, this is not a feature request but rather a bug fix.
We can introduce a flag that maintains the current default behavior but can be used to bypass all the range-related calculations in streaming situations where data streams in.
Motivation and Detailed Description
The usage of the VolumeMapper is bound to calculating the range on the volume for half-float default fallback when the range allows. This limitation requires the application to always provide the full data for range consideration, which can be slow and sometimes wrong since data might stream inside.
We can introduce a feature flag that allows skipping the range calculation if the application doesn't need it. By default, it would use the current approach, but it can be overridden by a flag like
streamingData
or similar.What do you think? @finetjul
The text was updated successfully, but these errors were encountered: