summaryrefslogtreecommitdiff
path: root/recordmydesktop/src/rmd_update_image.c
diff options
context:
space:
mode:
authorVito Caputo <vcaputo@pengaru.com>2020-07-09 23:16:16 -0700
committerVito Caputo <vcaputo@pengaru.com>2020-07-11 13:36:42 -0700
commit6ff81d0947a68fa5432c88a08bb9842c71c81489 (patch)
tree825f461faae05fbfa63b684d2a150e7325a26e84 /recordmydesktop/src/rmd_update_image.c
parent4aebce99a7811e4defc89c65efd69e9ba71f1f0c (diff)
*: introduce Image type
Baby step towards encapsulating the shmem and ximage state
Diffstat (limited to 'recordmydesktop/src/rmd_update_image.c')
-rw-r--r--recordmydesktop/src/rmd_update_image.c14
1 files changed, 5 insertions, 9 deletions
diff --git a/recordmydesktop/src/rmd_update_image.c b/recordmydesktop/src/rmd_update_image.c
index 615bcd3..52ed478 100644
--- a/recordmydesktop/src/rmd_update_image.c
+++ b/recordmydesktop/src/rmd_update_image.c
@@ -42,20 +42,18 @@ void rmdUpdateImage( Display * dpy,
RectArea **root,
BRWindow *brwin,
EncData *enc,
- char *datatemp,
+ Image *image,
int noshmem,
- XShmSegmentInfo *shminfo,
int shm_opcode,
int no_quick_subsample){
- unsigned char *dtap=(unsigned char*)datatemp;
RectArea *temp;
for (temp = *root; temp; temp = temp->next) {
if (noshmem) {
rmdGetZPixmap( dpy,
specs->root,
- datatemp,
+ image->ximage->data,
temp->rect.x,
temp->rect.y,
temp->rect.width,
@@ -63,19 +61,17 @@ void rmdUpdateImage( Display * dpy,
} else {
rmdGetZPixmapSHM( dpy,
specs->root,
- shminfo,
+ &image->shm_info,
shm_opcode,
- datatemp,
+ image->ximage->data,
temp->rect.x,
temp->rect.y,
temp->rect.width,
temp->rect.height);
}
-
-
rmdUpdateYuvBuffer(
yuv,
- dtap,
+ (unsigned char *)image->ximage->data,
NULL,
temp->rect.x - brwin->rrect.x + enc->x_offset,
temp->rect.y - brwin->rrect.y + enc->y_offset,
© All Rights Reserved