fix blitter clipping
This commit is contained in:
parent
0ec983829d
commit
606a7460ee
1 changed files with 12 additions and 6 deletions
|
@ -177,6 +177,12 @@ HRESULT dds_Blt(
|
|||
int dst_x = dst_rect.left;
|
||||
int dst_y = dst_rect.top;
|
||||
|
||||
if (!is_stretch_blt)
|
||||
{
|
||||
src_w = dst_w = min(src_w, dst_w);
|
||||
src_h = dst_h = min(src_h, dst_h);
|
||||
}
|
||||
|
||||
void* dst_buf = dds_GetBuffer(This);
|
||||
void* src_buf = dds_GetBuffer(src_surface);
|
||||
|
||||
|
@ -294,8 +300,8 @@ HRESULT dds_Blt(
|
|||
dst_buf,
|
||||
dst_x,
|
||||
dst_y,
|
||||
min(dst_w, src_w),
|
||||
min(dst_h, src_h),
|
||||
dst_w,
|
||||
dst_h,
|
||||
This->l_pitch,
|
||||
src_buf,
|
||||
src_x,
|
||||
|
@ -350,8 +356,8 @@ HRESULT dds_Blt(
|
|||
dst_buf,
|
||||
dst_x,
|
||||
dst_y,
|
||||
min(dst_w, src_w),
|
||||
min(dst_h, src_h),
|
||||
dst_w,
|
||||
dst_h,
|
||||
This->l_pitch,
|
||||
src_buf,
|
||||
src_x,
|
||||
|
@ -365,8 +371,8 @@ HRESULT dds_Blt(
|
|||
dst_buf,
|
||||
dst_x,
|
||||
dst_y,
|
||||
min(dst_w, src_w),
|
||||
min(dst_h, src_h),
|
||||
dst_w,
|
||||
dst_h,
|
||||
This->l_pitch,
|
||||
src_buf,
|
||||
src_x,
|
||||
|
|
Loading…
Reference in a new issue