Richard Boegli's CnC_Generals_Zero_Hour Fork
WIP
This is documentation of Richard Boegil's Zero Hour Fork
Loading...
Searching...
No Matches
dib.h
Go to the documentation of this file.
1
/*
2
** Command & Conquer Generals Zero Hour(tm)
3
** Copyright 2025 Electronic Arts Inc.
4
**
5
** This program is free software: you can redistribute it and/or modify
6
** it under the terms of the GNU General Public License as published by
7
** the Free Software Foundation, either version 3 of the License, or
8
** (at your option) any later version.
9
**
10
** This program is distributed in the hope that it will be useful,
11
** but WITHOUT ANY WARRANTY; without even the implied warranty of
12
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
** GNU General Public License for more details.
14
**
15
** You should have received a copy of the GNU General Public License
16
** along with this program. If not, see <http://www.gnu.org/licenses/>.
17
*/
18
19
/***********************************************************************************************
20
*** C O N F I D E N T I A L --- W E S T W O O D S T U D I O S ***
21
***********************************************************************************************
22
* *
23
* Project Name : Command & Conquer *
24
* *
25
* $Archive:: /Commando/Code/Library/dib.h $*
26
* *
27
* $Author:: Greg_h $*
28
* *
29
* $Modtime:: 7/26/97 11:33a $*
30
* *
31
* $Revision:: 2 $*
32
* *
33
*---------------------------------------------------------------------------------------------*
34
* Functions: *
35
* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
36
37
#ifndef DIB_H
38
#define DIB_H
39
40
#include "
always.h
"
41
#include "
bsurface.h
"
42
#include "
palette.h
"
43
#include "
win.h
"
44
45
46
class
DIB8Class
47
{
48
public
:
49
50
DIB8Class
(HWND hwnd,
int
width,
int
height,
PaletteClass
& pal);
51
~DIB8Class
(
void
);
52
53
HBITMAP
Get_Handle
() {
return
Handle; }
54
int
Get_Width
(
void
) {
return
Width; }
55
int
Get_Height
(
void
) {
return
Height; }
56
Surface &
Get_Surface
(
void
) {
return
*Surface; }
57
58
void
Clear
(
unsigned
char
color);
59
60
private
:
61
62
bool
IsZombie;
// object constructor failed, its a living-dead object!
63
BITMAPINFO * Info;
// info used in creating the dib + the palette.
64
HBITMAP Handle;
// handle to the actual dib
65
unsigned
char
* Pixels;
// address of memory containing the pixel data
66
int
Width;
// width of the dib
67
int
Height;
// height of the dib
68
unsigned
char
* PixelBase;
// address of upper left pixel (this and DIBPitch abstract up/down DIBS)
69
int
Pitch;
// offset from DIBPixelBase to next row (can be negative for bottom-up DIBS)
70
71
BSurface
*
Surface
;
// Bsurface wrapped around the pixel buffer.
72
};
73
74
75
#endif
/*DIB_H*/
PALETTE.H
always.h
win.h
bsurface.h
BSurface
Definition
bsurface.h:50
DIB8Class::DIB8Class
DIB8Class(HWND hwnd, int width, int height, PaletteClass &pal)
Definition
dib.cpp:56
DIB8Class::~DIB8Class
~DIB8Class(void)
Definition
dib.cpp:148
DIB8Class::Get_Width
int Get_Width(void)
Definition
dib.h:54
DIB8Class::Get_Height
int Get_Height(void)
Definition
dib.h:55
DIB8Class::Clear
void Clear(unsigned char color)
Definition
dib.cpp:168
DIB8Class::Get_Handle
HBITMAP Get_Handle()
Definition
dib.h:53
DIB8Class::Get_Surface
Surface & Get_Surface(void)
Definition
dib.h:56
PaletteClass
Definition
PALETTE.H:50
Surface
Definition
Surface.h:53
Code
Libraries
Source
WWVegas
WWLib
dib.h
Generated by
1.13.2