How to use dcmpsmk
Moderator: Moderator Team
How to use dcmpsmk
Anyone can tell me how to use dcmpsmk to create ps file with
ShutterEllipse
ShutterRectangle
ShutterFreehand
Rectangle
Ellipse
Arrow
Line
Angle
Text
Polygon
I will be very appreciated, if someone can give me a sample, thanks!
ShutterEllipse
ShutterRectangle
ShutterFreehand
Rectangle
Ellipse
Arrow
Line
Angle
Text
Polygon
I will be very appreciated, if someone can give me a sample, thanks!
-
- DCMTK Developer
- Posts: 2517
- Joined: Tue, 2011-05-03, 14:38
- Location: Oldenburg, Germany
- Contact:
Thank you for your update.
Now I have write a new dcmpsmk, which can be used to create ps file.
usage:
$dcmpsmk dicomfile pstemplatefile
pstemplatefile format:
[Shutter]
shutterShape=RECTANGULAR\\CIRCULAR\\POLYGONAL
shutterLeftVerticalEdge=52
shutterRightVerticalEdge=327
shutterUpperHorizontalEdge=26
shutterLowerHorizontalEdge=307
centerOfCircularShutter=35\\71
radiusOfCircularShutter=344
verticesOfThePolygonalShutter=56\\67\\293\\64\\307\\267\\26\\293\\63\\19\\56\\67
shutterPresentationValue=0
[GraphicAnnotation]
TextObject=(BoundingBoxAnnotationUnits=PIXEL;TextValue=aaa;AnchorPointAnnotationUnits=;AnchorPointX=;AnchorPointY=;AnchorPointVisibility=;BoundingBoxTopLeftHandCornerX=133.103241;BoundingBoxTopLeftHandCornerY=191.488052;BoundingBoxBottomRightHandCornerX=145.450897;BoundingBoxBottomRightHandCornerY=182.445084;BoundingBoxTextHorizontalJustification=LEFT;)
TextObject=(BoundingBoxAnnotationUnits=PIXEL;TextValue=bbb;AnchorPointAnnotationUnits=;AnchorPointX=;AnchorPointY=;AnchorPointVisibility=;BoundingBoxTopLeftHandCornerX=268.743195;BoundingBoxTopLeftHandCornerY=225.890778;BoundingBoxBottomRightHandCornerX=259.700226;BoundingBoxBottomRightHandCornerY=211.543121;BoundingBoxTextHorizontalJustification=CENTER;)
GraphicObject=(GraphicAnnotationUnits=PIXEL;NumberofGraphicPoints=2;GraphicData=159.815704,72.989761,94.832764,194.764511,;GraphicType=POLYLINE;GraphicFilled=N;)
GraphicObject=(GraphicAnnotationUnits=PIXEL;NumberofGraphicPoints=5;GraphicData=222.614334,74.627983,275.037537,74.627983,275.037537,159.269623,222.614334,159.269623,222.614334,74.627983,;GraphicType=POLYLINE;GraphicFilled=N;)
GraphicObject=(GraphicAnnotationUnits=PIXEL;NumberofGraphicPoints=1;GraphicData=287.051208,53.331059,;GraphicType=POINT;GraphicFilled=;)
GraphicObject=(GraphicAnnotationUnits=PIXEL;NumberofGraphicPoints=2;GraphicData=164.184296,171.283279,256.471008,216.061432,;GraphicType=CIRCLE;GraphicFilled=N;)
[softcopyVOIList]
WindowCenter=200
WindowWidth=500
[PresentationLUT]
PresentationLUTShape=INVERSE
[SpatialTransformation]
ImageHorizontalFlip=Y
ImageRotation=90
[DisplayedArea]
DisplayedAreaTopLeftHandCornerX=1
DisplayedAreaTopLeftHandCornerY=1
DisplayedAreaBottomRightHandCornerX=320
DisplayedAreaBottomRightHandCornerY=320
PresentationSizeMode=MAGNIFY
PresentationPixelSpacingX=0.5
PresentationPixelSpacingY=0.5
PresentationPixelMagnificationRatio=2.000000
Now I have write a new dcmpsmk, which can be used to create ps file.
usage:
$dcmpsmk dicomfile pstemplatefile
pstemplatefile format:
[Shutter]
shutterShape=RECTANGULAR\\CIRCULAR\\POLYGONAL
shutterLeftVerticalEdge=52
shutterRightVerticalEdge=327
shutterUpperHorizontalEdge=26
shutterLowerHorizontalEdge=307
centerOfCircularShutter=35\\71
radiusOfCircularShutter=344
verticesOfThePolygonalShutter=56\\67\\293\\64\\307\\267\\26\\293\\63\\19\\56\\67
shutterPresentationValue=0
[GraphicAnnotation]
TextObject=(BoundingBoxAnnotationUnits=PIXEL;TextValue=aaa;AnchorPointAnnotationUnits=;AnchorPointX=;AnchorPointY=;AnchorPointVisibility=;BoundingBoxTopLeftHandCornerX=133.103241;BoundingBoxTopLeftHandCornerY=191.488052;BoundingBoxBottomRightHandCornerX=145.450897;BoundingBoxBottomRightHandCornerY=182.445084;BoundingBoxTextHorizontalJustification=LEFT;)
TextObject=(BoundingBoxAnnotationUnits=PIXEL;TextValue=bbb;AnchorPointAnnotationUnits=;AnchorPointX=;AnchorPointY=;AnchorPointVisibility=;BoundingBoxTopLeftHandCornerX=268.743195;BoundingBoxTopLeftHandCornerY=225.890778;BoundingBoxBottomRightHandCornerX=259.700226;BoundingBoxBottomRightHandCornerY=211.543121;BoundingBoxTextHorizontalJustification=CENTER;)
GraphicObject=(GraphicAnnotationUnits=PIXEL;NumberofGraphicPoints=2;GraphicData=159.815704,72.989761,94.832764,194.764511,;GraphicType=POLYLINE;GraphicFilled=N;)
GraphicObject=(GraphicAnnotationUnits=PIXEL;NumberofGraphicPoints=5;GraphicData=222.614334,74.627983,275.037537,74.627983,275.037537,159.269623,222.614334,159.269623,222.614334,74.627983,;GraphicType=POLYLINE;GraphicFilled=N;)
GraphicObject=(GraphicAnnotationUnits=PIXEL;NumberofGraphicPoints=1;GraphicData=287.051208,53.331059,;GraphicType=POINT;GraphicFilled=;)
GraphicObject=(GraphicAnnotationUnits=PIXEL;NumberofGraphicPoints=2;GraphicData=164.184296,171.283279,256.471008,216.061432,;GraphicType=CIRCLE;GraphicFilled=N;)
[softcopyVOIList]
WindowCenter=200
WindowWidth=500
[PresentationLUT]
PresentationLUTShape=INVERSE
[SpatialTransformation]
ImageHorizontalFlip=Y
ImageRotation=90
[DisplayedArea]
DisplayedAreaTopLeftHandCornerX=1
DisplayedAreaTopLeftHandCornerY=1
DisplayedAreaBottomRightHandCornerX=320
DisplayedAreaBottomRightHandCornerY=320
PresentationSizeMode=MAGNIFY
PresentationPixelSpacingX=0.5
PresentationPixelSpacingY=0.5
PresentationPixelMagnificationRatio=2.000000
-
- DCMTK Developer
- Posts: 2517
- Joined: Tue, 2011-05-03, 14:38
- Location: Oldenburg, Germany
- Contact:
I guess you mean an anchor point that is associated with a textual annotation, right?how to save a arrow in PS file
Regarding your "new dcmpsmk": Since your template file looks pretty much like a 1:1 mapping of the DICOM Presentation State object, why don't you use XML and an appropriate stylesheet (XSLT) in order to create the input for xml2dcm?
thank you for replay.
Graphic Type:
The shape of graphic that is to be drawn.
See C.10.5.1.2.
Enumerated Values:
POINT
POLYLINE
INTERPOLATED
CIRCLE
ELLIPSE
in despite of there is no ARROW, I still want to save the arrow drawn on image in PS file, what should I do?
good idea, maybe later I will change it to XML.
Graphic Type:
The shape of graphic that is to be drawn.
See C.10.5.1.2.
Enumerated Values:
POINT
POLYLINE
INTERPOLATED
CIRCLE
ELLIPSE
in despite of there is no ARROW, I still want to save the arrow drawn on image in PS file, what should I do?
good idea, maybe later I will change it to XML.
-
- DCMTK Developer
- Posts: 2517
- Joined: Tue, 2011-05-03, 14:38
- Location: Oldenburg, Germany
- Contact:
Who is online
Users browsing this forum: Bing [Bot] and 1 guest