1 /* User-based primary surface driver
3 * Copyright 2000-2001 TransGaming Technologies Inc.
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
10 * This library 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 GNU
13 * Lesser General Public License for more details.
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, write to the Free Software
17 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
27 #include "wine/debug.h"
28 #include "ddraw_private.h"
29 #include "dsurface/main.h"
30 #include "dsurface/dib.h"
31 #include "dsurface/user.h"
32 #include "dsurface/wndproc.h"
34 WINE_DEFAULT_DEBUG_CHANNEL(ddraw
);
36 /* if you use OWN_WINDOW, don't use SYNC_UPDATE, or you may get trouble */
37 /* #define SYNC_UPDATE */
39 * FIXME: This does not work any more because the created window has its own
40 * thread queue that cannot be manipulated by application threads.
45 static void User_create_own_window(IDirectDrawSurfaceImpl
* This
);
46 static void User_destroy_own_window(IDirectDrawSurfaceImpl
* This
);
49 static DWORD CALLBACK
User_update_thread(LPVOID
);
51 static void User_copy_to_screen(IDirectDrawSurfaceImpl
* This
, LPCRECT rc
);
52 static void User_copy_from_screen(IDirectDrawSurfaceImpl
* This
, LPCRECT rc
);
54 static HWND
get_display_window(IDirectDrawSurfaceImpl
* This
, LPPOINT pt
);
56 static ICOM_VTABLE(IDirectDrawSurface7
) User_IDirectDrawSurface7_VTable
;
59 User_DirectDrawSurface_Construct(IDirectDrawSurfaceImpl
* This
,
61 const DDSURFACEDESC2
* pDDSD
)
63 USER_PRIV_VAR(priv
, This
);
66 TRACE("(%p,%p,%p)\n",This
,pDD
,pDDSD
);
67 hr
= DIB_DirectDrawSurface_Construct(This
, pDD
, pDDSD
);
68 if (FAILED(hr
)) return hr
;
70 ICOM_INIT_INTERFACE(This
, IDirectDrawSurface7
,
71 User_IDirectDrawSurface7_VTable
);
73 This
->final_release
= User_DirectDrawSurface_final_release
;
74 This
->duplicate_surface
= User_DirectDrawSurface_duplicate_surface
;
76 This
->lock_update
= User_DirectDrawSurface_lock_update
;
77 This
->unlock_update
= User_DirectDrawSurface_unlock_update
;
79 This
->flip_data
= User_DirectDrawSurface_flip_data
;
80 This
->flip_update
= User_DirectDrawSurface_flip_update
;
82 This
->get_dc
= User_DirectDrawSurface_get_dc
;
83 This
->release_dc
= User_DirectDrawSurface_release_dc
;
85 This
->set_palette
= User_DirectDrawSurface_set_palette
;
86 This
->update_palette
= User_DirectDrawSurface_update_palette
;
88 This
->get_gamma_ramp
= User_DirectDrawSurface_get_gamma_ramp
;
89 This
->set_gamma_ramp
= User_DirectDrawSurface_set_gamma_ramp
;
91 This
->get_display_window
= User_DirectDrawSurface_get_display_window
;
93 if (This
->surface_desc
.ddsCaps
.dwCaps
& DDSCAPS_PRIMARYSURFACE
)
96 DirectDrawSurface_RegisterClass();
99 InitializeCriticalSection(&priv
->user
.crit
);
100 priv
->user
.refresh_event
= CreateEventA(NULL
, TRUE
, FALSE
, NULL
);
101 priv
->user
.update_event
= CreateEventA(NULL
, FALSE
, FALSE
, NULL
);
102 priv
->user
.update_thread
= CreateThread(NULL
, 0, User_update_thread
, This
, 0, NULL
);
104 if (This
->ddraw_owner
->cooperative_level
& DDSCL_FULLSCREEN
) {
105 /* wait for window creation (or update thread destruction) */
106 while (WaitForMultipleObjects(1, &priv
->user
.update_thread
, FALSE
, 100) == WAIT_TIMEOUT
)
107 if (This
->more
.lpDDRAWReserved
) break;
108 if (!This
->more
.lpDDRAWReserved
) {
109 ERR("window creation failed\n");
115 User_create_own_window(This
);
118 if (!This
->more
.lpDDRAWReserved
)
119 This
->more
.lpDDRAWReserved
= (LPVOID
)pDD
->window
;
122 return DIB_DirectDrawSurface_alloc_dc(This
, &priv
->user
.cached_dc
);
126 User_DirectDrawSurface_Create(IDirectDrawImpl
*pDD
,
127 const DDSURFACEDESC2
*pDDSD
,
128 LPDIRECTDRAWSURFACE7
*ppSurf
,
131 IDirectDrawSurfaceImpl
* This
;
133 assert(pUnkOuter
== NULL
);
135 This
= HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY
,
136 sizeof(*This
) + sizeof(User_DirectDrawSurfaceImpl
));
137 if (This
== NULL
) return E_OUTOFMEMORY
;
139 This
->private = (User_DirectDrawSurfaceImpl
*)(This
+1);
141 hr
= User_DirectDrawSurface_Construct(This
, pDD
, pDDSD
);
143 HeapFree(GetProcessHeap(), 0, This
);
145 *ppSurf
= ICOM_INTERFACE(This
, IDirectDrawSurface7
);
150 void User_DirectDrawSurface_final_release(IDirectDrawSurfaceImpl
* This
)
152 USER_PRIV_VAR(priv
, This
);
154 if (This
->surface_desc
.ddsCaps
.dwCaps
& DDSCAPS_PRIMARYSURFACE
)
157 HANDLE event
= priv
->user
.update_event
;
158 priv
->user
.update_event
= 0;
160 TRACE("waiting for update thread to terminate...\n");
162 /* dispatch any waiting sendmessages */
165 PeekMessageA(&msg
, 0, 0, 0, PM_NOREMOVE
);
167 /* to avoid deadlocks, allow SendMessages from update thread
168 * through while we wait for it */
169 while (MsgWaitForMultipleObjects(1, &priv
->user
.update_thread
, FALSE
,
170 INFINITE
, QS_SENDMESSAGE
) == WAIT_OBJECT_0
+1)
173 PeekMessageA(&msg
, 0, 0, 0, PM_NOREMOVE
);
176 WaitForSingleObject(priv
->user
.update_thread
,INFINITE
);
178 TRACE("update thread terminated\n");
180 CloseHandle(priv
->user
.update_thread
);
181 CloseHandle(priv
->user
.refresh_event
);
182 DeleteCriticalSection(&priv
->user
.crit
);
185 User_destroy_own_window(This
);
188 This
->more
.lpDDRAWReserved
= 0;
190 DirectDrawSurface_UnregisterClass();
193 DIB_DirectDrawSurface_free_dc(This
, priv
->user
.cached_dc
);
194 DIB_DirectDrawSurface_final_release(This
);
197 static int User_DirectDrawSurface_init_wait(IDirectDrawSurfaceImpl
* This
)
199 USER_PRIV_VAR(priv
, This
);
201 EnterCriticalSection(&priv
->user
.crit
);
202 priv
->user
.wait_count
++;
203 need_wait
= priv
->user
.in_refresh
;
204 LeaveCriticalSection(&priv
->user
.crit
);
208 static void User_DirectDrawSurface_end_wait(IDirectDrawSurfaceImpl
* This
)
210 USER_PRIV_VAR(priv
, This
);
211 EnterCriticalSection(&priv
->user
.crit
);
212 if (!--priv
->user
.wait_count
)
213 ResetEvent(priv
->user
.refresh_event
);
214 LeaveCriticalSection(&priv
->user
.crit
);
217 static void User_DirectDrawSurface_wait_update(IDirectDrawSurfaceImpl
* This
)
219 USER_PRIV_VAR(priv
, This
);
220 if (priv
->user
.in_refresh
) {
221 if (User_DirectDrawSurface_init_wait(This
))
222 WaitForSingleObject(priv
->user
.refresh_event
, 2);
223 User_DirectDrawSurface_end_wait(This
);
227 void User_DirectDrawSurface_lock_update(IDirectDrawSurfaceImpl
* This
,
228 LPCRECT pRect
, DWORD dwFlags
)
231 if (!(dwFlags
& DDLOCK_WRITEONLY
))
232 User_copy_from_screen(This
, pRect
);
234 if (dwFlags
& DDLOCK_WAIT
) User_DirectDrawSurface_wait_update(This
);
237 This
->lastlockrect
= *pRect
;
239 This
->lastlockrect
.left
= This
->lastlockrect
.right
= 0;
243 void User_DirectDrawSurface_unlock_update(IDirectDrawSurfaceImpl
* This
,
246 if (This
->surface_desc
.ddsCaps
.dwCaps
& DDSCAPS_PRIMARYSURFACE
)
249 User_copy_to_screen(This
, pRect
);
251 USER_PRIV_VAR(priv
, This
);
252 SetEvent(priv
->user
.update_event
);
257 void User_DirectDrawSurface_set_palette(IDirectDrawSurfaceImpl
* This
,
258 IDirectDrawPaletteImpl
* pal
)
260 USER_PRIV_VAR(priv
, This
);
263 FIXME("selecting null palette\n");
264 /* I don't think selecting GDI object 0 will work, we should select
265 * the original palette, returned by the first SelectPalette */
266 SelectPalette(priv
->user
.cached_dc
, 0, FALSE
);
270 SelectPalette(priv
->user
.cached_dc
, pal
->hpal
, FALSE
);
272 DIB_DirectDrawSurface_set_palette(This
, pal
);
275 void User_DirectDrawSurface_update_palette(IDirectDrawSurfaceImpl
* This
,
276 IDirectDrawPaletteImpl
* pal
,
277 DWORD dwStart
, DWORD dwCount
,
278 LPPALETTEENTRY palent
)
281 USER_PRIV_VAR(priv
, This
);
284 DIB_DirectDrawSurface_update_palette(This
, pal
, dwStart
, dwCount
, palent
);
285 /* FIXME: realize palette on display window */
288 /* with async updates, it's probably cool to force an update */
289 SetEvent(priv
->user
.update_event
);
293 HRESULT
User_DirectDrawSurface_duplicate_surface(IDirectDrawSurfaceImpl
* This
,
294 LPDIRECTDRAWSURFACE7
* ppDup
)
296 return User_DirectDrawSurface_Create(This
->ddraw_owner
,
297 &This
->surface_desc
, ppDup
, NULL
);
300 BOOL
User_DirectDrawSurface_flip_data(IDirectDrawSurfaceImpl
* front
,
301 IDirectDrawSurfaceImpl
* back
,
304 USER_PRIV_VAR(front_priv
, front
);
305 USER_PRIV_VAR(back_priv
, back
);
309 tmp
= front_priv
->user
.cached_dc
;
310 front_priv
->user
.cached_dc
= back_priv
->user
.cached_dc
;
311 back_priv
->user
.cached_dc
= tmp
;
314 return DIB_DirectDrawSurface_flip_data(front
, back
, dwFlags
);
317 void User_DirectDrawSurface_flip_update(IDirectDrawSurfaceImpl
* This
, DWORD dwFlags
)
320 This
->lastlockrect
.left
= This
->lastlockrect
.right
= 0;
321 assert(This
->surface_desc
.ddsCaps
.dwCaps
& DDSCAPS_PRIMARYSURFACE
);
322 User_copy_to_screen(This
,NULL
);
324 USER_PRIV_VAR(priv
, This
);
325 assert(This
->surface_desc
.ddsCaps
.dwCaps
& DDSCAPS_PRIMARYSURFACE
);
326 if (dwFlags
& DDFLIP_WAIT
) User_DirectDrawSurface_wait_update(This
);
327 This
->lastlockrect
.left
= This
->lastlockrect
.right
= 0;
328 SetEvent(priv
->user
.update_event
);
332 HRESULT
User_DirectDrawSurface_get_dc(IDirectDrawSurfaceImpl
* This
, HDC
* phDC
)
334 USER_PRIV_VAR(priv
, This
);
336 *phDC
= priv
->user
.cached_dc
;
340 HRESULT
User_DirectDrawSurface_release_dc(IDirectDrawSurfaceImpl
* This
,
346 HRESULT
User_DirectDrawSurface_get_gamma_ramp(IDirectDrawSurfaceImpl
* This
,
348 LPDDGAMMARAMP lpGammaRamp
)
350 if (This
->surface_desc
.ddsCaps
.dwCaps
& DDSCAPS_PRIMARYSURFACE
)
356 hDisplayWnd
= get_display_window(This
, &offset
);
357 hDisplayDC
= GetDCEx(hDisplayWnd
, 0, DCX_CLIPSIBLINGS
|DCX_CACHE
);
358 hr
= GetDeviceGammaRamp(hDisplayDC
, lpGammaRamp
) ? DD_OK
: DDERR_UNSUPPORTED
;
359 ReleaseDC(hDisplayWnd
, hDisplayDC
);
362 return Main_DirectDrawSurface_get_gamma_ramp(This
, dwFlags
, lpGammaRamp
);
365 HRESULT
User_DirectDrawSurface_set_gamma_ramp(IDirectDrawSurfaceImpl
* This
,
367 LPDDGAMMARAMP lpGammaRamp
)
369 if (This
->surface_desc
.ddsCaps
.dwCaps
& DDSCAPS_PRIMARYSURFACE
)
375 hDisplayWnd
= get_display_window(This
, &offset
);
376 hDisplayDC
= GetDCEx(hDisplayWnd
, 0, DCX_CLIPSIBLINGS
|DCX_CACHE
);
377 hr
= SetDeviceGammaRamp(hDisplayDC
, lpGammaRamp
) ? DD_OK
: DDERR_UNSUPPORTED
;
378 ReleaseDC(hDisplayWnd
, hDisplayDC
);
381 return Main_DirectDrawSurface_set_gamma_ramp(This
, dwFlags
, lpGammaRamp
);
384 /* Returns the window that hosts the display.
385 * *pt is set to the upper left position of the window relative to the
386 * upper left corner of the surface. */
387 static HWND
get_display_window(IDirectDrawSurfaceImpl
* This
, LPPOINT pt
)
389 memset(pt
, 0, sizeof(*pt
));
391 if (This
->ddraw_owner
->cooperative_level
& DDSCL_FULLSCREEN
)
394 USER_PRIV_VAR(priv
, This
);
396 SetWindowPos(priv
->user
.window
, HWND_TOP
, 0, 0, 0, 0,
397 SWP_DEFERERASE
|SWP_NOACTIVATE
|SWP_NOCOPYBITS
|SWP_NOMOVE
|
398 SWP_NOREDRAW
|SWP_NOSENDCHANGING
|SWP_NOSIZE
);
400 return priv
->user
.window
;
402 return This
->ddraw_owner
->window
;
407 if (This
->clipper
!= NULL
)
409 /* looks silly, but since we don't have the clipper locked */
410 HWND hWnd
= This
->clipper
->hWnd
;
414 ClientToScreen(hWnd
, pt
);
419 static BOOL warn
= 0;
420 if (!warn
++) FIXME("clipper clip lists not supported\n");
422 return GetDesktopWindow();
427 static BOOL warn
= 0;
428 if (!warn
++) WARN("hosting on root\n");
430 return GetDesktopWindow();
435 HWND
User_DirectDrawSurface_get_display_window(IDirectDrawSurfaceImpl
* This
)
438 return get_display_window(This
, &offset
);
442 static void User_create_own_window(IDirectDrawSurfaceImpl
* This
)
444 USER_PRIV_VAR(priv
, This
);
446 if (This
->ddraw_owner
->cooperative_level
& DDSCL_FULLSCREEN
)
448 priv
->user
.window
= CreateWindowExA(WS_EX_TOPMOST
|
451 "WINE_DDRAW", "DirectDraw",
454 This
->surface_desc
.dwWidth
,
455 This
->surface_desc
.dwHeight
,
458 This
->more
.lpDDRAWReserved
= (LPVOID
)priv
->user
.window
;
459 SetWindowPos(priv
->user
.window
, HWND_TOP
, 0, 0, 0, 0,
460 SWP_DEFERERASE
|SWP_NOACTIVATE
|SWP_NOCOPYBITS
|SWP_NOMOVE
|
461 SWP_NOREDRAW
|SWP_NOSENDCHANGING
|SWP_NOSIZE
|SWP_SHOWWINDOW
);
462 UpdateWindow(priv
->user
.window
);
466 static void User_destroy_own_window(IDirectDrawSurfaceImpl
* This
)
468 USER_PRIV_VAR(priv
, This
);
470 if (priv
->user
.window
)
472 SetWindowPos(priv
->user
.window
, 0, 0, 0, 0, 0,
473 SWP_DEFERERASE
|SWP_NOACTIVATE
|SWP_NOCOPYBITS
|SWP_NOMOVE
|SWP_NOZORDER
|
474 SWP_NOREDRAW
|SWP_NOSENDCHANGING
|SWP_NOSIZE
|SWP_HIDEWINDOW
);
475 This
->more
.lpDDRAWReserved
= NULL
;
476 DestroyWindow(priv
->user
.window
);
477 priv
->user
.window
= 0;
483 static DWORD CALLBACK
User_update_thread(LPVOID arg
)
485 IDirectDrawSurfaceImpl
*This
= (IDirectDrawSurfaceImpl
*)arg
;
486 USER_PRIV_VAR(priv
, This
);
487 volatile DWORD
*pActive
= (volatile DWORD
*)&priv
->user
.update_event
;
488 HANDLE event
= *pActive
;
491 User_create_own_window(This
);
494 /* the point of this is that many games lock the primary surface
495 * multiple times per frame; this thread will then simply copy as
496 * often as it can without keeping the main thread waiting for
497 * each unlock, thus keeping the frame rate high */
500 DWORD ret
= MsgWaitForMultipleObjects(1, &event
, FALSE
, INFINITE
, QS_ALLINPUT
);
503 while (PeekMessageA(&msg
, 0, 0, 0, PM_REMOVE
))
505 switch (msg
.message
) {
507 DispatchMessageA(&msg
);
510 /* since we risk getting keyboard messages posted to us,
511 * repost posted messages to cooperative window */
512 PostMessageA(This
->ddraw_owner
->window
, msg
.message
, msg
.wParam
, msg
.lParam
);
516 DWORD ret
= WaitForSingleObject(event
, INFINITE
);
518 if (ret
== WAIT_OBJECT_0
)
521 priv
->user
.in_refresh
= TRUE
;
522 User_copy_to_screen(This
, NULL
);
523 EnterCriticalSection(&priv
->user
.crit
);
524 priv
->user
.in_refresh
= FALSE
;
525 if (priv
->user
.wait_count
)
526 SetEvent(priv
->user
.refresh_event
);
527 LeaveCriticalSection(&priv
->user
.crit
);
531 else if (ret
!= WAIT_OBJECT_0
+1) break;
534 SetEvent(priv
->user
.refresh_event
);
536 User_destroy_own_window(This
);
543 static void User_copy_to_screen(IDirectDrawSurfaceImpl
* This
, LPCRECT rc
)
545 if (This
->surface_desc
.ddsCaps
.dwCaps
& DDSCAPS_PRIMARYSURFACE
)
553 if (FAILED(This
->get_dc(This
, &hSurfaceDC
)))
556 hDisplayWnd
= get_display_window(This
, &offset
);
557 hDisplayDC
= GetDCEx(hDisplayWnd
, 0, DCX_CLIPSIBLINGS
|DCX_CACHE
);
559 /* FIXME: this doesn't work... if users really want to run
560 * X in 8bpp, then we need to call directly into display.drv
561 * (or Wine's equivalent), and force a private colormap
562 * without default entries. */
564 SelectPalette(hDisplayDC
, This
->palette
->hpal
, FALSE
);
565 RealizePalette(hDisplayDC
); /* sends messages => deadlocks */
569 drawrect
.right
= This
->surface_desc
.dwWidth
;
571 drawrect
.bottom
= This
->surface_desc
.dwHeight
;
575 HWND hwnd
= This
->clipper
->hWnd
;
576 if (hwnd
&& GetClientRect(hwnd
,&xrc
)) {
577 OffsetRect(&xrc
,offset
.x
,offset
.y
);
578 IntersectRect(&drawrect
,&drawrect
,&xrc
);
582 IntersectRect(&drawrect
,&drawrect
,rc
);
584 /* Only use this if the caller did not pass a rectangle, since
585 * due to double locking this could be the wrong one ... */
586 if (This
->lastlockrect
.left
!= This
->lastlockrect
.right
)
587 IntersectRect(&drawrect
,&drawrect
,&This
->lastlockrect
);
590 drawrect
.left
-offset
.x
, drawrect
.top
-offset
.y
,
591 drawrect
.right
-drawrect
.left
, drawrect
.bottom
-drawrect
.top
,
593 drawrect
.left
, drawrect
.top
,
596 ReleaseDC(hDisplayWnd
, hDisplayDC
);
600 static void User_copy_from_screen(IDirectDrawSurfaceImpl
* This
, LPCRECT rc
)
602 if (This
->surface_desc
.ddsCaps
.dwCaps
& DDSCAPS_PRIMARYSURFACE
)
605 HWND hDisplayWnd
= get_display_window(This
, &offset
);
606 HDC hDisplayDC
= GetDC(hDisplayWnd
);
610 drawrect
.right
= This
->surface_desc
.dwWidth
;
612 drawrect
.bottom
= This
->surface_desc
.dwHeight
;
614 IntersectRect(&drawrect
,&drawrect
,rc
);
617 drawrect
.left
, drawrect
.top
,
618 drawrect
.right
-drawrect
.left
, drawrect
.bottom
-drawrect
.top
,
620 drawrect
.left
+offset
.x
, drawrect
.top
+offset
.y
,
623 ReleaseDC(hDisplayWnd
, hDisplayDC
);
627 static ICOM_VTABLE(IDirectDrawSurface7
) User_IDirectDrawSurface7_VTable
=
629 Main_DirectDrawSurface_QueryInterface
,
630 Main_DirectDrawSurface_AddRef
,
631 Main_DirectDrawSurface_Release
,
632 Main_DirectDrawSurface_AddAttachedSurface
,
633 Main_DirectDrawSurface_AddOverlayDirtyRect
,
634 DIB_DirectDrawSurface_Blt
,
635 Main_DirectDrawSurface_BltBatch
,
636 DIB_DirectDrawSurface_BltFast
,
637 Main_DirectDrawSurface_DeleteAttachedSurface
,
638 Main_DirectDrawSurface_EnumAttachedSurfaces
,
639 Main_DirectDrawSurface_EnumOverlayZOrders
,
640 Main_DirectDrawSurface_Flip
,
641 Main_DirectDrawSurface_GetAttachedSurface
,
642 Main_DirectDrawSurface_GetBltStatus
,
643 Main_DirectDrawSurface_GetCaps
,
644 Main_DirectDrawSurface_GetClipper
,
645 Main_DirectDrawSurface_GetColorKey
,
646 Main_DirectDrawSurface_GetDC
,
647 Main_DirectDrawSurface_GetFlipStatus
,
648 Main_DirectDrawSurface_GetOverlayPosition
,
649 Main_DirectDrawSurface_GetPalette
,
650 Main_DirectDrawSurface_GetPixelFormat
,
651 Main_DirectDrawSurface_GetSurfaceDesc
,
652 Main_DirectDrawSurface_Initialize
,
653 Main_DirectDrawSurface_IsLost
,
654 Main_DirectDrawSurface_Lock
,
655 Main_DirectDrawSurface_ReleaseDC
,
656 DIB_DirectDrawSurface_Restore
,
657 Main_DirectDrawSurface_SetClipper
,
658 Main_DirectDrawSurface_SetColorKey
,
659 Main_DirectDrawSurface_SetOverlayPosition
,
660 Main_DirectDrawSurface_SetPalette
,
661 Main_DirectDrawSurface_Unlock
,
662 Main_DirectDrawSurface_UpdateOverlay
,
663 Main_DirectDrawSurface_UpdateOverlayDisplay
,
664 Main_DirectDrawSurface_UpdateOverlayZOrder
,
665 Main_DirectDrawSurface_GetDDInterface
,
666 Main_DirectDrawSurface_PageLock
,
667 Main_DirectDrawSurface_PageUnlock
,
668 DIB_DirectDrawSurface_SetSurfaceDesc
,
669 Main_DirectDrawSurface_SetPrivateData
,
670 Main_DirectDrawSurface_GetPrivateData
,
671 Main_DirectDrawSurface_FreePrivateData
,
672 Main_DirectDrawSurface_GetUniquenessValue
,
673 Main_DirectDrawSurface_ChangeUniquenessValue
,
674 Main_DirectDrawSurface_SetPriority
,
675 Main_DirectDrawSurface_GetPriority
,
676 Main_DirectDrawSurface_SetLOD
,
677 Main_DirectDrawSurface_GetLOD