diff options
| author | MightyPlaza <123664421+MightyPlaza@users.noreply.github.com> | 2023-07-04 09:40:28 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-07-04 11:40:28 +0200 |
| commit | 283a8e77aaa27e207a6d3cd298b4f0bac354101f (patch) | |
| tree | 53baece46e2648ff8c2dd0d54366e51e283f4ac5 /src/protocols/Screencopy.cpp | |
| parent | 50755d26d4662f7392895f35a67502bc8c842a2d (diff) | |
screenshot fix (#2640)
Diffstat (limited to 'src/protocols/Screencopy.cpp')
| -rw-r--r-- | src/protocols/Screencopy.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/protocols/Screencopy.cpp b/src/protocols/Screencopy.cpp index d47888a0..60b1273e 100644 --- a/src/protocols/Screencopy.cpp +++ b/src/protocols/Screencopy.cpp @@ -233,14 +233,14 @@ void CScreencopyProtocolManager::captureOutput(wl_client* client, wl_resource* r } if (box.width == 0 && box.height == 0) - PFRAME->box = {0, 0, (int)(PFRAME->pMonitor->vecSize.x * PFRAME->pMonitor->scale), (int)(PFRAME->pMonitor->vecSize.y * PFRAME->pMonitor->scale)}; + PFRAME->box = {0, 0, (int)(PFRAME->pMonitor->vecSize.x), (int)(PFRAME->pMonitor->vecSize.y)}; else { PFRAME->box = box; - scaleBox(&PFRAME->box, PFRAME->pMonitor->scale); } int ow, oh; wlr_output_effective_resolution(PFRAME->pMonitor->output, &ow, &oh); wlr_box_transform(&PFRAME->box, &PFRAME->box, PFRAME->pMonitor->transform, ow, oh); + scaleBox(&PFRAME->box, PFRAME->pMonitor->scale); PFRAME->shmStride = (PSHMINFO->bpp / 8) * PFRAME->box.width; |
