girder-large-image 1.31.2.dev47__tar.gz → 1.31.2.dev64__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/PKG-INFO +3 -3
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/widgets/CompositeLayers.vue +8 -4
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/widgets/FrameSelector.vue +2 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/widgets/HistogramEditor.vue +114 -42
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image.egg-info/PKG-INFO +3 -3
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image.egg-info/requires.txt +2 -2
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/LICENSE +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/README.rst +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/__init__.py +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/constants.py +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/girder_tilesource.py +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/loadmodelcache.py +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/models/__init__.py +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/models/image_item.py +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/rest/__init__.py +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/rest/item_meta.py +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/rest/large_image_resource.py +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/rest/tiles.py +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/eventStream.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/extra/.gitignore +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/index.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/main.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/package.json +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/routes.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/stylesheets/fileList.styl +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/stylesheets/imageViewerSelectWidget.styl +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/stylesheets/itemList.styl +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/stylesheets/itemView.styl +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/stylesheets/itemViewCodemirror.styl +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/stylesheets/largeImageConfig.styl +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/stylesheets/metadataWidget.styl +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/templates/imageViewerSelectWidget.pug +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/templates/itemList.pug +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/templates/itemView.pug +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/templates/itemViewCodemirror.pug +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/templates/largeImageConfig.pug +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/templates/largeImage_fileAction.pug +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/templates/metadataWidget.pug +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/templates/metadatumEditWidget.pug +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/views/configView.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/views/fileList.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/views/imageViewerSelectWidget.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/views/imageViewerWidget/base.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/views/imageViewerWidget/geojs.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/views/imageViewerWidget/index.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/views/imageViewerWidget/leaflet.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/views/imageViewerWidget/openlayers.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/views/imageViewerWidget/openseadragon.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/views/imageViewerWidget/setFrameQuad.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/views/imageViewerWidget/slideatlas.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/views/index.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/views/itemList.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/views/itemView.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/views/itemViewCodemirror.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/views/itemViewWidget.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/views/metadataWidget.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/vue/components/PresetsMenu.vue +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/webpack.helper.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/widgets/DualInput.vue +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/widgets/colors.json +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/web_client/widgets/components.py +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image.egg-info/SOURCES.txt +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image.egg-info/dependency_links.txt +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image.egg-info/entry_points.txt +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image.egg-info/not-zip-safe +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image.egg-info/top_level.txt +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/pyproject.toml +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/setup.cfg +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/setup.py +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/test_girder/__init__.py +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/test_girder/conftest.py +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/test_girder/girder_utilities.py +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/test_girder/test_large_image.py +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/test_girder/test_tiles_rest.py +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/test_girder/test_web_client.py +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/test_girder/web_client_specs/.eslintrc +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/test_girder/web_client_specs/imageViewerSpec.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/test_girder/web_client_specs/largeImageSpec.js +0 -0
- {girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/test_girder/web_client_specs/otherFeatures.js +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: girder-large-image
|
|
3
|
-
Version: 1.31.2.
|
|
3
|
+
Version: 1.31.2.dev64
|
|
4
4
|
Summary: A Girder plugin to work with large, multiresolution images.
|
|
5
5
|
Home-page: https://github.com/girder/large_image
|
|
6
6
|
Author: Kitware, Inc.
|
|
@@ -21,9 +21,9 @@ Description-Content-Type: text/x-rst
|
|
|
21
21
|
License-File: LICENSE
|
|
22
22
|
Requires-Dist: girder>=3.1.18
|
|
23
23
|
Requires-Dist: girder-jobs>=3.0.3
|
|
24
|
-
Requires-Dist: large_image>=1.31.2.
|
|
24
|
+
Requires-Dist: large_image>=1.31.2.dev64
|
|
25
25
|
Provides-Extra: tasks
|
|
26
|
-
Requires-Dist: large-image-tasks[girder]>=1.31.2.
|
|
26
|
+
Requires-Dist: large-image-tasks[girder]>=1.31.2.dev64; extra == "tasks"
|
|
27
27
|
Requires-Dist: girder-worker[girder]>=0.6.0; extra == "tasks"
|
|
28
28
|
|
|
29
29
|
A Girder plugin to work with large, multiresolution images.
|
|
@@ -8,6 +8,7 @@ module.exports = {
|
|
|
8
8
|
'histogramParamStyle',
|
|
9
9
|
'frameHistograms',
|
|
10
10
|
'getFrameHistogram',
|
|
11
|
+
'dtype',
|
|
11
12
|
'layers',
|
|
12
13
|
'layerMap',
|
|
13
14
|
'active',
|
|
@@ -241,16 +242,18 @@ module.exports = {
|
|
|
241
242
|
this.updateStyle();
|
|
242
243
|
},
|
|
243
244
|
updateLayerMin(layer, newVal) {
|
|
244
|
-
const
|
|
245
|
+
const valid = Number.isFinite(newVal);
|
|
246
|
+
const newMinVal = valid ? parseFloat(newVal) : newVal;
|
|
245
247
|
this.compositeLayerInfo[layer].min = newMinVal;
|
|
246
248
|
this.compositeLayerInfo = Object.assign({}, this.compositeLayerInfo); // for reactivity
|
|
247
|
-
this.updateStyle();
|
|
249
|
+
if (valid) this.updateStyle();
|
|
248
250
|
},
|
|
249
251
|
updateLayerMax(layer, newVal) {
|
|
250
|
-
const
|
|
252
|
+
const valid = Number.isFinite(newVal);
|
|
253
|
+
const newMaxVal = valid ? parseFloat(newVal) : newVal;
|
|
251
254
|
this.compositeLayerInfo[layer].max = newMaxVal;
|
|
252
255
|
this.compositeLayerInfo = Object.assign({}, this.compositeLayerInfo); // for reactivity
|
|
253
|
-
this.updateStyle();
|
|
256
|
+
if (valid) this.updateStyle();
|
|
254
257
|
},
|
|
255
258
|
updateActiveLayers() {
|
|
256
259
|
this.layers.forEach((layer) => {
|
|
@@ -449,6 +452,7 @@ module.exports = {
|
|
|
449
452
|
:auto-range="autoRange"
|
|
450
453
|
:current-min="min"
|
|
451
454
|
:current-max="max"
|
|
455
|
+
:dtype="dtype"
|
|
452
456
|
:active="active"
|
|
453
457
|
:update-min="(v, d) => updateLayerMin(layerName, v, d)"
|
|
454
458
|
:update-max="(v, d) => updateLayerMax(layerName, v, d)"
|
|
@@ -389,6 +389,7 @@ module.exports = {
|
|
|
389
389
|
:histogram-param-style="histogramParamStyles[2]"
|
|
390
390
|
:frame-histograms="frameHistograms"
|
|
391
391
|
:get-frame-histogram="getFrameHistogram"
|
|
392
|
+
:dtype="metadata.dtype"
|
|
392
393
|
:layers="metadata.channels"
|
|
393
394
|
:layer-map="metadata.channelmap"
|
|
394
395
|
:active="currentModeId === 2"
|
|
@@ -405,6 +406,7 @@ module.exports = {
|
|
|
405
406
|
:histogram-param-style="histogramParamStyles[3]"
|
|
406
407
|
:frame-histograms="frameHistograms"
|
|
407
408
|
:get-frame-histogram="getFrameHistogram"
|
|
409
|
+
:dtype="metadata.dtype"
|
|
408
410
|
:layers="metadata.bands"
|
|
409
411
|
:layer-map="undefined"
|
|
410
412
|
:active="currentModeId === 3"
|
|
@@ -1,4 +1,34 @@
|
|
|
1
1
|
<script>
|
|
2
|
+
const dtypeAliases = {
|
|
3
|
+
i1: 'int8',
|
|
4
|
+
u1: 'uint8',
|
|
5
|
+
i2: 'int16',
|
|
6
|
+
u2: 'uint16',
|
|
7
|
+
i4: 'int32',
|
|
8
|
+
u4: 'uint32',
|
|
9
|
+
i8: 'int64',
|
|
10
|
+
u8: 'uint64',
|
|
11
|
+
f2: 'float16',
|
|
12
|
+
f4: 'float32',
|
|
13
|
+
f: 'float32',
|
|
14
|
+
f8: 'float64',
|
|
15
|
+
d: 'float64'
|
|
16
|
+
};
|
|
17
|
+
|
|
18
|
+
const dtypeRanges = {
|
|
19
|
+
int8: [-128, 127],
|
|
20
|
+
uint8: [0, 255],
|
|
21
|
+
int16: [-32768, 32767],
|
|
22
|
+
uint16: [0, 65535],
|
|
23
|
+
int32: [-2147483648, 2147483647],
|
|
24
|
+
uint32: [0, 4294967295],
|
|
25
|
+
int64: [-9.22e18, 9.22e18],
|
|
26
|
+
uint64: [0, 1.84e19],
|
|
27
|
+
float16: [-65500, 65500],
|
|
28
|
+
float32: [-3.4e38, 3.4e38],
|
|
29
|
+
float64: [-1.7e308, 1.7e308]
|
|
30
|
+
};
|
|
31
|
+
|
|
2
32
|
function clamp(num, min, max) {
|
|
3
33
|
return Math.min(Math.max(num, min), max);
|
|
4
34
|
}
|
|
@@ -23,14 +53,19 @@ function makeDraggableSVG(svg, validateDrag, callback, xRange) {
|
|
|
23
53
|
|
|
24
54
|
function startDrag(evt) {
|
|
25
55
|
const target = evt.target;
|
|
56
|
+
Array.from(document.body.getElementsByClassName('range-editor')).forEach(
|
|
57
|
+
(el) => {
|
|
58
|
+
el.style.userSelect = 'none';
|
|
59
|
+
}
|
|
60
|
+
);
|
|
26
61
|
if (target && target.classList.contains('draggable')) {
|
|
27
62
|
selectedShape = target;
|
|
28
63
|
posOffset = getMousePosition(evt);
|
|
29
64
|
posOffset.x -= parseFloat(
|
|
30
|
-
selectedShape.
|
|
65
|
+
selectedShape.getAttribute('x1') || '0'
|
|
31
66
|
);
|
|
32
67
|
posOffset.y -= parseFloat(
|
|
33
|
-
selectedShape.
|
|
68
|
+
selectedShape.getAttribute('y1') || '0'
|
|
34
69
|
);
|
|
35
70
|
}
|
|
36
71
|
}
|
|
@@ -46,20 +81,25 @@ function makeDraggableSVG(svg, validateDrag, callback, xRange) {
|
|
|
46
81
|
coord.x = clamp(coord.x, xRange[0], xRange[1]);
|
|
47
82
|
const [moveX, moveY] = validateDrag(selectedShape, coord);
|
|
48
83
|
if (!moveX) {
|
|
49
|
-
coord.x = parseFloat(selectedShape.
|
|
84
|
+
coord.x = parseFloat(selectedShape.getAttribute('x1') || '0');
|
|
50
85
|
}
|
|
51
86
|
if (!moveY) {
|
|
52
|
-
coord.y = parseFloat(selectedShape.
|
|
87
|
+
coord.y = parseFloat(selectedShape.getAttribute('y1') || '0');
|
|
53
88
|
}
|
|
54
89
|
|
|
55
|
-
selectedShape.
|
|
56
|
-
selectedShape.
|
|
57
|
-
selectedShape.
|
|
90
|
+
selectedShape.setAttribute('x1', `${coord.x}`);
|
|
91
|
+
selectedShape.setAttribute('x2', `${coord.x}`);
|
|
92
|
+
selectedShape.setAttribute('y1', `${coord.y}`);
|
|
58
93
|
callback(selectedShape, coord);
|
|
59
94
|
}
|
|
60
95
|
}
|
|
61
96
|
|
|
62
97
|
function endDrag() {
|
|
98
|
+
Array.from(document.body.getElementsByClassName('range-editor')).forEach(
|
|
99
|
+
(el) => {
|
|
100
|
+
el.style.userSelect = 'auto';
|
|
101
|
+
}
|
|
102
|
+
);
|
|
63
103
|
selectedShape = undefined;
|
|
64
104
|
}
|
|
65
105
|
}
|
|
@@ -75,6 +115,7 @@ module.exports = {
|
|
|
75
115
|
'framedelta',
|
|
76
116
|
'currentMin',
|
|
77
117
|
'currentMax',
|
|
118
|
+
'dtype',
|
|
78
119
|
'autoRange',
|
|
79
120
|
'active',
|
|
80
121
|
'updateMin',
|
|
@@ -101,7 +142,7 @@ module.exports = {
|
|
|
101
142
|
}
|
|
102
143
|
},
|
|
103
144
|
histogram() {
|
|
104
|
-
this.xRange = [5, this.$refs.svg.clientWidth
|
|
145
|
+
this.xRange = [5, this.$refs.svg.clientWidth];
|
|
105
146
|
this.vRange = [this.histogram.min, this.histogram.max];
|
|
106
147
|
this.drawHistogram(
|
|
107
148
|
this.simplifyHistogram(this.histogram.hist)
|
|
@@ -122,18 +163,42 @@ module.exports = {
|
|
|
122
163
|
},
|
|
123
164
|
autoRange() {
|
|
124
165
|
this.initializePositions();
|
|
166
|
+
},
|
|
167
|
+
invert() {
|
|
168
|
+
this.drawHistogram(this.simplifyHistogram(this.histogram.hist));
|
|
169
|
+
if (this.invert) {
|
|
170
|
+
this.$refs.maxExclusionBox.setAttribute('visibility', 'hidden');
|
|
171
|
+
} else {
|
|
172
|
+
this.$refs.maxExclusionBox.setAttribute('visibility', 'visible');
|
|
173
|
+
}
|
|
125
174
|
}
|
|
126
175
|
},
|
|
127
176
|
computed: {
|
|
128
177
|
minVal() {
|
|
129
178
|
if (!this.histogram) return 0;
|
|
130
179
|
if (this.autoRange !== undefined) return Math.round(this.fromDistributionPercentage(this.autoRange / 100));
|
|
131
|
-
|
|
180
|
+
if (this.currentMin === undefined) return parseFloat(this.histogram.min.toFixed(2));
|
|
181
|
+
return this.currentMin;
|
|
132
182
|
},
|
|
133
183
|
maxVal() {
|
|
134
184
|
if (!this.histogram) return 1;
|
|
135
185
|
if (this.autoRange !== undefined) return Math.round(this.fromDistributionPercentage((100 - this.autoRange) / 100));
|
|
136
|
-
|
|
186
|
+
if (this.currentMax === undefined) return parseFloat(this.histogram.max.toFixed(2));
|
|
187
|
+
return this.currentMax;
|
|
188
|
+
},
|
|
189
|
+
invert() {
|
|
190
|
+
return this.currentMin > this.currentMax;
|
|
191
|
+
},
|
|
192
|
+
dtypeRange() {
|
|
193
|
+
// remove byte-order characters
|
|
194
|
+
let dtype = this.dtype.replace('>', '').replace('<', '').replace('=', '').replace('|', '');
|
|
195
|
+
if (dtypeAliases[dtype]) dtype = dtypeAliases[dtype];
|
|
196
|
+
const range = dtypeRanges[dtype];
|
|
197
|
+
if (range && range.length === 2) {
|
|
198
|
+
return range;
|
|
199
|
+
} else {
|
|
200
|
+
return [this.histogram.min, this.histogram.max];
|
|
201
|
+
}
|
|
137
202
|
}
|
|
138
203
|
},
|
|
139
204
|
mounted() {
|
|
@@ -200,9 +265,13 @@ module.exports = {
|
|
|
200
265
|
}
|
|
201
266
|
const y1 = height;
|
|
202
267
|
|
|
203
|
-
|
|
268
|
+
if (this.invert) {
|
|
269
|
+
ctx.rect(x0, 0, (x1 - x0), (y0)); // inverted colors
|
|
270
|
+
} else {
|
|
271
|
+
ctx.rect(x0, y0, (x1 - x0), (y1 - y0));
|
|
272
|
+
}
|
|
204
273
|
}
|
|
205
|
-
ctx.fillStyle = '#
|
|
274
|
+
ctx.fillStyle = '#aaa';
|
|
206
275
|
ctx.fill();
|
|
207
276
|
},
|
|
208
277
|
xPositionToValue(xPosition) {
|
|
@@ -258,7 +327,7 @@ module.exports = {
|
|
|
258
327
|
if (newMaxPosition !== currentMaxPosition) {
|
|
259
328
|
this.setHandlePosition(
|
|
260
329
|
this.$refs.maxHandle,
|
|
261
|
-
newMaxPosition,
|
|
330
|
+
newMaxPosition - 5,
|
|
262
331
|
this.$refs.maxExclusionBox,
|
|
263
332
|
newMaxPosition,
|
|
264
333
|
this.xRange[1] - newMaxPosition
|
|
@@ -271,9 +340,7 @@ module.exports = {
|
|
|
271
340
|
const handleName = selected.getAttribute('name');
|
|
272
341
|
const newValue = this.xPositionToValue(newLocation.x);
|
|
273
342
|
if (handleName === 'min') {
|
|
274
|
-
if (this.autoRange
|
|
275
|
-
moveX = false;
|
|
276
|
-
} else if (this.autoRange !== undefined) {
|
|
343
|
+
if (this.autoRange !== undefined) {
|
|
277
344
|
const percentage = this.toDistributionPercentage(newValue);
|
|
278
345
|
if (
|
|
279
346
|
percentage >= 50 ||
|
|
@@ -283,9 +350,7 @@ module.exports = {
|
|
|
283
350
|
}
|
|
284
351
|
}
|
|
285
352
|
} else if (handleName === 'max') {
|
|
286
|
-
if (this.autoRange
|
|
287
|
-
moveX = false;
|
|
288
|
-
} else if (this.autoRange !== undefined) {
|
|
353
|
+
if (this.autoRange !== undefined) {
|
|
289
354
|
const percentage = this.toDistributionPercentage(newValue);
|
|
290
355
|
if (
|
|
291
356
|
percentage <= 50 ||
|
|
@@ -309,22 +374,29 @@ module.exports = {
|
|
|
309
374
|
newValue = parseFloat(parseFloat(newValue).toFixed(2));
|
|
310
375
|
this.updateAutoRange(newValue);
|
|
311
376
|
} else {
|
|
312
|
-
if (name === 'min')
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
377
|
+
if (name === 'min') this.updateMin(newValue);
|
|
378
|
+
if (name === 'max') this.updateMax(newValue);
|
|
379
|
+
|
|
380
|
+
// resize gray boxes
|
|
381
|
+
const minX = this.$refs.minHandle.getAttribute('x1');
|
|
382
|
+
const maxX = this.$refs.maxHandle.getAttribute('x1');
|
|
383
|
+
if (this.invert && minX - maxX > 0) {
|
|
384
|
+
this.$refs.minExclusionBox.setAttribute('x', `${maxX}`);
|
|
385
|
+
this.$refs.minExclusionBox.setAttribute('width', `${minX - maxX}`);
|
|
386
|
+
} else {
|
|
387
|
+
this.$refs.minExclusionBox.setAttribute('x', '0');
|
|
388
|
+
this.$refs.minExclusionBox.setAttribute('width', `${minX}`);
|
|
389
|
+
this.$refs.maxExclusionBox.setAttribute('x', `${maxX}`);
|
|
390
|
+
this.$refs.maxExclusionBox.setAttribute('width', `${this.xRange[1] - maxX}`);
|
|
319
391
|
}
|
|
320
392
|
}
|
|
321
393
|
},
|
|
322
394
|
setHandlePosition(handle, position, exclusionBox, exclusionBoxPosition, exclusionBoxWidth) {
|
|
323
|
-
handle.
|
|
324
|
-
handle.
|
|
325
|
-
exclusionBox.
|
|
395
|
+
handle.setAttribute('x1', `${position}`);
|
|
396
|
+
handle.setAttribute('x2', `${position}`);
|
|
397
|
+
exclusionBox.setAttribute('x', `${exclusionBoxPosition}`);
|
|
326
398
|
if (exclusionBoxWidth >= 0) {
|
|
327
|
-
exclusionBox.
|
|
399
|
+
exclusionBox.setAttribute('width', `${exclusionBoxWidth}`);
|
|
328
400
|
}
|
|
329
401
|
},
|
|
330
402
|
fromDistributionPercentage(percentage) {
|
|
@@ -367,8 +439,8 @@ module.exports = {
|
|
|
367
439
|
type="number"
|
|
368
440
|
class="input-80 min-input"
|
|
369
441
|
:disabled="autoRange !== undefined"
|
|
370
|
-
:min="
|
|
371
|
-
:max="
|
|
442
|
+
:min="dtypeRange[0]"
|
|
443
|
+
:max="dtypeRange[1]"
|
|
372
444
|
:value="minVal"
|
|
373
445
|
@input="(e) => updateFromInput('min', e.target.value)"
|
|
374
446
|
>
|
|
@@ -396,6 +468,14 @@ module.exports = {
|
|
|
396
468
|
height="30"
|
|
397
469
|
opacity="0.2"
|
|
398
470
|
/>
|
|
471
|
+
<rect
|
|
472
|
+
ref="maxExclusionBox"
|
|
473
|
+
x="5"
|
|
474
|
+
y="0"
|
|
475
|
+
width="0"
|
|
476
|
+
height="30"
|
|
477
|
+
opacity="0.2"
|
|
478
|
+
/>
|
|
399
479
|
<line
|
|
400
480
|
ref="minHandle"
|
|
401
481
|
class="draggable"
|
|
@@ -417,14 +497,6 @@ module.exports = {
|
|
|
417
497
|
>
|
|
418
498
|
{{ +vRange[1].toFixed(2) || 1 }}
|
|
419
499
|
</text>
|
|
420
|
-
<rect
|
|
421
|
-
ref="maxExclusionBox"
|
|
422
|
-
x="5"
|
|
423
|
-
y="0"
|
|
424
|
-
width="0"
|
|
425
|
-
height="30"
|
|
426
|
-
opacity="0.2"
|
|
427
|
-
/>
|
|
428
500
|
<line
|
|
429
501
|
ref="maxHandle"
|
|
430
502
|
class="draggable"
|
|
@@ -444,8 +516,8 @@ module.exports = {
|
|
|
444
516
|
type="number"
|
|
445
517
|
class="input-80 max-input"
|
|
446
518
|
:disabled="autoRange !== undefined"
|
|
447
|
-
:
|
|
448
|
-
:
|
|
519
|
+
:min="dtypeRange[0]"
|
|
520
|
+
:max="dtypeRange[1]"
|
|
449
521
|
:value="maxVal"
|
|
450
522
|
@input="(e) => updateFromInput('max', e.target.value)"
|
|
451
523
|
>
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: girder-large-image
|
|
3
|
-
Version: 1.31.2.
|
|
3
|
+
Version: 1.31.2.dev64
|
|
4
4
|
Summary: A Girder plugin to work with large, multiresolution images.
|
|
5
5
|
Home-page: https://github.com/girder/large_image
|
|
6
6
|
Author: Kitware, Inc.
|
|
@@ -21,9 +21,9 @@ Description-Content-Type: text/x-rst
|
|
|
21
21
|
License-File: LICENSE
|
|
22
22
|
Requires-Dist: girder>=3.1.18
|
|
23
23
|
Requires-Dist: girder-jobs>=3.0.3
|
|
24
|
-
Requires-Dist: large_image>=1.31.2.
|
|
24
|
+
Requires-Dist: large_image>=1.31.2.dev64
|
|
25
25
|
Provides-Extra: tasks
|
|
26
|
-
Requires-Dist: large-image-tasks[girder]>=1.31.2.
|
|
26
|
+
Requires-Dist: large-image-tasks[girder]>=1.31.2.dev64; extra == "tasks"
|
|
27
27
|
Requires-Dist: girder-worker[girder]>=0.6.0; extra == "tasks"
|
|
28
28
|
|
|
29
29
|
A Girder plugin to work with large, multiresolution images.
|
|
File without changes
|
|
File without changes
|
{girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/__init__.py
RENAMED
|
File without changes
|
{girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/constants.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/girder_large_image/rest/tiles.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/test_girder/girder_utilities.py
RENAMED
|
File without changes
|
{girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/test_girder/test_large_image.py
RENAMED
|
File without changes
|
{girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/test_girder/test_tiles_rest.py
RENAMED
|
File without changes
|
{girder_large_image-1.31.2.dev47 → girder_large_image-1.31.2.dev64}/test_girder/test_web_client.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|