Feature request: Button to synchronize projectionOrientation and crossSectionOrientation
- Dominant language
- TypeScript
- Stars
- 1.5k
- Forks
- 389
- Avg merge
- 3d 21h
- Merged PRs (30d)
- 3
Description
Sometimes I'm looking at a structure in 3D, and I want to orient the 2D slices so that they match the orientation in my 3D view. Here's the procedure I follow:
1. Find the orientation I want in the 3D view.
2. Open the JSON settings
3. Copy the `projectionOrientation` quaternion and paste it as the `crossSectionOrientation`.
It would be cool if there was a button in the UI to do that for me. In fact, maybe it could be a checkbox: `Sync 3D/2D orientations`. When checked, the `projectionOrientation` and `crossSectionOrientation` would be kept in lock step.
Here are some example use-cases:
- [Finding a nice cross section through the drosophila ellipsoid body][1]
- [Finding the cross section that makes a perpendicular cut through a fiber bundle][2]
- In general, it would be nice if I could easily use the 3D view to track a neurite in real time while keeping the 2D view perpendicular to the neurite's main axis.
[1]: https://neuroglancer-demo.appspot.com/#!%7B%22dimensions%22:%7B%22x%22:%5B8e-9%2C%22m%22%5D%2C%22y%22:%5B8e-9%2C%22m%22%5D%2C%22z%22:%5B8e-9%2C%22m%22%5D%7D%2C%22position%22:%5B25898.900390625%2C25555.21484375%2C20360.810546875%5D%2C%22crossSectionOrientation%22:%5B-0.25881072878837585%2C-0.025489550083875656%2C0.0023765789810568094%2C0.9655887484550476%5D%2C%22crossSectionScale%22:12.132318590451126%2C%22crossSectionDepth%22:-37.62185354999912%2C%22projectionOrientation%22:%5B-0.25881072878837585%2C-0.025489550083875656%2C0.0023765789810568094%2C0.9655887484550476%5D%2C%22projectionScale%22:16335.762045449683%2C%22layers%22:%5B%7B%22type%22:%22image%22%2C%22source%22:%22precomputed://gs://neuroglancer-janelia-flyem-hemibrain/emdata/clahe_yz/jpeg%22%2C%22tab%22:%22source%22%2C%22name%22:%22emdata%22%7D%2C%7B%22type%22:%22segmentation%22%2C%22source%22:%7B%22url%22:%22precomputed://gs://neuroglancer-janelia-flyem-hemibrain/v1.2/segmentation%22%2C%22subsources%22:%7B%22default%22:true%2C%22properties%22:true%2C%22mesh%22:true%7D%2C%22enableDefaultSubsources%22:false%7D%2C%22tab%22:%22segments%22%2C%22objectAlpha%22:0.3%2C%22name%22:%22segmentation%22%2C%22visible%22:false%7D%2C%7B%22type%22:%22segmentation%22%2C%22source%22:%7B%22url%22:%22precomputed://gs://neuroglancer-janelia-flyem-hemibrain/v1.2/mito-objects-grouped%22%2C%22subsources%22:%7B%22default%22:true%2C%22mesh%22:true%7D%2C%22enableDefaultSubsources%22:false%7D%2C%22pick%22:false%2C%22tab%22:%22segments%22%2C%22selectedAlpha%22:0%2C%22saturation%22:0%2C%22linkedSegmentationGroup%22:%22segmentation%22%2C%22name%22:%22mito-grouped%22%7D%2C%7B%22type%22:%22annotation%22%2C%22source%22:%22precomputed://gs://neuroglancer-janelia-flyem-hemibrain/v1.2/synapses%22%2C%22tab%22:%22rendering%22%2C%22ignoreNullSegmentFilter%22:false%2C%22shader%22:%22#uicontrol%20bool%20showPsds%20checkbox%28default=true%29%5Cn#uicontrol%20vec3%20preColor%20color%28default=%5C%22red%5C%22%29%5Cn#uicontrol%20vec3%20postColor%20color%28default=%5C%22blue%5C%22%29%5Cn#uicontrol%20float%20preConfidence%20slider%28min=0%2C%20max=1%2C%20default=0%29%5Cn#uicontrol%20float%20postConfidence%20slider%28min=0%2C%20max=1%2C%20default=0%29%5Cn%5Cnvoid%20main%28%29%20%7B%5Cn%20%20setColor%28defaultColor%28%29%29%3B%5Cn%20%20%5Cn%20%20setEndpointMarkerColor%28%5Cn%20%20%20%20vec4%28preColor%2C%200.5%29%2C%5Cn%20%20%20%20vec4%28postColor%2C%200.5%29%29%3B%5Cn%20%20%5Cn%20%20if%20%28showPsds%29%20%7B%5Cn%20%20%20%20setEndpointMarkerSize%288.0%2C%204.0%29%3B%5Cn%20%20%7D%5Cn%20%20else%20%7B%5Cn%20%20%20%20setLineWidth%280.0%29%3B%5Cn%20%20%20%20setEndpointMarkerSize%288.0%2C%200.0%29%3B%5Cn%20%20%7D%5Cn%20%20%5Cn%20%20if%20%28prop_pre_synaptic_confidence%28%29%3C%20preConfidence%20%7C%7C%5Cn%20%20%20%20%20%20prop_post_synaptic_confidence%28%29%3C%20postConfidence%29%20discard%3B%5Cn%7D%5Cn%22%2C%22shaderControls%22:%7B%22showPsds%22:false%7D%2C%22linkedSegmentationLayer%22:%7B%22pre_synaptic_cell%22:%22segmentation%22%2C%22post_synaptic_cell%22:%22segmentation%22%7D%2C%22filterBySegmentation%22:%5B%22pre_synaptic_cell%22%5D%2C%22name%22:%22synapse%22%2C%22visible%22:false%7D%2C%7B%22type%22:%22segmentation%22%2C%22source%22:%7B%22url%22:%22precomputed://gs://neuroglancer-janelia-flyem-hemibrain/v1.2/rois%22%2C%22subsources%22:%7B%22default%22:true%2C%22properties%22:true%2C%22mesh%22:true%7D%2C%22enableDefaultSubsources%22:false%7D%2C%22pick%22:false%2C%22tab%22:%22rendering%22%2C%22selectedAlpha%22:0.54%2C%22saturation%22:0%2C%22objectAlpha%22:0.8%2C%22ignoreNullVisibleSet%22:false%2C%22meshSilhouetteRendering%22:3%2C%22segments%22:%5B%2217%22%5D%2C%22name%22:%22roi%22%7D%2C%7B%22type%22:%22segmentation%22%2C%22source%22:%7B%22url%22:%22precomputed://gs://neuroglancer-janelia-flyem-hemibrain/v1.2/mito-classes%22%2C%22subsources%22:%7B%22default%22:true%2C%22properties%22:true%2C%22mesh%22:true%7D%2C%22enableDefaultSubsources%22:false%7D%2C%22pick%22:false%2C%22tab%22:%22segments%22%2C%22segmentColors%22:%7B%224%22:%22#000000%22%7D%2C%22name%22:%22mito-classes%22%2C%22visible%22:false%7D%2C%7B%22type%22:%22segmentation%22%2C%22source%22:%7B%22url%22:%22precomputed://gs://neuroglancer-janelia-flyem-hemibrain/mask_normalized_round6%22%2C%22subsources%22:%7B%22default%22:true%2C%22properties%22:true%7D%2C%22enableDefaultSubsources%22:false%7D%2C%22pick%22:false%2C%22tab%22:%22segments%22%2C%22selectedAlpha%22:0.53%2C%22segmentColors%22:%7B%227%22:%22#000000%22%7D%2C%22name%22:%22voxel-classes%22%2C%22visible%22:false%7D%2C%7B%22type%22:%22segmentation%22%2C%22source%22:%7B%22url%22:%22precomputed://gs://flyem-ng-layers/hemibrain/all_brain_roi%22%2C%22subsources%22:%7B%22default%22:true%2C%22properties%22:true%2C%22mesh%22:true%7D%2C%22enableDefaultSubsources%22:false%7D%2C%22pick%22:false%2C%22tab%22:%22source%22%2C%22selectedAlpha%22:0%2C%22saturation%22:0%2C%22meshSilhouetteRendering%22:4%2C%22segments%22:%5B%221%22%5D%2C%22name%22:%22brain-mask%22%2C%22visible%22:false%7D%5D%2C%22showSlices%22:false%2C%22selectedLayer%22:%7B%22visible%22:true%2C%22layer%22:%22roi%22%7D%2C%22layout%22:%224panel%22%7D
[2]: https://neuroglancer-demo.appspot.com/#!%7B%22dimensions%22:%7B%22x%22:%5B8e-9%2C%22m%22%5D%2C%22y%22:%5B8e-9%2C%22m%22%5D%2C%22z%22:%5B8e-9%2C%22m%22%5D%7D%2C%22position%22:%5B22761.041015625%2C17579.001953125%2C17469.666015625%5D%2C%22crossSectionOrientation%22:%5B-0.11229529231786728%2C0.8244591355323792%2C-0.4458264708518982%2C-0.32999345660209656%5D%2C%22crossSectionScale%22:1.100619111180815%2C%22crossSectionDepth%22:-37.62185354999912%2C%22projectionOrientation%22:%5B-0.11229529231786728%2C0.8244591355323792%2C-0.4458264708518982%2C-0.32999345660209656%5D%2C%22projectionScale%22:6009.591012389681%2C%22layers%22:%5B%7B%22type%22:%22image%22%2C%22source%22:%22precomputed://gs://neuroglancer-janelia-flyem-hemibrain/emdata/clahe_yz/jpeg%22%2C%22tab%22:%22source%22%2C%22name%22:%22emdata%22%7D%2C%7B%22type%22:%22segmentation%22%2C%22source%22:%7B%22url%22:%22precomputed://gs://neuroglancer-janelia-flyem-hemibrain/v1.2/segmentation%22%2C%22subsources%22:%7B%22default%22:true%2C%22properties%22:true%2C%22mesh%22:true%7D%2C%22enableDefaultSubsources%22:false%7D%2C%22toolBindings%22:%7B%22Q%22:%22selectSegments%22%7D%2C%22tab%22:%22segments%22%2C%22segments%22:%5B%221017547830%22%2C%221019357327%22%2C%221160807120%22%2C%221175433492%22%2C%221223887468%22%2C%221223887527%22%2C%221224228290%22%2C%221224228359%22%2C%221254581155%22%2C%221254922094%22%2C%221298985697%22%2C%221455438367%22%2C%22330319983%22%2C%22361341837%22%2C%22362866879%22%2C%22388280249%22%2C%22423749262%22%2C%22424582092%22%2C%22454787848%22%2C%22454935401%22%2C%22487882254%22%2C%22517682957%22%2C%22548575149%22%2C%22549049148%22%2C%22549727330%22%2C%22550275987%22%2C%22579963818%22%2C%22580093930%22%2C%225812983281%22%2C%225812983404%22%2C%225812983510%22%2C%225812988064%22%2C%225813012995%22%2C%225813019676%22%2C%225813022370%22%2C%225813022811%22%2C%225813022915%22%2C%225813033255%22%2C%225813040766%22%2C%225813053669%22%2C%225813061934%22%2C%225813096198%22%2C%225901193671%22%2C%225901213819%22%2C%22608948356%22%2C%22609975449%22%2C%22612643681%22%2C%22639974538%22%2C%22642323384%22%2C%22642694410%22%2C%22642715563%22%2C%22642715875%22%2C%22643060819%22%2C%22643350227%22%2C%22644425543%22%2C%22669666822%22%2C%22669978138%22%2C%22671657343%22%2C%22672524871%22%2C%22673746538%22%2C%22674760695%22%2C%22674760884%22%2C%22675447609%22%2C%22675490017%22%2C%22675784199%22%2C%22699998408%22%2C%22700356592%22%2C%22702069970%22%2C%22702199343%22%2C%22703101952%22%2C%22703438567%22%2C%22704111734%22%2C%22704777224%22%2C%22705454177%22%2C%22705463175%22%2C%22705795727%22%2C%22706473389%22%2C%22706499298%22%2C%22728995438%22%2C%22730005624%22%2C%22734408687%22%2C%22736140238%22%2C%22736507123%22%2C%22736632557%22%2C%22738009096%22%2C%22759681018%22%2C%22760021137%22%2C%22760358472%22%2C%22761044410%22%2C%22762698149%22%2C%22764412104%22%2C%22765975775%22%2C%22766653726%22%2C%22766846796%22%2C%22767313008%22%2C%22767321428%22%2C%22767329844%22%2C%22767486231%22%2C%22769195048%22%2C%22769355285%22%2C%22769924974%22%2C%22793797279%22%2C%22794967711%22%2C%22795982617%22%2C%22796543393%22%2C%22796889169%22%2C%22797558130%22%2C%22797562316%22%2C%22798849134%22%2C%22799249679%22%2C%22800286386%22%2C%22800588608%22%2C%22827323331%22%2C%22827673856%22%2C%22827911067%22%2C%22828597380%22%2C%22829050526%22%2C%22829059301%22%2C%22831291329%22%2C%22832107249%22%2C%22857538779%22%2C%22862792304%22%2C%22862947261%22%2C%22863815503%22%2C%22889993487%22%2C%22890287086%22%2C%22891111303%22%2C%22892722090%22%2C%22895091952%22%2C%22919314668%22%2C%22982540894%22%2C%22983905050%22%5D%2C%22name%22:%22segmentation%22%7D%2C%7B%22type%22:%22segmentation%22%2C%22source%22:%7B%22url%22:%22precomputed://gs://neuroglancer-janelia-flyem-hemibrain/v1.2/mito-objects-grouped%22%2C%22subsources%22:%7B%22default%22:true%2C%22mesh%22:true%7D%2C%22enableDefaultSubsources%22:false%7D%2C%22pick%22:false%2C%22tab%22:%22segments%22%2C%22selectedAlpha%22:0%2C%22saturation%22:0%2C%22linkedSegmentationGroup%22:%22segmentation%22%2C%22name%22:%22mito-grouped%22%2C%22visible%22:false%7D%2C%7B%22type%22:%22annotation%22%2C%22source%22:%22precomputed://gs://neuroglancer-janelia-flyem-hemibrain/v1.2/synapses%22%2C%22tab%22:%22rendering%22%2C%22ignoreNullSegmentFilter%22:false%2C%22shader%22:%22#uicontrol%20bool%20showPsds%20checkbox%28default=true%29%5Cn#uicontrol%20vec3%20preColor%20color%28default=%5C%22red%5C%22%29%5Cn#uicontrol%20vec3%20postColor%20color%28default=%5C%22blue%5C%22%29%5Cn#uicontrol%20float%20preConfidence%20slider%28min=0%2C%20max=1%2C%20default=0%29%5Cn#uicontrol%20float%20postConfidence%20slider%28min=0%2C%20max=1%2C%20default=0%29%5Cn%5Cnvoid%20main%28%29%20%7B%5Cn%20%20setColor%28defaultColor%28%29%29%3B%5Cn%20%20%5Cn%20%20setEndpointMarkerColor%28%5Cn%20%20%20%20vec4%28preColor%2C%200.5%29%2C%5Cn%20%20%20%20vec4%28postColor%2C%200.5%29%29%3B%5Cn%20%20%5Cn%20%20if%20%28showPsds%29%20%7B%5Cn%20%20%20%20setEndpointMarkerSize%288.0%2C%204.0%29%3B%5Cn%20%20%7D%5Cn%20%20else%20%7B%5Cn%20%20%20%20setLineWidth%280.0%29%3B%5Cn%20%20%20%20setEndpointMarkerSize%288.0%2C%200.0%29%3B%5Cn%20%20%7D%5Cn%20%20%5Cn%20%20if%20%28prop_pre_synaptic_confidence%28%29%3C%20preConfidence%20%7C%7C%5Cn%20%20%20%20%20%20prop_post_synaptic_confidence%28%29%3C%20postConfidence%29%20discard%3B%5Cn%7D%5Cn%22%2C%22shaderControls%22:%7B%22showPsds%22:false%7D%2C%22linkedSegmentationLayer%22:%7B%22pre_synaptic_cell%22:%22segmentation%22%2C%22post_synaptic_cell%22:%22segmentation%22%7D%2C%22filterBySegmentation%22:%5B%22pre_synaptic_cell%22%5D%2C%22name%22:%22synapse%22%2C%22visible%22:false%7D%2C%7B%22type%22:%22segmentation%22%2C%22source%22:%7B%22url%22:%22precomputed://gs://neuroglancer-janelia-flyem-hemibrain/v1.2/rois%22%2C%22subsources%22:%7B%22default%22:true%2C%22properties%22:true%2C%22mesh%22:true%7D%2C%22enableDefaultSubsources%22:false%7D%2C%22pick%22:false%2C%22tab%22:%22segments%22%2C%22selectedAlpha%22:0.54%2C%22saturation%22:0%2C%22objectAlpha%22:0.8%2C%22ignoreNullVisibleSet%22:false%2C%22meshSilhouetteRendering%22:3%2C%22name%22:%22roi%22%2C%22visible%22:false%7D%2C%7B%22type%22:%22segmentation%22%2C%22source%22:%7B%22url%22:%22precomputed://gs://neuroglancer-janelia-flyem-hemibrain/v1.2/mito-classes%22%2C%22subsources%22:%7B%22default%22:true%2C%22properties%22:true%2C%22mesh%22:true%7D%2C%22enableDefaultSubsources%22:false%7D%2C%22pick%22:false%2C%22tab%22:%22segments%22%2C%22segmentColors%22:%7B%224%22:%22#000000%22%7D%2C%22name%22:%22mito-classes%22%2C%22visible%22:false%7D%2C%7B%22type%22:%22segmentation%22%2C%22source%22:%7B%22url%22:%22precomputed://gs://neuroglancer-janelia-flyem-hemibrain/mask_normalized_round6%22%2C%22subsources%22:%7B%22default%22:true%2C%22properties%22:true%7D%2C%22enableDefaultSubsources%22:false%7D%2C%22pick%22:false%2C%22tab%22:%22segments%22%2C%22selectedAlpha%22:0.53%2C%22segmentColors%22:%7B%227%22:%22#000000%22%7D%2C%22name%22:%22voxel-classes%22%2C%22visible%22:false%7D%2C%7B%22type%22:%22segmentation%22%2C%22source%22:%7B%22url%22:%22precomputed://gs://flyem-ng-layers/hemibrain/all_brain_roi%22%2C%22subsources%22:%7B%22default%22:true%2C%22properties%22:true%2C%22mesh%22:true%7D%2C%22enableDefaultSubsources%22:false%7D%2C%22pick%22:false%2C%22tab%22:%22source%22%2C%22selectedAlpha%22:0%2C%22saturation%22:0%2C%22meshSilhouetteRendering%22:4%2C%22segments%22:%5B%221%22%5D%2C%22name%22:%22brain-mask%22%2C%22visible%22:false%7D%5D%2C%22showSlices%22:false%2C%22selectedLayer%22:%7B%22visible%22:true%2C%22layer%22:%22segmentation%22%7D%2C%22layout%22:%22xz-3d%22%7D
Contributor guide
Assessment
This issue has not been assessed yet.