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

Add basic image view and controls #359

Merged
merged 14 commits into from
Mar 29, 2024
Merged

Add basic image view and controls #359

merged 14 commits into from
Mar 29, 2024

Conversation

annehaley
Copy link
Collaborator

@annehaley annehaley commented Mar 8, 2024

This PR adds the image view mode, which will be used by default for rendering any vtkImageData. Previously, we used an imageMarchingCubes filter to turn vtkImageData into vtkPolyData, which could take a while to compute.

The image view mode includes the following basic controls/features:

  • Axis selector
  • Slice slider
  • Window/Level sliders

When the "Groomed" layer is enabled:

  • Intersection mode, which makes the groomed shape invisible, instead showing where the shape intersects the current slice
  • Crop mode, which crops the image slices to the area where the groomed shape is (with 1% padding)

When the "Particles" layer is enabled and Intersection mode is enabled:

  • Particle filtering: show only particles that exist within the bounds of the current slice

The following video demonstrates each of these features (speed 2x).
https://github.com/girder/shapeworks-cloud/assets/44912689/ba9d7b60-f56b-4ef2-b4df-51953d92880d

Base automatically changed from constraints-and-landmarks to master March 18, 2024 17:15
@annehaley annehaley marked this pull request as ready for review March 21, 2024 13:23
@annehaley annehaley requested review from manthey and JakeWags March 21, 2024 13:23
Copy link
Collaborator

@JakeWags JakeWags left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All looks good! Approved 👍

renderer.resetCamera()
},
updateIntersection(slice) {
// TODO: account for multidomain cases
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a plan in place for this? The image slice should be the same regardless of domain number.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I will need a dataset to use to implement this; I don't currently have a multidomain dataset where the original data are images. The slices will be the same, but there would be n shapes to intersect and n particles objects to filter.

@annehaley annehaley merged commit 4313760 into master Mar 29, 2024
4 checks passed
@annehaley annehaley deleted the image-view branch March 29, 2024 17:25
@annehaley annehaley mentioned this pull request May 8, 2024
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.

2 participants