Re-printing stored print objects
Moderator: Moderator Team
-
- Posts: 347
- Joined: Mon, 2009-02-23, 19:57
Re-printing stored print objects
Hi, I'm using dcmprint (tcpsrv) to generate postscript files from Dicom Print modalities.
As I have to fine tune the parameters for each modality/page size I would like to generate a stored print object (this is already working in tcpsrv) and then re-send them to tcpsrv, but when I send using dcmprscu I get some errors, but I can open those stored print files from DicomScope.
Is there a way to send stored print objects to tcpsrv?.
As I have to fine tune the parameters for each modality/page size I would like to generate a stored print object (this is already working in tcpsrv) and then re-send them to tcpsrv, but when I send using dcmprscu I get some errors, but I can open those stored print files from DicomScope.
Is there a way to send stored print objects to tcpsrv?.
-
- DCMTK Developer
- Posts: 2542
- Joined: Tue, 2011-05-03, 14:38
- Location: Oldenburg, Germany
- Contact:
Re: Re-printing stored print objects
Did you already check dcmprscu from the DCMTK?
-
- Posts: 347
- Joined: Mon, 2009-02-23, 19:57
Re: Re-printing stored print objects
Yes, that's what I use to send stored print objects to tcpsrv. Are you sure it works?.J. Riesmeier wrote:Did you already check dcmprscu from the DCMTK?
-
- DCMTK Developer
- Posts: 2542
- Joined: Tue, 2011-05-03, 14:38
- Location: Oldenburg, Germany
- Contact:
Re: Re-printing stored print objects
Ah, sorry, seems that I read over the name of the tool *shameonme*
What errors do you get? Would be helpful to see the debug output of the tool.
What errors do you get? Would be helpful to see the debug output of the tool.
-
- Posts: 347
- Joined: Mon, 2009-02-23, 19:57
Re: Re-printing stored print objects
Here's the output of the command dcmprscu +d -c ./printers.cfg -p DCMPRINT ./sp_00001.dcm
Code: Select all
WW: : PatientName missing or incorrect in Stored PrintPatientName missing or incorrect in Stored Print
D: ===================== OUTGOING DIMSE MESSAGE ====================
D: Message Type : N-GET RQ
D: Message ID : 1
D: Requested SOP Class UID : PrinterSOPClass
D: Requested SOP Instance UID : 1.2.840.10008.5.1.1.17
D: Data Set : none
D: Attribute Identifier List : none
D: ======================= END DIMSE MESSAGE =======================
D: ===================== OUTGOING DIMSE MESSAGE ====================
D: Message Type : N-GET RQ
D: Message ID : 1
D: Requested SOP Class UID : PrinterSOPClass
D: Requested SOP Instance UID : 1.2.840.10008.5.1.1.17
D: Data Set : none
D: Attribute Identifier List : none
D: ======================= END DIMSE MESSAGE =======================
D: ===================== INCOMING DIMSE MESSAGE ====================
D: Message Type : N-EVENT-REPORT RQ
D: Message ID : 2
D: Affected SOP Class UID : PrinterSOPClass
D: Affected SOP Instance UID : 1.2.840.10008.5.1.1.17
D: Data Set : none
D: Event Type ID : 1
D: ======================= END DIMSE MESSAGE =======================
D: ===================== OUTGOING DIMSE MESSAGE ====================
D: Message Type : N-EVENT-REPORT RSP
D: Message ID Being Responded To : 2
D: Affected SOP Class UID : none
D: Affected SOP Instance UID : none
D: Data Set : none
D: Event Type ID : 1
D: DIMSE Status : 0x0000: Success
D: ======================= END DIMSE MESSAGE =======================
D: ===================== INCOMING DIMSE MESSAGE ====================
D: Message Type : N-EVENT-REPORT RQ
D: Message ID : 2
D: Affected SOP Class UID : PrinterSOPClass
D: Affected SOP Instance UID : 1.2.840.10008.5.1.1.17
D: Data Set : none
D: Event Type ID : 1
D: ======================= END DIMSE MESSAGE =======================
D: ===================== OUTGOING DIMSE MESSAGE ====================
D: Message Type : N-EVENT-REPORT RSP
D: Message ID Being Responded To : 2
D: Affected SOP Class UID : none
D: Affected SOP Instance UID : none
D: Data Set : none
D: Event Type ID : 1
D: DIMSE Status : 0x0000: Success
D: ======================= END DIMSE MESSAGE =======================
D: ===================== INCOMING DIMSE MESSAGE ====================
D: Message Type : N-GET RSP
D: Message ID Being Responded To : 1
D: Affected SOP Class UID : PrinterSOPClass
D: Affected SOP Instance UID : 1.2.840.10008.5.1.1.17
D: Data Set : present
D: DIMSE Status : 0x0000: Success
D: -----------------------------------------------------------------
D: # Dicom-Data-Set
D: # Used TransferSyntax: Little Endian Implicit
D: (0008,0070) LO [OFFIS] # 6, 1 Manufacturer
D: (0008,1090) LO [DCMPRINT] # 8, 1 ManufacturerModelName
D: (0018,1000) LO [0000001] # 8, 1 DeviceSerialNumber
D: (0018,1020) LO [3.5.3] # 6, 1 SoftwareVersions
D: (0018,1200) DA [20040615] # 8, 1 DateOfLastCalibration
D: (0018,1201) TM [1200] # 4, 1 TimeOfLastCalibration
D: (2110,0010) CS [NORMAL] # 6, 1 PrinterStatus
D: (2110,0020) CS [NORMAL] # 6, 1 PrinterStatusInfo
D: (2110,0030) LO [Default Printer] # 16, 1 PrinterName
D: ======================= END DIMSE MESSAGE =======================
W: spooler: printer does not support Presentation LUT SOP Class, presentation LUT related print job settings will be ignored.
D: ===================== OUTGOING DIMSE MESSAGE ====================
D: Message Type : N-CREATE RQ
D: Message ID : 2
D: Affected SOP Class UID : BasicFilmSessionSOPClass
D: Affected SOP Instance UID : none
D: Data Set : none
D: -----------------------------------------------------------------
D: # Dicom-Data-Set
D: # Used TransferSyntax: Little Endian Explicit
D: ======================= END DIMSE MESSAGE =======================
D: ===================== INCOMING DIMSE MESSAGE ====================
D: Message Type : N-GET RSP
D: Message ID Being Responded To : 1
D: Affected SOP Class UID : PrinterSOPClass
D: Affected SOP Instance UID : 1.2.840.10008.5.1.1.17
D: Data Set : present
D: DIMSE Status : 0x0000: Success
D: -----------------------------------------------------------------
D: # Dicom-Data-Set
D: # Used TransferSyntax: Little Endian Implicit
D: (0008,0070) LO [OFFIS] # 6, 1 Manufacturer
D: (0008,1090) LO [DCMPRINT] # 8, 1 ManufacturerModelName
D: (0018,1000) LO [0000001] # 8, 1 DeviceSerialNumber
D: (0018,1020) LO [3.5.3] # 6, 1 SoftwareVersions
D: (0018,1200) DA [20040615] # 8, 1 DateOfLastCalibration
D: (0018,1201) TM [1200] # 4, 1 TimeOfLastCalibration
D: (2110,0010) CS [NORMAL] # 6, 1 PrinterStatus
D: (2110,0020) CS [NORMAL] # 6, 1 PrinterStatusInfo
D: (2110,0030) LO [Default Printer] # 16, 1 PrinterName
D: ======================= END DIMSE MESSAGE =======================
W: spooler: printer does not support Presentation LUT SOP Class, presentation LUT related print job settings will be ignored.
D: ===================== OUTGOING DIMSE MESSAGE ====================
D: Message Type : N-CREATE RQ
D: Message ID : 2
D: Affected SOP Class UID : BasicFilmSessionSOPClass
D: Affected SOP Instance UID : none
D: Data Set : none
D: -----------------------------------------------------------------
D: # Dicom-Data-Set
D: # Used TransferSyntax: Little Endian Explicit
D: ======================= END DIMSE MESSAGE =======================
D: ===================== INCOMING DIMSE MESSAGE ====================
D: Message Type : N-CREATE RSP
D: Message ID Being Responded To : 2
D: Affected SOP Class UID : BasicFilmSessionSOPClass
D: Affected SOP Instance UID : 1.2.276.0.7230010.3.1.4.8323329.14870.1534252547.700135
D: Data Set : present
D: DIMSE Status : 0x0000: Success
D: -----------------------------------------------------------------
D: # Dicom-Data-Set
D: # Used TransferSyntax: Little Endian Implicit
D: (2000,0010) IS [1] # 2, 1 NumberOfCopies
D: (2000,0020) CS [MED] # 4, 1 PrintPriority
D: (2000,0030) CS [PAPER] # 6, 1 MediumType
D: (2000,0040) CS [MAGAZINE] # 8, 1 FilmDestination
D: (2000,0050) LO [Remote DICOM Printserver Session #1] # 36, 1 FilmSessionLabel
D: (2100,0160) SH (no value available) # 0, 0 OwnerID
D: ======================= END DIMSE MESSAGE =======================
D: ===================== OUTGOING DIMSE MESSAGE ====================
D: Message Type : N-CREATE RQ
D: Message ID : 3
D: Affected SOP Class UID : BasicFilmBoxSOPClass
D: Affected SOP Instance UID : none
D: Data Set : present
D: -----------------------------------------------------------------
D: # Dicom-Data-Set
D: # Used TransferSyntax: Little Endian Explicit
D: (2010,0010) ST [STANDARD\1,1] # 12, 1 ImageDisplayFormat
D: (2010,0040) CS [PORTRAIT] # 8, 1 FilmOrientation
D: (2010,0050) CS [14INX17IN] # 10, 1 FilmSizeID
D: (2010,0060) CS [BILINEAR] # 8, 1 MagnificationType
D: (2010,0080) CS [MEDIUM] # 6, 1 SmoothingType
D: (2010,0100) CS [BLACK] # 6, 1 BorderDensity
D: (2010,0110) CS [BLACK] # 6, 1 EmptyImageDensity
D: (2010,0120) US 20 # 2, 1 MinDensity
D: (2010,0130) US 255 # 2, 1 MaxDensity
D: (2010,0140) CS [NO] # 2, 1 Trim
D: (2010,0500) SQ (Sequence with explicit length #=1) # 0, 1 ReferencedFilmSessionSequence
D: (fffe,e000) na (Item with explicit length #=2) # 0, 1 Item
D: (0008,1150) UI =BasicFilmSessionSOPClass # 22, 1 ReferencedSOPClassUID
D: (0008,1155) UI [1.2.276.0.7230010.3.1.4.8323329.14870.1534252547.700135] # 56, 1 ReferencedSOPInstanceUID
D: (fffe,e00d) na (ItemDelimitationItem for re-encoding) # 0, 0 ItemDelimitationItem
D: (fffe,e0dd) na (SequenceDelimitationItem for re-encod.) # 0, 0 SequenceDelimitationItem
D: ======================= END DIMSE MESSAGE =======================
D: ===================== INCOMING DIMSE MESSAGE ====================
D: Message Type : N-CREATE RSP
D: Message ID Being Responded To : 2
D: Affected SOP Class UID : BasicFilmSessionSOPClass
D: Affected SOP Instance UID : 1.2.276.0.7230010.3.1.4.8323329.14870.1534252547.700135
D: Data Set : present
D: DIMSE Status : 0x0000: Success
D: -----------------------------------------------------------------
D: # Dicom-Data-Set
D: # Used TransferSyntax: Little Endian Implicit
D: (2000,0010) IS [1] # 2, 1 NumberOfCopies
D: (2000,0020) CS [MED] # 4, 1 PrintPriority
D: (2000,0030) CS [PAPER] # 6, 1 MediumType
D: (2000,0040) CS [MAGAZINE] # 8, 1 FilmDestination
D: (2000,0050) LO [Remote DICOM Printserver Session #1] # 36, 1 FilmSessionLabel
D: (2100,0160) SH (no value available) # 0, 0 OwnerID
D: ======================= END DIMSE MESSAGE =======================
D: ===================== OUTGOING DIMSE MESSAGE ====================
D: Message Type : N-CREATE RQ
D: Message ID : 3
D: Affected SOP Class UID : BasicFilmBoxSOPClass
D: Affected SOP Instance UID : none
D: Data Set : present
D: -----------------------------------------------------------------
D: # Dicom-Data-Set
D: # Used TransferSyntax: Little Endian Explicit
D: (2010,0010) ST [STANDARD\1,1] # 12, 1 ImageDisplayFormat
D: (2010,0040) CS [PORTRAIT] # 8, 1 FilmOrientation
D: (2010,0050) CS [14INX17IN] # 10, 1 FilmSizeID
D: (2010,0060) CS [BILINEAR] # 8, 1 MagnificationType
D: (2010,0080) CS [MEDIUM] # 6, 1 SmoothingType
D: (2010,0100) CS [BLACK] # 6, 1 BorderDensity
D: (2010,0110) CS [BLACK] # 6, 1 EmptyImageDensity
D: (2010,0120) US 20 # 2, 1 MinDensity
D: (2010,0130) US 255 # 2, 1 MaxDensity
D: (2010,0140) CS [NO] # 2, 1 Trim
D: (2010,0500) SQ (Sequence with explicit length #=1) # 0, 1 ReferencedFilmSessionSequence
D: (fffe,e000) na (Item with explicit length #=2) # 0, 1 Item
D: (0008,1150) UI =BasicFilmSessionSOPClass # 22, 1 ReferencedSOPClassUID
D: (0008,1155) UI [1.2.276.0.7230010.3.1.4.8323329.14870.1534252547.700135] # 56, 1 ReferencedSOPInstanceUID
D: (fffe,e00d) na (ItemDelimitationItem for re-encoding) # 0, 0 ItemDelimitationItem
D: (fffe,e0dd) na (SequenceDelimitationItem for re-encod.) # 0, 0 SequenceDelimitationItem
D: ======================= END DIMSE MESSAGE =======================
D: ===================== INCOMING DIMSE MESSAGE ====================
D: Message Type : N-CREATE RSP
D: Message ID Being Responded To : 3
D: Affected SOP Class UID : BasicFilmBoxSOPClass
D: Affected SOP Instance UID : 1.2.276.0.7230010.3.1.4.8323329.14870.1534252547.700137
D: Data Set : present
D: DIMSE Status : 0x0000: Success
D: -----------------------------------------------------------------
D: # Dicom-Data-Set
D: # Used TransferSyntax: Little Endian Implicit
D: (2010,0010) ST [STANDARD\1,1] # 12, 1 ImageDisplayFormat
D: (2010,0040) CS [PORTRAIT] # 8, 1 FilmOrientation
D: (2010,0050) CS [14INX17IN] # 10, 1 FilmSizeID
D: (2010,0060) CS [BILINEAR] # 8, 1 MagnificationType
D: (2010,0080) CS [MEDIUM] # 6, 1 SmoothingType
D: (2010,0100) CS [BLACK] # 6, 1 BorderDensity
D: (2010,0110) CS [BLACK] # 6, 1 EmptyImageDensity
D: (2010,0120) US 20 # 2, 1 MinDensity
D: (2010,0130) US 255 # 2, 1 MaxDensity
D: (2010,0140) CS [NO] # 2, 1 Trim
D: (2010,0150) ST (no value available) # 0, 0 ConfigurationInformation
D: (2010,0500) SQ (Sequence with explicit length #=1) # 102, 1 ReferencedFilmSessionSequence
D: (fffe,e000) na (Item with explicit length #=2) # 94, 1 Item
D: (0008,1150) UI =BasicFilmSessionSOPClass # 22, 1 ReferencedSOPClassUID
D: (0008,1155) UI [1.2.276.0.7230010.3.1.4.8323329.14870.1534252547.700135] # 56, 1 ReferencedSOPInstanceUID
D: (fffe,e00d) na (ItemDelimitationItem for re-encoding) # 0, 0 ItemDelimitationItem
D: (fffe,e0dd) na (SequenceDelimitationItem for re-encod.) # 0, 0 SequenceDelimitationItem
D: (2010,0510) SQ (Sequence with explicit length #=1) # 102, 1 ReferencedImageBoxSequence
D: (fffe,e000) na (Item with explicit length #=2) # 94, 1 Item
D: (0008,1150) UI =BasicGrayscaleImageBoxSOPClass # 22, 1 ReferencedSOPClassUID
D: (0008,1155) UI [1.2.276.0.7230010.3.1.4.8323329.14870.1534252547.700139] # 56, 1 ReferencedSOPInstanceUID
D: (fffe,e00d) na (ItemDelimitationItem for re-encoding) # 0, 0 ItemDelimitationItem
D: (fffe,e0dd) na (SequenceDelimitationItem for re-encod.) # 0, 0 SequenceDelimitationItem
D: ======================= END DIMSE MESSAGE =======================
E: spooler: unable to locate image file in database
D: ===================== INCOMING DIMSE MESSAGE ====================
D: Message Type : N-CREATE RSP
D: Message ID Being Responded To : 3
D: Affected SOP Class UID : BasicFilmBoxSOPClass
D: Affected SOP Instance UID : 1.2.276.0.7230010.3.1.4.8323329.14870.1534252547.700137
D: Data Set : present
D: DIMSE Status : 0x0000: Success
D: -----------------------------------------------------------------
D: # Dicom-Data-Set
D: # Used TransferSyntax: Little Endian Implicit
D: (2010,0010) ST [STANDARD\1,1] # 12, 1 ImageDisplayFormat
D: (2010,0040) CS [PORTRAIT] # 8, 1 FilmOrientation
D: (2010,0050) CS [14INX17IN] # 10, 1 FilmSizeID
D: (2010,0060) CS [BILINEAR] # 8, 1 MagnificationType
D: (2010,0080) CS [MEDIUM] # 6, 1 SmoothingType
D: (2010,0100) CS [BLACK] # 6, 1 BorderDensity
D: (2010,0110) CS [BLACK] # 6, 1 EmptyImageDensity
D: (2010,0120) US 20 # 2, 1 MinDensity
D: (2010,0130) US 255 # 2, 1 MaxDensity
D: (2010,0140) CS [NO] # 2, 1 Trim
D: (2010,0150) ST (no value available) # 0, 0 ConfigurationInformation
D: (2010,0500) SQ (Sequence with explicit length #=1) # 102, 1 ReferencedFilmSessionSequence
D: (fffe,e000) na (Item with explicit length #=2) # 94, 1 Item
D: (0008,1150) UI =BasicFilmSessionSOPClass # 22, 1 ReferencedSOPClassUID
D: (0008,1155) UI [1.2.276.0.7230010.3.1.4.8323329.14870.1534252547.700135] # 56, 1 ReferencedSOPInstanceUID
D: (fffe,e00d) na (ItemDelimitationItem for re-encoding) # 0, 0 ItemDelimitationItem
D: (fffe,e0dd) na (SequenceDelimitationItem for re-encod.) # 0, 0 SequenceDelimitationItem
D: (2010,0510) SQ (Sequence with explicit length #=1) # 102, 1 ReferencedImageBoxSequence
D: (fffe,e000) na (Item with explicit length #=2) # 94, 1 Item
D: (0008,1150) UI =BasicGrayscaleImageBoxSOPClass # 22, 1 ReferencedSOPClassUID
D: (0008,1155) UI [1.2.276.0.7230010.3.1.4.8323329.14870.1534252547.700139] # 56, 1 ReferencedSOPInstanceUID
D: (fffe,e00d) na (ItemDelimitationItem for re-encoding) # 0, 0 ItemDelimitationItem
D: (fffe,e0dd) na (SequenceDelimitationItem for re-encod.) # 0, 0 SequenceDelimitationItem
D: ======================= END DIMSE MESSAGE =======================
E: spooler: unable to locate image file in database
-
- DCMTK Developer
- Posts: 2542
- Joined: Tue, 2011-05-03, 14:38
- Location: Oldenburg, Germany
- Contact:
Re: Re-printing stored print objects
I guess the error message ("spooler: unable to locate image file in database") is clear: the Hardcopy Grayscale Image that is referenced from the Stored Print object cannot be found in the "database" (i.e. in the index file "index.dat" that is used by DICOMscope's underlying networking and printing tools).
-
- Posts: 347
- Joined: Mon, 2009-02-23, 19:57
Re: Re-printing stored print objects
And how can I generate that file?.J. Riesmeier wrote:I guess the error message ("spooler: unable to locate image file in database") is clear: the Hardcopy Grayscale Image that is referenced from the Stored Print object cannot be found in the "database" (i.e. in the index file "index.dat" that is used by DICOMscope's underlying networking and printing tools).
-
- DCMTK Developer
- Posts: 2542
- Joined: Tue, 2011-05-03, 14:38
- Location: Oldenburg, Germany
- Contact:
Re: Re-printing stored print objects
The dcmprscu tool has been developed in order to be used together with dcmpsprt. Both are just supporting tools for DICOMscope.
-
- Posts: 347
- Joined: Mon, 2009-02-23, 19:57
Re: Re-printing stored print objects
So, isn't a quick (command line) way to just take the stored print files generated by tcpsrv and re-send to it?. The only method is opening the stored print files with DicomScope?.J. Riesmeier wrote:The dcmprscu tool has been developed in order to be used together with dcmpsprt. Both are just supporting tools for DICOMscope.
-
- DCMTK Developer
- Posts: 2542
- Joined: Tue, 2011-05-03, 14:38
- Location: Oldenburg, Germany
- Contact:
Re: Re-printing stored print objects
The Stored Print object does not contain the images (Pixel Data). That's why you also need the Hardcopy Grayscale Images. Create all required files with dcmpsprt and you should be fine.
-
- Posts: 347
- Joined: Mon, 2009-02-23, 19:57
Re: Re-printing stored print objects
Yes, the tcpsrv create both, the sp_xxx.dcm file and the HG_xxxx.dcm files. Then, how can I send those to the tcpsrv again?, without DicomScope.J. Riesmeier wrote:The Stored Print object does not contain the images (Pixel Data). That's why you also need the Hardcopy Grayscale Images. Create all required files with dcmpsprt and you should be fine.
-
- DCMTK Developer
- Posts: 2542
- Joined: Tue, 2011-05-03, 14:38
- Location: Oldenburg, Germany
- Contact:
Re: Re-printing stored print objects
Somebody from OFFIS should answer this since DCMPRINT is not part of the public DCMTK... maybe, it works if you register the SP and HG files to the "index.dat" with the tool "dcmqridx".
-
- Posts: 347
- Joined: Mon, 2009-02-23, 19:57
Re: Re-printing stored print objects
Great, I didn't know about that tool. I'll try it.J. Riesmeier wrote:Somebody from OFFIS should answer this since DCMPRINT is not part of the public DCMTK... maybe, it works if you register the SP and HG files to the "index.dat" with the tool "dcmqridx".
-
- OFFIS DICOM Team
- Posts: 1493
- Joined: Tue, 2004-11-02, 17:22
- Location: Oldenburg, Germany
- Contact:
Re: Re-printing stored print objects
Both the DICOM print implementation in the free toolkit, and DCMPRINT have the ability to store incoming print jobs using the DICOM Stored Print and Hardcopy Grayscale/Color Image SOP Classes.
When you are using the DCMPRINT print server (tcpsrv), you can use the --stored-print and --forward command line options to forward a stored print job to another print server.
If I remember correctly, the name of the stored print file (SP*) is the parameter to --stored-print, and the print server assumes that the images related to this stored print instance are in the same directory.
The print server and print client in the public DCMTK (dcmprscp and dcmprscu) use a slightly different storage format, which is also used by DICOMscope and the dcmqrscp archive:
All DICOM files reside in one directory, and there is a binary index file named "index.dat" in the same directory that is used to lookup files. The index file can be manually generated
with the dcmqridx tool, which is also part of the free toolkit.
I hope this provides some clarification. I would encourage you to read the manual pages of these tools as they provide more information.
When you are using the DCMPRINT print server (tcpsrv), you can use the --stored-print and --forward command line options to forward a stored print job to another print server.
If I remember correctly, the name of the stored print file (SP*) is the parameter to --stored-print, and the print server assumes that the images related to this stored print instance are in the same directory.
The print server and print client in the public DCMTK (dcmprscp and dcmprscu) use a slightly different storage format, which is also used by DICOMscope and the dcmqrscp archive:
All DICOM files reside in one directory, and there is a binary index file named "index.dat" in the same directory that is used to lookup files. The index file can be manually generated
with the dcmqridx tool, which is also part of the free toolkit.
I hope this provides some clarification. I would encourage you to read the manual pages of these tools as they provide more information.
Who is online
Users browsing this forum: No registered users and 1 guest