/// <summary> /// Casts an image to an bitmap. /// <para>Notice that GDI+ does not support bitmaps which stride is not 4.</para> /// </summary> /// <param name="img">Input image.</param> /// <returns>Bitmap</returns> public static Bitmap AsBitmap(this Image<Bgra<short>> img) { return asBitmap(img, PixelFormat.Format64bppArgb); }
/// <summary> /// Casts an image to an bitmap. /// <para>Notice that GDI+ does not support bitmaps which stride is not 4.</para> /// </summary> /// <param name="img">Input image.</param> /// <returns>Bitmap</returns> public static Bitmap AsBitmap(this Image<Bgr<short>> img) { return asBitmap(img, PixelFormat.Format48bppRgb); }
/// <summary> /// Casts an image to an bitmap. /// <para>Notice that GDI+ does not support bitmaps which stride is not 4.</para> /// </summary> /// <param name="img">Input image.</param> /// <returns>Bitmap</returns> public static Bitmap AsBitmap(this Image<Bgra<byte>> img) { return asBitmap(img, PixelFormat.Format32bppArgb); }
/// <summary> /// Casts an image to an bitmap. /// <para>Notice that GDI+ does not support bitmaps which stride is not 4.</para> /// </summary> /// <param name="img">Input image.</param> /// <returns>Bitmap</returns> public static Bitmap AsBitmap(this Image<Bgr<byte>> img) { return asBitmap(img, PixelFormat.Format24bppRgb); }
/// <summary> /// Casts an image to an bitmap. /// <para>Notice that GDI+ does not support bitmaps which stride is not 4.</para> /// </summary> /// <param name="img">Input image.</param> /// <returns>Bitmap</returns> public static Bitmap AsBitmap(this Image<Gray<short>> img) { return asBitmap(img, PixelFormat.Format16bppGrayScale); }
/// <summary> /// Casts an image to an bitmap. /// <para>Notice that GDI+ does not support bitmaps which stride is not 4.</para> /// </summary> /// <param name="img">Input image.</param> /// <returns>Bitmap</returns> public static Bitmap AsBitmap(this Image<Gray<byte>> img) { return asBitmap(img, PixelFormat.Format8bppIndexed); }