The result of these questions is twofold
- I have modified some of the code to overcome difficiencies that were highlighted. These modifications will be available in the next release of oro.dicom (0.4.2).
- I would like to raise the profile of a useful option in readDICOMFile(), the debug = TRUE input parameter.
The first attempt at reading this file on line #2 fails. The error message is very informative, bytes 129-132 do not contain the characters DICM which is part of the DICOM Standard. So... it's safe to assume that this file is not a valid DICOM file. Delving further we turn on the debugging option (line #4) and are able to see what the first 128 bytes, which are skipped by default as part of the DICOM Standard, look like. They obviously contain information. By setting skipFirst128=FALSE and DICM=FALSE (line #13) we can override the default settings are start reading information from the first set of bytes. This does the trick and with the debugging option turned on every field from the header is displayed. No errors have occurred, so we can display the image data from this file (line #40) below.