Main Page | Alphabetical List | Compound List | File List | Compound Members | File Members

display.h

Go to the documentation of this file.
00001 /****************************************************************************************/
00002 /*  Display.H                                                                           */
00003 /*                                                                                      */
00004 /*  Author:  Mike Sandige                                                               */
00005 /*  Description:  Abstracts all low-level display surfaces into a single API            */
00006 /*                                                                                      */
00007 /*  The contents of this file are subject to the Genesis3D Public License               */
00008 /*  Version 1.01 (the "License"); you may not use this file except in                   */
00009 /*  compliance with the License. You may obtain a copy of the License at                */
00010 /*  http://www.genesis3d.com                                                            */
00011 /*                                                                                      */
00012 /*  Software distributed under the License is distributed on an "AS IS"                 */
00013 /*  basis, WITHOUT WARRANTY OF ANY KIND, either express or implied.  See                */
00014 /*  the License for the specific language governing rights and limitations              */
00015 /*  under the License.                                                                  */
00016 /*                                                                                      */
00017 /*  The Original Code is Genesis3D, released March 25, 1999.                            */
00018 /*  Genesis3D Version 1.1 released November 15, 1999                                 */
00019 /*  Copyright (C) 1999 WildTangent, Inc. All Rights Reserved           */
00020 /*                                                                                      */
00021 /****************************************************************************************/
00022 // Display
00023 //   display manager 
00024 //
00025 //   manages 
00026 //     DIB format window displays
00027 //     DDRAW format fullscreen displays
00028 
00029 
00030 #ifndef Display_H
00031 #define Display_H
00032 
00033 #include "basetype.h"
00034 #include "DisplayModeInfo.h"
00035 
00036 #ifdef __cplusplus
00037 extern "C" {
00038 #endif
00039 
00040 typedef enum { DISPLAY_DIB_WINDOW, DISPLAY_DDRAW_FULLSCREEN, DISPLAY_COUNT } Display_Type;
00041 
00042 typedef struct Display Display;
00043 
00044 geBoolean Display_GetDisplayInfo(               Display_Type     DisplayType,
00045                                                                                 char                    *DescriptionString, 
00046                                                                                 unsigned int     DescriptionStringMaxLength,
00047                                                                                 DisplayModeInfo *Info);
00048 
00049 geBoolean Display_GetPixelFormat        (       const Display *D,
00050                                                                                 //int32       *pixel_pitch,
00051                                                                                 int32       *bytes_per_pixel,
00052                                                                                 int32       *R_shift,
00053                                                                                 uint32      *R_mask,
00054                                                                                 int32       *R_width,
00055                                                                                 int32       *G_shift,
00056                                                                                 uint32      *G_mask,
00057                                                                                 int32       *G_width,
00058                                                                                 int32       *B_shift,
00059                                                                                 uint32      *B_mask,
00060                                                                                 int32       *B_width);
00061 
00062 void    Display_GetDisplayFormat(               const Display *D,
00063                                                                                 Display_Type *DisplayType,
00064                                                                                 int32   *Width, 
00065                                                                                 int32   *Height,
00066                                                                                 int32   *BitsPerPixel,
00067                                                                                 uint32  *Flags);
00068 
00069 geBoolean Display_Blit          (       Display *D);
00070 
00071 geBoolean Display_Wipe          (       Display *D,     
00072                                                                 uint32        color);
00073 
00074 geBoolean Display_Lock          (       Display *D,
00075                                                                 uint8       **ptr,
00076                                                                 int32       *pitch);
00077 
00078 geBoolean Display_Unlock        (       Display *D);
00079 
00080 void Display_Destroy            (       Display **pDisplay);
00081 
00082 geBoolean Display_SetActive     (       Display *D, geBoolean Active );
00083 
00084                                                  
00085 #ifdef _INC_WINDOWS                                                                          
00086 Display *Display_Create (       HWND hWindow,
00087                                                         Display_Type DisplayType,
00088                                                         int32   RenderSizeAcross, 
00089                                                         int32   RenderSizeDown,
00090                                                         int32   Display_BitsPerPixel,
00091                                                         uint32  Display_Flags);
00092 #endif
00093 
00094 #ifdef __cplusplus
00095 }
00096 #endif
00097 
00098 #endif

Generated on Tue Sep 30 12:35:38 2003 for GTestAndEngine by doxygen 1.3.2