Class DicomImage
DICOM Image class for image rendering.
Inherited Members
Namespace: Dicom.Imaging
Assembly: cs.temp.dll.dll
Syntax
public class DicomImage
Constructors
DicomImage(DicomDataset, Int32)
Creates DICOM image object from dataset
Declaration
public DicomImage(DicomDataset dataset, int frame = 0)
Parameters
Type | Name | Description |
---|---|---|
DicomDataset | dataset | Source dataset |
Int32 | frame | Zero indexed frame number. If |
DicomImage(String, Int32)
Creates DICOM image object from file
Declaration
public DicomImage(string fileName, int frame = 0)
Parameters
Type | Name | Description |
---|---|---|
String | fileName | Source file |
Int32 | frame | Zero indexed frame number |
Properties
CurrentFrame
Gets the index of the current frame.
Declaration
public int CurrentFrame { get; }
Property Value
Type | Description |
---|---|
Int32 |
Dataset
Gets the dataset constituting the DICOM image.
Declaration
[Obsolete("Dataset should not be publicly accessible from DicomImage object.")]
public DicomDataset Dataset { get; }
Property Value
Type | Description |
---|---|
DicomDataset |
GrayscaleColorMap
Gets or sets the color map to be applied when rendering grayscale images.
Declaration
public virtual Color32[] GrayscaleColorMap { get; set; }
Property Value
Type | Description |
---|---|
Color32[] |
Height
Height of image in pixels
Declaration
public int Height { get; }
Property Value
Type | Description |
---|---|
Int32 |
IsGrayscale
Gets or sets whether the image is gray scale.
Declaration
public virtual bool IsGrayscale { get; }
Property Value
Type | Description |
---|---|
Boolean |
NumberOfFrames
Number of frames contained in image data.
Declaration
public int NumberOfFrames { get; }
Property Value
Type | Description |
---|---|
Int32 |
OverlayColor
Gets or sets the color used for displaying DICOM overlays. Default is magenta.
Declaration
public int OverlayColor { get; set; }
Property Value
Type | Description |
---|---|
Int32 |
PhotometricInterpretation
Declaration
[Obsolete("Use IsGrayscale to determine whether DicomImage object is grayscale or color.")]
public PhotometricInterpretation PhotometricInterpretation { get; }
Property Value
Type | Description |
---|---|
PhotometricInterpretation |
PixelData
Gets the pixel data header object associated with the image.
Declaration
[Obsolete("PixelData should not be publicly accessible from the DicomImage object.")]
public DicomPixelData PixelData { get; }
Property Value
Type | Description |
---|---|
DicomPixelData |
Scale
Scaling factor of the rendered image
Declaration
public double Scale { get; set; }
Property Value
Type | Description |
---|---|
Double |
ShowOverlays
Show or hide DICOM overlays
Declaration
public bool ShowOverlays { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
UseVOILUT
Gets or sets whether to use VOI LUT.
Declaration
public virtual bool UseVOILUT { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
Width
Width of image in pixels
Declaration
public int Width { get; }
Property Value
Type | Description |
---|---|
Int32 |
WindowCenter
Gets or sets window center of rendered gray scale image.
Declaration
public virtual double WindowCenter { get; set; }
Property Value
Type | Description |
---|---|
Double |
WindowWidth
Gets or sets window width of rendered gray scale image.
Declaration
public virtual double WindowWidth { get; set; }
Property Value
Type | Description |
---|---|
Double |
Methods
RenderImage(Int32)
Renders DICOM image to IImage.
Declaration
public virtual IImage RenderImage(int frame = 0)
Parameters
Type | Name | Description |
---|---|---|
Int32 | frame | Zero indexed frame number. |
Returns
Type | Description |
---|---|
IImage | Rendered image |