Auto generate C++ structure from Dicom Standard

Questions regarding the DCMRT library, a DCMTK add-on that implements support for the various DICOM Radiation Therapy (RT) IODs

Moderator: Moderator Team

Post Reply
Message
Author
gaving
Posts: 3
Joined: Mon, 2025-02-10, 17:07

Auto generate C++ structure from Dicom Standard

#1 Post by gaving »

Hello team,

I noticed that bulks of .h/.cc files are generated from dicom standard.

Here is one example from drtrsis.cc

Code: Select all

/*
 *
 *  Copyright (C) 2008-2012, OFFIS e.V. and ICSMED AG, Oldenburg, Germany
 *  Copyright (C) 2013-2023, J. Riesmeier, Oldenburg, Germany
 *  All rights reserved.  See COPYRIGHT file for details.
 *
 *  Header file for class DRTReferencedSetupImageSequence
 *
 *  Generated automatically from DICOM PS 3.3-2023b
 *  File created on 2023-05-19 16:00:57
 *
 */
I want to add some IODs which isn't supported by version 3.6.9.
If anyone can share the tool which can generate IODs from DICOM stand files(.xml/.html), it will be very very helpful.

Thanks for any response.

J. Riesmeier
DCMTK Developer
Posts: 2572
Joined: Tue, 2011-05-03, 14:38
Location: Oldenburg, Germany
Contact:

Re: Auto generate C++ structure from Dicom Standard

#2 Post by J. Riesmeier »

Most of the source code of the dcmrt module is generated automatically from the DocBook/XML version of the DICOM standard by a set of XSL-T scripts. However, these scripts are not publicly available.

Code: Select all

I want to add some IODs which isn't supported by version 3.6.9.
You mean RT-specific IODs? Which ones?

gaving
Posts: 3
Joined: Mon, 2025-02-10, 17:07

Re: Auto generate C++ structure from Dicom Standard

#3 Post by gaving »

Dear Jörg, thanks for your information.
Yes, you are right, I need RT-specific IODs, all second generation IODs except Tomotherapeutic Radiation IOD and Tomotherapeutic Radiation Record IOD.
Could you please generate these files if you can?
Thank you in advance.

J. Riesmeier
DCMTK Developer
Posts: 2572
Joined: Tue, 2011-05-03, 14:38
Location: Oldenburg, Germany
Contact:

Re: Auto generate C++ structure from Dicom Standard

#4 Post by J. Riesmeier »

Unfortunately, it is not that easy as pressing a button and everything works "automagically", at least not when it comes to supporting new IODs. This is partly because of the filename mapping (we used to prefer short filenames according to the "8.3" pattern) and partly because of the way the RT IODs are defined. The first issue should be solved "sometime" (i.e. as time permits) as DCMTK is no longer restricted to only use 8.3 characters, but this change would also require some work. The second issue is a bit harder as RT IODs tend to use the same Sequence Attribute with different content, so we need to generate separate classes depending on where the Sequence Attribute is actually used (i.e. included). Also, support for Functional Groups is missing... Finally, Makefiles still need to be created/updated manually, and testing would also be required.

Bottom line: this is much work, and I don't known when I'll have time for that. Sorry. You also have to understand that the main work on "dcmrt" was funded by DKFZ (German Cancer Research Center) years ago, i.e. it was part of a research project.

gaving
Posts: 3
Joined: Mon, 2025-02-10, 17:07

Re: Auto generate C++ structure from Dicom Standard

#5 Post by gaving »

Jörg, I can totally understand what you mentioned. It's not a easy work.
Thanks again!

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest