DicomObjects.NET.8.48 Documentation
DicomObjects Namespace / DicomImage3D Class / ScreenToImage Method
The point on the output space
The Viewer being used for display
Example

In This Topic
    ScreenToImage Method (DicomImage3D)
    In This Topic
    Calculate where in image (X,Y) space, a given screen point lies
    Syntax
    'Declaration
     
    
    Public Overrides Function ScreenToImage( _
       ByVal ScreenLocation As System.Drawing.PointF, _
       ByVal Viewer As DicomViewer _
    ) As System.Nullable(Of PointF)
    public override System.Nullable<PointF> ScreenToImage( 
       System.Drawing.PointF ScreenLocation,
       DicomViewer Viewer
    )

    Parameters

    ScreenLocation
    The point on the output space
    Viewer
    The Viewer being used for display

    Return Value

    Point in 2D space if appropriate, or null, for 3D images
    Example
    DicomImage image = new DicomImage("your_dicom_image.dcm");
    Viewer.Images.Add(image); // Assumes an existing DicomViewer obj
    PointF point = new PointF(100, 150); 
    PointF? screenPoint = image.ImageToScreen(point, Viewer); // screenPoint Example Value: {X = 272.708344 Y = 289.0625}
    Requirements

    Target Platforms: .NET CLR 4.8 or higher

    See Also