- Timestamp:
- Nov 27, 2010, 11:27:43 AM (15 years ago)
- Location:
- trunk/src
- Files:
-
- 21 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/ddraw/clipper.cpp
r9459 r21479 20 20 #include <memory.h> 21 21 22 #define INITGUID22 #define CINTERFACE 23 23 #include "ddraw2d.h" 24 24 #include "clipper.h" 25 25 26 #include <misc.h> 26 27 #include <winerror.h> … … 39 40 // no ddraw object is associated 40 41 41 lpVtbl = &Vtbl;42 Vtbl. AddRef = ClipAddRef;43 Vtbl. Release = ClipRelease;44 Vtbl. QueryInterface = ClipQueryInterface;45 Vtbl. GetClipList = ClipGetClipList;46 Vtbl. GetHWnd = ClipGetHWnd;47 Vtbl. Initialize = ClipInitialize;48 Vtbl. IsClipListChanged = ClipIsClipListChanged;49 Vtbl. SetClipList = ClipSetClipList;50 Vtbl. SetHWnd = ClipSetHWnd;51 52 lpDraw = NULL;42 lpVtbl = &Vtbl; 43 Vtbl.fnAddRef = ClipAddRef; 44 Vtbl.fnRelease = ClipRelease; 45 Vtbl.fnQueryInterface = ClipQueryInterface; 46 Vtbl.fnGetClipList = ClipGetClipList; 47 Vtbl.fnGetHWnd = ClipGetHWnd; 48 Vtbl.fnInitialize = ClipInitialize; 49 Vtbl.fnIsClipListChanged = ClipIsClipListChanged; 50 Vtbl.fnSetClipList = ClipSetClipList; 51 Vtbl.fnSetHWnd = ClipSetHWnd; 52 53 lpDraw = NULL; 53 54 // lpDraw->Vtbl.AddRef(lpDraw); 54 55 // hDive = lpDirectDraw->GetDiveInstance(); … … 63 64 fClipListChangedInt(FALSE) 64 65 { 65 lpVtbl = &Vtbl;66 Vtbl. AddRef = ClipAddRef;67 Vtbl. Release = ClipRelease;68 Vtbl. QueryInterface = ClipQueryInterface;69 Vtbl. GetClipList = ClipGetClipList;70 Vtbl. GetHWnd = ClipGetHWnd;71 Vtbl. Initialize = ClipInitialize;72 Vtbl. IsClipListChanged = ClipIsClipListChanged;73 Vtbl. SetClipList = ClipSetClipList;74 Vtbl. SetHWnd = ClipSetHWnd;75 76 lpDraw = lpDirectDraw;77 lpDraw->Vtbl. AddRef(lpDraw);78 hDive = lpDirectDraw->GetDiveInstance();66 lpVtbl = &Vtbl; 67 Vtbl.fnAddRef = ClipAddRef; 68 Vtbl.fnRelease = ClipRelease; 69 Vtbl.fnQueryInterface = ClipQueryInterface; 70 Vtbl.fnGetClipList = ClipGetClipList; 71 Vtbl.fnGetHWnd = ClipGetHWnd; 72 Vtbl.fnInitialize = ClipInitialize; 73 Vtbl.fnIsClipListChanged = ClipIsClipListChanged; 74 Vtbl.fnSetClipList = ClipSetClipList; 75 Vtbl.fnSetHWnd = ClipSetHWnd; 76 77 lpDraw = lpDirectDraw; 78 lpDraw->Vtbl.fnAddRef(lpDraw); 79 hDive = lpDirectDraw->GetDiveInstance(); 79 80 } 80 81 //****************************************************************************** 81 82 //****************************************************************************** 82 83 OS2IDirectDrawClipper::~OS2IDirectDrawClipper() 83 { 84 { 84 85 if(lpRgnData) free(lpRgnData); 85 86 if(clipWindow) { 86 87 WinSetVisibleRgnNotifyProc(clipWindow, NULL, 0); 87 88 } 88 lpDraw->Vtbl. Release(lpDraw);89 lpDraw->Vtbl.fnRelease(lpDraw); 89 90 } 90 91 //****************************************************************************** … … 96 97 *ppvObj = NULL; 97 98 98 if(!IsEqualGUID(riid, IID_IDirectDrawClipper) &&99 !IsEqualGUID(riid, CLSID_DirectDrawClipper))99 if(!IsEqualGUID(riid, &IID_IDirectDrawClipper) && 100 !IsEqualGUID(riid, &CLSID_DirectDrawClipper)) 100 101 //&& !IsEqualGUID(riid, IID_IUnknown)) 101 102 return E_NOINTERFACE; … … 140 141 //****************************************************************************** 141 142 //****************************************************************************** 142 HRESULT WIN32API ClipGetClipList(THIS This, LPRECT lpRect, LPRGNDATA lpClipList, 143 HRESULT WIN32API ClipGetClipList(THIS This, LPRECT lpRect, LPRGNDATA lpClipList, 143 144 LPDWORD lpdwSize) 144 145 { … … 154 155 dprintf(("WARNING: clipping the cliplist is not yet implemented")); 155 156 } 156 if(me->clipWindow) 157 if(me->clipWindow) 157 158 { 158 159 RECT *rect = (RECT *)&lpClipList->Buffer; … … 216 217 OS2IDirectDraw *os2DD = (OS2IDirectDraw *)lpDD; 217 218 me->lpDraw = os2DD; 218 me->lpDraw->Vtbl. AddRef(me->lpDraw);219 me->lpDraw->Vtbl.fnAddRef(me->lpDraw); 219 220 me->hDive = me->lpDraw->GetDiveInstance(); 220 221 } -
trunk/src/ddraw/ddclipper.cpp
r9459 r21479 19 19 #include <memory.h> 20 20 #include <stdio.h> 21 #define INITGUID 22 #define ICOM_CINTERFACE 1 21 23 22 #define CINTERFACE 24 25 23 #include "ddraw2d.h" 26 24 #include "clipper.h" … … 59 57 else 60 58 { 61 newDDClipper->Vtbl. AddRef((IDirectDrawClipper *)newDDClipper);59 newDDClipper->Vtbl.fnAddRef((IDirectDrawClipper *)newDDClipper); 62 60 63 61 rc = newDDClipper->GetLastError(); -
trunk/src/ddraw/ddmain.cpp
r9459 r21479 22 22 #include <memory.h> 23 23 #include <stdio.h> 24 #define INITGUID 25 #define ICOM_CINTERFACE 1 24 26 25 #define CINTERFACE 27 28 26 #include "ddraw2d.h" 29 27 #include "winerror.h" … … 50 48 else 51 49 { 52 newdraw->Vtbl. AddRef((IDirectDraw2 *)newdraw);50 newdraw->Vtbl.fnAddRef((IDirectDraw2 *)newdraw); 53 51 54 52 rc = newdraw->GetLastError(); … … 217 215 dprintf(("DDRAW:DDCF_CreateInstance")); 218 216 if( lpGUID && 219 ( (*lpGUID == IID_IDirectDraw) ||220 (*lpGUID ==IID_IDirectDraw2) ||221 (*lpGUID ==IID_IDirectDraw4))217 ( IsEqualGUID(lpGUID, &IID_IDirectDraw) || 218 IsEqualGUID(lpGUID, &IID_IDirectDraw2) || 219 IsEqualGUID(lpGUID, &IID_IDirectDraw4)) 222 220 ) 223 221 { … … 267 265 { 268 266 *ppv = (LPVOID)&DDRAW_CF; 269 DDRAW_CF.lpvtbl-> AddRef((IClassFactory*)&DDRAW_CF);267 DDRAW_CF.lpvtbl->fnAddRef((IClassFactory*)&DDRAW_CF); 270 268 return S_OK; 271 269 } -
trunk/src/ddraw/ddraw2d.cpp
r9560 r21479 23 23 24 24 #define INITGUID 25 #define CINTERFACE 25 26 #include "ddraw2d.h" 26 27 #include "clipper.h" 27 28 #include "palette.h" 28 29 #include "surface.h" 30 29 31 #include <misc.h> 30 32 #include <string.h> … … 105 107 106 108 107 if(lpGUID && *lpGUID == IID_IDirect3D)109 if(lpGUID && IsEqualGUID(lpGUID, &IID_IDirect3D)) 108 110 { 109 111 dprintf(("DDRAW: D3D Interface -> using V4 Interface")); … … 113 115 else 114 116 { 115 if(lpGUID && *lpGUID == IID_IDirectDraw4)117 if(lpGUID && IsEqualGUID(lpGUID, &IID_IDirectDraw4)) 116 118 { 117 119 dprintf(("DDRAW: V4 Interface\n")); … … 184 186 185 187 // Check to see if FS DDraw is enabled in ODIN.INI 186 if (!fNoFSDD && PROFILE_GetOdinIniBool(ODINDDRAW_SECTION, "Fullscreen", FALSE)) 188 if (!fNoFSDD && PROFILE_GetOdinIniBool(ODINDDRAW_SECTION, "Fullscreen", FALSE)) 187 189 { 188 190 #if 0 … … 201 203 rc = LoadPMIService(); 202 204 dprintf(("DDRAW: LoadPMIService() rc=0x%08X",rc)); 203 205 204 206 if (!rc) { 205 207 SetUpModeTable(); 206 208 207 209 bUseFSDD = TRUE; 208 210 dprintf(("DDRAW: Fullscreen enabled",rc)); 209 } 210 } 211 } 212 } 211 213 } 212 214 //****************************************************************************** … … 258 260 *ppvObj = NULL; 259 261 260 if(!IsEqualGUID(riid, CLSID_DirectDraw) &&261 !IsEqualGUID(riid, IID_IDirectDraw) &&262 !IsEqualGUID(riid, IID_IDirectDraw2) &&263 !IsEqualGUID(riid, IID_IDirectDraw4) &&264 !IsEqualGUID(riid, IID_IDirect3D))262 if(!IsEqualGUID(riid, &CLSID_DirectDraw) && 263 !IsEqualGUID(riid, &IID_IDirectDraw) && 264 !IsEqualGUID(riid, &IID_IDirectDraw2) && 265 !IsEqualGUID(riid, &IID_IDirectDraw4) && 266 !IsEqualGUID(riid, &IID_IDirect3D)) 265 267 // !IsEqualGUID(riid, IID_IUnknown)) 266 268 return E_NOINTERFACE; 267 269 268 270 // ToDo Better way of returning differnent interfaces for same class 269 if(IsEqualGUID(riid, IID_IDirect3D))271 if(IsEqualGUID(riid, &IID_IDirect3D)) 270 272 { 271 273 me->lpVtbl3D = &me->Vtbl3D; … … 278 280 else 279 281 { 280 if(IsEqualGUID(riid, IID_IDirectDraw4))282 if(IsEqualGUID(riid, &IID_IDirectDraw4)) 281 283 { 282 284 dprintf(("DDRAW: IID_IDirectDraw4 Interface")); … … 285 287 else 286 288 { 287 if(IsEqualGUID(riid, IID_IDirectDraw2))289 if(IsEqualGUID(riid, &IID_IDirectDraw2)) 288 290 { 289 291 dprintf(("DDRAW: IID_IDirectDraw2 Interface")); … … 366 368 else 367 369 { 368 newclip->Vtbl. AddRef((IDirectDrawClipper *)newclip);370 newclip->Vtbl.fnAddRef((IDirectDrawClipper *)newclip); 369 371 rc = newclip->GetLastError(); 370 372 if(rc != DD_OK) … … 422 424 else 423 425 { 424 newpal->Vtbl. AddRef((IDirectDrawPalette *)newpal);426 newpal->Vtbl.fnAddRef((IDirectDrawPalette *)newpal); 425 427 rc = newpal->GetLastError(); 426 428 … … 465 467 else 466 468 { 467 newsurf->Vtbl. AddRef((IDirectDrawSurface *)newsurf);469 newsurf->Vtbl.fnAddRef((IDirectDrawSurface *)newsurf); 468 470 rc = newsurf->GetLastError(); 469 471 if(rc != DD_OK) … … 509 511 else 510 512 { 511 newsurf->Vtbl. AddRef((IDirectDrawSurface *)newsurf);513 newsurf->Vtbl.fnAddRef((IDirectDrawSurface *)newsurf); 512 514 rc = newsurf->GetLastError(); 513 515 if(rc != DD_OK) … … 2089 2091 // Setup table for 3d devices 2090 2092 //****************************************************************************** 2091 IDirect3DVtbl DDraw3DTable = 2092 { 2093 D3DQueryInterface, 2094 D3DAddRef, 2095 D3DRelease, 2096 D3DInitialize, 2097 D3DEnumDevices, 2098 D3DCreateLight, 2099 D3DCreateMaterial, 2100 D3DCreateViewport, 2093 IDirect3DVtbl DDraw3DTable = 2094 { 2095 D3DQueryInterface, 2096 D3DAddRef, 2097 D3DRelease, 2098 D3DInitialize, 2099 D3DEnumDevices, 2100 D3DCreateLight, 2101 D3DCreateMaterial, 2102 D3DCreateViewport, 2101 2103 D3DFindDevice 2102 2104 }; … … 2104 2106 // Org Interface 2105 2107 //****************************************************************************** 2106 IDirectDrawVtbl DDrawV1Table = 2107 { 2108 DrawQueryInterface, 2109 DrawAddRef, 2110 DrawRelease, 2111 DrawCompact, 2112 DrawCreateClipper, 2113 DrawCreatePalette, 2114 DrawCreateSurface, 2115 DrawDuplicateSurface, 2116 DrawEnumDisplayModes, 2117 DrawEnumSurfaces, 2118 DrawFlipToGDISurface, 2119 DrawGetCaps, 2120 DrawGetDisplayMode, 2121 DrawGetFourCCCodes, 2122 DrawGetGDISurface, 2123 DrawGetMonitorFrequency, 2124 DrawGetScanLine, 2125 DrawGetVerticalBlankStatus, 2126 DrawInitialize, 2127 DrawRestoreDisplayMode, 2128 DrawSetCooperativeLevel, 2129 DrawSetDisplayMode, 2108 IDirectDrawVtbl DDrawV1Table = 2109 { 2110 DrawQueryInterface, 2111 DrawAddRef, 2112 DrawRelease, 2113 DrawCompact, 2114 DrawCreateClipper, 2115 DrawCreatePalette, 2116 DrawCreateSurface, 2117 DrawDuplicateSurface, 2118 DrawEnumDisplayModes, 2119 DrawEnumSurfaces, 2120 DrawFlipToGDISurface, 2121 DrawGetCaps, 2122 DrawGetDisplayMode, 2123 DrawGetFourCCCodes, 2124 DrawGetGDISurface, 2125 DrawGetMonitorFrequency, 2126 DrawGetScanLine, 2127 DrawGetVerticalBlankStatus, 2128 DrawInitialize, 2129 DrawRestoreDisplayMode, 2130 DrawSetCooperativeLevel, 2131 DrawSetDisplayMode, 2130 2132 DrawWaitForVerticalBlank 2131 2133 }; … … 2133 2135 // V2 Interface 2134 2136 //****************************************************************************** 2135 IDirectDraw2Vtbl DDrawV2Table = 2136 { 2137 DrawQueryInterface, 2138 DrawAddRef, 2139 DrawRelease, 2140 DrawCompact, 2141 DrawCreateClipper, 2142 DrawCreatePalette, 2143 DrawCreateSurface, 2144 DrawDuplicateSurface, 2145 DrawEnumDisplayModes, 2146 DrawEnumSurfaces, 2147 DrawFlipToGDISurface, 2148 DrawGetCaps, 2149 DrawGetDisplayMode, 2150 DrawGetFourCCCodes, 2151 DrawGetGDISurface, 2152 DrawGetMonitorFrequency, 2153 DrawGetScanLine, 2154 DrawGetVerticalBlankStatus, 2155 DrawInitialize, 2156 DrawRestoreDisplayMode, 2157 DrawSetCooperativeLevel, 2158 DrawSetDisplayMode2, 2159 DrawWaitForVerticalBlank, 2137 IDirectDraw2Vtbl DDrawV2Table = 2138 { 2139 DrawQueryInterface, 2140 DrawAddRef, 2141 DrawRelease, 2142 DrawCompact, 2143 DrawCreateClipper, 2144 DrawCreatePalette, 2145 DrawCreateSurface, 2146 DrawDuplicateSurface, 2147 DrawEnumDisplayModes, 2148 DrawEnumSurfaces, 2149 DrawFlipToGDISurface, 2150 DrawGetCaps, 2151 DrawGetDisplayMode, 2152 DrawGetFourCCCodes, 2153 DrawGetGDISurface, 2154 DrawGetMonitorFrequency, 2155 DrawGetScanLine, 2156 DrawGetVerticalBlankStatus, 2157 DrawInitialize, 2158 DrawRestoreDisplayMode, 2159 DrawSetCooperativeLevel, 2160 DrawSetDisplayMode2, 2161 DrawWaitForVerticalBlank, 2160 2162 DrawGetAvailableVidMem 2161 2163 }; … … 2163 2165 // New V4 interface 2164 2166 //****************************************************************************** 2165 IDirectDraw4Vtbl DDrawV4Table = 2166 { 2167 DrawQueryInterface, 2168 DrawAddRef, // todo change to a DrawAddRef4 as handling this has change, 2169 DrawRelease, // see abov, 2170 DrawCompact, 2171 DrawCreateClipper, 2172 DrawCreatePalette, 2173 DrawCreateSurface4, 2174 DrawDuplicateSurface4, 2175 DrawEnumDisplayModes4, 2176 DrawEnumSurfaces4, 2177 DrawFlipToGDISurface, 2178 DrawGetCaps, 2179 DrawGetDisplayMode4, 2180 DrawGetFourCCCodes, 2181 DrawGetGDISurface4, 2182 DrawGetMonitorFrequency, 2183 DrawGetScanLine, 2184 DrawGetVerticalBlankStatus, 2185 DrawInitialize, 2186 DrawRestoreDisplayMode, 2187 DrawSetCooperativeLevel, 2188 DrawSetDisplayMode2, 2189 DrawWaitForVerticalBlank, 2190 DrawGetAvailableVidMem4, 2191 DrawGetSurfaceFromDC, 2192 DrawRestoreAllSurfaces, 2193 DrawTestCooperativeLevel, 2194 DrawGetDeviceIdentifier, 2167 IDirectDraw4Vtbl DDrawV4Table = 2168 { 2169 DrawQueryInterface, 2170 DrawAddRef, // todo change to a DrawAddRef4 as handling this has change, 2171 DrawRelease, // see abov, 2172 DrawCompact, 2173 DrawCreateClipper, 2174 DrawCreatePalette, 2175 DrawCreateSurface4, 2176 DrawDuplicateSurface4, 2177 DrawEnumDisplayModes4, 2178 DrawEnumSurfaces4, 2179 DrawFlipToGDISurface, 2180 DrawGetCaps, 2181 DrawGetDisplayMode4, 2182 DrawGetFourCCCodes, 2183 DrawGetGDISurface4, 2184 DrawGetMonitorFrequency, 2185 DrawGetScanLine, 2186 DrawGetVerticalBlankStatus, 2187 DrawInitialize, 2188 DrawRestoreDisplayMode, 2189 DrawSetCooperativeLevel, 2190 DrawSetDisplayMode2, 2191 DrawWaitForVerticalBlank, 2192 DrawGetAvailableVidMem4, 2193 DrawGetSurfaceFromDC, 2194 DrawRestoreAllSurfaces, 2195 DrawTestCooperativeLevel, 2196 DrawGetDeviceIdentifier, 2195 2197 }; 2196 2198 //****************************************************************************** -
trunk/src/ddraw/ddraw3d.cpp
r9560 r21479 14 14 #include <memory.h> 15 15 16 #define INITGUID17 16 #define _OS2WIN_H 18 17 #define FAR … … 20 19 #include <odin.h> 21 20 #include <winbase.h> 21 22 #define CINTERFACE 22 23 #include "ddraw2d.h" 23 24 #include "clipper.h" 24 25 #include "palette.h" 25 26 #include "surface.h" 27 26 28 #include <misc.h> 27 29 #include <winerror.h> … … 36 38 *ppvObj = NULL; 37 39 38 if (!IsEqualGUID(riid, IID_IDirect3D))40 if (!IsEqualGUID(riid, &IID_IDirect3D)) 39 41 return E_NOINTERFACE; 40 42 -
trunk/src/ddraw/palette.cpp
r9560 r21479 20 20 #include <string.h> 21 21 #include <memory.h> 22 #define INITGUID 22 23 #define CINTERFACE 23 24 #include "ddraw2d.h" 24 25 #include "clipper.h" 25 26 #include "palette.h" 26 27 #include "surface.h" 28 27 29 #include <misc.h> 28 30 #include "os2palset.h" … … 49 51 50 52 lpDraw = lpDirectDraw; 51 ((OS2IDirectDraw*)lpDraw)->Vtbl. AddRef(lpDraw);53 ((OS2IDirectDraw*)lpDraw)->Vtbl.fnAddRef(lpDraw); 52 54 hDive = ((OS2IDirectDraw*)lpDirectDraw)->GetDiveInstance(); 53 55 dwCaps = dwPalFlags; … … 85 87 if(os2pal) 86 88 free(os2pal); 87 ((OS2IDirectDraw*)lpDraw)->Vtbl. Release((OS2IDirectDraw*)lpDraw);89 ((OS2IDirectDraw*)lpDraw)->Vtbl.fnRelease((OS2IDirectDraw*)lpDraw); 88 90 } 89 91 //****************************************************************************** … … 95 97 *ppvObj = NULL; 96 98 97 if(!IsEqualGUID(riid, IID_IDirectDrawPalette))98 //&& !IsEqualGUID(riid, IID_IUnknown))99 if(!IsEqualGUID(riid, &IID_IDirectDrawPalette)) 100 //&& !IsEqualGUID(riid, &IID_IUnknown)) 99 101 return E_NOINTERFACE; 100 102 … … 237 239 // Run appropriate code depening on whether FS DDraw is enabled 238 240 if (bUseFSDD) 239 SetSVGAPalette(os2pal); 240 else 241 SetSVGAPalette(os2pal); 242 else 241 243 OS2SetPhysPalette(os2pal); 242 244 } … … 270 272 //****************************************************************************** 271 273 //****************************************************************************** 272 IDirectDrawPaletteVtbl DDrawPaletteTable = 274 IDirectDrawPaletteVtbl DDrawPaletteTable = 273 275 { 274 276 PalQueryInterface, -
trunk/src/ddraw/surface.cpp
r9566 r21479 24 24 ( (DWORD)(BYTE)(ch2) << 16 ) | ( (DWORD)(BYTE)(ch3) << 24 ) ) 25 25 #include <fourcc.h> 26 #define INITGUID 26 27 #define CINTERFACE 27 28 #include "ddraw2d.h" 28 29 #include "clipper.h" … … 82 83 83 84 lpDraw = lpDirectDraw; 84 lpDraw->Vtbl. AddRef(lpDraw);85 lpDraw->Vtbl.fnAddRef(lpDraw); 85 86 86 87 ImplicitSurface = Implicit; … … 283 284 //TODO: Docs say this is done, but does it really happen in windows? 284 285 // check for invalid flag combinations 285 switch(lpDDSurfaceDesc->ddsCaps.dwCaps2 & (DDSCAPS2_OPAQUE|DDSCAPS2_HINTDYNAMIC|DDSCAPS2_HINTSTATIC)) 286 switch(lpDDSurfaceDesc->ddsCaps.dwCaps2 & (DDSCAPS2_OPAQUE|DDSCAPS2_HINTDYNAMIC|DDSCAPS2_HINTSTATIC)) 286 287 { 287 288 case 0: … … 439 440 440 441 BackBuffer = new OS2IDirectDrawSurface(lpDraw, &ComplexSurfaceDesc, TRUE, TRUE); 441 BackBuffer->Vtbl. AddRef((IDirectDrawSurface *)BackBuffer);442 BackBuffer->Vtbl.fnAddRef((IDirectDrawSurface *)BackBuffer); 442 443 443 444 if (BackBuffer->GetLastError()==DD_OK) … … 477 478 { 478 479 DirectDrawSurface_RegisterClass(); 479 hwndFullScreen = DirectDrawSurface_CreateWindow(DDSurfaceDesc.dwWidth, 480 hwndFullScreen = DirectDrawSurface_CreateWindow(DDSurfaceDesc.dwWidth, 480 481 DDSurfaceDesc.dwHeight, 481 482 lpDraw->GetClientWindow()); … … 778 779 779 780 BackBuffer = new OS2IDirectDrawSurface(lpDraw, &ComplexSurfaceDesc, TRUE, TRUE); 780 BackBuffer->Vtbl. AddRef((IDirectDrawSurface *)BackBuffer);781 BackBuffer->Vtbl.fnAddRef((IDirectDrawSurface *)BackBuffer); 781 782 782 783 if (BackBuffer->GetLastError()==DD_OK) … … 808 809 } 809 810 BackBuffer = new OS2IDirectDrawSurface(lpDraw, &ComplexSurfaceDesc, TRUE, Mainchain); 810 BackBuffer->Vtbl. AddRef((IDirectDrawSurface *)BackBuffer);811 BackBuffer->Vtbl.fnAddRef((IDirectDrawSurface *)BackBuffer); 811 812 812 813 if (BackBuffer->GetLastError()==DD_OK) … … 840 841 841 842 MipMapSurface = new OS2IDirectDrawSurface(lpDraw, &ComplexSurfaceDesc, TRUE); 842 MipMapSurface->Vtbl. AddRef((IDirectDrawSurface *)MipMapSurface);843 MipMapSurface->Vtbl.fnAddRef((IDirectDrawSurface *)MipMapSurface); 843 844 844 845 DPA_InsertPtr( DPA_SurfaceMipMaps, … … 1150 1151 OS2IDirectDrawSurface *pSurf; 1151 1152 pSurf = (OS2IDirectDrawSurface *)lpItem; 1152 pSurf->Vtbl. Release(pSurf);1153 pSurf->Vtbl.fnRelease(pSurf); 1153 1154 return 1; 1154 1155 } … … 1202 1203 if(lpClipper) 1203 1204 { 1204 lpClipper->Vtbl. Release((IDirectDrawClipper*)lpClipper);1205 lpClipper->Vtbl.fnRelease((IDirectDrawClipper*)lpClipper); 1205 1206 lpClipper = NULL; 1206 1207 } … … 1208 1209 if(lpPalette) 1209 1210 { 1210 lpPalette->Vtbl. Release((IDirectDrawPalette*)lpPalette);1211 lpPalette->Vtbl.fnRelease((IDirectDrawPalette*)lpPalette); 1211 1212 lpPalette = NULL; 1212 1213 } … … 1219 1220 1220 1221 if (NULL!=BackBuffer) 1221 BackBuffer->Vtbl. Release(BackBuffer);1222 BackBuffer->Vtbl.fnRelease(BackBuffer); 1222 1223 1223 1224 if (DPA_GetPtrCount(DPA_SurfaceMipMaps)>0) … … 1235 1236 } 1236 1237 1237 lpDraw->Vtbl. Release(lpDraw);1238 lpDraw->Vtbl.fnRelease(lpDraw); 1238 1239 } 1239 1240 … … 1305 1306 *ppvObj = NULL; 1306 1307 1307 if(IsEqualGUID(riid, IID_IDirectDrawSurface))1308 if(IsEqualGUID(riid, &IID_IDirectDrawSurface)) 1308 1309 { 1309 1310 *ppvObj = &me->lpVtbl; // ToDo DO a real V1 table … … 1311 1312 goto RetFn; 1312 1313 } 1313 if(IsEqualGUID(riid, IID_IDirectDrawSurface2))1314 if(IsEqualGUID(riid, &IID_IDirectDrawSurface2)) 1314 1315 { 1315 1316 *ppvObj = &me->lpVtbl2; … … 1317 1318 goto RetFn; 1318 1319 } 1319 if(IsEqualGUID(riid, IID_IDirectDrawSurface3))1320 if(IsEqualGUID(riid, &IID_IDirectDrawSurface3)) 1320 1321 { 1321 1322 *ppvObj = &me->Vtbl3; … … 1323 1324 goto RetFn; 1324 1325 } 1325 if(IsEqualGUID(riid, IID_IDirectDrawSurface4))1326 if(IsEqualGUID(riid, &IID_IDirectDrawSurface4)) 1326 1327 { 1327 1328 *ppvObj = This; … … 1329 1330 } 1330 1331 1331 //if(IsEqualGUID(riid, IID_IUnknown)) ...1332 //if(IsEqualGUID(riid, &IID_IUnknown)) ... 1332 1333 1333 1334 RetFn: … … 1432 1433 me->DDSurfaceDesc.dwMipMapCount++; 1433 1434 1434 AttachedSurface->Vtbl. AddRef(AttachedSurface);1435 AttachedSurface->Vtbl.fnAddRef(AttachedSurface); 1435 1436 } 1436 1437 else … … 1454 1455 if(rc>=0) 1455 1456 { 1456 AttachedSurface->Vtbl. AddRef(AttachedSurface);1457 AttachedSurface->Vtbl.fnAddRef(AttachedSurface); 1457 1458 } 1458 1459 else … … 1508 1509 me->DDSurfaceDesc.ddsCaps.dwCaps |= DDSCAPS_FLIP; 1509 1510 1510 AttachedSurface->Vtbl. AddRef(AttachedSurface);1511 AttachedSurface->Vtbl.fnAddRef(AttachedSurface); 1511 1512 return (DD_OK); 1512 1513 } … … 1531 1532 me->DDSurfaceDesc.ddsCaps.dwCaps |= DDSCAPS_FRONTBUFFER; 1532 1533 1533 AttachedSurface->Vtbl. AddRef(AttachedSurface);1534 AttachedSurface->Vtbl.fnAddRef(AttachedSurface); 1534 1535 } 1535 1536 else … … 1551 1552 AttachedSurface) >=0) 1552 1553 { 1553 AttachedSurface->Vtbl. AddRef(AttachedSurface);1554 AttachedSurface->Vtbl.fnAddRef(AttachedSurface); 1554 1555 } 1555 1556 else … … 1655 1656 AttachedSurface->DDSurfaceDesc.ddsCaps.dwCaps &= ~DDSCAPS_FLIP; 1656 1657 AttachedSurface->DDSurfaceDesc.ddsCaps.dwCaps |= DDSCAPS_BACKBUFFER; // Set this flag as adding to the chain removed it 1657 AttachedSurface->lpVtbl-> Release(AttachedSurface);1658 AttachedSurface->lpVtbl->fnRelease(AttachedSurface); 1658 1659 1659 1660 } … … 1682 1683 AttachedSurface->DDSurfaceDesc.dwFlags &= ~DDSD_BACKBUFFERCOUNT; 1683 1684 AttachedSurface->DDSurfaceDesc.ddsCaps.dwCaps &= ~DDSCAPS_FLIP; 1684 AttachedSurface->lpVtbl-> Release(AttachedSurface);1685 AttachedSurface->lpVtbl->fnRelease(AttachedSurface); 1685 1686 } 1686 1687 … … 1698 1699 Found = TRUE; 1699 1700 DPA_DeletePtr(me->DPA_SurfaceMipMaps,i); 1700 AttachedSurface->lpVtbl-> Release(AttachedSurface);1701 AttachedSurface->lpVtbl->fnRelease(AttachedSurface); 1701 1702 // adjust our info 1702 1703 me->DDSurfaceDesc.dwMipMapCount-- ; … … 1720 1721 Found = TRUE; 1721 1722 DPA_DeletePtr(me->DPA_SurfaceAttached,i); 1722 AttachedSurface->lpVtbl-> Release(AttachedSurface);1723 AttachedSurface->lpVtbl->fnRelease(AttachedSurface); 1723 1724 } 1724 1725 i++; … … 2037 2038 *lpDDSurf = (IDirectDrawSurface4*)AttachedSurface; 2038 2039 // not sure but as we returned an reference rains usage count 2039 AttachedSurface->lpVtbl-> AddRef(AttachedSurface);2040 AttachedSurface->lpVtbl->fnAddRef(AttachedSurface); 2040 2041 } 2041 2042 else … … 2388 2389 2389 2390 #if 0 2390 if(me->diveBufNr == DIVE_BUFFER_SCREEN) 2391 if(me->diveBufNr == DIVE_BUFFER_SCREEN) 2391 2392 { 2392 2393 OS2RECTL rectOS2; … … 2405 2406 me->fLocked = TRUE; 2406 2407 2407 if(me->diveBufNr == DIVE_BUFFER_SCREEN) 2408 if(me->diveBufNr == DIVE_BUFFER_SCREEN) 2408 2409 { 2409 2410 //If fHideCursorOnLock is set, then we hide the cursor to prevent … … 2436 2437 LockedSurfaceDesc.dwSize = sizeof(DDSURFACEDESC2); 2437 2438 2438 if(DD_OK != me->Vtbl. Lock(me,NULL,&LockedSurfaceDesc,0,0))2439 if(DD_OK != me->Vtbl.fnLock(me,NULL,&LockedSurfaceDesc,0,0)) 2439 2440 { 2440 2441 return(DDERR_DCALREADYCREATED); … … 2450 2451 { 2451 2452 dprintf(("DDRAW: Can't create compatible DC!\n")); 2452 me->Vtbl. Unlock(me,NULL);2453 me->Vtbl.fnUnlock(me,NULL); 2453 2454 rc = DDERR_GENERIC; 2454 2455 } … … 2484 2485 ddpal = me->FrontBuffer->lpPalette; 2485 2486 if (ddpal != NULL) { 2486 ddpal->Vtbl. GetEntries((IDirectDrawPalette*)ddpal,2487 ddpal->Vtbl.fnGetEntries((IDirectDrawPalette*)ddpal, 2487 2488 0, 0, 256, (PPALETTEENTRY)&BitmapInfo.bmiCols[0]); 2488 2489 } … … 2531 2532 DeleteDC(me->hdcImage); 2532 2533 me->hdcImage = NULL; 2533 me->Vtbl. Unlock(me,NULL);2534 me->Vtbl.fnUnlock(me,NULL); 2534 2535 rc = DDERR_GENERIC; 2535 2536 } … … 2592 2593 DeleteObject(me->hbmImage); 2593 2594 me->hbmImage = NULL; 2594 me->Vtbl. Unlock(me,NULL);2595 me->Vtbl.fnUnlock(me,NULL); 2595 2596 rc = DDERR_GENERIC; 2596 2597 } … … 2699 2700 } // end switch (me->DDSurfaceDesc.ddpfPixelFormat.dwRGBBitCount) 2700 2701 2701 me->Vtbl. Unlock(me,NULL);2702 me->Vtbl.fnUnlock(me,NULL); 2702 2703 me->dwLastDCUnique = me->dwUniqueValue; // Store this to see if the surface was locked after we released the DC 2703 2704 … … 2725 2726 if(me->lpClipper) 2726 2727 { 2727 me->lpClipper->Vtbl. Release((IDirectDrawClipper*)me->lpClipper);2728 me->lpClipper->Vtbl.fnRelease((IDirectDrawClipper*)me->lpClipper); 2728 2729 me->lpClipper = NULL; 2729 2730 return(DD_OK); … … 2738 2739 if(me->lpClipper != NULL) 2739 2740 { 2740 me->lpClipper->Vtbl. Release((IDirectDrawClipper*)me->lpClipper); //attach other surface2741 me->lpClipper->Vtbl.fnRelease((IDirectDrawClipper*)me->lpClipper); //attach other surface 2741 2742 return(DD_OK); 2742 2743 } 2743 2744 2744 2745 me->lpClipper = (OS2IDirectDrawClipper *)lpClipper; 2745 me->lpClipper->Vtbl. AddRef((IDirectDrawClipper*)me->lpClipper);2746 me->lpClipper->Vtbl.fnAddRef((IDirectDrawClipper*)me->lpClipper); 2746 2747 2747 2748 return(DD_OK); … … 2817 2818 me->lpPalette->SetIsPrimary(FALSE); 2818 2819 } 2819 me->lpPalette->Vtbl. Release((IDirectDrawPalette*)me->lpPalette);2820 me->lpPalette->Vtbl.fnRelease((IDirectDrawPalette*)me->lpPalette); 2820 2821 me->lpPalette = NULL; 2821 2822 return(DD_OK); … … 2830 2831 if(me->lpPalette != NULL) 2831 2832 { 2832 me->lpPalette->Vtbl. Release((IDirectDrawPalette*)me->lpPalette); //attach other palette2833 me->lpPalette->Vtbl.fnRelease((IDirectDrawPalette*)me->lpPalette); //attach other palette 2833 2834 //return(DD_OK); 2834 2835 } 2835 2836 me->lpPalette = (OS2IDirectDrawPalette *)lpPalette; 2836 me->lpPalette->Vtbl. AddRef((IDirectDrawPalette*)me->lpPalette);2837 me->lpPalette->Vtbl.fnAddRef((IDirectDrawPalette*)me->lpPalette); 2837 2838 2838 2839 // If Attached to a primary surface notify … … 2988 2989 2989 2990 #if 0 2990 if(me->diveBufNr == DIVE_BUFFER_SCREEN) 2991 if(me->diveBufNr == DIVE_BUFFER_SCREEN) 2991 2992 { 2992 2993 OS2RECTL rectOS2; … … 3013 3014 rc = DD_OK; 3014 3015 3015 if(me->diveBufNr == DIVE_BUFFER_SCREEN) 3016 if(me->diveBufNr == DIVE_BUFFER_SCREEN) 3016 3017 { 3017 3018 //If fHideCursorOnLock is set, then we hide the cursor to prevent in SurfLock4 … … 3282 3283 pSData = (PSURFPRIVATEDATA) DPA_FastGetPtr(me->DPA_SurfacePrivateData,i); 3283 3284 3284 if (IsEqualGUID( pSData->guidTag,refGUID))3285 if (IsEqualGUID(&pSData->guidTag,refGUID)) 3285 3286 bFound = TRUE; 3286 3287 … … 3303 3304 pSData->dwFlags = dwFlags; 3304 3305 pSData->isValid = TRUE; 3305 ((OS2IDirectDrawSurface *) lpData)->lpVtbl-> AddRef(lpData);3306 ((OS2IDirectDrawSurface *) lpData)->lpVtbl->fnAddRef(lpData); 3306 3307 } 3307 3308 else … … 3331 3332 { 3332 3333 // Change of IUNKOWNPOINTER => release old and add ref to new one 3333 ((OS2IDirectDrawSurface *)pSData->pData)->lpVtbl-> Release(pSData->pData);3334 ((OS2IDirectDrawSurface *)lpData)->lpVtbl-> AddRef(lpData);3334 ((OS2IDirectDrawSurface *)pSData->pData)->lpVtbl->fnRelease(pSData->pData); 3335 ((OS2IDirectDrawSurface *)lpData)->lpVtbl->fnAddRef(lpData); 3335 3336 pSData->pData = lpData; 3336 3337 } … … 3344 3345 { 3345 3346 // release old ref and copy data 3346 ((OS2IDirectDrawSurface *)pSData->pData)->lpVtbl-> Release(pSData->pData);3347 ((OS2IDirectDrawSurface *)pSData->pData)->lpVtbl->fnRelease(pSData->pData); 3347 3348 memcpy(pBuffer,lpData,dwDataSize); 3348 3349 pSData->pData = pBuffer; … … 3360 3361 // Change of data to IUNKOWNPOINTER => free old memory and add ref to new one 3361 3362 free(pSData->pData); 3362 ((OS2IDirectDrawSurface *)lpData)->lpVtbl-> AddRef(lpData);3363 ((OS2IDirectDrawSurface *)lpData)->lpVtbl->fnAddRef(lpData); 3363 3364 pSData->pData = lpData; 3364 3365 pSData->dwSize = dwDataSize; // Update the size … … 3401 3402 pSData->dwFlags = dwFlags; 3402 3403 pSData->isValid = TRUE; 3403 ((OS2IDirectDrawSurface *)lpData)->lpVtbl-> AddRef(lpData);3404 ((OS2IDirectDrawSurface *)lpData)->lpVtbl->fnAddRef(lpData); 3404 3405 } 3405 3406 else … … 3461 3462 pSData = (PSURFPRIVATEDATA) DPA_FastGetPtr(me->DPA_SurfacePrivateData,i); 3462 3463 3463 if (IsEqualGUID( pSData->guidTag,refGUID))3464 if (IsEqualGUID(&pSData->guidTag,refGUID)) 3464 3465 bFound = TRUE; 3465 3466 … … 3516 3517 pSData = (PSURFPRIVATEDATA) DPA_FastGetPtr(me->DPA_SurfacePrivateData,i); 3517 3518 3518 if (IsEqualGUID( pSData->guidTag,refGUID))3519 if (IsEqualGUID(&pSData->guidTag,refGUID)) 3519 3520 { 3520 3521 bFound = TRUE; … … 3526 3527 { 3527 3528 // pointer to com stored so calll its release 3528 ((OS2IDirectDrawSurface *) pSData->pData)->lpVtbl-> Release(pSData->pData);3529 ((OS2IDirectDrawSurface *) pSData->pData)->lpVtbl->fnRelease(pSData->pData); 3529 3530 } 3530 3531 else … … 3579 3580 { 3580 3581 // pointer to com stored so call its release 3581 ((OS2IDirectDrawSurface *) pSData->pData)->lpVtbl-> Release(pSData->pData);3582 ((OS2IDirectDrawSurface *) pSData->pData)->lpVtbl->fnRelease(pSData->pData); 3582 3583 } 3583 3584 else … … 3598 3599 //****************************************************************************** 3599 3600 //****************************************************************************** 3600 IDirectDrawSurface4Vtbl DDrawSurfaceV4Table = 3601 IDirectDrawSurface4Vtbl DDrawSurfaceV4Table = 3601 3602 { 3602 3603 SurfQueryInterface, … … 3610 3611 SurfDeleteAttachedSurface4, 3611 3612 SurfEnumAttachedSurfaces4, 3612 SurfEnumOverlayZOrders4, 3613 SurfFlip4, 3614 SurfGetAttachedSurface4, 3615 SurfGetBltStatus, 3616 SurfGetCaps4, 3617 SurfGetClipper, 3618 SurfGetColorKey, 3619 SurfGetDC, 3620 SurfGetFlipStatus, 3621 SurfGetOverlayPosition, 3622 SurfGetPalette, 3623 SurfGetPixelFormat, 3624 SurfGetSurfaceDesc4, 3625 SurfInitialize4, 3626 SurfIsLost, 3627 SurfLock4, 3628 SurfReleaseDC, 3629 SurfRestore, 3630 SurfSetClipper, 3631 SurfSetColorKey, 3632 SurfSetOverlayPosition, 3633 SurfSetPalette, 3634 SurfUnlock4, 3635 SurfUpdateOverlay4, 3636 SurfUpdateOverlayDisplay, 3637 SurfUpdateOverlayZOrder4, 3638 SurfGetDDInterface, 3639 SurfPageLock, 3640 SurfPageUnlock, 3641 SurfSetSurfaceDesc4, 3642 SurfSetPrivateData, 3643 SurfGetPrivateData, 3644 SurfFreePrivateData, 3613 SurfEnumOverlayZOrders4, 3614 SurfFlip4, 3615 SurfGetAttachedSurface4, 3616 SurfGetBltStatus, 3617 SurfGetCaps4, 3618 SurfGetClipper, 3619 SurfGetColorKey, 3620 SurfGetDC, 3621 SurfGetFlipStatus, 3622 SurfGetOverlayPosition, 3623 SurfGetPalette, 3624 SurfGetPixelFormat, 3625 SurfGetSurfaceDesc4, 3626 SurfInitialize4, 3627 SurfIsLost, 3628 SurfLock4, 3629 SurfReleaseDC, 3630 SurfRestore, 3631 SurfSetClipper, 3632 SurfSetColorKey, 3633 SurfSetOverlayPosition, 3634 SurfSetPalette, 3635 SurfUnlock4, 3636 SurfUpdateOverlay4, 3637 SurfUpdateOverlayDisplay, 3638 SurfUpdateOverlayZOrder4, 3639 SurfGetDDInterface, 3640 SurfPageLock, 3641 SurfPageUnlock, 3642 SurfSetSurfaceDesc4, 3643 SurfSetPrivateData, 3644 SurfGetPrivateData, 3645 SurfFreePrivateData, 3645 3646 SurfGetUniquenessValue, 3646 3647 SurfChangeUniquenessValue … … 3648 3649 //****************************************************************************** 3649 3650 //****************************************************************************** 3650 IDirectDrawSurface3Vtbl DDrawSurfaceV3Table = 3651 { 3652 SurfQueryInterface, 3653 SurfAddRef, 3654 SurfRelease, 3655 SurfAddAttachedSurface3, 3656 SurfAddOverlayDirtyRect, 3657 SurfBlt3, 3658 SurfBltBatch, 3659 SurfBltFast3, 3660 SurfDeleteAttachedSurface3, 3661 SurfEnumAttachedSurfaces, 3662 SurfEnumOverlayZOrders, 3663 SurfFlip3, 3664 SurfGetAttachedSurface3, 3665 SurfGetBltStatus, 3666 SurfGetCaps, 3667 SurfGetClipper, 3668 SurfGetColorKey, 3669 SurfGetDC, 3670 SurfGetFlipStatus, 3671 SurfGetOverlayPosition, 3672 SurfGetPalette, 3673 SurfGetPixelFormat, 3674 SurfGetSurfaceDesc, 3675 SurfInitialize, 3676 SurfIsLost, 3677 SurfLock, 3678 SurfReleaseDC, 3679 SurfRestore, 3680 SurfSetClipper, 3681 SurfSetColorKey, 3682 SurfSetOverlayPosition, 3683 SurfSetPalette, 3684 SurfUnlock, 3685 SurfUpdateOverlay3, 3686 SurfUpdateOverlayDisplay, 3687 SurfUpdateOverlayZOrder3, 3688 SurfGetDDInterface, 3689 SurfPageLock, 3690 SurfPageUnlock, 3651 IDirectDrawSurface3Vtbl DDrawSurfaceV3Table = 3652 { 3653 SurfQueryInterface, 3654 SurfAddRef, 3655 SurfRelease, 3656 SurfAddAttachedSurface3, 3657 SurfAddOverlayDirtyRect, 3658 SurfBlt3, 3659 SurfBltBatch, 3660 SurfBltFast3, 3661 SurfDeleteAttachedSurface3, 3662 SurfEnumAttachedSurfaces, 3663 SurfEnumOverlayZOrders, 3664 SurfFlip3, 3665 SurfGetAttachedSurface3, 3666 SurfGetBltStatus, 3667 SurfGetCaps, 3668 SurfGetClipper, 3669 SurfGetColorKey, 3670 SurfGetDC, 3671 SurfGetFlipStatus, 3672 SurfGetOverlayPosition, 3673 SurfGetPalette, 3674 SurfGetPixelFormat, 3675 SurfGetSurfaceDesc, 3676 SurfInitialize, 3677 SurfIsLost, 3678 SurfLock, 3679 SurfReleaseDC, 3680 SurfRestore, 3681 SurfSetClipper, 3682 SurfSetColorKey, 3683 SurfSetOverlayPosition, 3684 SurfSetPalette, 3685 SurfUnlock, 3686 SurfUpdateOverlay3, 3687 SurfUpdateOverlayDisplay, 3688 SurfUpdateOverlayZOrder3, 3689 SurfGetDDInterface, 3690 SurfPageLock, 3691 SurfPageUnlock, 3691 3692 SurfSetSurfaceDesc 3692 3693 }; 3693 3694 //****************************************************************************** 3694 3695 //****************************************************************************** 3695 IDirectDrawSurface2Vtbl DDrawSurfaceV2Table = 3696 { 3697 SurfQueryInterface, 3698 SurfAddRef, 3699 SurfRelease, 3700 SurfAddAttachedSurface, 3701 SurfAddOverlayDirtyRect, 3702 SurfBlt, 3703 SurfBltBatch, 3704 SurfBltFast, 3705 SurfDeleteAttachedSurface, 3706 SurfEnumAttachedSurfaces, 3707 SurfEnumOverlayZOrders, 3708 SurfFlip, 3709 SurfGetAttachedSurface, 3710 SurfGetBltStatus, 3711 SurfGetCaps, 3712 SurfGetClipper, 3713 SurfGetColorKey, 3714 SurfGetDC, 3715 SurfGetFlipStatus, 3716 SurfGetOverlayPosition, 3717 SurfGetPalette, 3718 SurfGetPixelFormat, 3719 SurfGetSurfaceDesc, 3720 SurfInitialize, 3721 SurfIsLost, 3722 SurfLock, 3723 SurfReleaseDC, 3724 SurfRestore, 3725 SurfSetClipper, 3726 SurfSetColorKey, 3727 SurfSetOverlayPosition, 3728 SurfSetPalette, 3729 SurfUnlock, 3730 SurfUpdateOverlay, 3731 SurfUpdateOverlayDisplay, 3732 SurfUpdateOverlayZOrder, 3733 SurfGetDDInterface, 3734 SurfPageLock, 3696 IDirectDrawSurface2Vtbl DDrawSurfaceV2Table = 3697 { 3698 SurfQueryInterface, 3699 SurfAddRef, 3700 SurfRelease, 3701 SurfAddAttachedSurface, 3702 SurfAddOverlayDirtyRect, 3703 SurfBlt, 3704 SurfBltBatch, 3705 SurfBltFast, 3706 SurfDeleteAttachedSurface, 3707 SurfEnumAttachedSurfaces, 3708 SurfEnumOverlayZOrders, 3709 SurfFlip, 3710 SurfGetAttachedSurface, 3711 SurfGetBltStatus, 3712 SurfGetCaps, 3713 SurfGetClipper, 3714 SurfGetColorKey, 3715 SurfGetDC, 3716 SurfGetFlipStatus, 3717 SurfGetOverlayPosition, 3718 SurfGetPalette, 3719 SurfGetPixelFormat, 3720 SurfGetSurfaceDesc, 3721 SurfInitialize, 3722 SurfIsLost, 3723 SurfLock, 3724 SurfReleaseDC, 3725 SurfRestore, 3726 SurfSetClipper, 3727 SurfSetColorKey, 3728 SurfSetOverlayPosition, 3729 SurfSetPalette, 3730 SurfUnlock, 3731 SurfUpdateOverlay, 3732 SurfUpdateOverlayDisplay, 3733 SurfUpdateOverlayZOrder, 3734 SurfGetDDInterface, 3735 SurfPageLock, 3735 3736 SurfPageUnlock 3736 3737 }; -
trunk/src/ddraw/surfacehlp.cpp
r9459 r21479 12 12 ( (DWORD)(BYTE)(ch2) << 16 ) | ( (DWORD)(BYTE)(ch3) << 24 ) ) 13 13 #include <fourcc.h> 14 #define INITGUID 14 15 #define CINTERFACE 15 16 #include "ddraw2d.h" 16 17 #include "clipper.h" … … 20 21 #include "os2util.h" 21 22 #include "rectangle.h" 23 22 24 #include <misc.h> 23 25 #include "asmutil.h" -
trunk/src/ddraw/surfblit.cpp
r9698 r21479 24 24 ( (DWORD)(BYTE)(ch2) << 16 ) | ( (DWORD)(BYTE)(ch3) << 24 ) ) 25 25 #include <fourcc.h> 26 #define INITGUID 26 27 #define CINTERFACE 27 28 #include "ddraw2d.h" 28 29 #include "clipper.h" … … 32 33 #include "os2util.h" 33 34 #include "rectangle.h" 35 34 36 #include <misc.h> 35 37 #include "asmutil.h" -
trunk/src/ddraw/surfoverlay.cpp
r9560 r21479 24 24 ( (DWORD)(BYTE)(ch2) << 16 ) | ( (DWORD)(BYTE)(ch3) << 24 ) ) 25 25 #include <fourcc.h> 26 #define INITGUID 26 27 #define CINTERFACE 27 28 #include "ddraw2d.h" 28 29 #include "clipper.h" … … 32 33 #include "os2util.h" 33 34 #include "rectangle.h" 35 34 36 #include <misc.h> 35 37 #include "asmutil.h" -
trunk/src/dsound/DAudioBuffer.cpp
r8217 r21479 20 20 #include <string.h> 21 21 22 #define INITGUID22 #define CINTERFACE 23 23 #include <dsound.h> 24 24 … … 186 186 { 187 187 lpVtbl = &Vtbl; 188 Vtbl. AddRef = DAudioBufAddRef;189 Vtbl. Release = DAudioBufRelease;190 Vtbl. QueryInterface = DAudioBufQueryInterface;191 Vtbl. GetCaps = DAudioBufGetCaps;192 Vtbl. GetFormat = DAudioBufGetFormat;193 Vtbl. GetVolume = DAudioBufGetVolume;194 Vtbl. GetStatus = DAudioBufGetStatus;195 Vtbl. GetCurrentPosition = DAudioBufGetCurrentPosition;196 Vtbl. GetPan = DAudioBufGetPan;197 Vtbl. GetFrequency = DAudioBufGetFrequency;198 Vtbl. Initialize = DAudioBufInitialize;199 Vtbl. Restore = DAudioBufRestore;200 Vtbl. SetFormat = DAudioBufSetFormat;201 Vtbl. SetVolume = DAudioBufSetVolume;202 Vtbl. SetCurrentPosition = DAudioBufSetCurrentPosition;203 Vtbl. SetPan = DAudioBufSetPan;204 Vtbl. SetFrequency = DAudioBufSetFrequency;205 Vtbl. Lock = DAudioBufLock;206 Vtbl. Unlock = DAudioBufUnlock;207 Vtbl. Stop = DAudioBufStop;208 Vtbl. Play = DAudioBufPlay;188 Vtbl.fnAddRef = DAudioBufAddRef; 189 Vtbl.fnRelease = DAudioBufRelease; 190 Vtbl.fnQueryInterface = DAudioBufQueryInterface; 191 Vtbl.fnGetCaps = DAudioBufGetCaps; 192 Vtbl.fnGetFormat = DAudioBufGetFormat; 193 Vtbl.fnGetVolume = DAudioBufGetVolume; 194 Vtbl.fnGetStatus = DAudioBufGetStatus; 195 Vtbl.fnGetCurrentPosition = DAudioBufGetCurrentPosition; 196 Vtbl.fnGetPan = DAudioBufGetPan; 197 Vtbl.fnGetFrequency = DAudioBufGetFrequency; 198 Vtbl.fnInitialize = DAudioBufInitialize; 199 Vtbl.fnRestore = DAudioBufRestore; 200 Vtbl.fnSetFormat = DAudioBufSetFormat; 201 Vtbl.fnSetVolume = DAudioBufSetVolume; 202 Vtbl.fnSetCurrentPosition = DAudioBufSetCurrentPosition; 203 Vtbl.fnSetPan = DAudioBufSetPan; 204 Vtbl.fnSetFrequency = DAudioBufSetFrequency; 205 Vtbl.fnLock = DAudioBufLock; 206 Vtbl.fnUnlock = DAudioBufUnlock; 207 Vtbl.fnStop = DAudioBufStop; 208 Vtbl.fnPlay = DAudioBufPlay; 209 209 } 210 210 //****************************************************************************** … … 233 233 *ppvObj = NULL; 234 234 235 if (IsEqualGUID(riid, IID_IDirectSoundBuffer)) {235 if (IsEqualGUID(riid, &IID_IDirectSoundBuffer)) { 236 236 *ppvObj = this; 237 237 … … 240 240 } 241 241 242 if (IsEqualGUID(riid, IID_IDirectSoundNotify))242 if (IsEqualGUID(riid, &IID_IDirectSoundNotify)) 243 243 { 244 244 IDirectAudioNotify *notify; … … 246 246 notify = new IDirectAudioNotify(this); 247 247 *ppvObj = notify; 248 notify->Vtbl. AddRef(notify);248 notify->Vtbl.fnAddRef(notify); 249 249 return DS_OK; 250 250 } 251 251 #if 0 252 if (IsEqualGUID(riid, IID_IDirectSound3DBuffer)) {252 if (IsEqualGUID(riid, &IID_IDirectSound3DBuffer)) { 253 253 OS2IDirectSound3DBuffer *buffer3D; 254 254 255 255 buffer3D = new OS2IDirectSound3DBuffer(this); 256 256 *ppvObj = buffer3D; 257 buffer3D->Vtbl. AddRef((IDirectSound3DBuffer *)buffer3D);257 buffer3D->Vtbl.fnAddRef((IDirectSound3DBuffer *)buffer3D); 258 258 return DS_OK; 259 259 } -
trunk/src/dsound/DAudioNotify.cpp
r5608 r21479 19 19 #include <string.h> 20 20 21 #define INITGUID21 #define CINTERFACE 22 22 #include <dsound.h> 23 23 … … 32 32 { 33 33 lpVtbl = &Vtbl; 34 Vtbl. AddRef = DAudioNotifyAddRef;35 Vtbl. Release = DAudioNotifyRelease;36 Vtbl. QueryInterface = DAudioNotifyQueryInterface;37 Vtbl. SetNotificationPositions = DAudioNotifySetNotificationPositions;34 Vtbl.fnAddRef = DAudioNotifyAddRef; 35 Vtbl.fnRelease = DAudioNotifyRelease; 36 Vtbl.fnQueryInterface = DAudioNotifyQueryInterface; 37 Vtbl.fnSetNotificationPositions = DAudioNotifySetNotificationPositions; 38 38 39 39 dprintf(("DSOUND-IDirectAudioNotify::IDirectAudioNotify (this=%X)", this)); … … 45 45 46 46 // add a reference to the parent SoundBuffer to make sure it won't suddenly disappear 47 lpSoundBuffer->Vtbl. AddRef(lpSoundBuffer);47 lpSoundBuffer->Vtbl.fnAddRef(lpSoundBuffer); 48 48 // set pointer to ourselves in parent SoundBuffer 49 49 lpSoundBuffer->SetNotify(this); … … 56 56 dprintf(("DSOUND-IDirectAudioNotify::~IDirectAudioNotify (this=%X)", this)); 57 57 lpSoundBuffer->SetNotify(NULL); 58 lpSoundBuffer->Vtbl. Release(lpSoundBuffer);58 lpSoundBuffer->Vtbl.fnRelease(lpSoundBuffer); 59 59 if (lpPositions != NULL) 60 60 free(lpPositions); … … 71 71 *ppvObj = NULL; 72 72 73 if (!IsEqualGUID(riid, IID_IDirectSoundNotify))73 if (!IsEqualGUID(riid, &IID_IDirectSoundNotify)) 74 74 return E_NOINTERFACE; 75 75 -
trunk/src/dsound/DSOUND.CPP
r7431 r21479 20 20 21 21 #define INITGUID 22 #define ICOM_CINTERFACE 123 22 #define CINTERFACE 24 23 #include <dsound.h> … … 45 44 if (OS2IDirectSound::fDSExists) { 46 45 *ppDS = (LPDIRECTSOUND)DS; 47 DS->Vtbl. AddRef(DS);46 DS->Vtbl.fnAddRef(DS); 48 47 return DS_OK; 49 48 } … … 61 60 else { 62 61 *ppDS = (LPDIRECTSOUND)newsound; 63 newsound->Vtbl. AddRef(newsound);62 newsound->Vtbl.fnAddRef(newsound); 64 63 DS = newsound; 65 64 } … … 178 177 179 178 dprintf(("DSOUND:DSCF_CreateInstance\n")); 180 if( lpGUID && (*lpGUID == IID_IDirectSound)) {179 if(lpGUID && IsEqualGUID(lpGUID, &IID_IDirectSound)) { 181 180 return OS2DirectSoundCreate(lpGUID,(LPDIRECTSOUND*)ppobj,pOuter); 182 181 } … … 223 222 { 224 223 *ppv = (LPVOID)&DSOUND_CF; 225 DSOUND_CF.lpvtbl-> AddRef((IClassFactory*)&DSOUND_CF);224 DSOUND_CF.lpvtbl->fnAddRef((IClassFactory*)&DSOUND_CF); 226 225 return S_OK; 227 226 } -
trunk/src/dsound/OS23DBuffer.cpp
r3925 r21479 19 19 #include <string.h> 20 20 21 #define INITGUID21 #define CINTERFACE 22 22 #include <dsound.h> 23 23 … … 42 42 { 43 43 lpVtbl = &Vtbl; 44 Vtbl. AddRef = Sound3DBufferAddRef;45 Vtbl. Release = Sound3DBufferRelease;46 Vtbl. QueryInterface = Sound3DBufferQueryInterface;47 Vtbl. GetAllParameters = Sound3DBufferGetAllParameters;48 Vtbl. SetAllParameters = Sound3DBufferSetAllParameters;49 Vtbl. GetMaxDistance = Sound3DBufferGetMaxDistance;50 Vtbl. SetMaxDistance = Sound3DBufferSetMaxDistance;51 Vtbl. GetMinDistance = Sound3DBufferGetMinDistance;52 Vtbl. SetMinDistance = Sound3DBufferSetMinDistance;53 Vtbl. GetMode = Sound3DBufferGetMode;54 Vtbl. SetMode = Sound3DBufferSetMode;55 Vtbl. GetPosition = Sound3DBufferGetPosition;56 Vtbl. SetPosition = Sound3DBufferSetPosition;57 Vtbl. GetConeAngles = Sound3DBufferGetConeAngles;58 Vtbl. SetConeAngles = Sound3DBufferSetConeAngles;59 Vtbl. GetConeOrientation = Sound3DBufferGetConeOrientation;60 Vtbl. SetConeOrientation = Sound3DBufferSetConeOrientation;61 Vtbl. GetConeOutsideVolume = Sound3DBufferGetConeOutsideVolume;62 Vtbl. SetConeOutsideVolume = Sound3DBufferSetConeOutsideVolume;63 Vtbl. GetVelocity = Sound3DBufferGetVelocity;64 Vtbl. SetVelocity = Sound3DBufferSetVelocity;44 Vtbl.fnAddRef = Sound3DBufferAddRef; 45 Vtbl.fnRelease = Sound3DBufferRelease; 46 Vtbl.fnQueryInterface = Sound3DBufferQueryInterface; 47 Vtbl.fnGetAllParameters = Sound3DBufferGetAllParameters; 48 Vtbl.fnSetAllParameters = Sound3DBufferSetAllParameters; 49 Vtbl.fnGetMaxDistance = Sound3DBufferGetMaxDistance; 50 Vtbl.fnSetMaxDistance = Sound3DBufferSetMaxDistance; 51 Vtbl.fnGetMinDistance = Sound3DBufferGetMinDistance; 52 Vtbl.fnSetMinDistance = Sound3DBufferSetMinDistance; 53 Vtbl.fnGetMode = Sound3DBufferGetMode; 54 Vtbl.fnSetMode = Sound3DBufferSetMode; 55 Vtbl.fnGetPosition = Sound3DBufferGetPosition; 56 Vtbl.fnSetPosition = Sound3DBufferSetPosition; 57 Vtbl.fnGetConeAngles = Sound3DBufferGetConeAngles; 58 Vtbl.fnSetConeAngles = Sound3DBufferSetConeAngles; 59 Vtbl.fnGetConeOrientation = Sound3DBufferGetConeOrientation; 60 Vtbl.fnSetConeOrientation = Sound3DBufferSetConeOrientation; 61 Vtbl.fnGetConeOutsideVolume = Sound3DBufferGetConeOutsideVolume; 62 Vtbl.fnSetConeOutsideVolume = Sound3DBufferSetConeOutsideVolume; 63 Vtbl.fnGetVelocity = Sound3DBufferGetVelocity; 64 Vtbl.fnSetVelocity = Sound3DBufferSetVelocity; 65 65 66 66 … … 74 74 75 75 // add a reference to the parent primary SoundBuffer to make sure it won't suddenly disappear 76 lpSoundBuffer->Vtbl. AddRef(lpSoundBuffer);76 lpSoundBuffer->Vtbl.fnAddRef(lpSoundBuffer); 77 77 // set pointer to ourselves in parent SoundBuffer 78 78 lpSoundBuffer->Set3DBuffer(this); … … 85 85 dprintf(("DSOUND-OS2IDirectSound3DBuffer::~OS2IDirectSound3DBuffer (this=%X)", this)); 86 86 lpSoundBuffer->Set3DBuffer(NULL); 87 lpSoundBuffer->Vtbl. Release(lpSoundBuffer);87 lpSoundBuffer->Vtbl.fnRelease(lpSoundBuffer); 88 88 } 89 89 … … 98 98 *ppvObj = NULL; 99 99 100 if (!IsEqualGUID(riid, IID_IDirectSound3DBuffer))100 if (!IsEqualGUID(riid, &IID_IDirectSound3DBuffer)) 101 101 return E_NOINTERFACE; 102 102 -
trunk/src/dsound/OS23DListener.cpp
r3925 r21479 19 19 #include <string.h> 20 20 21 #define INITGUID21 #define CINTERFACE 22 22 #include <dsound.h> 23 23 … … 42 42 { 43 43 lpVtbl = &Vtbl; 44 Vtbl. AddRef = Sound3DListenerAddRef;45 Vtbl. Release = Sound3DListenerRelease;46 Vtbl. QueryInterface = Sound3DListenerQueryInterface;47 Vtbl. GetAllParameters = Sound3DListenerGetAllParameters;48 Vtbl. SetAllParameters = Sound3DListenerSetAllParameters;49 Vtbl. CommitDeferredSettings = Sound3DListenerCommitDeferredSettings;50 Vtbl. GetDistanceFactor = Sound3DListenerGetDistanceFactor;51 Vtbl. SetDistanceFactor = Sound3DListenerSetDistanceFactor;52 Vtbl. GetDopplerFactor = Sound3DListenerGetDopplerFactor;53 Vtbl. SetDopplerFactor = Sound3DListenerSetDopplerFactor;54 Vtbl. GetOrientation = Sound3DListenerGetOrientation;55 Vtbl. SetOrientation = Sound3DListenerSetOrientation;56 Vtbl. GetPosition = Sound3DListenerGetPosition;57 Vtbl. SetPosition = Sound3DListenerSetPosition;58 Vtbl. GetRolloffFactor = Sound3DListenerGetRolloffFactor;59 Vtbl. SetRolloffFactor = Sound3DListenerSetRolloffFactor;60 Vtbl. GetVelocity = Sound3DListenerGetVelocity;61 Vtbl. SetVelocity = Sound3DListenerSetVelocity;44 Vtbl.fnAddRef = Sound3DListenerAddRef; 45 Vtbl.fnRelease = Sound3DListenerRelease; 46 Vtbl.fnQueryInterface = Sound3DListenerQueryInterface; 47 Vtbl.fnGetAllParameters = Sound3DListenerGetAllParameters; 48 Vtbl.fnSetAllParameters = Sound3DListenerSetAllParameters; 49 Vtbl.fnCommitDeferredSettings = Sound3DListenerCommitDeferredSettings; 50 Vtbl.fnGetDistanceFactor = Sound3DListenerGetDistanceFactor; 51 Vtbl.fnSetDistanceFactor = Sound3DListenerSetDistanceFactor; 52 Vtbl.fnGetDopplerFactor = Sound3DListenerGetDopplerFactor; 53 Vtbl.fnSetDopplerFactor = Sound3DListenerSetDopplerFactor; 54 Vtbl.fnGetOrientation = Sound3DListenerGetOrientation; 55 Vtbl.fnSetOrientation = Sound3DListenerSetOrientation; 56 Vtbl.fnGetPosition = Sound3DListenerGetPosition; 57 Vtbl.fnSetPosition = Sound3DListenerSetPosition; 58 Vtbl.fnGetRolloffFactor = Sound3DListenerGetRolloffFactor; 59 Vtbl.fnSetRolloffFactor = Sound3DListenerSetRolloffFactor; 60 Vtbl.fnGetVelocity = Sound3DListenerGetVelocity; 61 Vtbl.fnSetVelocity = Sound3DListenerSetVelocity; 62 62 63 63 … … 71 71 72 72 // add a reference to the parent primary SoundBuffer to make sure it won't suddenly disappear 73 lpSoundBuffer->Vtbl. AddRef(lpSoundBuffer);73 lpSoundBuffer->Vtbl.fnAddRef(lpSoundBuffer); 74 74 // set pointer to ourselves in parent SoundBuffer 75 75 lpSoundBuffer->Set3DListener(this); … … 82 82 dprintf(("DSOUND-OS2IDirectSound3DListener::~OS2IDirectSound3DListener (this=%X)", this)); 83 83 lpSoundBuffer->Set3DListener(NULL); 84 lpSoundBuffer->Vtbl. Release(lpSoundBuffer);84 lpSoundBuffer->Vtbl.fnRelease(lpSoundBuffer); 85 85 } 86 86 … … 95 95 *ppvObj = NULL; 96 96 97 if (!IsEqualGUID(riid, IID_IDirectSound3DListener))97 if (!IsEqualGUID(riid, &IID_IDirectSound3DListener)) 98 98 return E_NOINTERFACE; 99 99 -
trunk/src/dsound/OS2DSOUND.CPP
r5292 r21479 21 21 #include <stdio.h> /****** DEBUGGING ********/ 22 22 23 #define INITGUID23 #define CINTERFACE 24 24 #include <dsound.h> 25 25 … … 42 42 { 43 43 lpVtbl = &Vtbl; 44 Vtbl. AddRef = SoundAddRef;45 Vtbl. Release = SoundRelease;46 Vtbl. QueryInterface = SoundQueryInterface;47 Vtbl. Compact = SoundCompact;48 Vtbl. CreateSoundBuffer = SoundCreateSoundBuffer;49 Vtbl. GetCaps = SoundGetCaps;50 Vtbl. DuplicateSoundBuffer = SoundDuplicateSoundBuffer;51 Vtbl. SetCooperativeLevel = SoundSetCooperativeLevel;52 Vtbl. Compact = SoundCompact;53 Vtbl. GetSpeakerConfig = SoundGetSpeakerConfig;54 Vtbl. SetSpeakerConfig = SoundSetSpeakerConfig;55 Vtbl. Initialize = SoundInitialize;44 Vtbl.fnAddRef = SoundAddRef; 45 Vtbl.fnRelease = SoundRelease; 46 Vtbl.fnQueryInterface = SoundQueryInterface; 47 Vtbl.fnCompact = SoundCompact; 48 Vtbl.fnCreateSoundBuffer = SoundCreateSoundBuffer; 49 Vtbl.fnGetCaps = SoundGetCaps; 50 Vtbl.fnDuplicateSoundBuffer = SoundDuplicateSoundBuffer; 51 Vtbl.fnSetCooperativeLevel = SoundSetCooperativeLevel; 52 Vtbl.fnCompact = SoundCompact; 53 Vtbl.fnGetSpeakerConfig = SoundGetSpeakerConfig; 54 Vtbl.fnSetSpeakerConfig = SoundSetSpeakerConfig; 55 Vtbl.fnInitialize = SoundInitialize; 56 56 57 57 dprintf(("DSOUND-OS2IDirectSound::OS2IDirectSound")); … … 75 75 return; 76 76 } 77 primary->Vtbl. AddRef(primary);77 primary->Vtbl.fnAddRef(primary); 78 78 79 79 dprintf(("Sound init OK")); … … 99 99 *ppvObj = NULL; 100 100 101 if (!IsEqualGUID(riid, CLSID_DirectSound) &&102 !IsEqualGUID(riid, IID_IDirectSound))101 if (!IsEqualGUID(riid, &CLSID_DirectSound) && 102 !IsEqualGUID(riid, &IID_IDirectSound)) 103 103 return E_NOINTERFACE; 104 104 … … 181 181 return lastErr; 182 182 } 183 sndbuf->Vtbl. AddRef(sndbuf);183 sndbuf->Vtbl.fnAddRef(sndbuf); 184 184 185 185 *lplpDirectSoundBuffer = (LPDIRECTSOUNDBUFFER)sndbuf; … … 251 251 return lastErr; 252 252 } 253 tgtBuf->Vtbl. AddRef(tgtBuf);253 tgtBuf->Vtbl.fnAddRef(tgtBuf); 254 254 255 255 *lplpDirectSoundBuffer = (LPDIRECTSOUNDBUFFER)tgtBuf; -
trunk/src/dsound/OS2NOTIFY.CPP
r3925 r21479 19 19 #include <string.h> 20 20 21 #define INITGUID21 #define CINTERFACE 22 22 #include <dsound.h> 23 23 … … 32 32 { 33 33 lpVtbl = &Vtbl; 34 Vtbl. AddRef = SoundNotifyAddRef;35 Vtbl. Release = SoundNotifyRelease;36 Vtbl. QueryInterface = SoundNotifyQueryInterface;37 Vtbl. SetNotificationPositions = SoundNotifySetNotificationPositions;34 Vtbl.fnAddRef = SoundNotifyAddRef; 35 Vtbl.fnRelease = SoundNotifyRelease; 36 Vtbl.fnQueryInterface = SoundNotifyQueryInterface; 37 Vtbl.fnSetNotificationPositions = SoundNotifySetNotificationPositions; 38 38 39 39 dprintf(("DSOUND-OS2IDirectSoundNotify::OS2IDirectSoundNotify (this=%X)", this)); … … 45 45 46 46 // add a reference to the parent SoundBuffer to make sure it won't suddenly disappear 47 lpSoundBuffer->Vtbl. AddRef(lpSoundBuffer);47 lpSoundBuffer->Vtbl.fnAddRef(lpSoundBuffer); 48 48 // set pointer to ourselves in parent SoundBuffer 49 49 lpSoundBuffer->SetNotify(this); … … 56 56 dprintf(("DSOUND-OS2IDirectSoundNotify::~OS2IDirectSoundNotify (this=%X)", this)); 57 57 lpSoundBuffer->SetNotify(NULL); 58 lpSoundBuffer->Vtbl. Release(lpSoundBuffer);58 lpSoundBuffer->Vtbl.fnRelease(lpSoundBuffer); 59 59 if (lpPositions != NULL) 60 60 free(lpPositions); … … 71 71 *ppvObj = NULL; 72 72 73 if (!IsEqualGUID(riid, IID_IDirectSoundNotify))73 if (!IsEqualGUID(riid, &IID_IDirectSoundNotify)) 74 74 return E_NOINTERFACE; 75 75 -
trunk/src/dsound/OS2PrimBuff.cpp
r5285 r21479 33 33 #include <string.h> 34 34 35 #define INITGUID35 #define CINTERFACE 36 36 #include <dsound.h> 37 37 … … 55 55 { 56 56 lpVtbl = &Vtbl; 57 Vtbl. AddRef = PrimBufAddRef;58 Vtbl. Release = PrimBufRelease;59 Vtbl. QueryInterface = PrimBufQueryInterface;60 Vtbl. GetCaps = PrimBufGetCaps;61 Vtbl. GetFormat = PrimBufGetFormat;62 Vtbl. GetVolume = PrimBufGetVolume;63 Vtbl. GetStatus = PrimBufGetStatus;64 Vtbl. GetCurrentPosition = PrimBufGetCurrentPosition;65 Vtbl. GetPan = PrimBufGetPan;66 Vtbl. GetFrequency = PrimBufGetFrequency;67 Vtbl. Initialize = PrimBufInitialize;68 Vtbl. Restore = PrimBufRestore;69 Vtbl. SetFormat = PrimBufSetFormat;70 Vtbl. SetVolume = PrimBufSetVolume;71 Vtbl. SetCurrentPosition = PrimBufSetCurrentPosition;72 Vtbl. SetPan = PrimBufSetPan;73 Vtbl. SetFrequency = PrimBufSetFrequency;74 Vtbl. Lock = PrimBufLock;75 Vtbl. Unlock = PrimBufUnlock;76 Vtbl. Stop = PrimBufStop;77 Vtbl. Play = PrimBufPlay;57 Vtbl.fnAddRef = PrimBufAddRef; 58 Vtbl.fnRelease = PrimBufRelease; 59 Vtbl.fnQueryInterface = PrimBufQueryInterface; 60 Vtbl.fnGetCaps = PrimBufGetCaps; 61 Vtbl.fnGetFormat = PrimBufGetFormat; 62 Vtbl.fnGetVolume = PrimBufGetVolume; 63 Vtbl.fnGetStatus = PrimBufGetStatus; 64 Vtbl.fnGetCurrentPosition = PrimBufGetCurrentPosition; 65 Vtbl.fnGetPan = PrimBufGetPan; 66 Vtbl.fnGetFrequency = PrimBufGetFrequency; 67 Vtbl.fnInitialize = PrimBufInitialize; 68 Vtbl.fnRestore = PrimBufRestore; 69 Vtbl.fnSetFormat = PrimBufSetFormat; 70 Vtbl.fnSetVolume = PrimBufSetVolume; 71 Vtbl.fnSetCurrentPosition = PrimBufSetCurrentPosition; 72 Vtbl.fnSetPan = PrimBufSetPan; 73 Vtbl.fnSetFrequency = PrimBufSetFrequency; 74 Vtbl.fnLock = PrimBufLock; 75 Vtbl.fnUnlock = PrimBufUnlock; 76 Vtbl.fnStop = PrimBufStop; 77 Vtbl.fnPlay = PrimBufPlay; 78 78 79 79 dprintf(("DSOUND-PrimBuff: Constructor")); … … 135 135 *ppvObj = NULL; 136 136 137 if (IsEqualGUID(riid, IID_IDirectSoundBuffer)) {137 if (IsEqualGUID(riid, &IID_IDirectSoundBuffer)) { 138 138 *ppvObj = This; 139 139 PrimBufAddRef(This); … … 142 142 143 143 144 if (IsEqualGUID(riid, IID_IDirectSound3DListener)) {144 if (IsEqualGUID(riid, &IID_IDirectSound3DListener)) { 145 145 OS2PrimBuff *me = (OS2PrimBuff *)This; 146 146 OS2IDirectSound3DListener *listener; … … 148 148 listener = new OS2IDirectSound3DListener(me); 149 149 *ppvObj = listener; 150 listener->Vtbl. AddRef((IDirectSound3DListener *)listener);150 listener->Vtbl.fnAddRef((IDirectSound3DListener *)listener); 151 151 return DS_OK; 152 152 } -
trunk/src/dsound/OS2SNDBUFFER.CPP
r5331 r21479 21 21 #include <string.h> 22 22 23 #define INITGUID23 #define CINTERFACE 24 24 #include <dsound.h> 25 25 … … 52 52 //This is the "normal" constructor 53 53 lpVtbl = &Vtbl; 54 Vtbl. AddRef = SoundBufAddRef;55 Vtbl. Release = SoundBufRelease;56 Vtbl. QueryInterface = SoundBufQueryInterface;57 Vtbl. GetCaps = SoundBufGetCaps;58 Vtbl. GetFormat = SoundBufGetFormat;59 Vtbl. GetVolume = SoundBufGetVolume;60 Vtbl. GetStatus = SoundBufGetStatus;61 Vtbl. GetCurrentPosition = SoundBufGetCurrentPosition;62 Vtbl. GetPan = SoundBufGetPan;63 Vtbl. GetFrequency = SoundBufGetFrequency;64 Vtbl. Initialize = SoundBufInitialize;65 Vtbl. Restore = SoundBufRestore;66 Vtbl. SetFormat = SoundBufSetFormat;67 Vtbl. SetVolume = SoundBufSetVolume;68 Vtbl. SetCurrentPosition = SoundBufSetCurrentPosition;69 Vtbl. SetPan = SoundBufSetPan;70 Vtbl. SetFrequency = SoundBufSetFrequency;71 Vtbl. Lock = SoundBufLock;72 Vtbl. Unlock = SoundBufUnlock;73 Vtbl. Stop = SoundBufStop;74 Vtbl. Play = SoundBufPlay;54 Vtbl.fnAddRef = SoundBufAddRef; 55 Vtbl.fnRelease = SoundBufRelease; 56 Vtbl.fnQueryInterface = SoundBufQueryInterface; 57 Vtbl.fnGetCaps = SoundBufGetCaps; 58 Vtbl.fnGetFormat = SoundBufGetFormat; 59 Vtbl.fnGetVolume = SoundBufGetVolume; 60 Vtbl.fnGetStatus = SoundBufGetStatus; 61 Vtbl.fnGetCurrentPosition = SoundBufGetCurrentPosition; 62 Vtbl.fnGetPan = SoundBufGetPan; 63 Vtbl.fnGetFrequency = SoundBufGetFrequency; 64 Vtbl.fnInitialize = SoundBufInitialize; 65 Vtbl.fnRestore = SoundBufRestore; 66 Vtbl.fnSetFormat = SoundBufSetFormat; 67 Vtbl.fnSetVolume = SoundBufSetVolume; 68 Vtbl.fnSetCurrentPosition = SoundBufSetCurrentPosition; 69 Vtbl.fnSetPan = SoundBufSetPan; 70 Vtbl.fnSetFrequency = SoundBufSetFrequency; 71 Vtbl.fnLock = SoundBufLock; 72 Vtbl.fnUnlock = SoundBufUnlock; 73 Vtbl.fnStop = SoundBufStop; 74 Vtbl.fnPlay = SoundBufPlay; 75 75 76 76 dprintf(("DSOUND-OS2IDirectSoundBuffer::OS2IDirectSoundBuffer (buf=%X)", this)); … … 94 94 // destroyed; moreover if the user didn't create a primary buffer himself/herself, 95 95 // it will automatically get created and destroyed with the last secondary buffer 96 primary->Vtbl. AddRef(primary);96 primary->Vtbl.fnAddRef(primary); 97 97 98 98 // Start playing the primary buffer 99 99 // TODO: only start playing the primary buffer when necessary! 100 OS2IDirectSoundBuffer::primary->Vtbl. Play(OS2IDirectSoundBuffer::primary, 0, 0, DSBPLAY_LOOPING);100 OS2IDirectSoundBuffer::primary->Vtbl.fnPlay(OS2IDirectSoundBuffer::primary, 0, 0, DSBPLAY_LOOPING); 101 101 102 102 parentDS = DSound; … … 156 156 //This is the constructor used for duplicating sound buffers 157 157 lpVtbl = &Vtbl; 158 Vtbl. AddRef = SoundBufAddRef;159 Vtbl. Release = SoundBufRelease;160 Vtbl. QueryInterface = SoundBufQueryInterface;161 Vtbl. GetCaps = SoundBufGetCaps;162 Vtbl. GetFormat = SoundBufGetFormat;163 Vtbl. GetVolume = SoundBufGetVolume;164 Vtbl. GetStatus = SoundBufGetStatus;165 Vtbl. GetCurrentPosition = SoundBufGetCurrentPosition;166 Vtbl. GetPan = SoundBufGetPan;167 Vtbl. GetFrequency = SoundBufGetFrequency;168 Vtbl. Initialize = SoundBufInitialize;169 Vtbl. Restore = SoundBufRestore;170 Vtbl. SetFormat = SoundBufSetFormat;171 Vtbl. SetVolume = SoundBufSetVolume;172 Vtbl. SetCurrentPosition = SoundBufSetCurrentPosition;173 Vtbl. SetPan = SoundBufSetPan;174 Vtbl. SetFrequency = SoundBufSetFrequency;175 Vtbl. Lock = SoundBufLock;176 Vtbl. Unlock = SoundBufUnlock;177 Vtbl. Stop = SoundBufStop;178 Vtbl. Play = SoundBufPlay;158 Vtbl.fnAddRef = SoundBufAddRef; 159 Vtbl.fnRelease = SoundBufRelease; 160 Vtbl.fnQueryInterface = SoundBufQueryInterface; 161 Vtbl.fnGetCaps = SoundBufGetCaps; 162 Vtbl.fnGetFormat = SoundBufGetFormat; 163 Vtbl.fnGetVolume = SoundBufGetVolume; 164 Vtbl.fnGetStatus = SoundBufGetStatus; 165 Vtbl.fnGetCurrentPosition = SoundBufGetCurrentPosition; 166 Vtbl.fnGetPan = SoundBufGetPan; 167 Vtbl.fnGetFrequency = SoundBufGetFrequency; 168 Vtbl.fnInitialize = SoundBufInitialize; 169 Vtbl.fnRestore = SoundBufRestore; 170 Vtbl.fnSetFormat = SoundBufSetFormat; 171 Vtbl.fnSetVolume = SoundBufSetVolume; 172 Vtbl.fnSetCurrentPosition = SoundBufSetCurrentPosition; 173 Vtbl.fnSetPan = SoundBufSetPan; 174 Vtbl.fnSetFrequency = SoundBufSetFrequency; 175 Vtbl.fnLock = SoundBufLock; 176 Vtbl.fnUnlock = SoundBufUnlock; 177 Vtbl.fnStop = SoundBufStop; 178 Vtbl.fnPlay = SoundBufPlay; 179 179 180 180 dprintf(("DSOUND-OS2IDirectSoundBuffer::OS2IDirectSoundBuffer/Duplicate (buf=%X)", this)); … … 197 197 // destroyed; moreover if the user didn't create a primary buffer himself/herself, 198 198 // it will automatically get created and destroyed with the last secondary buffer 199 primary->Vtbl. AddRef(primary);199 primary->Vtbl.fnAddRef(primary); 200 200 201 201 parentDS = DSound; … … 259 259 260 260 // release the primary buffer too 261 primary->Vtbl. Release(primary);261 primary->Vtbl.fnRelease(primary); 262 262 263 263 if (this == dsbroot) // is this the first SoundBuffer? … … 284 284 285 285 if (primary != NULL) 286 primary->Vtbl. Stop(primary);286 primary->Vtbl.fnStop(primary); 287 287 288 288 while (cur != NULL) { … … 293 293 dprintf(("DSOUND-OS2IDirectSoundBuffer::DestroyAllBuffers - %X", primary)); 294 294 if (primary != NULL) 295 primary->Vtbl. Release(primary);295 primary->Vtbl.fnRelease(primary); 296 296 } 297 297 … … 306 306 *ppvObj = NULL; 307 307 308 if (IsEqualGUID(riid, IID_IDirectSoundBuffer)) {308 if (IsEqualGUID(riid, &IID_IDirectSoundBuffer)) { 309 309 *ppvObj = This; 310 310 … … 313 313 } 314 314 315 if (IsEqualGUID(riid, IID_IDirectSoundNotify)) {315 if (IsEqualGUID(riid, &IID_IDirectSoundNotify)) { 316 316 OS2IDirectSoundBuffer *me = (OS2IDirectSoundBuffer *)This; 317 317 OS2IDirectSoundNotify *notify; … … 319 319 notify = new OS2IDirectSoundNotify(me); 320 320 *ppvObj = notify; 321 notify->Vtbl. AddRef(notify);321 notify->Vtbl.fnAddRef(notify); 322 322 return DS_OK; 323 323 } 324 324 325 if (IsEqualGUID(riid, IID_IDirectSound3DBuffer)) {325 if (IsEqualGUID(riid, &IID_IDirectSound3DBuffer)) { 326 326 OS2IDirectSoundBuffer *me = (OS2IDirectSoundBuffer *)This; 327 327 OS2IDirectSound3DBuffer *buffer3D; … … 329 329 buffer3D = new OS2IDirectSound3DBuffer(me); 330 330 *ppvObj = buffer3D; 331 buffer3D->Vtbl. AddRef((IDirectSound3DBuffer *)buffer3D);331 buffer3D->Vtbl.fnAddRef((IDirectSound3DBuffer *)buffer3D); 332 332 return DS_OK; 333 333 } -
trunk/src/dsound/dsmixer.cpp
r21342 r21479 20 20 #include <string.h> 21 21 22 #define INITGUID22 #define CINTERFACE 23 23 #include <dsound.h> 24 24 -
trunk/src/opengl/mesa/wmesadef.h
r3597 r21479 87 87 88 88 #if defined(DDRAW) 89 #ifdef __WIN32OS2__ 90 #define __WINE_DD_OBJ_BASE_H/* Don't include dd_obj_base.h, or the file won't*/ 91 #endif /* compile due to redefined symbols.*/ 92 #include <ddraw.h> /* Is this a bug in the Odin DDRAW implementation??*/ 89 #include <ddraw.h> 93 90 #endif 94 91
Note:
See TracChangeset
for help on using the changeset viewer.