shithub: purgatorio

Download patch

ref: d3da2e1b89f30f404c3d11053680098f1b7bf677
parent: f5cc6fbe3a7bcf8bdb002c646ddd519014afafd2
author: henesy <devnull@localhost>
date: Sat Feb 29 18:54:49 EST 2020

merge f2847740e449ea52349968e40fa4e5fb8426bb41 from upstream

--- a/.hgignore	Sat Oct 12 06:31:24 2019
+++ b/.hgignore	Sat Feb 29 18:54:49 2020
@@ -53,6 +53,7 @@
 keydb/signed
 keydb/signerkey
 tmp/*
+*.rej
 
 syntax: regexp
 ^dis/.*.dis
--- a/emu/port/win-x11a.c	Sat Oct 12 06:31:24 2019
+++ b/emu/port/win-x11a.c	Sat Feb 29 18:54:49 2020
@@ -341,6 +341,33 @@
 }
 
 static void
+copy16to16(Rectangle r)
+{
+	int dx, width;
+	u16int *dp, *wp, *edp, *lp;
+
+	width = Dx(r);
+	dx = Xsize - width;
+	dp = (u16int*)(gscreendata + ((r.min.y * Xsize) + r.min.x) * 2);
+	wp = (u16int*)(xscreendata + ((r.min.y * Xsize) + r.min.x) * 2);
+	edp = (u16int*)(gscreendata + ((r.max.y * Xsize) + r.max.x) * 2);
+
+	/* The pixel format should be the same as the underlying X display (see
+	   the xtruevisual function) unless a different channel format is
+	   explicitly specified on the command line, so just copy the pixel data
+	   without any processing. */
+
+	while(dp < edp) {
+		lp = dp + width;
+		while(dp < lp){
+			*wp++ = *dp++;
+		}
+		dp += dx;
+		wp += dx;
+	}
+}
+
+static void
 copy8to32(Rectangle r)
 {
 	int dx, width;