]> git.saurik.com Git - wxWidgets.git/blame_incremental - include/wx/msw/dib.h
Disabled memory tracing code for mingw32,
[wxWidgets.git] / include / wx / msw / dib.h
... / ...
CommitLineData
1/////////////////////////////////////////////////////////////////////////////
2// Name: wx/msw/dib.h
3// Purpose: Routines for loading and saving DIBs
4// Author: Various
5// Modified by:
6// Created: 01/02/97
7// RCS-ID: $Id$
8// Copyright: (c) Julian Smart
9// Licence: wxWindows licence
10/////////////////////////////////////////////////////////////////////////////
11
12#ifndef _WX_DIB_H_
13#define _WX_DIB_H_
14
15class WXDLLEXPORT wxBitmap;
16class WXDLLEXPORT wxPalette;
17
18// ----------------------------------------------------------------------------
19// Functions for working with DIBs
20// ----------------------------------------------------------------------------
21
22// VZ: we have 3 different sets of functions: from bitmap.cpp (wxCreateDIB and
23// wxFreeDIB), from dib.cpp and from dataobj.cpp - surely there is some
24// redundancy between them? (FIXME)
25
26// defined in bitmap.cpp
27extern bool wxCreateDIB(long xSize, long ySize, long bitsPerPixel,
28 HPALETTE hPal, LPBITMAPINFO* lpDIBHeader);
29extern void wxFreeDIB(LPBITMAPINFO lpDIBHeader);
30
31// defined in ole/dataobj.cpp
32extern size_t wxConvertBitmapToDIB(LPBITMAPINFO pbi, const wxBitmap& bitmap);
33extern wxBitmap wxConvertDIBToBitmap(const LPBITMAPINFO pbi);
34
35// the rest is defined in dib.cpp
36
37// Save (device dependent) wxBitmap as a DIB
38bool wxSaveBitmap(wxChar *filename, wxBitmap *bitmap, wxPalette *colourmap = NULL);
39
40// Load device independent bitmap into device dependent bitmap
41wxBitmap *wxLoadBitmap(wxChar *filename, wxPalette **colourmap = NULL);
42
43// Load into existing bitmap;
44bool wxLoadIntoBitmap(wxChar *filename, wxBitmap *bitmap, wxPalette **pal = NULL);
45
46HANDLE wxBitmapToDIB (HBITMAP hBitmap, HPALETTE hPal);
47BOOL wxReadDIB(LPTSTR lpFileName, HBITMAP *bitmap, HPALETTE *palette);
48HANDLE wxReadDIB2(LPTSTR lpFileName);
49LPSTR wxFindDIBBits (LPSTR lpbi);
50HPALETTE wxMakeDIBPalette(LPBITMAPINFOHEADER lpInfo);
51
52#endif // _WX_DIB_H_
53