summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLode <lvandeve@gmail.com>2014-11-19 22:22:33 +0100
committerLode <lvandeve@gmail.com>2014-11-19 22:22:33 +0100
commitb5eb75dc2d7c7f29509b1c0a74b0ab349372e767 (patch)
treeb565a2d541b161acd1054873ccb29d532bd303fc
parentd6e061315e6df91a4d8025daefea769896190eef (diff)
unit test was a bit slow like that
-rw-r--r--lodepng_unittest.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/lodepng_unittest.cpp b/lodepng_unittest.cpp
index 150511c..d3b3498 100644
--- a/lodepng_unittest.cpp
+++ b/lodepng_unittest.cpp
@@ -497,18 +497,18 @@ void testColor(int r, int g, int b, int a)
{
std::cout << "codec test color " << r << " " << g << " " << b << " " << a << std::endl;
Image image;
- image.width = 100;
- image.height = 100;
+ image.width = 20;
+ image.height = 20;
image.colorType = LCT_RGBA;
image.bitDepth = 8;
- image.data.resize(100 * 100 * 4);
- for(int y = 0; y < 100; y++)
- for(int x = 0; x < 100; x++)
+ image.data.resize(20 * 20 * 4);
+ for(int y = 0; y < 20; y++)
+ for(int x = 0; x < 20; x++)
{
- image.data[100 * 4 * y + 4 * x + 0] = r;
- image.data[100 * 4 * y + 4 * x + 0] = g;
- image.data[100 * 4 * y + 4 * x + 0] = b;
- image.data[100 * 4 * y + 4 * x + 0] = a;
+ image.data[20 * 4 * y + 4 * x + 0] = r;
+ image.data[20 * 4 * y + 4 * x + 0] = g;
+ image.data[20 * 4 * y + 4 * x + 0] = b;
+ image.data[20 * 4 * y + 4 * x + 0] = a;
}
doCodecTest(image);