0023024: Update headers of OCCT files
[occt.git] / src / AlienImage / AlienImage_BMPHeader.hxx
CommitLineData
b311480e 1// Copyright (c) 1999-2012 OPEN CASCADE SAS
2//
3// The content of this file is subject to the Open CASCADE Technology Public
4// License Version 6.5 (the "License"). You may not use the content of this file
5// except in compliance with the License. Please obtain a copy of the License
6// at http://www.opencascade.org and read it completely before using this file.
7//
8// The Initial Developer of the Original Code is Open CASCADE S.A.S., having its
9// main offices at: 1, place des Freres Montgolfier, 78280 Guyancourt, France.
10//
11// The Original Code and all software distributed under the License is
12// distributed on an "AS IS" basis, without warranty of any kind, and the
13// Initial Developer hereby disclaims all such warranties, including without
14// limitation, any warranties of merchantability, fitness for a particular
15// purpose or non-infringement. Please see the License for the specific terms
16// and conditions governing the rights and limitations under the License.
17
7fd59977 18//============================================================================
19//==== Titre: AlienImage_BMPHeader.hxx
20//============================================================================
21
22#ifndef _AlienImage_BMPHeader_HeaderFile
23#define _AlienImage_BMPHeader_HeaderFile
24
25//==== Definition de Type ====================================================
26#include <Standard_Type.hxx>
27
28#ifdef WNT
29# include <windows.h>
30#else
31typedef unsigned int DWORD; // 32-bit signed
32typedef unsigned int* PDWORD;
33typedef int LONG; // 32-bit unsigned
34typedef unsigned short WORD; // 16-bit unsigned
35typedef unsigned char BYTE; // 8-bit unsigned
36#endif // WNT
37
38typedef struct {
39// WORD bfType;
40 DWORD bfSize;
41 DWORD bfReserved;
42 DWORD bfOffBits;
43} AlienImage_BMPHeader;
44
45const Handle(Standard_Type)& STANDARD_TYPE(AlienImage_BMPHeader);
46
47//============================================================================
48#ifndef WNT
49
50typedef struct tagBITMAPINFOHEADER {
51 DWORD biSize;
52 LONG biWidth;
53 LONG biHeight;
54 WORD biPlanes;
55 WORD biBitCount;
56 DWORD biCompression;
57 DWORD biSizeImage;
58 LONG biXPelsPerMeter;
59 LONG biYPelsPerMeter;
60 DWORD biClrUsed;
61 DWORD biClrImportant;
62} BITMAPINFOHEADER;
63
64typedef struct tagBITMAPCOREHEADER {
65 DWORD bcSize;
66 WORD bcWidth;
67 WORD bcHeight;
68 WORD bcPlanes; // 1
69 WORD bcBitCount; // 1,4,8 or 24
70} BITMAPCOREHEADER;
71
72// constants for the biCompression field
73#define BI_RGB 0
74#define BI_RLE8 1
75#define BI_RLE4 2
76#define BI_BITFIELDS 3
77
78typedef struct tagRGBQUAD {
79 BYTE rgbBlue;
80 BYTE rgbGreen;
81 BYTE rgbRed;
82 BYTE rgbReserved;
83} RGBQUAD;
84
85#endif // WNT
86
87#define LOW_VAL_AT_LOW_ADDR (*(char*)&__swaptest)
88
89#endif // _AlienImage_BMPHeader_HeaderFile
90