ReactOS  0.4.14-dev-317-g96040ec
surface.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

ULONG WINAPI Main_DDrawSurface_AddRef (LPDDRAWI_DDRAWSURFACE_INT)
 
ULONG WINAPI Main_DDrawSurface_Release (LPDDRAWI_DDRAWSURFACE_INT)
 
HRESULT WINAPI Main_DDrawSurface_QueryInterface (LPDDRAWI_DDRAWSURFACE_INT, REFIID, LPVOID *)
 
HRESULT WINAPI Main_DDrawSurface_Blt (LPDDRAWI_DDRAWSURFACE_INT, LPRECT, LPDDRAWI_DDRAWSURFACE_INT, LPRECT, DWORD, LPDDBLTFX)
 
HRESULT WINAPI Main_DDrawSurface_BltBatch (LPDDRAWI_DDRAWSURFACE_INT, LPDDBLTBATCH, DWORD, DWORD)
 
HRESULT WINAPI Main_DDrawSurface_BltFast (LPDDRAWI_DDRAWSURFACE_INT, DWORD, DWORD, LPDDRAWI_DDRAWSURFACE_INT, LPRECT, DWORD)
 
HRESULT WINAPI Main_DDrawSurface_DeleteAttachedSurface (LPDDRAWI_DDRAWSURFACE_INT, DWORD, LPDDRAWI_DDRAWSURFACE_INT)
 
HRESULT WINAPI Main_DDrawSurface_EnumAttachedSurfaces (LPDDRAWI_DDRAWSURFACE_INT, LPVOID, LPDDENUMSURFACESCALLBACK7)
 
HRESULT WINAPI Main_DDrawSurface_EnumOverlayZOrders (LPDDRAWI_DDRAWSURFACE_INT, DWORD, LPVOID, LPDDENUMSURFACESCALLBACK7)
 
HRESULT WINAPI Main_DDrawSurface_Flip (LPDDRAWI_DDRAWSURFACE_INT, LPDDRAWI_DDRAWSURFACE_INT, DWORD)
 
HRESULT WINAPI Main_DDrawSurface_FreePrivateData (LPDDRAWI_DDRAWSURFACE_INT, REFGUID)
 
HRESULT WINAPI Main_DDrawSurface_GetAttachedSurface (LPDDRAWI_DDRAWSURFACE_INT, LPDDSCAPS2, LPDDRAWI_DDRAWSURFACE_INT *)
 
HRESULT WINAPI Main_DDrawSurface_GetBltStatus (LPDDRAWI_DDRAWSURFACE_INT, DWORD dwFlags)
 
HRESULT WINAPI Main_DDrawSurface_GetCaps (LPDDRAWI_DDRAWSURFACE_INT, LPDDSCAPS2 pCaps)
 
HRESULT WINAPI Main_DDrawSurface_GetClipper (LPDDRAWI_DDRAWSURFACE_INT, LPDIRECTDRAWCLIPPER *)
 
HRESULT WINAPI Main_DDrawSurface_GetColorKey (LPDDRAWI_DDRAWSURFACE_INT, DWORD, LPDDCOLORKEY)
 
HRESULT WINAPI Main_DDrawSurface_GetDC (LPDDRAWI_DDRAWSURFACE_INT, HDC *)
 
HRESULT WINAPI Main_DDrawSurface_GetDDInterface (LPDDRAWI_DDRAWSURFACE_INT, LPVOID *)
 
HRESULT WINAPI Main_DDrawSurface_GetFlipStatus (LPDDRAWI_DDRAWSURFACE_INT, DWORD)
 
HRESULT WINAPI Main_DDrawSurface_GetLOD (LPDDRAWI_DDRAWSURFACE_INT, LPDWORD)
 
HRESULT WINAPI Main_DDrawSurface_GetOverlayPosition (LPDDRAWI_DDRAWSURFACE_INT, LPLONG, LPLONG)
 
HRESULT WINAPI Main_DDrawSurface_GetPalette (LPDDRAWI_DDRAWSURFACE_INT, LPDIRECTDRAWPALETTE *)
 
HRESULT WINAPI Main_DDrawSurface_GetPixelFormat (LPDDRAWI_DDRAWSURFACE_INT, LPDDPIXELFORMAT)
 
HRESULT WINAPI Main_DDrawSurface_GetPriority (LPDDRAWI_DDRAWSURFACE_INT, LPDWORD)
 
HRESULT WINAPI Main_DDrawSurface_GetPrivateData (LPDDRAWI_DDRAWSURFACE_INT, REFGUID, LPVOID, LPDWORD)
 
HRESULT WINAPI Main_DDrawSurface_GetSurfaceDesc (LPDDRAWI_DDRAWSURFACE_INT, LPDDSURFACEDESC2)
 
HRESULT WINAPI Main_DDrawSurface_GetUniquenessValue (LPDDRAWI_DDRAWSURFACE_INT, LPDWORD)
 
HRESULT WINAPI Main_DDrawSurface_IsLost (LPDDRAWI_DDRAWSURFACE_INT)
 
HRESULT WINAPI Main_DDrawSurface_PageLock (LPDDRAWI_DDRAWSURFACE_INT, DWORD)
 
HRESULT WINAPI Main_DDrawSurface_PageUnlock (LPDDRAWI_DDRAWSURFACE_INT, DWORD)
 
HRESULT WINAPI Main_DDrawSurface_ReleaseDC (LPDDRAWI_DDRAWSURFACE_INT, HDC)
 
HRESULT WINAPI Main_DDrawSurface_SetClipper (LPDDRAWI_DDRAWSURFACE_INT, LPDIRECTDRAWCLIPPER)
 
HRESULT WINAPI Main_DDrawSurface_SetColorKey (LPDDRAWI_DDRAWSURFACE_INT, DWORD, LPDDCOLORKEY)
 
HRESULT WINAPI Main_DDrawSurface_SetOverlayPosition (LPDDRAWI_DDRAWSURFACE_INT, LONG, LONG)
 
HRESULT WINAPI Main_DDrawSurface_SetPalette (LPDDRAWI_DDRAWSURFACE_INT, LPDIRECTDRAWPALETTE)
 
HRESULT WINAPI Main_DDrawSurface_SetPriority (LPDDRAWI_DDRAWSURFACE_INT, DWORD)
 
HRESULT WINAPI Main_DDrawSurface_SetPrivateData (LPDDRAWI_DDRAWSURFACE_INT, REFGUID, LPVOID, DWORD, DWORD)
 
HRESULT WINAPI Main_DDrawSurface_UpdateOverlayDisplay (LPDDRAWI_DDRAWSURFACE_INT, DWORD)
 
HRESULT WINAPI Main_DDrawSurface_UpdateOverlayZOrder (LPDDRAWI_DDRAWSURFACE_INT, DWORD, LPDDRAWI_DDRAWSURFACE_INT)
 
HRESULT WINAPI Main_DDrawSurface_SetSurfaceDesc (LPDDRAWI_DDRAWSURFACE_INT, DDSURFACEDESC2 *, DWORD)
 
HRESULT WINAPI Main_DDrawSurface_SetLOD (LPDDRAWI_DDRAWSURFACE_INT, DWORD)
 
HRESULT WINAPI Main_DDrawSurface_Unlock (LPDDRAWI_DDRAWSURFACE_INT, LPRECT)
 
HRESULT WINAPI Main_DDrawSurface_Initialize (LPDDRAWI_DDRAWSURFACE_INT, LPDIRECTDRAW, LPDDSURFACEDESC2)
 
HRESULT WINAPI Main_DDrawSurface_Lock (LPDDRAWI_DDRAWSURFACE_INT, LPRECT, LPDDSURFACEDESC2, DWORD, HANDLE)
 
HRESULT WINAPI Main_DDrawSurface_Restore (LPDDRAWI_DDRAWSURFACE_INT)
 
HRESULT WINAPI Main_DDrawSurface_UpdateOverlay (LPDDRAWI_DDRAWSURFACE_INT, LPRECT, LPDDRAWI_DDRAWSURFACE_INT, LPRECT, DWORD, LPDDOVERLAYFX)
 
HRESULT WINAPI Main_DDrawSurface_ChangeUniquenessValue (LPDDRAWI_DDRAWSURFACE_INT iface)
 
HRESULT WINAPI Main_DDrawSurface_AddAttachedSurface (LPDDRAWI_DDRAWSURFACE_INT iface, LPDDRAWI_DDRAWSURFACE_INT pAttach)
 
HRESULT WINAPI Main_DDrawSurface_AddOverlayDirtyRect (LPDDRAWI_DDRAWSURFACE_INT iface, LPRECT pRect)
 
DWORD CALLBACK HelDdDestroyDriver (LPDDHAL_DESTROYDRIVERDATA lpDestroyDriver)
 
DWORD CALLBACK HelDdCreateSurface (LPDDHAL_CREATESURFACEDATA lpCreateSurface)
 
DWORD CALLBACK HelDdSetColorKey (LPDDHAL_DRVSETCOLORKEYDATA lpSetColorKey)
 
DWORD CALLBACK HelDdSetMode (LPDDHAL_SETMODEDATA SetMode)
 
DWORD CALLBACK HelDdWaitForVerticalBlank (LPDDHAL_WAITFORVERTICALBLANKDATA lpWaitForVerticalBlank)
 
DWORD CALLBACK HelDdCanCreateSurface (LPDDHAL_CANCREATESURFACEDATA lpCanCreateSurface)
 
DWORD CALLBACK HelDdCreatePalette (LPDDHAL_CREATEPALETTEDATA lpCreatePalette)
 
DWORD CALLBACK HelDdGetScanLine (LPDDHAL_GETSCANLINEDATA lpGetScanLine)
 
DWORD CALLBACK HelDdSetExclusiveMode (LPDDHAL_SETEXCLUSIVEMODEDATA lpSetExclusiveMode)
 
DWORD CALLBACK HelDdFlipToGDISurface (LPDDHAL_FLIPTOGDISURFACEDATA lpFlipToGDISurface)
 

Function Documentation

◆ HelDdCanCreateSurface()

DWORD CALLBACK HelDdCanCreateSurface ( LPDDHAL_CANCREATESURFACEDATA  lpCanCreateSurface)

Definition at line 72 of file callbacks_dd_hel.c.

73 {
74  DX_STUB;
75 }
#define DX_STUB
Definition: rosdraw.h:224

Referenced by StartDirectDrawHel().

◆ HelDdCreatePalette()

DWORD CALLBACK HelDdCreatePalette ( LPDDHAL_CREATEPALETTEDATA  lpCreatePalette)

Definition at line 77 of file callbacks_dd_hel.c.

78 {
79  DDRAWI_DDRAWPALETTE_GBL* ddPalGbl = lpCreatePalette->lpDDPalette;
80  LOGPALETTE* logPal ;
81  WORD size=1;
82 
83  if(ddPalGbl->dwFlags & DDRAWIPAL_2)
84  size = 2;
85  else if(ddPalGbl->dwFlags & DDRAWIPAL_4)
86  size = 4;
87  else if(ddPalGbl->dwFlags & DDRAWIPAL_16)
88  size = 16;
89  else if(ddPalGbl->dwFlags & DDRAWIPAL_256)
90  size = 256;
91 
92  DxHeapMemAlloc(logPal, sizeof(LOGPALETTE) + size*sizeof(PALETTEENTRY));
93  if(logPal == NULL)
94  {
95  lpCreatePalette->ddRVal = DDERR_OUTOFMEMORY;
96  return DDHAL_DRIVER_HANDLED;
97  }
98 
99  logPal->palVersion = 0x300;
100  logPal->palNumEntries = size;
101  CopyMemory(&logPal->palPalEntry[0], lpCreatePalette->lpColorTable, size*sizeof(PALETTEENTRY));
102 
103  ddPalGbl->hHELGDIPalette = CreatePalette(logPal);
104 
105  if (ddPalGbl->hHELGDIPalette == NULL)
106  {
107  DxHeapMemFree(logPal);
108  lpCreatePalette->ddRVal = DDERR_INVALIDOBJECT;
109  return DDHAL_DRIVER_HANDLED;
110  }
111 
112  DxHeapMemFree(logPal);
113  ddPalGbl->lpColorTable = lpCreatePalette->lpColorTable;
114  ddPalGbl->dwFlags |= DDRAWIPAL_INHEL | DDRAWIPAL_GDI ;
115  lpCreatePalette->ddRVal = DD_OK;
116  return DDHAL_DRIVER_HANDLED;
117 }
#define DDRAWIPAL_GDI
Definition: ddrawi.h:1563
#define DDRAWIPAL_256
Definition: ddrawi.h:1561
#define DDERR_OUTOFMEMORY
Definition: ddraw.h:111
#define DxHeapMemFree(p)
Definition: rosdraw.h:120
LPPALETTEENTRY lpColorTable
Definition: ddrawi.h:1550
WORD palVersion
Definition: wingdi.h:1828
#define DDHAL_DRIVER_HANDLED
Definition: ddrawi.h:321
#define DD_OK
Definition: ddraw.h:186
#define DDERR_INVALIDOBJECT
Definition: ddraw.h:78
#define DDRAWIPAL_16
Definition: ddrawi.h:1562
smooth NULL
Definition: ftsmooth.c:416
LPDDRAWI_DDRAWPALETTE_GBL lpDDPalette
Definition: ddrawi.h:793
LPPALETTEENTRY lpColorTable
Definition: ddrawi.h:794
GLsizeiptr size
Definition: glext.h:5919
HPALETTE WINAPI CreatePalette(_In_reads_(_Inexpressible_(2 *sizeof(WORD)+plpal->palNumEntries *sizeof(PALETTEENTRY))) const LOGPALETTE *)
#define DxHeapMemAlloc(p, m)
Definition: rosdraw.h:113
#define CopyMemory
Definition: winbase.h:1640
unsigned short WORD
Definition: ntddk_ex.h:93
#define DDRAWIPAL_INHEL
Definition: ddrawi.h:1568
#define DDRAWIPAL_2
Definition: ddrawi.h:1572
#define DDRAWIPAL_4
Definition: ddrawi.h:1571
WORD palNumEntries
Definition: wingdi.h:1829

Referenced by StartDirectDrawHel().

◆ HelDdCreateSurface()

DWORD CALLBACK HelDdCreateSurface ( LPDDHAL_CREATESURFACEDATA  lpCreateSurface)

Definition at line 25 of file callbacks_dd_hel.c.

26 {
27  DX_STUB;
28 }
#define DX_STUB
Definition: rosdraw.h:224

Referenced by StartDirectDrawHel().

◆ HelDdDestroyDriver()

DWORD CALLBACK HelDdDestroyDriver ( LPDDHAL_DESTROYDRIVERDATA  lpDestroyDriver)

Definition at line 20 of file callbacks_dd_hel.c.

21 {
22  DX_STUB;
23 }
#define DX_STUB
Definition: rosdraw.h:224

Referenced by StartDirectDrawHel().

◆ HelDdFlipToGDISurface()

DWORD CALLBACK HelDdFlipToGDISurface ( LPDDHAL_FLIPTOGDISURFACEDATA  lpFlipToGDISurface)

Definition at line 133 of file callbacks_dd_hel.c.

134 {
135  DX_STUB;
136 }
#define DX_STUB
Definition: rosdraw.h:224

Referenced by StartDirectDrawHel().

◆ HelDdGetScanLine()

DWORD CALLBACK HelDdGetScanLine ( LPDDHAL_GETSCANLINEDATA  lpGetScanLine)

Definition at line 119 of file callbacks_dd_hel.c.

120 {
121  DX_STUB;
122 }
#define DX_STUB
Definition: rosdraw.h:224

Referenced by StartDirectDrawHel().

◆ HelDdSetColorKey()

DWORD CALLBACK HelDdSetColorKey ( LPDDHAL_DRVSETCOLORKEYDATA  lpSetColorKey)

Definition at line 31 of file callbacks_dd_hel.c.

32 {
33  DX_STUB;
34 }
#define DX_STUB
Definition: rosdraw.h:224

Referenced by StartDirectDrawHel().

◆ HelDdSetExclusiveMode()

DWORD CALLBACK HelDdSetExclusiveMode ( LPDDHAL_SETEXCLUSIVEMODEDATA  lpSetExclusiveMode)

Definition at line 124 of file callbacks_dd_hel.c.

125 {
126  DX_WINDBG_trace();
127  DX_STUB_str("Not implement yet, return DD_OK for not bsod\n");
128  lpSetExclusiveMode->ddRVal = DD_OK;
129 
130  return DDHAL_DRIVER_HANDLED;
131 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB_str(x)
Definition: rosdraw.h:254
#define DDHAL_DRIVER_HANDLED
Definition: ddrawi.h:321
#define DD_OK
Definition: ddraw.h:186

Referenced by StartDirectDrawHel().

◆ HelDdSetMode()

DWORD CALLBACK HelDdSetMode ( LPDDHAL_SETMODEDATA  SetMode)

Definition at line 37 of file callbacks_dd_hel.c.

38 {
39  DEVMODE DevMode;
40 
41  DX_STUB_str("in hel");
42 
43  DevMode.dmSize = (WORD)sizeof(DEVMODE);
44  DevMode.dmDriverExtra = 0;
45 
46  SetMode->ddRVal = DDERR_UNSUPPORTEDMODE;
47 
48  if (EnumDisplaySettingsEx(NULL, SetMode->dwModeIndex, &DevMode, 0 ) != 0)
49  {
50 
51 
52  if (ChangeDisplaySettings(&DevMode, CDS_FULLSCREEN) != DISP_CHANGE_SUCCESSFUL)
53  {
54  DX_STUB_str("FAIL");
55  SetMode->ddRVal = DDERR_UNSUPPORTEDMODE;
56  }
57  else
58  {
59  DX_STUB_str("OK");
60  SetMode->ddRVal = DD_OK;
61  }
62  }
63 
64  return DDHAL_DRIVER_HANDLED;
65 }
WORD dmSize
Definition: wingdi.h:1563
WORD dmDriverExtra
Definition: wingdi.h:1564
#define CDS_FULLSCREEN
Definition: winuser.h:183
#define DX_STUB_str(x)
Definition: rosdraw.h:254
HRESULT ddRVal
Definition: ddrawi.h:768
#define DDHAL_DRIVER_HANDLED
Definition: ddrawi.h:321
#define DD_OK
Definition: ddraw.h:186
smooth NULL
Definition: ftsmooth.c:416
#define DISP_CHANGE_SUCCESSFUL
Definition: winuser.h:190
unsigned short WORD
Definition: ntddk_ex.h:93
#define DDERR_UNSUPPORTEDMODE
Definition: ddraw.h:164
DWORD dwModeIndex
Definition: ddrawi.h:767

Referenced by StartDirectDrawHel().

◆ HelDdWaitForVerticalBlank()

DWORD CALLBACK HelDdWaitForVerticalBlank ( LPDDHAL_WAITFORVERTICALBLANKDATA  lpWaitForVerticalBlank)

Definition at line 67 of file callbacks_dd_hel.c.

68 {
69  DX_STUB;
70 }
#define DX_STUB
Definition: rosdraw.h:224

Referenced by StartDirectDrawHel().

◆ Main_DDrawSurface_AddAttachedSurface()

HRESULT WINAPI Main_DDrawSurface_AddAttachedSurface ( LPDDRAWI_DDRAWSURFACE_INT  iface,
LPDDRAWI_DDRAWSURFACE_INT  pAttach 
)

Definition at line 571 of file surface_main.c.

573 {
574 
575  // LPDDRAWI_DDRAWSURFACE_INT This = (LPDDRAWI_DDRAWSURFACE_INT)iface;
576  // LPDDRAWI_DDRAWSURFACE_INT That = (LPDDRAWI_DDRAWSURFACE_INT)pAttach;
577 
578  DX_WINDBG_trace();
579 
580  DX_STUB;
581 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_AddAttachedSurface().

◆ Main_DDrawSurface_AddOverlayDirtyRect()

HRESULT WINAPI Main_DDrawSurface_AddOverlayDirtyRect ( LPDDRAWI_DDRAWSURFACE_INT  iface,
LPRECT  pRect 
)

Definition at line 17 of file surface_stubs.c.

19 {
21 
22  DX_STUB;
23 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_AddOverlayDirtyRect().

◆ Main_DDrawSurface_AddRef()

ULONG WINAPI Main_DDrawSurface_AddRef ( LPDDRAWI_DDRAWSURFACE_INT  )

Definition at line 40 of file surface_main.c.

41 {
42 
44 
45  if (This!=NULL)
46  {
47  This->dwIntRefCnt++;
48  This->lpLcl->dwLocalRefCnt++;
49 
50  if (This->lpLcl->lpGbl != NULL)
51  {
52  This->lpLcl->lpGbl->dwRefCnt++;
53  }
54  }
55  return This->dwIntRefCnt;
56 
57 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
smooth NULL
Definition: ftsmooth.c:416

Referenced by Internal_CreateSurface(), Main_DDrawSurface_QueryInterface(), and Thunk_DDrawSurface3_AddRef().

◆ Main_DDrawSurface_Blt()

HRESULT WINAPI Main_DDrawSurface_Blt ( LPDDRAWI_DDRAWSURFACE_INT  ,
LPRECT  ,
LPDDRAWI_DDRAWSURFACE_INT  ,
LPRECT  ,
DWORD  ,
LPDDBLTFX   
)

Definition at line 289 of file surface_main.c.

291 {
293 
294  DX_WINDBG_trace();
295 
296  if (ThisDest == NULL)
297  {
298  return DDERR_INVALIDPARAMS;
299  }
300 
301  /* Zero out members in DDHAL_BLTDATA */
302  ZeroMemory(&mDdBlt, sizeof(DDHAL_BLTDATA));
303  ZeroMemory(&mDdBlt.bltFX, sizeof(DDBLTFX));
304 
305  /* Check if we got HAL support for this api */
306  if (( ThisDest->lpLcl->lpGbl->lpDD->lpDDCBtmp->HALDDSurface.dwFlags &
308  {
309  mDdBlt.Blt = ThisDest->lpLcl->lpSurfMore->lpDD_lcl->lpGbl->lpDDCBtmp->HALDDSurface.Blt;
310  }
311  /* Check if we got HEL support for this api */
312  else if (( ThisDest->lpLcl->lpGbl->lpDD->lpDDCBtmp->HELDDSurface.dwFlags &
314  {
315  mDdBlt.Blt = ThisDest->lpLcl->lpSurfMore->lpDD_lcl->lpGbl->lpDDCBtmp->HELDDSurface.Blt;
316  }
317 
318  if (mDdBlt.Blt == NULL)
319  {
320  /* This API is unsupported */
321  return DDERR_UNSUPPORTED;
322  }
323 
324  /* Prepare for draw, if we do not reset the DdResetVisrgn some graphics card will not draw on the screen */
325  if (!DdResetVisrgn( ThisDest->lpLcl->lpSurfMore->slist[0], NULL))
326  {
327  DX_STUB_str("DdResetVisrgn failed");
328  }
329 
330  mDdBlt.lpDD = ThisDest->lpLcl->lpSurfMore->lpDD_lcl->lpGbl;
331  mDdBlt.lpDDDestSurface = ThisDest->lpLcl->lpSurfMore->slist[0];
332  ThisDest->lpLcl->lpSurfMore->slist[0]->hDC = ThisDest->lpLcl->lpSurfMore->lpDD_lcl->hDC;
333 
334  /* Setup Src */
335  if (( ThisSrc != NULL ) )
336  {
337 
338  mDdBlt.lpDDSrcSurface = ThisSrc->lpLcl->lpSurfMore->slist[0];
339  ThisSrc->lpLcl->lpSurfMore->slist[0]->hDC = ThisSrc->lpLcl->lpSurfMore->lpDD_lcl->hDC;
340 
341  if (rsrc != NULL)
342  {
343  memmove(&mDdBlt.rSrc, rsrc, sizeof (RECTL));
344  }
345  else
346  {
347  if(!GetWindowRect((HWND)ThisSrc->lpLcl->lpSurfMore->lpDD_lcl->hWnd,
348  (RECT *)&mDdBlt.rSrc))
349  {
350  DX_STUB_str("GetWindowRect failed");
351  }
352  }
353 
354  /* FIXME
355  * compare so we do not write too far
356  * ThisDest->lpLcl->lpGbl->wWidth; <- surface max width
357  * ThisDest->lpLcl->lpGbl->wHeight <- surface max height
358  * ThisDest->lpLcl->lpGbl->lPitch <- surface bpp
359  */
360 
361  }
362 
363  /* Setup dest */
364  if (rdst != NULL)
365  {
366  memmove(&mDdBlt.rDest, rdst, sizeof (RECTL));
367  }
368  else
369  {
370  if (!GetWindowRect((HWND)ThisDest->lpLcl->lpSurfMore->lpDD_lcl->hWnd,
371  (RECT *)&mDdBlt.rDest))
372  {
373  DX_STUB_str("GetWindowRect failed");
374  }
375  }
376 
377  /* FIXME
378  * compare so we do not write too far
379  * ThisDest->lpLcl->lpGbl->wWidth; <- surface max width
380  * ThisDest->lpLcl->lpGbl->wHeight <- surface max height
381  * ThisDest->lpLcl->lpGbl->lPitch <- surface bpp
382  */
383 
384 
385  /* setup bltFX */
386  if (lpbltfx != NULL)
387  {
388  memmove(&mDdBlt.bltFX, lpbltfx, sizeof (DDBLTFX));
389  }
390 
391  /* setup value that are not config yet */
394  mDdBlt.bltFX.dwSize = sizeof(DDBLTFX);
395 
396 
397  /* FIXME
398  BltData.dwRectCnt
399  BltData.dwROPFlags
400  BltData.IsClipped
401  BltData.prDestRects
402  BltData.rOrigDest
403  BltData.rOrigSrc
404  BltData.ddRVal
405  */
406 
408  {
409  DX_STUB_str("mDdBlt DDHAL_DRIVER_HANDLED");
410  return DDERR_NOBLTHW;
411  }
412 
413  return mDdBlt.ddRVal;
414 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define memmove(s1, s2, n)
Definition: mkisofs.h:881
RECTL rDest
Definition: ddrawi.h:848
#define DDERR_UNSUPPORTED
Definition: ddraw.h:127
ActualNumberDriverObjects * sizeof(PDRIVER_OBJECT)) PDRIVER_OBJECT *DriverObjectList
LPDDRAWI_DDRAWSURFACE_LCL lpDDSrcSurface
Definition: ddrawi.h:849
#define DdResetVisrgn
Definition: ddrawgdi.h:29
DWORD dwSize
Definition: ddraw.h:1272
#define DX_STUB_str(x)
Definition: rosdraw.h:254
#define ZeroMemory
Definition: winbase.h:1642
#define DDERR_NOBLTHW
Definition: ddraw.h:149
#define DDHAL_DRIVER_HANDLED
Definition: ddrawi.h:321
#define DDHAL_SURFCB32_BLT
Definition: ddrawi.h:679
smooth NULL
Definition: ftsmooth.c:416
DWORD dwFlags
Definition: ddrawi.h:851
HRESULT ddRVal
Definition: ddrawi.h:854
struct _DDBLTFX DDBLTFX
_In_ PCCERT_CONTEXT _In_ DWORD dwFlags
Definition: wincrypt.h:1175
LPDDRAWI_DDRAWSURFACE_LCL lpDDDestSurface
Definition: ddrawi.h:847
RECTL rSrc
Definition: ddrawi.h:850
LPDDRAWI_DIRECTDRAW_GBL lpDD
Definition: ddrawi.h:846
DDBLTFX bltFX
Definition: ddrawi.h:853
DDHAL_BLTDATA mDdBlt
Definition: main.c:47
LPDDHALSURFCB_BLT Blt
Definition: ddrawi.h:855
BOOL WINAPI GetWindowRect(_In_ HWND, _Out_ LPRECT)
#define DDERR_INVALIDPARAMS
Definition: ddraw.h:79
BOOL IsClipped
Definition: ddrawi.h:856

Referenced by Thunk_DDrawSurface3_Blt().

◆ Main_DDrawSurface_BltBatch()

HRESULT WINAPI Main_DDrawSurface_BltBatch ( LPDDRAWI_DDRAWSURFACE_INT  ,
LPDDBLTBATCH  ,
DWORD  ,
DWORD   
)

Definition at line 45 of file surface_stubs.c.

48 {
50 
51  DX_STUB;
52 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_BltBatch().

◆ Main_DDrawSurface_BltFast()

HRESULT WINAPI Main_DDrawSurface_BltFast ( LPDDRAWI_DDRAWSURFACE_INT  ,
DWORD  ,
DWORD  ,
LPDDRAWI_DDRAWSURFACE_INT  ,
LPRECT  ,
DWORD   
)

Definition at line 26 of file surface_stubs.c.

29 {
31 
32  DX_STUB;
33 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_BltFast().

◆ Main_DDrawSurface_ChangeUniquenessValue()

HRESULT WINAPI Main_DDrawSurface_ChangeUniquenessValue ( LPDDRAWI_DDRAWSURFACE_INT  iface)

Definition at line 55 of file surface_stubs.c.

56 {
58 
59  DX_STUB;
60 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

◆ Main_DDrawSurface_DeleteAttachedSurface()

HRESULT WINAPI Main_DDrawSurface_DeleteAttachedSurface ( LPDDRAWI_DDRAWSURFACE_INT  ,
DWORD  ,
LPDDRAWI_DDRAWSURFACE_INT   
)

Definition at line 63 of file surface_stubs.c.

66 {
68 
69  DX_STUB;
70 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_DeleteAttachedSurface().

◆ Main_DDrawSurface_EnumAttachedSurfaces()

HRESULT WINAPI Main_DDrawSurface_EnumAttachedSurfaces ( LPDDRAWI_DDRAWSURFACE_INT  ,
LPVOID  ,
LPDDENUMSURFACESCALLBACK7   
)

Definition at line 73 of file surface_stubs.c.

76 {
78 
79  DX_STUB;
80 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_EnumAttachedSurfaces().

◆ Main_DDrawSurface_EnumOverlayZOrders()

HRESULT WINAPI Main_DDrawSurface_EnumOverlayZOrders ( LPDDRAWI_DDRAWSURFACE_INT  ,
DWORD  ,
LPVOID  ,
LPDDENUMSURFACESCALLBACK7   
)

Definition at line 83 of file surface_stubs.c.

86 {
88 
89  DX_STUB;
90 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_EnumOverlayZOrders().

◆ Main_DDrawSurface_Flip()

HRESULT WINAPI Main_DDrawSurface_Flip ( LPDDRAWI_DDRAWSURFACE_INT  ,
LPDDRAWI_DDRAWSURFACE_INT  ,
DWORD   
)

Definition at line 93 of file surface_stubs.c.

95 {
97 
98  DX_STUB;
99 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_Flip().

◆ Main_DDrawSurface_FreePrivateData()

HRESULT WINAPI Main_DDrawSurface_FreePrivateData ( LPDDRAWI_DDRAWSURFACE_INT  ,
REFGUID   
)

Definition at line 102 of file surface_stubs.c.

103 {
104  DX_WINDBG_trace();
105 
106  DX_STUB;
107 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

◆ Main_DDrawSurface_GetAttachedSurface()

HRESULT WINAPI Main_DDrawSurface_GetAttachedSurface ( LPDDRAWI_DDRAWSURFACE_INT  ,
LPDDSCAPS2  ,
LPDDRAWI_DDRAWSURFACE_INT  
)

Definition at line 584 of file surface_main.c.

587 {
588  /* FIXME hacked */
589 
590 
591  DX_WINDBG_trace();
592 
593  *ppSurface = This->lpLcl->lpGbl->lpDD->dsList;
594 
595 
596  return DD_OK;
597 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DD_OK
Definition: ddraw.h:186

Referenced by Thunk_DDrawSurface3_GetAttachedSurface().

◆ Main_DDrawSurface_GetBltStatus()

HRESULT WINAPI Main_DDrawSurface_GetBltStatus ( LPDDRAWI_DDRAWSURFACE_INT  ,
DWORD  dwFlags 
)

Definition at line 600 of file surface_main.c.

601 {
602 
603  DX_WINDBG_trace();
604 
605  if (!(This->lpLcl->lpGbl->lpDD->lpDDCBtmp->cbDDSurfaceCallbacks.dwFlags & DDHAL_SURFCB32_FLIP))
606  {
607  return DDERR_GENERIC;
608  }
609 
610  DX_STUB;
611 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DDHAL_SURFCB32_FLIP
Definition: ddrawi.h:675
#define DDERR_GENERIC
Definition: ddraw.h:72
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_GetBltStatus().

◆ Main_DDrawSurface_GetCaps()

HRESULT WINAPI Main_DDrawSurface_GetCaps ( LPDDRAWI_DDRAWSURFACE_INT  ,
LPDDSCAPS2  pCaps 
)

Definition at line 614 of file surface_main.c.

615 {
616 
617  DX_WINDBG_trace();
618 
619  if (This == NULL)
620  {
621  return DDERR_INVALIDOBJECT;
622  }
623 
624  if (pCaps == NULL)
625  {
626  return DDERR_INVALIDPARAMS;
627  }
628 
629  RtlZeroMemory(pCaps,sizeof(DDSCAPS2));
630 
631  pCaps->dwCaps = This->lpLcl->ddsCaps.dwCaps;
632 
633  return DD_OK;
634 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DD_OK
Definition: ddraw.h:186
#define DDERR_INVALIDOBJECT
Definition: ddraw.h:78
DWORD dwCaps
Definition: ddraw.h:732
smooth NULL
Definition: ftsmooth.c:416
#define RtlZeroMemory(Destination, Length)
Definition: typedefs.h:261
#define DDERR_INVALIDPARAMS
Definition: ddraw.h:79

Referenced by Thunk_DDrawSurface3_GetCaps().

◆ Main_DDrawSurface_GetClipper()

HRESULT WINAPI Main_DDrawSurface_GetClipper ( LPDDRAWI_DDRAWSURFACE_INT  ,
LPDIRECTDRAWCLIPPER  
)

Definition at line 637 of file surface_main.c.

639 {
640 
641  DX_WINDBG_trace();
642 
643  if (This == NULL)
644  {
645  return DDERR_INVALIDOBJECT;
646  }
647 
648  if (ppClipper == NULL)
649  {
650  return DDERR_INVALIDPARAMS;
651  }
652 
653  if (This->lpLcl->lp16DDClipper == NULL)
654  {
656  }
657 
658  *ppClipper = (LPDIRECTDRAWCLIPPER)This->lpLcl->lp16DDClipper;
659 
660  return DD_OK;
661 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DDERR_NOCLIPPERATTACHED
Definition: ddraw.h:142
#define DD_OK
Definition: ddraw.h:186
#define DDERR_INVALIDOBJECT
Definition: ddraw.h:78
smooth NULL
Definition: ftsmooth.c:416
struct IDirectDrawClipper * LPDIRECTDRAWCLIPPER
Definition: ddraw.h:721
#define DDERR_INVALIDPARAMS
Definition: ddraw.h:79

Referenced by Thunk_DDrawSurface3_GetClipper().

◆ Main_DDrawSurface_GetColorKey()

HRESULT WINAPI Main_DDrawSurface_GetColorKey ( LPDDRAWI_DDRAWSURFACE_INT  ,
DWORD  ,
LPDDCOLORKEY   
)

Definition at line 109 of file surface_stubs.c.

111 {
112  //LPDDRAWI_DDRAWSURFACE_INT This = (LPDDRAWI_DDRAWSURFACE_INT)iface;
113 
114  DX_WINDBG_trace();
115 
116  DX_STUB;
117 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_GetColorKey().

◆ Main_DDrawSurface_GetDC()

HRESULT WINAPI Main_DDrawSurface_GetDC ( LPDDRAWI_DDRAWSURFACE_INT  ,
HDC  
)

Definition at line 694 of file surface_main.c.

695 {
696 
697  DX_WINDBG_trace();
698 
699  if (This == NULL)
700  {
701  return DDERR_INVALIDOBJECT;
702  }
703 
704  if (phDC == NULL)
705  {
706  return DDERR_INVALIDPARAMS;
707  }
708 
709 
710  *phDC = (HDC)This->lpLcl->lpSurfMore->lpDD_lcl->hDC;
711 
712  return DD_OK;
713 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
static HDC
Definition: imagelist.c:92
#define DD_OK
Definition: ddraw.h:186
#define DDERR_INVALIDOBJECT
Definition: ddraw.h:78
smooth NULL
Definition: ftsmooth.c:416
#define DDERR_INVALIDPARAMS
Definition: ddraw.h:79

Referenced by Thunk_DDrawSurface3_GetDC().

◆ Main_DDrawSurface_GetDDInterface()

HRESULT WINAPI Main_DDrawSurface_GetDDInterface ( LPDDRAWI_DDRAWSURFACE_INT  ,
LPVOID  
)

Definition at line 120 of file surface_stubs.c.

121 {
122  DX_WINDBG_trace();
123 
124  DX_STUB;
125 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_GetDDInterface().

◆ Main_DDrawSurface_GetFlipStatus()

HRESULT WINAPI Main_DDrawSurface_GetFlipStatus ( LPDDRAWI_DDRAWSURFACE_INT  ,
DWORD   
)

Definition at line 127 of file surface_stubs.c.

128 {
129  DX_WINDBG_trace();
130 
131  DX_STUB;
132 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_GetFlipStatus().

◆ Main_DDrawSurface_GetLOD()

HRESULT WINAPI Main_DDrawSurface_GetLOD ( LPDDRAWI_DDRAWSURFACE_INT  ,
LPDWORD   
)

Definition at line 135 of file surface_stubs.c.

136 {
137  DX_WINDBG_trace();
138 
139  DX_STUB;
140 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

◆ Main_DDrawSurface_GetOverlayPosition()

HRESULT WINAPI Main_DDrawSurface_GetOverlayPosition ( LPDDRAWI_DDRAWSURFACE_INT  ,
LPLONG  ,
LPLONG   
)

Definition at line 143 of file surface_stubs.c.

145 {
146  DX_WINDBG_trace();
147 
148  DX_STUB;
149 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_GetOverlayPosition().

◆ Main_DDrawSurface_GetPalette()

HRESULT WINAPI Main_DDrawSurface_GetPalette ( LPDDRAWI_DDRAWSURFACE_INT  ,
LPDIRECTDRAWPALETTE  
)

Definition at line 151 of file surface_stubs.c.

153 {
154  DX_WINDBG_trace();
155 
156  DX_STUB;
157 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_GetPalette().

◆ Main_DDrawSurface_GetPixelFormat()

HRESULT WINAPI Main_DDrawSurface_GetPixelFormat ( LPDDRAWI_DDRAWSURFACE_INT  ,
LPDDPIXELFORMAT   
)

Definition at line 716 of file surface_main.c.

718 {
719  HRESULT retVale = DDERR_INVALIDPARAMS;
720 
721  DX_WINDBG_trace();
722 
723  if (pDDPixelFormat != NULL)
724  {
725  if (This->lpLcl->dwFlags & DDRAWISURF_HASPIXELFORMAT)
726  {
727  memcpy(pDDPixelFormat,&This->lpLcl->lpGbl->ddpfSurface,sizeof(DDPIXELFORMAT));
728  }
729  else
730  {
731  memcpy(pDDPixelFormat,&This->lpLcl->lpSurfMore->
732  lpDD_lcl->lpGbl->vmiData.ddpfDisplay,sizeof(DDPIXELFORMAT));
733  }
734  retVale = DD_OK;
735  }
736 
737  return retVale;
738 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DDRAWISURF_HASPIXELFORMAT
Definition: ddrawi.h:1515
#define DD_OK
Definition: ddraw.h:186
smooth NULL
Definition: ftsmooth.c:416
LONG HRESULT
Definition: typedefs.h:77
#define memcpy(s1, s2, n)
Definition: mkisofs.h:878
#define DDERR_INVALIDPARAMS
Definition: ddraw.h:79

Referenced by Thunk_DDrawSurface3_GetPixelFormat().

◆ Main_DDrawSurface_GetPriority()

HRESULT WINAPI Main_DDrawSurface_GetPriority ( LPDDRAWI_DDRAWSURFACE_INT  ,
LPDWORD   
)

Definition at line 160 of file surface_stubs.c.

162 {
163  DX_WINDBG_trace();
164 
165  DX_STUB;
166 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

◆ Main_DDrawSurface_GetPrivateData()

HRESULT WINAPI Main_DDrawSurface_GetPrivateData ( LPDDRAWI_DDRAWSURFACE_INT  ,
REFGUID  ,
LPVOID  ,
LPDWORD   
)

Definition at line 169 of file surface_stubs.c.

172 {
173  DX_WINDBG_trace();
174 
175  DX_STUB;
176 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

◆ Main_DDrawSurface_GetSurfaceDesc()

HRESULT WINAPI Main_DDrawSurface_GetSurfaceDesc ( LPDDRAWI_DDRAWSURFACE_INT  ,
LPDDSURFACEDESC2   
)

Definition at line 741 of file surface_main.c.

743 {
744  DWORD dwSize;
745 
746  DX_WINDBG_trace();
747 
748  dwSize = pDDSD->dwSize;
749 
750  if ((dwSize != sizeof(DDSURFACEDESC)) &&
751  (dwSize != sizeof(DDSURFACEDESC2)))
752  {
753  return DDERR_GENERIC;
754  }
755 
756  ZeroMemory(pDDSD,dwSize);
757 
758  if (dwSize == sizeof(DDSURFACEDESC))
759  {
760  LPDDSURFACEDESC lpDS = (LPDDSURFACEDESC) pDDSD;
761  memcpy(&lpDS->ddckCKDestBlt, &This->lpLcl->ddckCKDestBlt, sizeof(DDCOLORKEY));
762  memcpy(&lpDS->ddckCKDestOverlay, &This->lpLcl->ddckCKDestOverlay, sizeof(DDCOLORKEY));
763  memcpy(&lpDS->ddckCKSrcBlt, &This->lpLcl->ddckCKSrcBlt, sizeof(DDCOLORKEY));
764  memcpy(&lpDS->ddckCKSrcOverlay, &This->lpLcl->ddckCKSrcOverlay, sizeof(DDCOLORKEY));
765  memcpy(&lpDS->ddpfPixelFormat, &This->lpLcl->lpGbl->ddpfSurface, sizeof(DDPIXELFORMAT));
766  memcpy(&lpDS->ddsCaps, &This->lpLcl->ddsCaps, sizeof(DDSCAPS));
767 
768  lpDS->dwAlphaBitDepth = This->lpLcl->dwAlpha;
769  lpDS->dwBackBufferCount = This->lpLcl->dwBackBufferCount;
770 
771  /* FIXME setting the flags right */
772  // lpDS->dwFlags = This->lpLcl->dwFlags;
773 
774  lpDS->dwHeight = This->lpLcl->lpGbl->wHeight;
775  lpDS->dwWidth = This->lpLcl->lpGbl->wWidth;
776 
777  /* This two are a union in lpDS and in This->lpLcl->lpGbl
778  so I comment out lPitch
779  lpDS->lPitch = This->lpLcl->lpGbl->lPitch;
780  */
781  lpDS->dwLinearSize = This->lpLcl->lpGbl->dwLinearSize;
782 
783 
784  /* This tree are a union */
785  //lpDS->dwMipMapCount
786  //lpDS->dwRefreshRate
787  //lpDS->dwZBufferBitDepth
788 
789  /* Unknown */
790  // lpDS->dwReserved
791  // lpDS->lpSurface
792  }
793  else
794  {
795  memcpy(&pDDSD->ddckCKDestBlt, &This->lpLcl->ddckCKDestBlt, sizeof(DDCOLORKEY));
796 
797  /*
798  pDDSD->dwEmptyFaceColor is a union to ddckCKDestOverlay
799  */
800  memcpy(&pDDSD->ddckCKDestOverlay, &This->lpLcl->ddckCKDestOverlay, sizeof(DDCOLORKEY));
801  memcpy(&pDDSD->ddckCKSrcBlt, &This->lpLcl->ddckCKSrcBlt, sizeof(DDCOLORKEY));
802  memcpy(&pDDSD->ddckCKSrcOverlay, &This->lpLcl->ddckCKSrcOverlay, sizeof(DDCOLORKEY));
803 
804  /*
805  pDDSD->dwFVF is a union to ddpfPixelFormat
806  */
807  memcpy(&pDDSD->ddpfPixelFormat, &This->lpLcl->lpGbl->ddpfSurface, sizeof(DDPIXELFORMAT));
808  memcpy(&pDDSD->ddsCaps, &This->lpLcl->ddsCaps, sizeof(DDSCAPS));
809 
810 
811  pDDSD->dwAlphaBitDepth = This->lpLcl->dwAlpha;
812  pDDSD->dwBackBufferCount = This->lpLcl->dwBackBufferCount;
813 
814  /* FIXME setting the flags right */
815  // lpDS->dwFlags = This->lpLcl->dwFlags;
816 
817  pDDSD->dwHeight = This->lpLcl->lpGbl->wHeight;
818  pDDSD->dwWidth = This->lpLcl->lpGbl->wWidth;
819 
820  /* This two are a union in lpDS and in This->lpLcl->lpGbl
821  so I comment out lPitch
822  lpDS->lPitch = This->lpLcl->lpGbl->lPitch;
823  */
824  pDDSD->dwLinearSize = This->lpLcl->lpGbl->dwLinearSize;
825 
826  /* This tree are a union */
827  // pDDSD->dwMipMapCount
828  // pDDSD->dwRefreshRate
829  // pDDSD->dwSrcVBHandle
830 
831  /* Unknown */
832  // lpDS->dwReserved
833  // lpDS->lpSurface
834  // pDDSD->dwTextureStage
835  }
836 
837  return DD_OK;
838 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
DDCOLORKEY ddckCKDestBlt
Definition: ddraw.h:1180
#define ZeroMemory
Definition: winbase.h:1642
DWORD dwWidth
Definition: ddraw.h:1155
DDCOLORKEY ddckCKSrcOverlay
Definition: ddraw.h:1181
#define DD_OK
Definition: ddraw.h:186
DWORD dwBackBufferCount
Definition: ddraw.h:1163
DDSCAPS2 ddsCaps
Definition: ddraw.h:1188
DDPIXELFORMAT ddpfPixelFormat
Definition: ddraw.h:1185
#define DDERR_GENERIC
Definition: ddraw.h:72
unsigned long DWORD
Definition: ntddk_ex.h:95
DWORD dwSize
Definition: ddraw.h:1152
#define memcpy(s1, s2, n)
Definition: mkisofs.h:878
DWORD dwHeight
Definition: ddraw.h:1154
DWORD dwAlphaBitDepth
Definition: ddraw.h:1172
DDCOLORKEY ddckCKDestOverlay
Definition: ddraw.h:1177
DWORD dwLinearSize
Definition: ddraw.h:1159
void * LPDDSURFACEDESC
Definition: ddstream.idl:19
PSDBQUERYRESULT_VISTA PVOID DWORD * dwSize
Definition: env.c:54
DDCOLORKEY ddckCKSrcBlt
Definition: ddraw.h:1182

Referenced by Thunk_DDrawSurface3_GetSurfaceDesc().

◆ Main_DDrawSurface_GetUniquenessValue()

HRESULT WINAPI Main_DDrawSurface_GetUniquenessValue ( LPDDRAWI_DDRAWSURFACE_INT  ,
LPDWORD   
)

Definition at line 179 of file surface_stubs.c.

181 {
182  DX_WINDBG_trace();
183 
184  DX_STUB;
185 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

◆ Main_DDrawSurface_Initialize()

HRESULT WINAPI Main_DDrawSurface_Initialize ( LPDDRAWI_DDRAWSURFACE_INT  ,
LPDIRECTDRAW  ,
LPDDSURFACEDESC2   
)

Definition at line 35 of file surface_main.c.

36 {
38 }
#define DDERR_ALREADYINITIALIZED
Definition: ddraw.h:67

Referenced by Thunk_DDrawSurface3_Initialize().

◆ Main_DDrawSurface_IsLost()

HRESULT WINAPI Main_DDrawSurface_IsLost ( LPDDRAWI_DDRAWSURFACE_INT  )

Definition at line 188 of file surface_stubs.c.

189 {
190  DX_WINDBG_trace();
191 
192  //DX_STUB;
193  DX_STUB_str("not implement return not lost\n");
194  return DD_OK;
195 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB_str(x)
Definition: rosdraw.h:254
#define DD_OK
Definition: ddraw.h:186

Referenced by Thunk_DDrawSurface3_IsLost().

◆ Main_DDrawSurface_Lock()

HRESULT WINAPI Main_DDrawSurface_Lock ( LPDDRAWI_DDRAWSURFACE_INT  ,
LPRECT  ,
LPDDSURFACEDESC2  ,
DWORD  ,
HANDLE   
)

Definition at line 418 of file surface_main.c.

420 {
421  DDHAL_LOCKDATA mdLock;
422 
423  DX_WINDBG_trace();
424 
425  DX_WINDBG_trace_res( (DWORD)ThisDest->lpLcl->lpGbl->wWidth, (DWORD)ThisDest->lpLcl->lpGbl->wHeight, (DWORD)ThisDest->lpLcl->lpGbl->lPitch, (DWORD) 0);
426 
427  /* Zero out members in DDHAL_LOCKDATA */
428  ZeroMemory(&mdLock, sizeof(DDHAL_LOCKDATA));
429 
430  /* Check if we got HAL support for this api */
431  if (( ThisDest->lpLcl->lpGbl->lpDD->lpDDCBtmp->HALDDSurface.dwFlags &
433  {
434  mdLock.Lock = ThisDest->lpLcl->lpSurfMore->lpDD_lcl->lpGbl->lpDDCBtmp->HALDDSurface.Lock;
435  }
436  /* Check if we got HEL support for this api */
437  else if (( ThisDest->lpLcl->lpGbl->lpDD->lpDDCBtmp->HELDDSurface.dwFlags &
439  {
440  mdLock.Lock = ThisDest->lpLcl->lpSurfMore->lpDD_lcl->lpGbl->lpDDCBtmp->HELDDSurface.Lock;
441  }
442 
443  if (mdLock.Lock == NULL)
444  {
445  /* This api are unsupported */
446  return DDERR_UNSUPPORTED;
447  }
448 
449  if (events != NULL)
450  {
451  return DDERR_INVALIDPARAMS;
452  }
453 
454  /* FIXME add a check see if lock support or not */
455 
456  if (prect!=NULL)
457  {
458  mdLock.bHasRect = TRUE;
459  memcpy(&mdLock.rArea,prect,sizeof(RECTL));
460  }
461  else
462  {
463  mdLock.bHasRect = FALSE;
464  }
465 
466  //FIXME check if it primary or not and use primary or pixelformat data, at moment it is hardcode to primary
467 
468  mdLock.ddRVal = DDERR_CANTLOCKSURFACE;
469  mdLock.dwFlags = flags;
470  mdLock.lpDDSurface = ThisDest->lpLcl->lpSurfMore->slist[0];
471  mdLock.lpDD = ThisDest->lpLcl->lpSurfMore->lpDD_lcl->lpGbl;
472  mdLock.lpSurfData = NULL;
473 
474 
475  if (!DdResetVisrgn(ThisDest->lpLcl->lpSurfMore->slist[0], NULL))
476  {
477  DX_STUB_str("Here DdResetVisrgn lock");
478  // return DDERR_UNSUPPORTED;
479  }
480 
481  if (mdLock.Lock(&mdLock)!= DDHAL_DRIVER_HANDLED)
482  {
483  DX_STUB_str("Here DDHAL_DRIVER_HANDLED lock");
484  return DDERR_UNSUPPORTED;
485  }
486 
487  // FIXME ??? is this right ??
488 
489  if (pDDSD != NULL)
490  {
491  ZeroMemory(pDDSD,sizeof(DDSURFACEDESC2));
492  pDDSD->dwSize = sizeof(DDSURFACEDESC2);
493 
494  //if (pDDSD->dwSize == sizeof(DDSURFACEDESC2))
495  //{
496  // ZeroMemory(pDDSD,sizeof(DDSURFACEDESC2));
497  // // FIXME the internal mddsdPrimary shall be DDSURFACEDESC2
498  // memcpy(pDDSD,&This->Surf->mddsdPrimary,sizeof(DDSURFACEDESC));
499  // pDDSD->dwSize = sizeof(DDSURFACEDESC2);
500  //}
501  //if (pDDSD->dwSize == sizeof(DDSURFACEDESC))
502  //{
503  // RtlZeroMemory(pDDSD,sizeof(DDSURFACEDESC));
504  // memcpy(pDDSD,&This->Surf->mddsdPrimary,sizeof(DDSURFACEDESC));
505  // pDDSD->dwSize = sizeof(DDSURFACEDESC);
506  //}
507 
508 
509  pDDSD->lpSurface = (LPVOID) mdLock.lpSurfData;
510 
511  pDDSD->dwHeight = ThisDest->lpLcl->lpGbl->wHeight;
512  pDDSD->dwWidth = ThisDest->lpLcl->lpGbl->wWidth;
513 
514  pDDSD->ddpfPixelFormat.dwRGBBitCount = ThisDest->lpLcl->lpGbl->lpDD->lpModeInfo->dwBPP;// .lpModeInfo->dwBPP; //This->lpLcl->lpGbl->lPitch/ 8;
515  pDDSD->lPitch = ThisDest->lpLcl->lpGbl->lPitch;
516  pDDSD->dwFlags = DDSD_WIDTH | DDSD_HEIGHT | DDSD_PITCH;
517  }
518 
519  return mdLock.ddRVal;
520 }
HRESULT ddRVal
Definition: ddrawi.h:833
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define TRUE
Definition: types.h:120
#define DDERR_UNSUPPORTED
Definition: ddraw.h:127
DWORD dwFlags
Definition: ddrawi.h:835
#define DdResetVisrgn
Definition: ddrawgdi.h:29
LPDDRAWI_DDRAWSURFACE_LCL lpDDSurface
Definition: ddrawi.h:829
#define DX_STUB_str(x)
Definition: rosdraw.h:254
RECTL rArea
Definition: ddrawi.h:831
#define ZeroMemory
Definition: winbase.h:1642
#define DX_WINDBG_trace_res(width, height, bpp, freq)
Definition: rosdraw.h:273
#define DDHAL_DRIVER_HANDLED
Definition: ddrawi.h:321
DWORD bHasRect
Definition: ddrawi.h:830
#define DDHAL_SURFCB32_LOCK
Definition: ddrawi.h:677
smooth NULL
Definition: ftsmooth.c:416
LPDDHALSURFCB_LOCK Lock
Definition: ddrawi.h:834
#define DDERR_CANTLOCKSURFACE
Definition: ddraw.h:120
#define DDSD_HEIGHT
Definition: ddraw.h:209
LPDDRAWI_DIRECTDRAW_GBL lpDD
Definition: ddrawi.h:828
unsigned long DWORD
Definition: ntddk_ex.h:95
#define LPVOID
Definition: nt_native.h:45
GLbitfield flags
Definition: glext.h:7161
#define memcpy(s1, s2, n)
Definition: mkisofs.h:878
#define DDSD_WIDTH
Definition: ddraw.h:210
HANDLE events[2]
Definition: event.c:4
struct _DDSURFACEDESC2 DDSURFACEDESC2
#define DDERR_INVALIDPARAMS
Definition: ddraw.h:79
#define DDSD_PITCH
Definition: ddraw.h:211
LPVOID lpSurfData
Definition: ddrawi.h:832

Referenced by Thunk_DDrawSurface3_Lock().

◆ Main_DDrawSurface_PageLock()

HRESULT WINAPI Main_DDrawSurface_PageLock ( LPDDRAWI_DDRAWSURFACE_INT  ,
DWORD   
)

Definition at line 198 of file surface_stubs.c.

199 {
200  DX_WINDBG_trace();
201 
202  DX_STUB;
203 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_PageLock().

◆ Main_DDrawSurface_PageUnlock()

HRESULT WINAPI Main_DDrawSurface_PageUnlock ( LPDDRAWI_DDRAWSURFACE_INT  ,
DWORD   
)

Definition at line 206 of file surface_stubs.c.

207 {
208  DX_WINDBG_trace();
209 
210  DX_STUB;
211 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_PageUnlock().

◆ Main_DDrawSurface_QueryInterface()

HRESULT WINAPI Main_DDrawSurface_QueryInterface ( LPDDRAWI_DDRAWSURFACE_INT  ,
REFIID  ,
LPVOID  
)

Definition at line 60 of file surface_main.c.

61 {
62  HRESULT retVal = DD_OK;
63  *ppObj = NULL;
64 
66 
67  _SEH2_TRY
68  {
69  if (IsEqualGUID(&IID_IDirectDrawSurface7, riid))
70  {
71  if (This->lpVtbl != &DirectDrawSurface7_Vtable)
72  {
74  if (!This)
75  {
76  retVal = DDERR_OUTOFVIDEOMEMORY;
78  }
79  }
81  *ppObj = This;
83  }
84  else if (IsEqualGUID(&IID_IDirectDrawSurface4, riid))
85  {
86  if (This->lpVtbl != &DirectDrawSurface4_Vtable)
87  {
89  if (!This)
90  {
91  retVal = DDERR_OUTOFVIDEOMEMORY;
93  }
94  }
96  *ppObj = This;
98  }
99  else if (IsEqualGUID(&IID_IDirectDrawSurface3, riid))
100  {
101  if (This->lpVtbl != &DirectDrawSurface3_Vtable)
102  {
104  if (!This)
105  {
106  retVal = DDERR_OUTOFVIDEOMEMORY;
107  _SEH2_LEAVE;
108  }
109  }
110  This->lpVtbl = &DirectDrawSurface3_Vtable;
111  *ppObj = This;
113  }
114  else if (IsEqualGUID(&IID_IDirectDrawSurface2, riid))
115  {
116  if (This->lpVtbl != &DirectDrawSurface2_Vtable)
117  {
119  if (!This)
120  {
121  retVal = DDERR_OUTOFVIDEOMEMORY;
122  _SEH2_LEAVE;
123  }
124  }
125  This->lpVtbl = &DirectDrawSurface2_Vtable;
126  *ppObj = This;
128  }
129  else if (IsEqualGUID(&IID_IDirectDrawSurface, riid))
130  {
131  if (This->lpVtbl != &DirectDrawSurface_Vtable)
132  {
134  if (!This)
135  {
136  retVal = DDERR_OUTOFVIDEOMEMORY;
137  _SEH2_LEAVE;
138  }
139  }
140  This->lpVtbl = &DirectDrawSurface_Vtable;
141  *ppObj = This;
143  }
144  else if (IsEqualGUID(&IID_IDirectDrawColorControl, riid))
145  {
146  if (This->lpVtbl != &DirectDrawColorControl_Vtable)
147  {
149  if (!This)
150  {
151  retVal = DDERR_OUTOFVIDEOMEMORY;
152  _SEH2_LEAVE;
153  }
154  }
156  *ppObj = This;
158  }
159  else if (IsEqualGUID(&IID_IDirectDrawGammaControl, riid))
160  {
161  if (This->lpVtbl != &DirectDrawGammaControl_Vtable)
162  {
164  if (!This)
165  {
166  retVal = DDERR_OUTOFVIDEOMEMORY;
167  _SEH2_LEAVE;
168  }
169  }
171  *ppObj = This;
173  }
174  else if (IsEqualGUID(&IID_IDirectDrawSurfaceKernel, riid))
175  {
176  if (This->lpVtbl != &DirectDrawSurfaceKernel_Vtable)
177  {
179  if (!This)
180  {
181  retVal = DDERR_OUTOFVIDEOMEMORY;
182  _SEH2_LEAVE;
183  }
184  }
186  *ppObj = This;
188  }
189  else if (IsEqualGUID(&IID_IDirect3D, riid))
190  {
191  if (This->lpVtbl != &IDirect3D_Vtbl)
192  {
194  if (!This)
195  {
196  retVal = DDERR_OUTOFVIDEOMEMORY;
197  _SEH2_LEAVE;
198  }
199  }
200  This->lpVtbl = &IDirect3D_Vtbl;
201  *ppObj = This;
203  }
204  else if (IsEqualGUID(&IID_IDirect3D2, riid))
205  {
206  if (This->lpVtbl != &IDirect3D2_Vtbl)
207  {
209  if (!This)
210  {
211  retVal = DDERR_OUTOFVIDEOMEMORY;
212  _SEH2_LEAVE;
213  }
214  }
215  This->lpVtbl = &IDirect3D2_Vtbl;
216  *ppObj = This;
218  }
219  else if (IsEqualGUID(&IID_IDirect3D3, riid))
220  {
221  if (This->lpVtbl != &IDirect3D3_Vtbl)
222  {
224  if (!This)
225  {
226  retVal = DDERR_OUTOFVIDEOMEMORY;
227  _SEH2_LEAVE;
228  }
229  }
230  This->lpVtbl = &IDirect3D3_Vtbl;
231  *ppObj = This;
233  }
234  else if (IsEqualGUID(&IID_IDirect3D7, riid))
235  {
236  if (This->lpVtbl != &IDirect3D7_Vtbl)
237  {
239  if (!This)
240  {
241  retVal = DDERR_OUTOFVIDEOMEMORY;
242  _SEH2_LEAVE;
243  }
244  }
245  This->lpVtbl = &IDirect3D7_Vtbl;
246  *ppObj = This;
248  }
249  else
250  {
251  DX_STUB_str("E_NOINTERFACE");
252  retVal = E_NOINTERFACE;
253  }
254  }
256  {
257  }
258  _SEH2_END;
259  return retVal;
260 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define E_NOINTERFACE
Definition: winerror.h:2364
REFIID riid
Definition: precomp.h:44
#define DX_STUB_str(x)
Definition: rosdraw.h:254
LPDDRAWI_DDRAWSURFACE_INT internal_directdrawsurface_int_alloc(LPDDRAWI_DDRAWSURFACE_INT This)
Definition: surface_main.c:23
#define DDERR_OUTOFVIDEOMEMORY
Definition: ddraw.h:112
IDirectDrawSurface2Vtbl DirectDrawSurface2_Vtable
_SEH2_TRY
Definition: create.c:4250
IDirectDrawSurfaceKernelVtbl DirectDrawSurfaceKernel_Vtable
Definition: kernel_stubs.c:123
#define DD_OK
Definition: ddraw.h:186
IDirectDrawSurface4Vtbl DirectDrawSurface4_Vtable
#define EXCEPTION_EXECUTE_HANDLER
Definition: excpt.h:85
smooth NULL
Definition: ftsmooth.c:416
IDirectDrawGammaControlVtbl DirectDrawGammaControl_Vtable
Definition: gamma_stubs.c:60
IDirectDrawColorControlVtbl DirectDrawColorControl_Vtable
Definition: color_stubs.c:58
IDirect3D2Vtbl IDirect3D2_Vtbl
IDirectDrawSurface3Vtbl DirectDrawSurface3_Vtable
IDirectDrawSurfaceVtbl DirectDrawSurface_Vtable
IDirect3D7Vtbl IDirect3D7_Vtbl
LONG HRESULT
Definition: typedefs.h:77
IDirect3DVtbl IDirect3D_Vtbl
IDirectDrawSurface7Vtbl DirectDrawSurface7_Vtable
_SEH2_END
Definition: create.c:4424
ULONG WINAPI Main_DDrawSurface_AddRef(LPDDRAWI_DDRAWSURFACE_INT This)
Definition: surface_main.c:40
BOOL WINAPI IsEqualGUID(REFGUID rguid1, REFGUID rguid2)
Definition: compobj.c:4112
#define _SEH2_EXCEPT(...)
Definition: pseh2_64.h:6
#define _SEH2_LEAVE
Definition: filesup.c:20
IDirect3D3Vtbl IDirect3D3_Vtbl

Referenced by Thunk_DDrawSurface3_QueryInterface().

◆ Main_DDrawSurface_Release()

ULONG WINAPI Main_DDrawSurface_Release ( LPDDRAWI_DDRAWSURFACE_INT  )

Definition at line 264 of file surface_main.c.

265 {
266  /* FIXME
267  This is not right exiame how it should be done
268  */
269  ULONG ret = --This->dwIntRefCnt;
270  if(!ret)
271  {
272  DX_STUB_str("Release is a bit simplistic right now\n");
276  }
277  return ret;
278 }
#define DX_STUB_str(x)
Definition: rosdraw.h:254
#define DxHeapMemFree(p)
Definition: rosdraw.h:120
VOID WINAPI AcquireDDThreadLock()
Definition: main.c:412
VOID WINAPI ReleaseDDThreadLock()
Definition: main.c:421
int ret
unsigned int ULONG
Definition: retypes.h:1

Referenced by Main_DDrawSurface_Release4(), and Thunk_DDrawSurface3_Release().

◆ Main_DDrawSurface_ReleaseDC()

HRESULT WINAPI Main_DDrawSurface_ReleaseDC ( LPDDRAWI_DDRAWSURFACE_INT  ,
HDC   
)

Definition at line 841 of file surface_main.c.

842 {
843  DX_WINDBG_trace();
844 
845  if (This == NULL)
846  {
847  return DDERR_INVALIDOBJECT;
848  }
849 
850  if (hDC == NULL)
851  {
852  return DDERR_INVALIDPARAMS;
853  }
854 
855  /* FIXME check if surface exits or not */
856 
857 
858  if ((HDC)This->lpLcl->hDC == NULL)
859  {
860  return DDERR_GENERIC;
861  }
862 
863  return DD_OK;
864 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
static HDC
Definition: imagelist.c:92
#define DD_OK
Definition: ddraw.h:186
#define DDERR_INVALIDOBJECT
Definition: ddraw.h:78
smooth NULL
Definition: ftsmooth.c:416
#define DDERR_GENERIC
Definition: ddraw.h:72
static HDC hDC
Definition: 3dtext.c:33
#define DDERR_INVALIDPARAMS
Definition: ddraw.h:79

Referenced by Thunk_DDrawSurface3_ReleaseDC().

◆ Main_DDrawSurface_Restore()

HRESULT WINAPI Main_DDrawSurface_Restore ( LPDDRAWI_DDRAWSURFACE_INT  )

Definition at line 36 of file surface_stubs.c.

37 {
39 
40  DX_STUB;
41 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_Restore().

◆ Main_DDrawSurface_SetClipper()

HRESULT WINAPI Main_DDrawSurface_SetClipper ( LPDDRAWI_DDRAWSURFACE_INT  ,
LPDIRECTDRAWCLIPPER   
)

Definition at line 664 of file surface_main.c.

666 {
667 
668  DX_WINDBG_trace();
669 
670  if (This == NULL)
671  {
672  return DDERR_INVALIDOBJECT;
673  }
674 
675  if(pDDClipper == NULL)
676  {
677  if(!This->lpLcl->lp16DDClipper)
679 
680  DirectDrawClipper_Release((LPDIRECTDRAWCLIPPER)This->lpLcl->lp16DDClipper);
681  This->lpLcl->lp16DDClipper = NULL;
682  return DD_OK;
683  }
684 
685  // FIXME: Check Surface type and return DDERR_INVALIDSURFACETYPE
686 
688  This->lpLcl->lp16DDClipper = (LPDDRAWI_DDRAWCLIPPER_INT)pDDClipper;
689 
690  return DD_OK;
691 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DDERR_NOCLIPPERATTACHED
Definition: ddraw.h:142
#define DD_OK
Definition: ddraw.h:186
#define DDERR_INVALIDOBJECT
Definition: ddraw.h:78
smooth NULL
Definition: ftsmooth.c:416
ULONG WINAPI DirectDrawClipper_AddRef(LPDIRECTDRAWCLIPPER)
Definition: clipper_main.c:75
ULONG WINAPI DirectDrawClipper_Release(LPDIRECTDRAWCLIPPER)
Definition: clipper_main.c:54
struct _DDRAWI_DDRAWCLIPPER_INT * LPDDRAWI_DDRAWCLIPPER_INT
Definition: ddrawi.h:145
struct IDirectDrawClipper * LPDIRECTDRAWCLIPPER
Definition: ddraw.h:721

Referenced by Thunk_DDrawSurface3_SetClipper().

◆ Main_DDrawSurface_SetColorKey()

HRESULT WINAPI Main_DDrawSurface_SetColorKey ( LPDDRAWI_DDRAWSURFACE_INT  ,
DWORD  ,
LPDDCOLORKEY   
)

Definition at line 867 of file surface_main.c.

869 {
870 
871  DDHAL_SETCOLORKEYDATA ColorKeyData;
872 
873  DX_WINDBG_trace();
874 
875  ColorKeyData.ddRVal = DDERR_COLORKEYNOTSET;
876 
877  if (This->lpLcl->lpGbl->lpDD->lpDDCBtmp->cbDDSurfaceCallbacks.dwFlags & DDHAL_SURFCB32_SETCOLORKEY)
878  {
879 
880  ColorKeyData.lpDD = This->lpLcl->lpGbl->lpDD;
881  ColorKeyData.SetColorKey = This->lpLcl->lpGbl->lpDD->lpDDCBtmp->cbDDSurfaceCallbacks.SetColorKey;
882 
883  //ColorKeyData.lpDDSurface = &This->lpLcl->hDDSurface;
884  ColorKeyData.dwFlags = dwFlags;
885  /* FIXME
886  ColorKeyData.ckNew = ?
887  add / move dwFlags to This->lpLcl->dwFlags ??
888  */
889 
890  if (ColorKeyData.SetColorKey(&ColorKeyData) == DDHAL_DRIVER_HANDLED )
891  {
892  return ColorKeyData.ddRVal;
893  }
894  }
895  return DDERR_COLORKEYNOTSET;
896 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
LPDDRAWI_DIRECTDRAW_GBL lpDD
Definition: ddrawi.h:1850
LPDDHALSURFCB_SETCOLORKEY SetColorKey
Definition: ddrawi.h:1855
#define DDERR_COLORKEYNOTSET
Definition: ddraw.h:116
#define DDHAL_SURFCB32_SETCOLORKEY
Definition: ddrawi.h:680
#define DDHAL_DRIVER_HANDLED
Definition: ddrawi.h:321
_In_ PCCERT_CONTEXT _In_ DWORD dwFlags
Definition: wincrypt.h:1175

Referenced by Thunk_DDrawSurface3_SetColorKey().

◆ Main_DDrawSurface_SetLOD()

HRESULT WINAPI Main_DDrawSurface_SetLOD ( LPDDRAWI_DDRAWSURFACE_INT  ,
DWORD   
)

Definition at line 288 of file surface_stubs.c.

289 {
290  DX_WINDBG_trace();
291 
292  DX_STUB;
293 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

◆ Main_DDrawSurface_SetOverlayPosition()

HRESULT WINAPI Main_DDrawSurface_SetOverlayPosition ( LPDDRAWI_DDRAWSURFACE_INT  ,
LONG  ,
LONG   
)

Definition at line 901 of file surface_main.c.

902 {
903 
904  DDHAL_SETOVERLAYPOSITIONDATA OverLayPositionData;
905 
906  DX_WINDBG_trace();
907 
908  OverLayPositionData.ddRVal = DDERR_COLORKEYNOTSET;
909 
910  if (This->lpLcl->lpGbl->lpDD->lpDDCBtmp->cbDDSurfaceCallbacks.dwFlags & DDHAL_SURFCB32_SETOVERLAYPOSITION)
911  {
912 
913  OverLayPositionData.lpDD = This->lpLcl->lpGbl->lpDD;
914  OverLayPositionData.SetOverlayPosition = This->lpLcl->lpGbl->lpDD->lpDDCBtmp->cbDDSurfaceCallbacks.SetOverlayPosition;
915 
916  //OverLayPositionData.lpDDSrcSurface = This->lpLcl->lpSurfaceOverlaying->lpLcl->hDDSurface;
917  //OverLayPositionData.lpDDDestSurface = This->lpLcl->hDDSurface;
918 
919  OverLayPositionData.lXPos = X;
920  OverLayPositionData.lYPos = Y;
921 
922 
923  /* FIXME
924  Should X and Y be save ??
925  */
926 
927  if (OverLayPositionData.SetOverlayPosition(&OverLayPositionData) == DDHAL_DRIVER_HANDLED )
928  {
929  return OverLayPositionData.ddRVal;
930  }
931  }
932 
933  return DDERR_GENERIC;
934 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define Y(I)
#define DDERR_COLORKEYNOTSET
Definition: ddraw.h:116
#define DDHAL_DRIVER_HANDLED
Definition: ddrawi.h:321
#define DDERR_GENERIC
Definition: ddraw.h:72
LPDDRAWI_DIRECTDRAW_GBL lpDD
Definition: ddrawi.h:1859
#define DDHAL_SURFCB32_SETOVERLAYPOSITION
Definition: ddrawi.h:685
LPDDHALSURFCB_SETOVERLAYPOSITION SetOverlayPosition
Definition: ddrawi.h:1865
#define X(b, s)

Referenced by Thunk_DDrawSurface3_SetOverlayPosition().

◆ Main_DDrawSurface_SetPalette()

HRESULT WINAPI Main_DDrawSurface_SetPalette ( LPDDRAWI_DDRAWSURFACE_INT  ,
LPDIRECTDRAWPALETTE   
)

Definition at line 214 of file surface_stubs.c.

216 {
217  DX_WINDBG_trace();
218 
219  DX_STUB;
220 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_SetPalette().

◆ Main_DDrawSurface_SetPriority()

HRESULT WINAPI Main_DDrawSurface_SetPriority ( LPDDRAWI_DDRAWSURFACE_INT  ,
DWORD   
)

Definition at line 223 of file surface_stubs.c.

225 {
226  DX_WINDBG_trace();
227 
228  DX_STUB;
229 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

◆ Main_DDrawSurface_SetPrivateData()

HRESULT WINAPI Main_DDrawSurface_SetPrivateData ( LPDDRAWI_DDRAWSURFACE_INT  ,
REFGUID  ,
LPVOID  ,
DWORD  ,
DWORD   
)

Definition at line 232 of file surface_stubs.c.

235 {
236  DX_WINDBG_trace();
237 
238  DX_STUB;
239 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

◆ Main_DDrawSurface_SetSurfaceDesc()

HRESULT WINAPI Main_DDrawSurface_SetSurfaceDesc ( LPDDRAWI_DDRAWSURFACE_INT  ,
DDSURFACEDESC2 ,
DWORD   
)

Definition at line 280 of file surface_stubs.c.

281 {
282  DX_WINDBG_trace();
283 
284  DX_STUB;
285 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_SetSurfaceDesc().

◆ Main_DDrawSurface_Unlock()

HRESULT WINAPI Main_DDrawSurface_Unlock ( LPDDRAWI_DDRAWSURFACE_INT  ,
LPRECT   
)

Definition at line 523 of file surface_main.c.

524 {
525  DDHAL_UNLOCKDATA mdUnLock;
526 
527  DX_WINDBG_trace();
528 
529  /* Zero out members in DDHAL_UNLOCKDATA */
530  ZeroMemory(&mdUnLock, sizeof(DDHAL_UNLOCKDATA));
531 
532  /* Check if we got HAL support for this api */
533  if (( This->lpLcl->lpGbl->lpDD->lpDDCBtmp->HALDDSurface.dwFlags &
535  {
536  mdUnLock.Unlock = This->lpLcl->lpSurfMore->lpDD_lcl->lpGbl->lpDDCBtmp->HALDDSurface.Unlock;
537  }
538  /* Check if we got HEL support for this api */
539  else if (( This->lpLcl->lpGbl->lpDD->lpDDCBtmp->HELDDSurface.dwFlags &
541  {
542  mdUnLock.Unlock = This->lpLcl->lpSurfMore->lpDD_lcl->lpGbl->lpDDCBtmp->HELDDSurface.Unlock;
543  }
544 
545  if (mdUnLock.Unlock == NULL)
546  {
547  /* This api are unsupported */
548  return DDERR_UNSUPPORTED;
549  }
550 
551  mdUnLock.ddRVal = DDERR_NOTPALETTIZED;
552  mdUnLock.lpDD = This->lpLcl->lpSurfMore->lpDD_lcl->lpGbl;
553  mdUnLock.lpDDSurface = This->lpLcl->lpSurfMore->slist[0];
554 
555  if (!DdResetVisrgn( mdUnLock.lpDDSurface, NULL))
556  {
557  DX_STUB_str("DdResetVisrgn fail");
558  //return DDERR_UNSUPPORTED; /* this can fail */
559  }
560 
561  if (mdUnLock.Unlock(&mdUnLock)!= DDHAL_DRIVER_HANDLED)
562  {
563  DX_STUB_str("unLock fail");
564  return DDERR_UNSUPPORTED;
565  }
566 
567  return mdUnLock.ddRVal;
568 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DDERR_UNSUPPORTED
Definition: ddraw.h:127
#define DdResetVisrgn
Definition: ddrawgdi.h:29
#define DX_STUB_str(x)
Definition: rosdraw.h:254
LPDDRAWI_DDRAWSURFACE_LCL lpDDSurface
Definition: ddrawi.h:840
#define ZeroMemory
Definition: winbase.h:1642
#define DDERR_NOTPALETTIZED
Definition: ddraw.h:163
LPDDRAWI_DIRECTDRAW_GBL lpDD
Definition: ddrawi.h:839
#define DDHAL_DRIVER_HANDLED
Definition: ddrawi.h:321
smooth NULL
Definition: ftsmooth.c:416
LPDDHALSURFCB_UNLOCK Unlock
Definition: ddrawi.h:842
HRESULT ddRVal
Definition: ddrawi.h:841
#define DDHAL_SURFCB32_UNLOCK
Definition: ddrawi.h:678

◆ Main_DDrawSurface_UpdateOverlay()

HRESULT WINAPI Main_DDrawSurface_UpdateOverlay ( LPDDRAWI_DDRAWSURFACE_INT  ,
LPRECT  ,
LPDDRAWI_DDRAWSURFACE_INT  ,
LPRECT  ,
DWORD  ,
LPDDOVERLAYFX   
)

Definition at line 242 of file surface_stubs.c.

247 {
248  DX_WINDBG_trace();
249 
250  DX_STUB;
251 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_UpdateOverlay().

◆ Main_DDrawSurface_UpdateOverlayDisplay()

HRESULT WINAPI Main_DDrawSurface_UpdateOverlayDisplay ( LPDDRAWI_DDRAWSURFACE_INT  ,
DWORD   
)

Definition at line 256 of file surface_stubs.c.

258 {
259 
260  DX_WINDBG_trace();
261 
262  if (!(This->lpLcl->lpGbl->lpDD->lpDDCBtmp->cbDDSurfaceCallbacks.dwFlags & DDHAL_SURFCB32_UPDATEOVERLAY))
263  {
264  return DDERR_GENERIC;
265  }
266 
267  DX_STUB;
268 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DDHAL_SURFCB32_UPDATEOVERLAY
Definition: ddrawi.h:684
#define DDERR_GENERIC
Definition: ddraw.h:72
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_UpdateOverlayDisplay().

◆ Main_DDrawSurface_UpdateOverlayZOrder()

HRESULT WINAPI Main_DDrawSurface_UpdateOverlayZOrder ( LPDDRAWI_DDRAWSURFACE_INT  ,
DWORD  ,
LPDDRAWI_DDRAWSURFACE_INT   
)

Definition at line 271 of file surface_stubs.c.

273 {
274  DX_WINDBG_trace();
275 
276  DX_STUB;
277 }
#define DX_WINDBG_trace()
Definition: rosdraw.h:262
#define DX_STUB
Definition: rosdraw.h:224

Referenced by Thunk_DDrawSurface3_UpdateOverlayZOrder().