doom3-gpl
Doom 3 GPL source release
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Macros | Functions | Variables
win_glimp.cpp File Reference
#include "../../idlib/precompiled.h"
#include "win_local.h"
#include "rc/AFEditor_resource.h"
#include "rc/doom_resource.h"
#include "../../renderer/tr_local.h"

Go to the source code of this file.

Macros

#define WGL_NUMBER_PIXEL_FORMATS_ARB   0x2000
 
#define WGL_DRAW_TO_WINDOW_ARB   0x2001
 
#define WGL_DRAW_TO_BITMAP_ARB   0x2002
 
#define WGL_ACCELERATION_ARB   0x2003
 
#define WGL_NEED_PALETTE_ARB   0x2004
 
#define WGL_NEED_SYSTEM_PALETTE_ARB   0x2005
 
#define WGL_SWAP_LAYER_BUFFERS_ARB   0x2006
 
#define WGL_SWAP_METHOD_ARB   0x2007
 
#define WGL_NUMBER_OVERLAYS_ARB   0x2008
 
#define WGL_NUMBER_UNDERLAYS_ARB   0x2009
 
#define WGL_TRANSPARENT_ARB   0x200A
 
#define WGL_SHARE_DEPTH_ARB   0x200C
 
#define WGL_SHARE_STENCIL_ARB   0x200D
 
#define WGL_SHARE_ACCUM_ARB   0x200E
 
#define WGL_SUPPORT_GDI_ARB   0x200F
 
#define WGL_SUPPORT_OPENGL_ARB   0x2010
 
#define WGL_DOUBLE_BUFFER_ARB   0x2011
 
#define WGL_STEREO_ARB   0x2012
 
#define WGL_PIXEL_TYPE_ARB   0x2013
 
#define WGL_COLOR_BITS_ARB   0x2014
 
#define WGL_RED_BITS_ARB   0x2015
 
#define WGL_RED_SHIFT_ARB   0x2016
 
#define WGL_GREEN_BITS_ARB   0x2017
 
#define WGL_GREEN_SHIFT_ARB   0x2018
 
#define WGL_BLUE_BITS_ARB   0x2019
 
#define WGL_BLUE_SHIFT_ARB   0x201A
 
#define WGL_ALPHA_BITS_ARB   0x201B
 
#define WGL_ALPHA_SHIFT_ARB   0x201C
 
#define WGL_ACCUM_BITS_ARB   0x201D
 
#define WGL_ACCUM_RED_BITS_ARB   0x201E
 
#define WGL_ACCUM_GREEN_BITS_ARB   0x201F
 
#define WGL_ACCUM_BLUE_BITS_ARB   0x2020
 
#define WGL_ACCUM_ALPHA_BITS_ARB   0x2021
 
#define WGL_DEPTH_BITS_ARB   0x2022
 
#define WGL_STENCIL_BITS_ARB   0x2023
 
#define WGL_AUX_BUFFERS_ARB   0x2024
 
#define WGL_NO_ACCELERATION_ARB   0x2025
 
#define WGL_GENERIC_ACCELERATION_ARB   0x2026
 
#define WGL_FULL_ACCELERATION_ARB   0x2027
 
#define WGL_SWAP_EXCHANGE_ARB   0x2028
 
#define WGL_SWAP_COPY_ARB   0x2029
 
#define WGL_SWAP_UNDEFINED_ARB   0x202A
 
#define WGL_TYPE_RGBA_ARB   0x202B
 
#define WGL_TYPE_COLORINDEX_ARB   0x202C
 
#define WGL_TRANSPARENT_RED_VALUE_ARB   0x2037
 
#define WGL_TRANSPARENT_GREEN_VALUE_ARB   0x2038
 
#define WGL_TRANSPARENT_BLUE_VALUE_ARB   0x2039
 
#define WGL_TRANSPARENT_ALPHA_VALUE_ARB   0x203A
 
#define WGL_TRANSPARENT_INDEX_VALUE_ARB   0x203B
 
#define WGL_SAMPLE_BUFFERS_ARB   0x2041
 
#define WGL_SAMPLES_ARB   0x2042
 

Functions

bool QGL_Init (const char *dllname)
 
void QGL_Shutdown (void)
 
void GLimp_SetGamma (unsigned short red[256], unsigned short green[256], unsigned short blue[256])
 
LONG WINAPI FakeWndProc (HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
 
void GLW_CheckWGLExtensions (HDC hDC)
 
void GLW_WM_CREATE (HWND hWnd)
 
bool GLimp_Init (glimpParms_t parms)
 
bool GLimp_SetScreenParms (glimpParms_t parms)
 
void GLimp_Shutdown (void)
 
void GLimp_SwapBuffers (void)
 
void GLimp_ActivateContext (void)
 
void GLimp_DeactivateContext (void)
 
bool GLimp_SpawnRenderThread (void(*function)(void))
 
voidGLimp_BackEndSleep (void)
 
void GLimp_FrontEndSleep (void)
 
void GLimp_WakeBackEnd (void *data)
 
GLExtension_t GLimp_ExtensionPointer (const char *name)
 

Variables

PFNWGLGETEXTENSIONSSTRINGARBPROC wglGetExtensionsStringARB
 
PFNWGLSWAPINTERVALEXTPROC wglSwapIntervalEXT
 
PFNWGLGETPIXELFORMATATTRIBIVARBPROC wglGetPixelFormatAttribivARB
 
PFNWGLGETPIXELFORMATATTRIBFVARBPROC wglGetPixelFormatAttribfvARB
 
PFNWGLCHOOSEPIXELFORMATARBPROC wglChoosePixelFormatARB
 
PFNWGLCREATEPBUFFERARBPROC wglCreatePbufferARB
 
PFNWGLGETPBUFFERDCARBPROC wglGetPbufferDCARB
 
PFNWGLRELEASEPBUFFERDCARBPROC wglReleasePbufferDCARB
 
PFNWGLDESTROYPBUFFERARBPROC wglDestroyPbufferARB
 
PFNWGLQUERYPBUFFERARBPROC wglQueryPbufferARB
 
PFNWGLBINDTEXIMAGEARBPROC wglBindTexImageARB
 
PFNWGLRELEASETEXIMAGEARBPROC wglReleaseTexImageARB
 
PFNWGLSETPBUFFERATTRIBARBPROC wglSetPbufferAttribARB
 
volatile bool renderThreadActive
 

Macro Definition Documentation

#define WGL_ACCELERATION_ARB   0x2003

Definition at line 83 of file win_glimp.cpp.

#define WGL_ACCUM_ALPHA_BITS_ARB   0x2021

Definition at line 112 of file win_glimp.cpp.

#define WGL_ACCUM_BITS_ARB   0x201D

Definition at line 108 of file win_glimp.cpp.

#define WGL_ACCUM_BLUE_BITS_ARB   0x2020

Definition at line 111 of file win_glimp.cpp.

#define WGL_ACCUM_GREEN_BITS_ARB   0x201F

Definition at line 110 of file win_glimp.cpp.

#define WGL_ACCUM_RED_BITS_ARB   0x201E

Definition at line 109 of file win_glimp.cpp.

#define WGL_ALPHA_BITS_ARB   0x201B

Definition at line 106 of file win_glimp.cpp.

#define WGL_ALPHA_SHIFT_ARB   0x201C

Definition at line 107 of file win_glimp.cpp.

#define WGL_AUX_BUFFERS_ARB   0x2024

Definition at line 115 of file win_glimp.cpp.

#define WGL_BLUE_BITS_ARB   0x2019

Definition at line 104 of file win_glimp.cpp.

#define WGL_BLUE_SHIFT_ARB   0x201A

Definition at line 105 of file win_glimp.cpp.

#define WGL_COLOR_BITS_ARB   0x2014

Definition at line 99 of file win_glimp.cpp.

#define WGL_DEPTH_BITS_ARB   0x2022

Definition at line 113 of file win_glimp.cpp.

#define WGL_DOUBLE_BUFFER_ARB   0x2011

Definition at line 96 of file win_glimp.cpp.

#define WGL_DRAW_TO_BITMAP_ARB   0x2002

Definition at line 82 of file win_glimp.cpp.

#define WGL_DRAW_TO_WINDOW_ARB   0x2001

Definition at line 81 of file win_glimp.cpp.

#define WGL_FULL_ACCELERATION_ARB   0x2027

Definition at line 118 of file win_glimp.cpp.

#define WGL_GENERIC_ACCELERATION_ARB   0x2026

Definition at line 117 of file win_glimp.cpp.

#define WGL_GREEN_BITS_ARB   0x2017

Definition at line 102 of file win_glimp.cpp.

#define WGL_GREEN_SHIFT_ARB   0x2018

Definition at line 103 of file win_glimp.cpp.

#define WGL_NEED_PALETTE_ARB   0x2004

Definition at line 84 of file win_glimp.cpp.

#define WGL_NEED_SYSTEM_PALETTE_ARB   0x2005

Definition at line 85 of file win_glimp.cpp.

#define WGL_NO_ACCELERATION_ARB   0x2025

Definition at line 116 of file win_glimp.cpp.

#define WGL_NUMBER_OVERLAYS_ARB   0x2008

Definition at line 88 of file win_glimp.cpp.

#define WGL_NUMBER_PIXEL_FORMATS_ARB   0x2000

Definition at line 80 of file win_glimp.cpp.

#define WGL_NUMBER_UNDERLAYS_ARB   0x2009

Definition at line 89 of file win_glimp.cpp.

#define WGL_PIXEL_TYPE_ARB   0x2013

Definition at line 98 of file win_glimp.cpp.

#define WGL_RED_BITS_ARB   0x2015

Definition at line 100 of file win_glimp.cpp.

#define WGL_RED_SHIFT_ARB   0x2016

Definition at line 101 of file win_glimp.cpp.

#define WGL_SAMPLE_BUFFERS_ARB   0x2041

Definition at line 131 of file win_glimp.cpp.

#define WGL_SAMPLES_ARB   0x2042

Definition at line 132 of file win_glimp.cpp.

#define WGL_SHARE_ACCUM_ARB   0x200E

Definition at line 93 of file win_glimp.cpp.

#define WGL_SHARE_DEPTH_ARB   0x200C

Definition at line 91 of file win_glimp.cpp.

#define WGL_SHARE_STENCIL_ARB   0x200D

Definition at line 92 of file win_glimp.cpp.

#define WGL_STENCIL_BITS_ARB   0x2023

Definition at line 114 of file win_glimp.cpp.

#define WGL_STEREO_ARB   0x2012

Definition at line 97 of file win_glimp.cpp.

#define WGL_SUPPORT_GDI_ARB   0x200F

Definition at line 94 of file win_glimp.cpp.

#define WGL_SUPPORT_OPENGL_ARB   0x2010

Definition at line 95 of file win_glimp.cpp.

#define WGL_SWAP_COPY_ARB   0x2029

Definition at line 120 of file win_glimp.cpp.

#define WGL_SWAP_EXCHANGE_ARB   0x2028

Definition at line 119 of file win_glimp.cpp.

#define WGL_SWAP_LAYER_BUFFERS_ARB   0x2006

Definition at line 86 of file win_glimp.cpp.

#define WGL_SWAP_METHOD_ARB   0x2007

Definition at line 87 of file win_glimp.cpp.

#define WGL_SWAP_UNDEFINED_ARB   0x202A

Definition at line 121 of file win_glimp.cpp.

#define WGL_TRANSPARENT_ALPHA_VALUE_ARB   0x203A

Definition at line 127 of file win_glimp.cpp.

#define WGL_TRANSPARENT_ARB   0x200A

Definition at line 90 of file win_glimp.cpp.

#define WGL_TRANSPARENT_BLUE_VALUE_ARB   0x2039

Definition at line 126 of file win_glimp.cpp.

#define WGL_TRANSPARENT_GREEN_VALUE_ARB   0x2038

Definition at line 125 of file win_glimp.cpp.

#define WGL_TRANSPARENT_INDEX_VALUE_ARB   0x203B

Definition at line 128 of file win_glimp.cpp.

#define WGL_TRANSPARENT_RED_VALUE_ARB   0x2037

Definition at line 124 of file win_glimp.cpp.

#define WGL_TYPE_COLORINDEX_ARB   0x202C

Definition at line 123 of file win_glimp.cpp.

#define WGL_TYPE_RGBA_ARB   0x202B

Definition at line 122 of file win_glimp.cpp.

Function Documentation

LONG WINAPI FakeWndProc ( HWND  hWnd,
UINT  uMsg,
WPARAM  wParam,
LPARAM  lParam 
)

Definition at line 224 of file win_glimp.cpp.

void GLimp_ActivateContext ( void  )

Definition at line 1040 of file win_glimp.cpp.

void* GLimp_BackEndSleep ( void  )

Definition at line 1133 of file win_glimp.cpp.

void GLimp_DeactivateContext ( void  )

Definition at line 1052 of file win_glimp.cpp.

GLExtension_t GLimp_ExtensionPointer ( const char *  name)

Definition at line 1230 of file win_glimp.cpp.

void GLimp_FrontEndSleep ( void  )

Definition at line 1166 of file win_glimp.cpp.

bool GLimp_Init ( glimpParms_t  parms)

Definition at line 793 of file win_glimp.cpp.

void GLimp_SetGamma ( unsigned short  red[256],
unsigned short  green[256],
unsigned short  blue[256] 
)

Definition at line 188 of file win_glimp.cpp.

bool GLimp_SetScreenParms ( glimpParms_t  parms)

Definition at line 867 of file win_glimp.cpp.

void GLimp_Shutdown ( void  )

Definition at line 945 of file win_glimp.cpp.

bool GLimp_SpawnRenderThread ( void(*)(void function)

Definition at line 1086 of file win_glimp.cpp.

void GLimp_SwapBuffers ( void  )

Definition at line 1006 of file win_glimp.cpp.

void GLimp_WakeBackEnd ( void data)

Definition at line 1185 of file win_glimp.cpp.

void GLW_CheckWGLExtensions ( HDC  hDC)

Definition at line 281 of file win_glimp.cpp.

void GLW_WM_CREATE ( HWND  hWnd)

Definition at line 354 of file win_glimp.cpp.

bool QGL_Init ( const char *  dllname)

Definition at line 1690 of file win_qgl.cpp.

void QGL_Shutdown ( void  )

Definition at line 1302 of file win_qgl.cpp.

Variable Documentation

volatile bool renderThreadActive

Definition at line 1177 of file win_glimp.cpp.

PFNWGLBINDTEXIMAGEARBPROC wglBindTexImageARB

Definition at line 73 of file win_glimp.cpp.

PFNWGLCHOOSEPIXELFORMATARBPROC wglChoosePixelFormatARB

Definition at line 63 of file win_glimp.cpp.

PFNWGLCREATEPBUFFERARBPROC wglCreatePbufferARB

Definition at line 66 of file win_glimp.cpp.

PFNWGLDESTROYPBUFFERARBPROC wglDestroyPbufferARB

Definition at line 69 of file win_glimp.cpp.

PFNWGLGETEXTENSIONSSTRINGARBPROC wglGetExtensionsStringARB

Definition at line 55 of file win_glimp.cpp.

PFNWGLGETPBUFFERDCARBPROC wglGetPbufferDCARB

Definition at line 67 of file win_glimp.cpp.

PFNWGLGETPIXELFORMATATTRIBFVARBPROC wglGetPixelFormatAttribfvARB

Definition at line 62 of file win_glimp.cpp.

PFNWGLGETPIXELFORMATATTRIBIVARBPROC wglGetPixelFormatAttribivARB

Definition at line 61 of file win_glimp.cpp.

PFNWGLQUERYPBUFFERARBPROC wglQueryPbufferARB

Definition at line 70 of file win_glimp.cpp.

PFNWGLRELEASEPBUFFERDCARBPROC wglReleasePbufferDCARB

Definition at line 68 of file win_glimp.cpp.

PFNWGLRELEASETEXIMAGEARBPROC wglReleaseTexImageARB

Definition at line 74 of file win_glimp.cpp.

PFNWGLSETPBUFFERATTRIBARBPROC wglSetPbufferAttribARB

Definition at line 75 of file win_glimp.cpp.

PFNWGLSWAPINTERVALEXTPROC wglSwapIntervalEXT

Definition at line 58 of file win_glimp.cpp.