mirror of
https://github.com/reactos/reactos.git
synced 2025-08-06 11:12:58 +00:00
[WIN32K] Implement RECTL_bClipRectBySize() and use it in IntEngBitBlt() to clip the target rect against the bounds of the target surface. Also clip the source rect against the source surface. Fixes remaining part of CORE-14463
This commit is contained in:
parent
79ad68ddc3
commit
2170901e6a
3 changed files with 45 additions and 10 deletions
|
@ -67,6 +67,20 @@ RECTL_bIsWellOrdered(
|
|||
(prcl->top <= prcl->bottom));
|
||||
}
|
||||
|
||||
FORCEINLINE
|
||||
BOOL
|
||||
RECTL_bClipRectBySize(
|
||||
_Out_ RECTL *prclDst,
|
||||
_In_ const RECTL *prclSrc,
|
||||
_In_ const SIZEL *pszl)
|
||||
{
|
||||
prclDst->left = max(prclSrc->left, 0);
|
||||
prclDst->top = max(prclSrc->top, 0);
|
||||
prclDst->right = min(prclSrc->right, pszl->cx);
|
||||
prclDst->bottom = min(prclSrc->bottom, pszl->cy);
|
||||
return !RECTL_bIsEmptyRect(prclDst);
|
||||
}
|
||||
|
||||
BOOL
|
||||
FASTCALL
|
||||
RECTL_bUnionRect(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue