BioImager  3.9.1
A .NET microscopy imaging library. Supports various microscopes by using imported libraries & GUI automation. Supported libraries include PriorĀ® & ZeissĀ® & all devices supported by Micromanager 2.0 and python-microscope.
Loading...
Searching...
No Matches
BioImager.DBitmap Class Reference

Public Member Functions

void Initialize (Configuration configuration, RenderTarget renderTarget2, AForge.Bitmap bf)
 

Static Public Member Functions

static Bitmap FromImage (RenderTarget renderTarget, AForge.Bitmap image)
 Loads a Direct2D Bitmap from a file using System.Drawing.Image.FromFile(...) More...
 

Detailed Description

Definition at line 75 of file DBitmap.cs.

Member Function Documentation

◆ FromImage()

static Bitmap BioImager.DBitmap.FromImage ( RenderTarget  renderTarget,
AForge.Bitmap  image 
)
static

Loads a Direct2D Bitmap from a file using System.Drawing.Image.FromFile(...)

Parameters
renderTargetThe render target.
fileThe file.
Returns
A D2D1 Bitmap

Definition at line 85 of file DBitmap.cs.

86 {
87 var bitmapProperties = new BitmapProperties(new PixelFormat(Format.R8G8B8A8_UNorm, AlphaMode.Ignore));
88 var size = new Size2(image.Width, image.Height);
89 return new Bitmap(renderTarget, size, new DataPointer(image.RGBData, image.Width * 4 * image.Height), image.Width * 4, bitmapProperties);
90 }

Referenced by BioImager.ImageView.UpdateImages().

◆ Initialize()

void BioImager.DBitmap.Initialize ( Configuration  configuration,
RenderTarget  renderTarget2,
AForge.Bitmap  bf 
)

Definition at line 91 of file DBitmap.cs.

92 {
93 _bitmap = FromImage(renderTarget2, bf);
94 }
static Bitmap FromImage(RenderTarget renderTarget, AForge.Bitmap image)
Loads a Direct2D Bitmap from a file using System.Drawing.Image.FromFile(...)
Definition: DBitmap.cs:85

The documentation for this class was generated from the following file: