体数据播放功能修改
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
parent
e53a18f212
commit
b971235164
|
|
@ -185,6 +185,7 @@ export default {
|
|||
rotateAngle: 0,
|
||||
rotateBarLeft: 0,
|
||||
loading: false,
|
||||
toggleClipPlayTimer: null
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
|
|
@ -491,11 +492,20 @@ export default {
|
|||
this.playClipState = isPlay
|
||||
const renderingEngine = getRenderingEngine(this.renderingEngineId)
|
||||
const viewport = renderingEngine.getViewport(this.viewportId)
|
||||
|
||||
if (isPlay) {
|
||||
cornerstoneTools.utilities.cine.playClip(viewport.element, { framesPerSecond, loop: true })
|
||||
this.toggleClipPlayTimer = setInterval(() => {
|
||||
let index = this.series.SliceIndex + 1;
|
||||
if (index > this.imageInfo.total - 1) index = 0
|
||||
csUtils.jumpToSlice(viewport.element, { imageIndex: index });
|
||||
|
||||
}, framesPerSecond)
|
||||
// cornerstoneTools.utilities.cine.playClip(viewport.element, { framesPerSecond, loop: true })
|
||||
} else {
|
||||
cornerstoneTools.utilities.cine.stopClip(viewport.element)
|
||||
if (this.toggleClipPlayTimer) {
|
||||
clearInterval(this.toggleClipPlayTimer)
|
||||
this.toggleClipPlayTimer = null
|
||||
}
|
||||
// cornerstoneTools.utilities.cine.stopClip(viewport.element)
|
||||
}
|
||||
},
|
||||
scrollPage(type) {
|
||||
|
|
@ -794,6 +804,12 @@ export default {
|
|||
return `NS: ${this.$store.state.trials.downloadTip}`
|
||||
}
|
||||
},
|
||||
destroyed() {
|
||||
if (this.toggleClipPlayTimer) {
|
||||
clearInterval(this.toggleClipPlayTimer)
|
||||
this.toggleClipPlayTimer = null
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
|
|
|
|||
|
|
@ -2829,7 +2829,9 @@ export default {
|
|||
const viewport = renderingEngine.getViewport(viewportId)
|
||||
this.$refs[`${this.viewportKey}-${this.activeViewportIndex}`][0].resetOrientationMarkers()
|
||||
let index = this.$refs[`${this.viewportKey}-${this.activeViewportIndex}`][0].series.SliceIndex
|
||||
if (this.readingTool !== 3) {
|
||||
viewport.resetCamera({ resetPan: true, resetZoom: true, resetToCenter: true })
|
||||
}
|
||||
viewport.resetProperties()
|
||||
if (this.isMPR) {
|
||||
let volume = cache.getVolume(this.$refs[`${this.viewportKey}-${this.activeViewportIndex}`][0].volumeId)
|
||||
|
|
|
|||
|
|
@ -203,6 +203,7 @@ export default {
|
|||
rotateAngle: 0,
|
||||
rotateBarLeft: 0,
|
||||
loading: false,
|
||||
toggleClipPlayTimer: null
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
|
|
@ -537,11 +538,20 @@ export default {
|
|||
this.playClipState = isPlay
|
||||
const renderingEngine = getRenderingEngine(this.renderingEngineId)
|
||||
const viewport = renderingEngine.getViewport(this.viewportId)
|
||||
|
||||
if (isPlay) {
|
||||
cornerstoneTools.utilities.cine.playClip(viewport.element, { framesPerSecond, loop: true })
|
||||
this.toggleClipPlayTimer = setInterval(() => {
|
||||
let index = this.series.SliceIndex + 1;
|
||||
if (index > this.imageInfo.total - 1) index = 0
|
||||
csUtils.jumpToSlice(viewport.element, { imageIndex: index });
|
||||
|
||||
}, framesPerSecond)
|
||||
// cornerstoneTools.utilities.cine.playClip(viewport.element, { framesPerSecond, loop: true })
|
||||
} else {
|
||||
cornerstoneTools.utilities.cine.stopClip(viewport.element)
|
||||
if (this.toggleClipPlayTimer) {
|
||||
clearInterval(this.toggleClipPlayTimer)
|
||||
this.toggleClipPlayTimer = null
|
||||
}
|
||||
// cornerstoneTools.utilities.cine.stopClip(viewport.element)
|
||||
}
|
||||
},
|
||||
scrollPage(type) {
|
||||
|
|
@ -639,7 +649,6 @@ export default {
|
|||
if (this.series && data.Id === this.series.Id && data.Description === this.series.Description && !isLocate && !data.isLocation) {
|
||||
data.SliceIndex = this.series.SliceIndex
|
||||
}
|
||||
console.log(data.SliceIndex, 'data.SliceIndex')
|
||||
const renderingEngine = getRenderingEngine(this.renderingEngineId)
|
||||
const viewport = renderingEngine.getViewport(this.viewportId)
|
||||
if (isLocate) return csUtils.jumpToSlice(viewport.element, { imageIndex: data.SliceIndex });
|
||||
|
|
@ -665,6 +674,7 @@ export default {
|
|||
setTimeout(() => { csUtils.jumpToSlice(viewport.element, { imageIndex: data.SliceIndex }); })
|
||||
}
|
||||
})
|
||||
res.volume.dimensionGroupNumber = 2;
|
||||
viewport.render()
|
||||
if (this.series.Modality === 'PT' || this.series.Modality === 'NM') {
|
||||
setTimeout(() => {
|
||||
|
|
@ -851,6 +861,12 @@ export default {
|
|||
return `NS: ${this.$store.state.trials.downloadTip}`
|
||||
}
|
||||
},
|
||||
destroyed() {
|
||||
if (this.toggleClipPlayTimer) {
|
||||
clearInterval(this.toggleClipPlayTimer)
|
||||
this.toggleClipPlayTimer = null
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
|
|
|
|||
Loading…
Reference in New Issue