ImageEn, unit iexBitmaps

TIEDicomTags


Description

Class to access and manage the metadata within a Dicom file. You can view a list of tags at: Dicom Tag List
You can get a description of tags using IEGetDicomTagDescription. You can output all fields using WriteTo.


Demo

Demo  Demos\InputOutput\Dicom\Dicom.dpr


Examples

ImageType := ImageEnView1.IO.Params.DICOM_Tags.GetTagString( $0008, $0008 );
PatientName := ImageEnView1.IO.Params.DICOM_Tags.GetTagString( 0010, $0010 );

// Alternatively
ImageType := ImageEnView1.IO.Params.DICOM_Tags.GetTagString( ImageEnView1.IO.Params.DICOM_Tags.IndexOf( $0008, $0008 ));
PatientName := ImageEnView1.IO.Params.DICOM_Tags.GetTagString( ImageEnView1.IO.Params.DICOM_Tags.IndexOf( $0010, $0010 ));

// Add a "Patient Name" tag to the current Dicom file (or replace tag if it already exists)
ImageEnView1.IO.Params.DICOM_Tags.SetTagString( $0010, $0010, 'Joe Bloggs' );

// Add a Unicode tag
ImageEnView1.IO.Params.DICOM_Tags.CharacterSet := 'ISO_IR 192';
ImageEnView1.IO.Params.DICOM_Tags.SetTagString( $0010, $0010, ...Unicode String... );

// Update the value of a nested tag
ImageEnView1.IO.LoadFromFile('D:\tags1.dcm');
Tags := imageenview1.IO.Params.DICOM_Tags.FindNestedTag($0040, $1001, Index);
if Index > -1 then
  Tags.SetTagString( Tags.GetTag( Index ).Group, Tags.GetTag( Index ).Element, 'NEW VALUE' );

// Add a "Priority" tag to the current Dicom file (or replace tag if it already exists)
ImageEnView1.IO.Params.DICOM_Tags.DICOM_Tags.SetTagNumeric( $0000, $0700, 7 );

// Remove patient name
ImageEnView1.IO.Params.DICOM_Tags.DeleteTag( tags.IndexOf($0010, $0010) );

Methods and Properties


Properties
Public Property  CharacterSet
Public Property  Count
Public Property  Sorted

Methods
Public Method  AddTag
Public Method  Clear
Public Method  DeleteGroup
Public Method  DeleteTag
Public Method  FindNestedTag
Public Method  GetTag
Public Method  GetTagChildren
Public Method  GetTagNumeric
Public Method  GetTagString
Public Method  IndexOf
Public Method  SetTagByteBuffer
Public Method  SetTagNumeric
Public Method  SetTagString