blob: f0d15f379d4c4fd05d92d18181478071aa53b5b0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
========================================================================
FreeImageIO.Net
Author: Marcos Pernambuco Motta (marcos.pernambuco@gmail.com)
========================================================================
This library allows programs that use FreeImage.Net to save images to or
to load images from .Net Streams.
The class FreeImageStream implements a FreeImageIO handler and routes
IO calls (read,write,tell and seek) to a wrapped System.IO.Stream.
Example:
using FreeImageAPI;
using FreeImageIODotNet;
uint dib = FreeImageAPI.FreeImage.Allocate(width,height,32,0,0,0);
// ... Image handling code goes here
System.IO.FileStream stream = new System.IO.FileStream(@"c:\sample.png",System.IO.FileMode.Create);
FreeImageStream imageStream = new FreeImageStream(stream);
imageStream.SaveImage((int)FREE_IMAGE_FORMAT.FIF_PNG,dib,0);
stream.Close();
Compile with VS2003.
|