Commit 554b4714 authored by Andy Ritger's avatar Andy Ritger Committed by Aaron Plattner

nvctrl samples: Add "--blend-after-warp" option to nv-control-warpblend

parent 9a680076
......@@ -70,6 +70,7 @@ int main(int ac, char **av)
Pixmap blendPixmap;
vertexDataRec warpData[6];
int nvDpyId;
Bool blendAfterWarp = False;
if (!xDpy) {
fprintf (stderr, "Could not open X Display %s!\n", XDisplayName(NULL));
......@@ -78,12 +79,16 @@ int main(int ac, char **av)
screenId = XDefaultScreen(xDpy);
if (ac != 2) {
fprintf (stderr, "Usage: ./nv-control-warpblend nvDpyId\n");
if ((ac != 2) && (ac != 3)) {
fprintf (stderr, "Usage: ./nv-control-warpblend nvDpyId [--blend-after-warp]\n");
fprintf (stderr, "See 'nvidia-settings -q CurrentMetaMode' for currently connected DPYs.\n");
return 1;
}
if (ac == 3) {
blendAfterWarp = (strcmp("--blend-after-warp", av[2]) == 0);
}
nvDpyId = atoi(av[1]);
// Start with two screen-aligned triangles, and warp them using the sample
......@@ -166,7 +171,7 @@ int main(int ac, char **av)
screenId,
nvDpyId,
blendPixmap,
False);
blendAfterWarp);
return 0;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment