diff options
author | Jay Sorg <jay.sorg@gmail.com> | 2012-08-16 23:23:18 -0700 |
---|---|---|
committer | Jay Sorg <jay.sorg@gmail.com> | 2012-08-16 23:23:18 -0700 |
commit | 68ef2fadde50188faf071798b384f7d71d1c3f6f (patch) | |
tree | 9bf7497cf2fe3327b44948bcdfc1e8a9202d6cd2 /xorg/X11R7.6/rdp/rdpPolyPoint.c | |
parent | ea98b503caf78170d5a1a94557cb1a6d98821645 (diff) | |
download | xrdp-proprietary-68ef2fadde50188faf071798b384f7d71d1c3f6f.tar.gz xrdp-proprietary-68ef2fadde50188faf071798b384f7d71d1c3f6f.zip |
xorg: work on delayed/dirty updates
Diffstat (limited to 'xorg/X11R7.6/rdp/rdpPolyPoint.c')
-rw-r--r-- | xorg/X11R7.6/rdp/rdpPolyPoint.c | 36 |
1 files changed, 33 insertions, 3 deletions
diff --git a/xorg/X11R7.6/rdp/rdpPolyPoint.c b/xorg/X11R7.6/rdp/rdpPolyPoint.c index 9e0a43de..cbbc4a98 100644 --- a/xorg/X11R7.6/rdp/rdpPolyPoint.c +++ b/xorg/X11R7.6/rdp/rdpPolyPoint.c @@ -62,6 +62,8 @@ rdpPolyPoint(DrawablePtr pDrawable, GCPtr pGC, int mode, int npt, DDXPointPtr in_pts) { RegionRec clip_reg; + RegionRec reg1; + RegionRec reg2; int num_clips; int cd; int x; @@ -83,6 +85,7 @@ rdpPolyPoint(DrawablePtr pDrawable, GCPtr pGC, int mode, rdpPixmapRec* pDirtyPriv; LLOGLN(10, ("rdpPolyPoint:")); + LLOGLN(10, ("rdpPolyPoint: npt %d", npt)); if (npt > 32) { @@ -145,7 +148,7 @@ rdpPolyPoint(DrawablePtr pDrawable, GCPtr pGC, int mode, LLOGLN(10, ("rdpPolyPoint: gettig dirty")); pDstPriv->is_dirty = 1; pDirtyPriv = pDstPriv; - dirty_type = RDI_IMGLY; + dirty_type = RDI_IMGLL; } else { @@ -182,7 +185,20 @@ rdpPolyPoint(DrawablePtr pDrawable, GCPtr pGC, int mode, { if (dirty_type != 0) { - /* TODO */ + RegionInit(®1, NullBox, 0); + for (i = 0; i < npt; i++) + { + box.x1 = pts[i].x; + box.y1 = pts[i].y; + box.x2 = box.x1 + 1; + box.y2 = box.y1 + 1; + RegionInit(®2, &box, 0); + RegionUnion(®1, ®1, ®2); + RegionUninit(®2); + } + draw_item_add_fill_region(pDirtyPriv, ®1, pGC->fgPixel, + pGC->alu); + RegionUninit(®1); } else if (got_id) { @@ -205,7 +221,21 @@ rdpPolyPoint(DrawablePtr pDrawable, GCPtr pGC, int mode, { if (dirty_type != 0) { - /* TODO */ + RegionInit(®1, NullBox, 0); + for (i = 0; i < npt; i++) + { + box.x1 = pts[i].x; + box.y1 = pts[i].y; + box.x2 = box.x1 + 1; + box.y2 = box.y1 + 1; + RegionInit(®2, &box, 0); + RegionUnion(®1, ®1, ®2); + RegionUninit(®2); + } + RegionIntersect(®1, ®1, &clip_reg); + draw_item_add_fill_region(pDirtyPriv, ®1, pGC->fgPixel, + pGC->alu); + RegionUninit(®1); } else if (got_id) { |