From f6be0cba1b23a6ebf08b1414dc896d757451942c Mon Sep 17 00:00:00 2001
From: Tomi Valkeinen <tomi.valkeinen@ti.com>
Date: Mon, 5 Jun 2017 10:19:38 +0300
Subject: testpat: fix the location of second diagonal line

---
 kms++util/src/testpat.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'kms++util/src')

diff --git a/kms++util/src/testpat.cpp b/kms++util/src/testpat.cpp
index dbd8fe6..faacda3 100644
--- a/kms++util/src/testpat.cpp
+++ b/kms++util/src/testpat.cpp
@@ -55,7 +55,7 @@ static RGB get_test_pattern_pixel(IMappedFramebuffer& fb, unsigned x, unsigned y
 		if (x == y || w - x == h - y)
 			return RGB(255, 255, 255);
 		// diagonal line
-		else if (w - x == y || x == h - y)
+		else if (w - x - 1 == y || x == h - y - 1)
 			return RGB(255, 255, 255);
 		else {
 			int t = (x - xm1 - 1) * 8 / (xm2 - xm1 - 1);
-- 
cgit v1.2.3