Introduction

ImageStone is a powerful C++ class library for image manipulation. Its features include load, save, display, transformation, and nearly 100 special image effects. It can be used cross platform (includes Windows, Linux, Mac), and especially under Windows, it can be used as a DIB wrapper class.

How to Use

Similar to STL and Boost library, ImageStone is a header-only C++ library, it consists entirely of header files, so you can begin to use it just add #include "ImageStone.h" at the beginning of your source code, But in order to take full advantage of operating system features, there are some differences between various platforms.

On Windows

Only need to add #include "ImageStone.h" in your project, normally to be added at the end of StdAfx.h file.

ImageStone uses raw Win32 GDI+ API to implement image load/save function, so it has high efficiency and small final file size.

Although BitBlt is faster than AlphaBlend, it will destroy the alpha channel of destination. Some features such as: layered window, DWM need alpha channel, so these cases we have to convert image to 32bpp, using AlphaBlend to draw.

But, if you want to call Load or Save method of FCObjImage in DllMain or constructor of global object in DLL, you need use FCAutoInitGDIPlus to init GDI+ module in your clients before load DLL, and disable auto GDI+ init of ImageStone in DLL.

Comments and Discussions

Excellent Library!
I've a question, for 32-bit images, how can I know the byte alignment (BGRA or ARGB)?
Loading one 24-bit image and then convert with "ConvertTo32Bit()" I have in "m_pByte" BGRA alignement.
Loading one 32-bit image I have in "m_pByte" ARGB alignement.

I am using Freeimage library in my application to load image, and wanted to add some image effects.As most of the work done is through freeimage i dont want to change the loading image pattern of freeimage to imagestone .

How can i add imagestone effects to my application with out using the load funtion of FCObjImage class. Is it possible to use ImageStone's classes through Freeimage Lib directly.
Thanks, in Advance

Is there any way to make a large image file print across multiple pages without some preprocessing of the image to break it into chunks? For instance: I have a bitmap image that is 2550px wide by say 10,000px high. If I print, it prints all image data to one page.

Hi,
According to your other thread (PCL i.e. Phoxo core library), Image stone is the new version of PCL.

But what's about the Region management? (not only rectangle regions but any region wich are basically a set of bits telling if each pixel in the image is or isn't into the region)
1. are the effects/manipulations acting on the region of an image or do they proceed always on the entire image?
2. How can I add the region (ROI) into the image, so that the image effect only process on the region?
3. Is there specific function that manage regions? (create/delete, add etc...)

I have then 2 main questions:
1. How can I convert FCObjImage into Image object (I've read that this conversion is easy for HBITMAPS....)
2. how can I get some kind of realtime effects on my displayed Image objects, like in the demo program, when you adjust the brightness for example...

Many thx in advance.
BTW, I am trying to contact you in your PhoXo company without success

2 ) this is not one or two sentences to make it clear, you need create a thread to process image to avoid blocking UI response. reference dlg_effect_base.h and dlg_effect_base.cpp in demo program source code

This looks like very good code, but I am having a problem with the GDIPlus_CreateTextLayer function. I added code to your sample application to display the text, but it only appears when the window is maximized. I have an application of my own that displays several bmp files on the same screen. I need to place text over these bmp files, but my application crashes on the GDIPlus_CreateTextLayer function call. Do you have any updated examples that show the text options in greater detail?

hi i am beginner in c++ language and starting from 0-level. did your programe run in turbo 4.5 compiler if yes tell how? which part of programe is worked for bmp image load.
my class project is that "load bmp image in turbo 4.5 compiler" please help me

hy,
thanks for that, it's so helpful,
I have a problem with the function : " _ConvertToTrueColor ",
she don't realy make my FCObjImage in true color, ( I want to convert it to TrueColor to take the alpha of PNG format into consideration )
any idea will be useful, thanks again