VintaSoft Imaging .NET SDK 15.1: Документация для .NET разработчика
В этом разделе
DICOM: Аннотирование DICOM изображения в WinForms
В этом разделе
Аннотации могут отображаться поверх DICOM изображения в WinForms просмотрщике изображений.

Для каждой аннотации реализован класс, который определяет способ отображения вида аннотации и то, как пользователь может взаимодействовать с аннотацией:
Класс DicomAnnotationTool позволяет отображать и редактировать аннотации к DICOM изображению в WinForms просмотрщике изображений.

Вот C#/VB.NET код, который демонстрирует, как отобразить аннотации DICOM файла в WinForms просмотрщике изображений:
// create a DICOM visual tool
Vintasoft.Imaging.Annotation.Dicom.UI.VisualTools.DicomAnnotationTool annotationTool = 
    new Vintasoft.Imaging.Annotation.Dicom.UI.VisualTools.DicomAnnotationTool();
// set the DICOM visual tool as active visual tool in image viewer
viewer.VisualTool = annotationTool;

// load a presentation state file
Vintasoft.Imaging.Codecs.ImageFiles.Dicom.DicomFile presentationStateFile = 
    new Vintasoft.Imaging.Codecs.ImageFiles.Dicom.DicomFile(presentationStateFilePath);
// add DICOM annotations from the presentation state file to the DICOM visual tool
annotationTool.AnnotationDataController.AddAnnotationDataSet(presentationStateFile.Annotations);

// load a DICOM file in the image viewer
viewer.Images.Add(dicomFilePath);
' create a DICOM visual tool
Dim annotationTool As New Vintasoft.Imaging.Annotation.Dicom.UI.VisualTools.DicomAnnotationTool()
' set the DICOM visual tool as active visual tool in image viewer
viewer.VisualTool = annotationTool

' load a presentation state file
Dim presentationStateFile As New Vintasoft.Imaging.Codecs.ImageFiles.Dicom.DicomFile(presentationStateFilePath)
' add DICOM annotations from the presentation state file to the DICOM visual tool
annotationTool.AnnotationDataController.AddAnnotationDataSet(presentationStateFile.Annotations)

' load a DICOM file in the image viewer
viewer.Images.Add(dicomFilePath)