Click here to Skip to main content
13,258,269 members (39,860 online)
Click here to Skip to main content

Stats

74.6K views
8.8K downloads
54 bookmarked
Posted 26 Feb 2008

FreeImage Display Demo

, 4 Jun 2008
How to display a bitmap in your MFC SDI application using FreeImage. Various rescaling algorithms considered.
fi_test_bin
FreeImage.dll
FreeImage Display Demo v1.0.exe
fi_test_bin2
FreeImage.dll
FreeImage Display Demo v2.0.exe
fi_test_bin2_1
FreeImage.dll
FreeImage Display Demo v2.1.exe
fi_test_bin2_2
FreeImage.dll
FreeImage Display Demo v2.2.exe
fi_test_bin3
FreeImage.dll
FreeImage Display Demo v3.0.exe
fi_test_bin3_1
FreeImage.dll
FreeImage Display Demo v3.1.exe
fi_test_bin3_2
FreeImage Display Demo v3.2.exe
FreeImage.dll
fi_test_bin3_3
FreeImage Display Demo v3.3.exe
FreeImage.dll
fi_test_bin3_4
FreeImage.dll
FreeImage Display Demo v3.4.exe
fi_test_bin4
FreeImage.dll
FreeImage Display Demo v4.0.exe
fi_test_bin5
FreeImage.dll
FreeImage Display Demo v5.0.exe
fi_test_src
fi_test
fi_test.dsw
fi_test.dsp
fi_test.clw
fi_test.aps
FreeImage.lib
res
fi_testDoc.ico
fi_test.ico
Toolbar.bmp
fi_test_src2
fi_test
fi_test.dsw
fi_test.clw
FreeImage.lib
fi_test.aps
fi_test.dsp
fi_test.opt
res
fi_testDoc.ico
fi_test.ico
toolbar.bmp
fi_test_src2_1
fi_test
fi_test.dsw
fi_test.clw
FreeImage.lib
Fi_test.opt
fi_test.aps
fi_test.dsp
res
fi_testDoc.ico
fi_test.ico
toolbar.bmp
fi_test_src2_2
fi_test
fi_test.dsw
fi_test.clw
FreeImage.lib
Fi_test.opt
fi_test.aps
fi_test.dsp
res
fi_testDoc.ico
Toolbar.bmp
fi_test.ico
fi_test_src3
fi_test
FI_TEST.DSW
FI_TEST.CLW
FreeImage.lib
Fi_test.opt
fi_test.plg
fi_test.aps
fi_test.dsp
RES
fi_testDoc.ico
FI_TEST.ICO
Toolbar.bmp
fi_test_src3_1
fi_test
FI_TEST.DSW
FI_TEST.CLW
FreeImage.lib
Fi_test.opt
fi_test.plg
fi_test.aps
fi_test.dsp
RES
fi_testDoc.ico
FI_TEST.ICO
Toolbar.bmp
fi_test_src3_2
fi_test
FreeImage.lib
RES
Toolbar.bmp
FI_TEST.ICO
fi_testDoc.ico
fi_test.aps
FI_TEST.CLW
fi_test.dsp
FI_TEST.DSW
Fi_test.opt
fi_test.plg
fi_test_src3_3
fi_test
FI_TEST.DSW
FI_TEST.CLW
FreeImage.lib
Fi_test.opt
fi_test.plg
fi_test.aps
fi_test.dsp
RES
fi_testDoc.ico
FI_TEST.ICO
Toolbar.bmp
fi_test_src3_4
fi_test
FI_TEST.DSW
FI_TEST.CLW
FreeImage.lib
Fi_test.opt
fi_test.plg
fi_test.aps
fi_test.dsp
RES
fi_testDoc.ico
FI_TEST.ICO
Toolbar.bmp
fi_test_src4
fi_test
FI_TEST.DSW
FI_TEST.CLW
FreeImage.lib
Fi_test.opt
fi_test.aps
fi_test.dsp
RES
fi_testDoc.ico
FI_TEST.ICO
Toolbar.bmp
fi_test_src5
fi_test
FI_TEST.DSW
FI_TEST.CLW
FreeImage.lib
Fi_test.opt
fi_test.aps
fi_test.dsp
RES
fi_testDoc.ico
FI_TEST.ICO
Toolbar.bmp
//	FreeImage Display Demo v5.0

//	Copyright (C) 2008 monday2000@yandex.ru
//
//	This program is free software; you can redistribute it and/or modify
//	it under the terms of the GNU General Public License as published by
//	the Free Software Foundation; either version 2 of the License, or
//	(at your option) any later version.
//
//	This program is distributed in the hope that it will be useful,
//	but WITHOUT ANY WARRANTY; without even the implied warranty of
//	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
//	GNU General Public License for more details.
//
//	You should have received a copy of the GNU General Public License
//	along with this program; if not, write to the Free Software
//	Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
//	http://www.gnu.org/copyleft/gpl.html

// Leptonica.h : header file for Leptonica.cpp
//
/////////////////////////////////////////////////////////////////////////////

#ifndef _LEPTONICA_H_
#define _LEPTONICA_H_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000


#include "stdafx.h" // added to the original file to allow the MFC compilation

#include "FreeImage.h"
#include "Utilities.h"

BOOL LeptonicaScaleBySamplingLow(FIBITMAP* src_dib, unsigned wd, unsigned hd, CPoint OffscreenSize, BYTE* pBits, RGBQUAD *dst_pal);

BOOL LeptonicaScaleSmoothLow(FIBITMAP* src_dib, unsigned wd, unsigned hd,  CPoint OffscreenSize, unsigned size, BYTE* pBits, RGBQUAD *dst_pal);

BOOL LeptonicaScaleLILow(BOOL Sc, FIBITMAP* src_dib, unsigned wd, unsigned hd, CPoint OffscreenSize, BYTE  *pBits, RGBQUAD *dst_pal, BOOL bInterpolate, CPoint OffscreenSizeSc, CPoint CoordSc);

BOOL LeptonicaScaleAreaMapLow(BOOL Sc, FIBITMAP* src_dib, unsigned wd, unsigned hd, CPoint OffscreenSize, BYTE* pBits, RGBQUAD *dst_pal, CPoint OffscreenSizeSc, CPoint CoordSc);

inline void Get1BitPixel(BYTE* line, int x, int color_mode, BYTE* value);

#endif

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under A Public Domain dedication

Share

About the Author

monday2000
Russian Federation Russian Federation
No Biography provided

You may also be interested in...

Permalink | Advertise | Privacy | Terms of Use | Mobile
Web01 | 2.8.171114.1 | Last Updated 4 Jun 2008
Article Copyright 2008 by monday2000
Everything else Copyright © CodeProject, 1999-2017
Layout: fixed | fluid