I had a query while running the dicom example. I intend to change the .dcm file used in dicom modelling. I managed to get the model I wanted. I have built a brain model using a dicom image of a brain ct containing a tumour, but I would like to distinguish the tumour area from the brain tissue area in the model with different colours.
I see a file called ColourMap in dicom’s folder and I see that it defines the colours of the different organisations. My question is if I should add some instructions here to achieve my purpose.
Also I would like to set the density of the model’s midbrain tissue and tumour. For modelling I am using the file AltData.dat. Is it possible to define the density of the model by just adding the brain tissue density here.
Thank you all for your replies!
Hello @Jodie_Comer ,
In the dicom example two methods are presented,
- The AltData.dat is based on the old method and read data from the g4dcm file extension
- The data.dat.new is based on the dcmtk.
The colour map requires the definition of the material defined in the meta data file (say AltData.dat). It is a choice of the user to define RGB colour of their own choice. As said the colour mapping of tissue or tumour depends on the HU range and densities defined in the AltData.dat, therefore, one need to define the material in the meta data file and same nomenclature to use in the colourmapping dat.
Addition :- 1.0 == 255 RGB scale therefore colour choices can be done based on the proportional values.
say R = 1.0 G = 1.0 B = 1.0 , opacity = 1.0 ==> white [TrabecularBone]
defines R = 255 , G=255, B = 255. , opacity = 1.0
Thank you for your answer, it was very useful for me.
Here’s how I understand it based on your answer.
The AltData.dat file defines the HU ranges and densities, and when the dicom data is read in, the program calculates the HU value for each microelement based on the information in the dicom.
AltData.dat will define the density of the microelement based on its HU value.
Is that correct?
@jodie, if you segmented your image and assigned a specific material to each voxel (e.g. distinguishing the tumor tissue from the brain tissue), you can use the option of the DICOM_HEAD, where the calibration curve is not used (associating specific materials to HUs), but associating directly a special material to a specific voxel.
I hope this helps,
Thank you for your reply.
I now have a problem, based on the AltData.dat file in the dicom example, and I find that the density of brain tissue is not defined in the original example.
I’m going to define my own based on the data given by ICRU, and then write this data into the AltData.dat file.
Is there any other work I need to do to achieve the definition of model density?
I really appreciate your advice.
Materials nomenclature must be same in both metaData and Colourdensity.
Thank you for your answer, I will try the advice you give.
@guatelli I tried using the
DICOM_HEAD option, I entered the export
DICOM_USE_HEAD=1 directive in the terminal in the build folder while running the program. But now I have a question.
Although I chose this option isn’t it that I still need to change the
AltData.dat file and the
ColourMap file because I see that the brainTissue and trabecularBone_head defined in the program don’t appear in either of these files.
Thank you for your answer.
The answer of your question lies in the DICOMHandler.cc line 124.