Class DicomImageInfo
Namespace: Aspose.Imaging.FileFormats.Dicom
Assembly: Aspose.Imaging.dll (25.2.0)
Contains all meta-information from Dicom file header
[JsonObject(MemberSerialization.OptIn)]
public sealed class DicomImageInfo
Inheritance
Inherited Members
object.GetType(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()
Properties
BitsAllocated
Gets a value of the “bitsAllocated”.
[JsonProperty]
public int BitsAllocated { get; }
Property Value
BitsStored
Gets the number of stored bits.
[JsonProperty]
public int BitsStored { get; }
Property Value
Blues
Gets the array colors of the blue
[JsonProperty]
public byte[] Blues { get; }
Property Value
byte[]
DicomHeaderInfoByBytes
Gets the dicom header information by bytes.
[JsonProperty]
public byte[] DicomHeaderInfoByBytes { get; }
Property Value
byte[]
DicomInfo
Gets the header information of the DICOM file.
public ReadOnlyCollection<string> DicomInfo { get; }
Property Value
Examples
The following example shows how to read the header information of a DICOM image.```csharp [C#]
string dir = "c:\\aspose.imaging\\issues\\net\\3635\\testdata\\3628";
using (Aspose.Imaging.FileFormats.Dicom.DicomImage image = (Aspose.Imaging.FileFormats.Dicom.DicomImage)Aspose.Imaging.Image.Load(System.IO.Path.Combine(dir, "ttfm.dcm")))
{
foreach (string s in image.FileInfo.DicomInfo)
{
System.Console.WriteLine(s);
}
}
// STDOUT:
//Media Storage Sop Class Uid: 1.2.840.10008.5.1.4.1.1.3.1
//Media Storage Sop Instance Uid: 2.16.840.1.114488.0.4.123489834087.1330071425.2
//Transfer Syntax Uid: 1.2.840.10008.1.2.4.70
//Implementation Class Uid: 1.2.840.114236
//Specific Character Set: ISO_IR 100
//Image Type: \SECONDARY\INTRAOPERATIVE
//Sop Class Uid: 1.2.840.10008.5.1.4.1.1.3.1
//Sop Instance Uid: 2.16.840.1.114488.0.4.123489834087.1330071425.2
//Study Date: 20110824
//Series Date: 20110824
//Content Date: 20110824
//Study Time: 094836.214743984
//Series Time: 094836.214743984
//Content Time: 100451.214743816
//Modality: US
//Manufacturer: Medistim
//Institution Name: Hospital Name
//Institution Address: Hospital Address or Department
//Station Name: VERIQ
//Performing Physician's Name: CA Prof. Debus
//Manufacturer's Model Name: VeriQ C
//Recommended Display Frame Rate: 1
//Patient's Name: Femoral trombenarterectomy^Case Report:
//Patient Id: Case Report 1
//Patient's Sex: M
//Patient's Size: 0
//Patient's Weight: 0
//Patient Comments: See case report on www.medistim.com
//Cine Rate: 1
//Effective Duration: 1
//Device Serial Number: 0
//Software Versions(s): 3.3.0 RC0 built 02 / 23 / 12 09:50:45
//Frame Time: 1000
//Study Instance Uid: 2.16.840.1.114488.0.4.123489834087.1330071425.0
//Series Instance Uid: 2.16.840.1.114488.0.4.123489834087.1330071425.1
//Series Number: 1
//Instance Number: 1
//Samples per Pixel: 3
//Photometric Interpretation: RGB
//Planar Configuration: 0
//Number of Frames: 1
//Frame Increment Pointer:
//Rows: 768
//Columns: 1024
//Bits Allocated: 8
//Bits Stored: 8
//high Bit: 7
//Pixel Representation: 0
//Lossy Image Compression: 00
//Pixel Data: 1492
### <a id="Aspose_Imaging_FileFormats_Dicom_DicomImageInfo_Greens"></a> Greens
Gets the array colors of the green
```csharp
[JsonProperty]
public byte[] Greens { get; }
Property Value
byte[]
Height
Gets the height.
[JsonProperty]
public int Height { get; }
Property Value
IsLittleEndian
Gets a value indicating whether this instance is little endian.
[JsonProperty]
public bool IsLittleEndian { get; }
Property Value
NumberOfFrames
Gets the number of frames.
[JsonProperty]
public int NumberOfFrames { get; }
Property Value
Offset
Gets the offset.
[JsonProperty]
public int Offset { get; }
Property Value
PhotoInterpretation
Gets a value of the “PhotoInterpretation”.
[JsonProperty]
public string PhotoInterpretation { get; }
Property Value
PixelRepresentation
Gets a value of the pixel “pixelRepresentation”.
[JsonProperty]
public int PixelRepresentation { get; }
Property Value
PlanarConfiguration
Gets the planar configuration.
[JsonProperty]
public int PlanarConfiguration { get; }
Property Value
ReadonlyTagsList
The read-only tags list. These tag values will be reset according to the actual image data upon image save.
public static ReadOnlyCollection<string> ReadonlyTagsList { get; }
Property Value
Reds
Gets the array colors of the red
[JsonProperty]
public byte[] Reds { get; }
Property Value
byte[]
RescaleIntercept
Gets a value of the “rescaleIntercept”.
[JsonProperty]
public double RescaleIntercept { get; }
Property Value
RescaleSlope
Gets a value of the “rescaleSlope”.
[JsonProperty]
public double RescaleSlope { get; }
Property Value
SamplesPerPixel
Gets a value of the “samplesPerPixel”.
[JsonProperty]
public int SamplesPerPixel { get; }
Property Value
SignedImage
Gets a value indicating whether “signedImage”.
public bool SignedImage { get; }
Property Value
Width
Gets the width.
[JsonProperty]
public int Width { get; }
Property Value
WindowCentre
Gets the window centre.
[JsonProperty]
public double WindowCentre { get; }
Property Value
WindowWidth
Gets the width of the window.
[JsonProperty]
public double WindowWidth { get; }
Property Value
Methods
AddTag(string, object)
Add new Dicom tag.
public void AddTag(string tagDescription, object value)
Parameters
tagDescription
string
The tag description. Can not be null or whitespace.
value
object
The tag value. Can not be null.
RemoveTagAt(int)
Remove an existing tag.
public void RemoveTagAt(int index)
Parameters
index
int
The index of the tag to be updated.
TryAddTag(string, object)
Add new Dicom tag.
public bool TryAddTag(string tagDescription, object value)
Parameters
tagDescription
string
The tag description. Can not be null or whitespace.
value
object
The tag value. Can not be null.
Returns
The operation result.
TryRemoveTagAt(int)
Remove an existing tag.
public bool TryRemoveTagAt(int index)
Parameters
index
int
The index of the tag to be updated.
Returns
The operation result.
TryUpdateTagAt(int, object)
Update an existing tag.
public bool TryUpdateTagAt(int index, object newValue)
Parameters
index
int
The index of the tag to be updated.
newValue
object
The tag value. Can not be null.
Returns
The operation result.
UpdateTagAt(int, object)
Update an existing tag.
public void UpdateTagAt(int index, object newValue)
Parameters
index
int
The index of the tag to be updated.
newValue
object
The tag value. Can not be null.