summaryrefslogtreecommitdiff
path: root/main.c
diff options
context:
space:
mode:
authorEric Anholt <anholt@FreeBSD.org>2006-06-16 09:49:06 -0700
committerEric Anholt <anholt@FreeBSD.org>2006-06-16 09:49:06 -0700
commit334d2203d35c27e0c0d73226ad8a58360c8b36bb (patch)
tree54f9d39bd6c3a2b6f0469887070b1d1b871ae4ce /main.c
parentb99c20783f3d77077eef2af18960db1a68d0dffd (diff)
Add an option "--minimalrendering" which suppresses the copying of offscreen
rendering results to the window, which reduces the runtime of the blend tests by 10.2% +/- 6.2% on my system. The copy remains on by default because I think it can be useful.
Diffstat (limited to 'main.c')
-rw-r--r--main.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/main.c b/main.c
index a6b3961..05653c5 100644
--- a/main.c
+++ b/main.c
@@ -29,7 +29,7 @@
extern int num_ops;
extern int num_colors;
-int is_verbose = FALSE;
+Bool is_verbose = FALSE, minimalrendering = FALSE;
int enabled_tests = ~0; /* Enable all tests by default */
/* Number of times to repeat operations so that pixmaps will tend to get moved
@@ -104,7 +104,7 @@ static void
usage (char *program)
{
fprintf(stderr, "usage: %s [-d|--display display] [-v|--verbose]\n"
- "\t[-t test1,test2,...] [--sync]\n"
+ "\t[-t test1,test2,...] [--sync] [--minimalrendering]\n"
"\tAvailable tests: dcoors,scoords,mcoords,tscoords,\n"
"\t\ttmcoords,blend,composite,cacomposite,gradients,repeat,triangles\n",
program);
@@ -129,6 +129,8 @@ int main(int argc, char **argv)
{ "tests", required_argument, NULL, 't' },
{ "verbose", no_argument, NULL, 'v' },
{ "sync", no_argument, &is_sync, 1},
+ { "minimalrendering", no_argument, &minimalrendering,
+ TRUE},
{ NULL, 0, NULL, 0 }
};