Пример #1
0
 /// <summary>
 /// Returns the Dose Matrix object for advanced evaluation
 /// </summary>
 /// <returns></returns>
 /// <exception cref="InvalidOperationException">Cannot call for dose on a Dicom file that is not a dose file</exception>
 public EvilDICOM.RT.RTDose DoseMatrix()
 {
     if (IsDoseFile)
     {
         DICOMObject         dcm1      = DICOMObject.Read(FileName);
         EvilDICOM.RT.RTDose dcmMatrix = new EvilDICOM.RT.RTDose(dcm1);
         X = dcmMatrix.DimensionX;
         Y = dcmMatrix.DimensionY;
         Z = dcmMatrix.DimensionZ;
         return(dcmMatrix);
     }
     else
     {
         throw new InvalidOperationException("Cannot call for dose on a Dicom file that is not a dose file");
     }
 }
 public DoseMatrixOptimal(EvilDICOM.RT.RTDose doseMatrix)
 {
     if (doseMatrix == null)
     {
         throw new ArgumentNullException(nameof(doseMatrix));
     }
     DimensionX   = doseMatrix.DimensionX;
     DimensionY   = doseMatrix.DimensionY;
     DimensionZ   = doseMatrix.DimensionZ;
     DoseValues   = doseMatrix.DoseValues.ToArray();
     Scaling      = doseMatrix.Scaling;
     X0           = doseMatrix.X0;
     Y0           = doseMatrix.Y0;
     Z0           = doseMatrix.Z0;
     XMax         = doseMatrix.XMax;
     YMax         = doseMatrix.YMax;
     ZMax         = doseMatrix.ZMax;
     XRes         = doseMatrix.XRes;
     YRes         = doseMatrix.YRes;
     ZRes         = doseMatrix.ZRes;
     Length       = DoseValues.Length;
     Count        = Length;
     MaxPointDose = doseMatrix.MaxPointDose;
 }