Comments (3)
Hello! That sounds like a nice thing to support. Is that something you can help with? Can you attach a sample DICOM file to this issue?
from volview.
Hello @PaulHax, thanks for you attention.
Archive attached with GSPS sample files that provide text and graphics (ELIPSE) annotation for DICOM file and also XML dumps.
gsps-samples.zip
This is how this is rendered in Weasis:
Following is the example script that can create GSPS using DCMTK dcmpsmk and dcmodify tools. I hope this helps to better understand tags involved.
#!/bin/bash
INPUT_DICOM=mri-brain.dcm
OUTPUT_GSPS=mri-brain-gsps-text.dcm
CONTENT_LABEL="GSPS Text"
CONTENT_DESCRIPTION="GSPS Text example annotation"
CONTENT_CREATOR_NAME="NAME"
dcmpsmk "$INPUT_DICOM" "$OUTPUT_GSPS"
dcmodify --no-backup --insert "(0070,0080)=$CONTENT_LABEL" "$OUTPUT_GSPS"
dcmodify --no-backup --insert "(0070,0081)=$CONTENT_DESCRIPTION" "$OUTPUT_GSPS"
dcmodify --no-backup --insert "(0070,0084)=$CONTENT_CREATOR_NAME" "$OUTPUT_GSPS"
# Add Graphic Layer Sequence
dcmodify --no-backup --insert "(0070,0060)[0].(0070,0002)=ANNOTATION" "$OUTPUT_GSPS"
dcmodify --no-backup --insert "(0070,0060)[0].(0070,0062)=0" "$OUTPUT_GSPS"
dcmodify --no-backup --insert "(0070,0060)[0].(0070,0068)=Annotations" "$OUTPUT_GSPS"
dcmodify --no-backup --insert "(0070,0060)[0].(0070,0401)=63658\27358\57178" "$OUTPUT_GSPS"
# Add Graphic Annotation Sequence with Text
dcmodify --no-backup --insert "(0070,0001)[0].(0070,0002)=ANNOTATION" "$OUTPUT_GSPS"
# Text annotation 1
dcmodify --no-backup --insert "(0070,0001)[0].(0070,0008)[0].(0070,0003)=PIXEL" "$OUTPUT_GSPS"
dcmodify --no-backup --insert "(0070,0001)[0].(0070,0008)[0].(0070,0006)=Annotation text created with DCMTK #1" "$OUTPUT_GSPS"
dcmodify --no-backup --insert "(0070,0001)[0].(0070,0008)[0].(0070,0010)=200\200" "$OUTPUT_GSPS"
dcmodify --no-backup --insert "(0070,0001)[0].(0070,0008)[0].(0070,0011)=300\300" "$OUTPUT_GSPS"
dcmodify --no-backup --insert "(0070,0001)[0].(0070,0008)[0].(0070,0014)=100\100" "$OUTPUT_GSPS"
dcmodify --no-backup --insert "(0070,0001)[0].(0070,0008)[0].(0070,0015)=Y" "$OUTPUT_GSPS"
dcmodify --no-backup --insert "(0070,0001)[0].(0070,0008)[0].(0070,0232)[0].(0070,0251)=63658\27358\57178" "$OUTPUT_GSPS"
dcmodify --no-backup --insert "(0070,0001)[0].(0070,0008)[0].(0070,0232)[0].(0070,0253)=1" "$OUTPUT_GSPS"
# Text annotation 2
dcmodify --no-backup --insert "(0070,0001)[0].(0070,0008)[1].(0070,0003)=PIXEL" "$OUTPUT_GSPS"
dcmodify --no-backup --insert "(0070,0001)[0].(0070,0008)[1].(0070,0006)=Annotation text created with DCMTK #2" "$OUTPUT_GSPS"
dcmodify --no-backup --insert "(0070,0001)[0].(0070,0008)[1].(0070,0010)=600\200" "$OUTPUT_GSPS"
dcmodify --no-backup --insert "(0070,0001)[0].(0070,0008)[1].(0070,0011)=700\300" "$OUTPUT_GSPS"
dcmodify --no-backup --insert "(0070,0001)[0].(0070,0008)[1].(0070,0014)=800\100" "$OUTPUT_GSPS"
dcmodify --no-backup --insert "(0070,0001)[0].(0070,0008)[1].(0070,0015)=Y" "$OUTPUT_GSPS"
dcmodify --no-backup --insert "(0070,0001)[0].(0070,0008)[1].(0070,0232)[0].(0070,0251)=63658\27358\57178" "$OUTPUT_GSPS"
dcmodify --no-backup --insert "(0070,0001)[0].(0070,0008)[1].(0070,0232)[0].(0070,0253)=1" "$OUTPUT_GSPS"
if [ $? -eq 0 ]; then
echo "GSPS with text created as $OUTPUT_GSPS"
else
echo "Failed to create GSPS with text"
fi
from volview.
Thanks for all this! Looks useful.
Next up for VolView file format work is upgrading "segmentation" support. Cuz AI. We could support you if you want to impliment this or if you have some funding to direct Kitware's way.
from volview.
Related Issues (20)
- Reset Views button not working HOT 1
- Remote loading HOT 3
- Code-split state file migration code
- Load remote data across domains HOT 1
- itk reader fail to detect image type ? HOT 5
- Copy image data for thumbnailer HOT 1
- nifti segmentation is not loading in axial plane HOT 6
- Cannot install canvas on Mac HOT 3
- Move collapsible menu button to the toolbar and make it visible, not for mobile only
- Left and right arrows to change through images
- Merge polygons new feature
- .
- Question about FPP and TPP View Modes HOT 1
- Scooping Tool for Cropping Inside the Widget HOT 3
- The rendered image looks incorrect HOT 3
- code problem HOT 1
- File loading error
- Export the current image or take a screenshot HOT 1
- Toggle camera reset HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from volview.