CopyGraphToBitmap() public method

public CopyGraphToBitmap ( Int32 bitmapWidthPx, Int32 bitmapHeightPx ) : System.Drawing.Bitmap
bitmapWidthPx System.Int32
bitmapHeightPx System.Int32
return System.Drawing.Bitmap
    GetImages
    (
        NodeXLControl oNodeXLControl,
        Boolean bUseFixedAspectRatio,
        out Byte [] abtFullSizeImage,
        out Byte [] abtThumbnail
    )
    {
        Debug.Assert(oNodeXLControl != null);
        Debug.Assert(oNodeXLControl.ActualWidth >= MinimumNodeXLControlWidth);
        Debug.Assert(oNodeXLControl.ActualHeight >= MinimumNodeXLControlHeight);

        Size oFullSizeImageSizePx = GetFullSizeImageSizePx(oNodeXLControl,
            bUseFixedAspectRatio);

        Image oFullSizeImage = oNodeXLControl.CopyGraphToBitmap(
            oFullSizeImageSizePx.Width, oFullSizeImageSizePx.Height);

        Size oThumbnailImageSizePx = GetThumbnailImageSizePx(
            oFullSizeImageSizePx);

        Image oThumbnail = oFullSizeImage.GetThumbnailImage(
            oThumbnailImageSizePx.Width, oThumbnailImageSizePx.Height,
            () => {return false;}, IntPtr.Zero);

        abtFullSizeImage = ImageToBytes(oFullSizeImage);
        abtThumbnail = ImageToBytes(oThumbnail);

        oFullSizeImage.Dispose();
        oThumbnail.Dispose();
    }