if (ctx == NULL)
goto no_ctx;
- ctx->hdc = hdc;
+ ctx->hDrawDC = hdc;
ctx->hReadDC = hdc;
ctx->iPixelFormat = iPixelFormat;
ctx->shared = shareCtx != NULL;
if (!ctx)
return NULL;
- return ctx->hdc;
+ return ctx->hDrawDC;
}
HDC
}
BOOL
-stw_make_current(HDC hdc, HDC hReadDC, DHGLRC dhglrc)
+stw_make_current(HDC hDrawDC, HDC hReadDC, DHGLRC dhglrc)
{
struct stw_context *old_ctx = NULL;
struct stw_context *ctx = NULL;
old_ctx = stw_current_context();
if (old_ctx != NULL) {
if (old_ctx->dhglrc == dhglrc) {
- if (old_ctx->hdc == hdc && old_ctx->hReadDC == hReadDC) {
+ if (old_ctx->hDrawDC == hDrawDC && old_ctx->hReadDC == hReadDC) {
/* Return if already current. */
return TRUE;
}
}
/* This call locks fb's mutex */
- fb = stw_framebuffer_from_hdc( hdc );
+ fb = stw_framebuffer_from_hdc( hDrawDC );
if (fb) {
stw_framebuffer_update(fb);
}
* pixel format in some cases, so we must create a framebuffer for
* those here.
*/
- int iPixelFormat = GetPixelFormat(hdc);
+ int iPixelFormat = GetPixelFormat(hDrawDC);
if (iPixelFormat)
- fb = stw_framebuffer_create( hdc, iPixelFormat );
+ fb = stw_framebuffer_create( hDrawDC, iPixelFormat );
if (!fb)
goto fail;
}
}
/* Bind the new framebuffer */
- ctx->hdc = hdc;
+ ctx->hDrawDC = hDrawDC;
ctx->hReadDC = hReadDC;
struct stw_framebuffer *old_fb = ctx->current_framebuffer;
struct st_context_iface *st;
DHGLRC dhglrc;
int iPixelFormat;
- HDC hdc;
+ HDC hDrawDC;
HDC hReadDC;
BOOL shared;
HDC stw_get_current_read_dc( void );
-BOOL stw_make_current( HDC hdc, HDC hReadDC, DHGLRC dhglrc );
+BOOL stw_make_current( HDC hDrawDC, HDC hReadDC, DHGLRC dhglrc );
void stw_notify_current_locked( struct stw_framebuffer *fb );