Click or drag to resize

DicomImage Class

DicomImage is a representation of raw or processed DicomImage data. DicomImage is meant to be used by those who need to do efficient and repeated window and leveling processing of image data.

The DicomImage object implements the IDisposable interface because it contains system resources that need to be freed. It should be noted that all DicomImage objects should be disposed before an application exits. Failure to do so may cause the application to throw an exception.

Inheritance Hierarchy

Namespace:  Atalasoft.Imaging.Codec.Dicom
Assembly:  Atalasoft.dotImage.Dicom (in Atalasoft.dotImage.Dicom.dll) Version: (.NET 4.5.2, x86)
public class DicomImage : IDisposable

The DicomImage type exposes the following members.

Public propertyDefaultLeveling
An integer representing the default leveling as specified by the Dicom file.
Public propertyDefaultWindow
An integer representing the default window center as specified by the Dicom file.
Public propertyHeight
The height of the DicomImage in pixels.
Public propertyImageCameFromSignedSamples
Indicates whether or not the image data came from signed samples.
Public propertyImageDataShiftedBy
An integer representing how the image samples were transformed if they had been signed.
Public propertyPixelFormat
The PixelFormat of the image.
Public propertyWidth
The width of the image in pixels
Public method{dtor}
Public methodAllocateAtalaImage
Allocates an AtalaImage object into which this DicomImage could be transformed.
Public methodDispose
Disposes the DicomImage object.
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Protected methodFinalize (Overrides ObjectFinalize.)
Public methodGetAtalaImage
Transforms the DicomImage into a new AtalaImage object.
Public methodGetAtalaImage(AtalaImage)
Transforms the DicomImage into the supplied AtalaImage object.
Public methodGetAtalaImage(Int32, Int32)
Allocates a new AtalaImage object and transforms the DicomImage data into it using the window and leveling values.
Public methodGetAtalaImage(AtalaImage, Int32, Int32)
Transforms the DicomImage into the given AtalaImage, applying the window and leveling.
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)

DicomImage objects reflect a few of the internal quirks of the DicomStandard. Very often DicomImages have been stored with samples that were signed rather than unsigned data. It is necessary to know this information when applying window and leveling as it affects how the data is interpreted.

DicomImage objects cannot be constructed directly. Instead, DicomImage objects are constructed through the DicomDataset object via the Get...Image() methods. It should be noted that calling a Get...Image() method will make unique copies of each image and will consume a commensurate amount of memory.

If an image was built from signed samples, the property ImageCameFromSignedSamples will be true and the property ImageDataShiftedBy will be set to the value that was added to the samples to put them into the signed range. This value should be added to the window value before window and leveling is applied.

See Also