- Timestamp:
- Nov 29, 2010, 2:07:07 PM (15 years ago)
- Location:
- trunk/src/ddraw
- Files:
-
- 10 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/ddraw/clipper.cpp
r21479 r21483 20 20 #include <memory.h> 21 21 22 #define CINTERFACE 22 #ifndef CINTERFACE 23 #define CINTERFACE 1 24 #endif 23 25 #include "ddraw2d.h" 24 26 #include "clipper.h" -
trunk/src/ddraw/ddclipper.cpp
r21479 r21483 20 20 #include <stdio.h> 21 21 22 #define CINTERFACE 22 #ifndef CINTERFACE 23 #define CINTERFACE 1 24 #endif 23 25 #include "ddraw2d.h" 24 26 #include "clipper.h" -
trunk/src/ddraw/ddmain.cpp
r21479 r21483 23 23 #include <stdio.h> 24 24 25 #define CINTERFACE 25 #ifndef CINTERFACE 26 #define CINTERFACE 1 27 #endif 26 28 #include "ddraw2d.h" 27 29 #include "winerror.h" -
trunk/src/ddraw/ddraw2d.cpp
r21479 r21483 22 22 #include <winuser32.h> 23 23 24 #ifndef CINTERFACE 25 #define CINTERFACE 1 26 #endif 24 27 #define INITGUID 25 #define CINTERFACE26 28 #include "ddraw2d.h" 27 29 #include "clipper.h" -
trunk/src/ddraw/ddraw3d.cpp
r21479 r21483 20 20 #include <winbase.h> 21 21 22 #define CINTERFACE 22 #ifndef CINTERFACE 23 #define CINTERFACE 1 24 #endif 23 25 #include "ddraw2d.h" 24 26 #include "clipper.h" -
trunk/src/ddraw/palette.cpp
r21479 r21483 21 21 #include <memory.h> 22 22 23 #define CINTERFACE 23 #ifndef CINTERFACE 24 #define CINTERFACE 1 25 #endif 24 26 #include "ddraw2d.h" 25 27 #include "clipper.h" -
trunk/src/ddraw/surface.cpp
r21479 r21483 25 25 #include <fourcc.h> 26 26 27 #define CINTERFACE 27 #ifndef CINTERFACE 28 #define CINTERFACE 1 29 #endif 28 30 #include "ddraw2d.h" 29 31 #include "clipper.h" -
trunk/src/ddraw/surfacehlp.cpp
r21479 r21483 13 13 #include <fourcc.h> 14 14 15 #define CINTERFACE 15 #ifndef CINTERFACE 16 #define CINTERFACE 1 17 #endif 16 18 #include "ddraw2d.h" 17 19 #include "clipper.h" … … 572 574 { 573 575 // +-------+ +-------+ +-------+ 574 // |S | |S | |S | 575 // | +---|---+ +-------+ +---|---+ | 576 // | | D | | | D | | D | | | 577 // +-------+ | +-------+ | +-------+ 578 // | | | | | | 576 // |S | |S | |S | 577 // | +---|---+ +-------+ +---|---+ | 578 // | | D | | | D | | D | | | 579 // +-------+ | +-------+ | +-------+ 580 // | | | | | | 579 581 // +-------+ +-------+ +-------+ 580 582 // -
trunk/src/ddraw/surfblit.cpp
r21479 r21483 25 25 #include <fourcc.h> 26 26 27 #define CINTERFACE 27 #ifndef CINTERFACE 28 #define CINTERFACE 1 29 #endif 28 30 #include "ddraw2d.h" 29 31 #include "clipper.h" … … 196 198 197 199 //src == NULL for colorfill 198 if(src) 200 if(src) 199 201 { 200 202 if (NULL!=lpSrcRect) … … 259 261 SrcRect.right = src->width; 260 262 } 261 263 262 264 if(src->fLocked) 263 265 { … … 299 301 if(dest->diveBufNr == DIVE_BUFFER_SCREEN && 300 302 !(dwFlags & (DDBLT_COLORFILL|DDBLT_DEPTHFILL|DDBLT_ROP) ) && 301 dest->DDSurfaceDesc.ddpfPixelFormat.dwRGBBitCount > 8 && 303 dest->DDSurfaceDesc.ddpfPixelFormat.dwRGBBitCount > 8 && 302 304 src->DDSurfaceDesc.ddpfPixelFormat.dwRGBBitCount > 8) 303 305 { … … 311 313 if( (src->DDSurfaceDesc.dwHeight == srcheight && 312 314 src->DDSurfaceDesc.dwWidth == srcwidth) || 313 (srcwidth != destwidth && srcheight != destheight) ) 315 (srcwidth != destwidth && srcheight != destheight) ) 314 316 { 315 317 SETUP_BLITTER sBlt = {0}; … … 333 335 sBlt.pVisDstRects = NULL; 334 336 335 if(dest->lpClipper && dest->lpClipper->IsClipListChangedInt()) 337 if(dest->lpClipper && dest->lpClipper->IsClipListChangedInt()) 336 338 { 337 339 DWORD rgnsize; 338 if(ClipGetClipList((IDirectDrawClipper*)dest->lpClipper, NULL, NULL, &rgnsize) == DD_OK) 340 if(ClipGetClipList((IDirectDrawClipper*)dest->lpClipper, NULL, NULL, &rgnsize) == DD_OK) 339 341 { 340 342 LPRGNDATA lpRgnData = (LPRGNDATA)alloca(rgnsize); … … 343 345 goto dodiveblit; 344 346 } 345 if(ClipGetClipList((IDirectDrawClipper*)dest->lpClipper, NULL, lpRgnData, &rgnsize) == DD_OK) 347 if(ClipGetClipList((IDirectDrawClipper*)dest->lpClipper, NULL, lpRgnData, &rgnsize) == DD_OK) 346 348 { 347 349 OS2RECTL *pRectl = (OS2RECTL *)&lpRgnData->Buffer; … … 352 354 } 353 355 dprintf(("visible region")); 354 for(i=0;i<lpRgnData->rdh.nCount;i++) 356 for(i=0;i<lpRgnData->rdh.nCount;i++) 355 357 { 356 358 //win32 -> os2 coordinates (region data in screen coordinates) … … 413 415 //TODO: do we need to check the source for clipping information in case 414 416 // the app wants to copy from the frame buffer? 415 if(dest->lpClipper) 417 if(dest->lpClipper) 416 418 { 417 419 DWORD rgnsize; 418 if(ClipGetClipList((IDirectDrawClipper*)dest->lpClipper, NULL, NULL, &rgnsize) == DD_OK) 420 if(ClipGetClipList((IDirectDrawClipper*)dest->lpClipper, NULL, NULL, &rgnsize) == DD_OK) 419 421 { 420 422 LPRGNDATA lpRgnData = (LPRGNDATA)alloca(rgnsize); … … 423 425 goto doblit; 424 426 } 425 if(ClipGetClipList((IDirectDrawClipper*)dest->lpClipper, NULL, lpRgnData, &rgnsize) == DD_OK) 427 if(ClipGetClipList((IDirectDrawClipper*)dest->lpClipper, NULL, lpRgnData, &rgnsize) == DD_OK) 426 428 { 427 429 RECT newdest, newsrc; … … 431 433 QueryPerformanceCounter(&liStart); 432 434 #endif 433 for(i=0;i<lpRgnData->rdh.nCount;i++) 435 for(i=0;i<lpRgnData->rdh.nCount;i++) 434 436 { 435 437 dprintf(("Clip list %d (%d,%d)(%d,%d)", i, lpClipRect[i].left, lpClipRect[i].bottom, lpClipRect[i].right, lpClipRect[i].top)); 436 438 437 if(IntersectRect(&newdest, &DestRect, &lpClipRect[i]) == TRUE) 439 if(IntersectRect(&newdest, &DestRect, &lpClipRect[i]) == TRUE) 438 440 { 439 441 //TODO: This is not correct for stretching blits … … 446 448 // DDSURFACEDESC2 surfdesc = {0}; 447 449 // SurfLock4(dest, &newdest, &surfdesc, 0, 0); 448 450 449 451 ret = SurfDoBlt(This, &newdest, lpDDSrcSurface, (lpSrcRect) ? &newsrc : NULL, dwFlags, lpDDBltFx); 450 452 if(ret != DD_OK) { -
trunk/src/ddraw/surfoverlay.cpp
r21479 r21483 25 25 #include <fourcc.h> 26 26 27 #define CINTERFACE 27 #ifndef CINTERFACE 28 #define CINTERFACE 1 29 #endif 28 30 #include "ddraw2d.h" 29 31 #include "clipper.h"
Note:
See TracChangeset
for help on using the changeset viewer.