Search code examples
dicomdcm4che

dcm4che get TAG of value multiplicity (VM) greater than 1


My question is somehow simple.

I want to get all the values from a TAG of VM>1.

For example the (0018,1310) tag, named Acquisition Matrix is of VM=4, so it stores 4 values separated by dash like:

0/320/192/0

I want to read all values stored in this TAG, but if i use:

...
acquisitionMatrix = dcmObj.getString(Tag.AcquisitionMatrix);
....

i only get the first! How can i achieve this?


Solution

  • I guess that it can be done as Tarmo suggested... However i managed to get these values as int(s) using:

    ...
    int[] matrix = null;
    matrix = dcmObj4.getInts(Tag.AcquisitionMatrix);
    for(int i=0; i<matrix.length;i++) {
        log.info(">>>>>> Acquisition matrix[" + i + "]: " + matrix[i]);
    }
    ...