MPR调窗同步
continuous-integration/drone/push Build is passing Details

main
wangxiaoshuang 2025-12-04 14:43:35 +08:00
parent dbc84b2f58
commit 1b25f6538e
3 changed files with 31 additions and 3 deletions

View File

@ -1 +0,0 @@
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1764646377457" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="7057" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M192 170.666667a21.333333 21.333333 0 0 0-21.333333 21.333333v640a21.333333 21.333333 0 0 0 21.333333 21.333333h640a21.333333 21.333333 0 0 0 21.333333-21.333333v-640a21.333333 21.333333 0 0 0-21.333333-21.333333h-640zM85.333333 192A106.666667 106.666667 0 0 1 192 85.333333h640A106.666667 106.666667 0 0 1 938.666667 192v640a106.666667 106.666667 0 0 1-106.666667 106.666667h-640A106.666667 106.666667 0 0 1 85.333333 832v-640z" fill="#e6e6e6" p-id="7058"></path><path d="M173.653333 170.666667c-1.621333 5.034667-2.986667 12.373333-2.986666 21.333333v640c0 8.96 1.365333 16.298667 2.986666 21.333333h292.693334c1.621333-5.034667 2.986667-12.373333 2.986666-21.333333v-640c0-8.96-1.365333-16.298667-2.986666-21.333333H173.653333zM99.157333 127.658667C107.306667 111.530667 126.293333 85.333333 160 85.333333h320c33.706667 0 52.736 26.197333 60.8 42.325334 9.301333 18.688 13.866667 41.472 13.866667 64.341333v640c0 22.869333-4.565333 45.653333-13.866667 64.341333-8.106667 16.128-27.093333 42.325333-60.8 42.325334h-320c-33.706667 0-52.736-26.197333-60.8-42.325334C89.856 877.653333 85.333333 854.869333 85.333333 832v-640c0-22.869333 4.522667-45.653333 13.866667-64.341333z" fill="#e6e6e6" p-id="7059"></path><path d="M170.666667 170.666667v298.666666h298.666666V170.666667H170.666667z m-85.333334-10.666667C85.333333 118.784 118.784 85.333333 160 85.333333h320c41.216 0 74.666667 33.450667 74.666667 74.666667v320A74.666667 74.666667 0 0 1 480 554.666667h-320A74.666667 74.666667 0 0 1 85.333333 480v-320z" fill="#e6e6e6" p-id="7060"></path></svg>

Before

Width:  |  Height:  |  Size: 1.8 KiB

View File

@ -0,0 +1 @@
<svg t="1764646377457" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="7057" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200" transform="rotate(180)"><path d="M192 170.666667a21.333333 21.333333 0 0 0-21.333333 21.333333v640a21.333333 21.333333 0 0 0 21.333333 21.333333h640a21.333333 21.333333 0 0 0 21.333333-21.333333v-640a21.333333 21.333333 0 0 0-21.333333-21.333333h-640zM85.333333 192A106.666667 106.666667 0 0 1 192 85.333333h640A106.666667 106.666667 0 0 1 938.666667 192v640a106.666667 106.666667 0 0 1-106.666667 106.666667h-640A106.666667 106.666667 0 0 1 85.333333 832v-640z" fill="#e6e6e6" p-id="7058"></path><path d="M173.653333 170.666667c-1.621333 5.034667-2.986667 12.373333-2.986666 21.333333v640c0 8.96 1.365333 16.298667 2.986666 21.333333h292.693334c1.621333-5.034667 2.986667-12.373333 2.986666-21.333333v-640c0-8.96-1.365333-16.298667-2.986666-21.333333H173.653333zM99.157333 127.658667C107.306667 111.530667 126.293333 85.333333 160 85.333333h320c33.706667 0 52.736 26.197333 60.8 42.325334 9.301333 18.688 13.866667 41.472 13.866667 64.341333v640c0 22.869333-4.565333 45.653333-13.866667 64.341333-8.106667 16.128-27.093333 42.325333-60.8 42.325334h-320c-33.706667 0-52.736-26.197333-60.8-42.325334C89.856 877.653333 85.333333 854.869333 85.333333 832v-640c0-22.869333 4.522667-45.653333 13.866667-64.341333z" fill="#e6e6e6" p-id="7059"></path><path d="M170.666667 170.666667v298.666666h298.666666V170.666667H170.666667z m-85.333334-10.666667C85.333333 118.784 118.784 85.333333 160 85.333333h320c41.216 0 74.666667 33.450667 74.666667 74.666667v320A74.666667 74.666667 0 0 1 480 554.666667h-320A74.666667 74.666667 0 0 1 85.333333 480v-320z" fill="#e6e6e6" p-id="7060"></path></svg>

After

Width:  |  Height:  |  Size: 1.7 KiB

View File

@ -163,7 +163,7 @@
<!-- MPR -->
<div class="tool-item" :title="`${$t('trials:reading:button:mpr')}`" @click.prevent="openMPRViewport()"
v-if="criterionType === 0 && readingTool === 0">
<svg-icon icon-class="mpr" class="svg-icon" />
<svg-icon icon-class="mprLeft" class="svg-icon" />
</div>
<!--融合-->
<div v-if="readingTool === 2" class="tool-item" :title="$t('trials:lugano:button:fusion')"
@ -1043,6 +1043,7 @@ export default {
}
let viewportIds = ['viewport-0', 'viewport-1', 'viewport-2', 'viewport-3']
const fusionViewportIds = ['viewport-fusion-0', 'viewport-fusion-1', 'viewport-fusion-2', 'viewport-fusion-3']
const volumeViewportIds = ['viewport-volume-0', 'viewport-volume-1', 'viewport-volume-2']
const element1 = this.$refs['viewport-0'][0].$el
const element2 = this.$refs['viewport-1'][0].$el
const element3 = this.$refs['viewport-2'][0].$el
@ -1070,7 +1071,6 @@ export default {
}
]
if (this.criterionType === 0 && this.readingTool === 0) {
let volumeViewportIds = ['viewport-volume-0', 'viewport-volume-1', 'viewport-volume-2']
const volumeElement1 = this.$refs['viewport-volume-0'][0].$el
const volumeElement2 = this.$refs['viewport-volume-1'][0].$el
const volumeElement3 = this.$refs['viewport-volume-2'][0].$el
@ -1180,6 +1180,13 @@ export default {
toolGroup.addTool(PanTool.toolName)
toolGroup.addTool(ZoomTool.toolName)
if (volumeViewportIds.includes(viewportId)) {
toolGroup.addTool(WindowLevelTool.toolName, {
targetViewportIds: volumeViewportIds
})
} else {
toolGroup.addTool(WindowLevelTool.toolName)
}
toolGroup.addTool(WindowLevelTool.toolName)
toolGroup.addTool(WindowLevelRegionTool.toolName)
toolGroup.addTool(PlanarRotateTool.toolName)
@ -1293,6 +1300,9 @@ export default {
if (this.readingTool === 2) {
this.setUpSynchronizers()
}
if (this.criterionType === 0 && this.readingTool === 0) {
this.setUpSynchronizersMPR()
}
},
//
imageLoadProgress(e) {
@ -3141,6 +3151,24 @@ export default {
})
})
},
// mpr
setUpSynchronizersMPR() {
const MPRVoiSynchronizer = createVOISynchronizer('MPR_VOI_SYNCHRONIZER_ID', {
syncInvertState: false,
syncColormap: false
})
let viewportIds = [
`viewport-volume-0`,
`viewport-volume-1`,
`viewport-volume-2`
]
viewportIds.forEach((viewportId) => {
MPRVoiSynchronizer.add({
renderingEngineId: this.renderingEngineId,
viewportId
})
});
},
setColorMap(rgbPresetName) {
const fusionViewportIds = [`viewport-fusion-1`, `viewport-fusion-2`, `viewport-fusion-3`]
fusionViewportIds.forEach(id => {