Commit dc1d9ed1 authored by Eric Anholt's avatar Eric Anholt

Merge branch 'glean-master'

parents b92a69b9 9a6cb4b2
......@@ -163,11 +163,23 @@ DrawingSurfaceFilter::matches(DrawingSurfaceConfig& c) {
///////////////////////////////////////////////////////////////////////////////
vector<DrawingSurfaceConfig*>
DrawingSurfaceFilter::filter(vector<DrawingSurfaceConfig*>& v) {
return filter(v, ~0u);
} // DrawingSurfaceFilter::filter
///////////////////////////////////////////////////////////////////////////////
// filter - filter as above, but limit number of results
///////////////////////////////////////////////////////////////////////////////
vector<DrawingSurfaceConfig*>
DrawingSurfaceFilter::filter(vector<DrawingSurfaceConfig*>& v,
unsigned int maxConfigs) {
vector<DrawingSurfaceConfig*> result;
unsigned count = 0;
for (vector<DrawingSurfaceConfig*>::const_iterator p = v.begin();
p < v.end(); ++p) {
if (matches(**p))
p < v.end() && count < maxConfigs; ++p) {
if (matches(**p)) {
result.push_back(*p);
count++;
}
}
sort(result.begin(), result.end(), ConfigSort(sortKeys));
......
......@@ -119,6 +119,10 @@ class DrawingSurfaceFilter {
// match the filter criteria, sorted according to the sorting
// criteria.
vector<DrawingSurfaceConfig*> filter(vector<DrawingSurfaceConfig*>& v,
unsigned int maxConfigs);
// As above, but limit number of filter results to given count.
protected:
typedef enum {
......
......@@ -61,6 +61,7 @@ main(int argc, char* argv[]) {
// Until someone gets around to writing a fancy GUI front-end,
// we'll set options the old-fashioned way.
Options o;
bool visFilter = false;
vector<string> allTestNames;
for (Test* t = Test::testList; t; t = t->nextTest)
......@@ -92,6 +93,7 @@ main(int argc, char* argv[]) {
++i;
o.db2Name = mandatoryArg(argc, argv, i);
} else if (!strcmp(argv[i], "--visuals")) {
visFilter = true;
++i;
o.visFilter = mandatoryArg(argc, argv, i);
} else if (!strcmp(argv[i], "-t")
......@@ -119,6 +121,13 @@ main(int argc, char* argv[]) {
exit(0);
}
if (o.quick && !visFilter) {
// If we have --quick but not --visuals then limit testing to
// a single RGB, Z, Stencil visual.
o.visFilter = "rgb && z>0 && s>0 && conformant";
o.maxVisuals = 1;
}
// Create the test environment, then invoke each test to generate
// results or compare two previous runs.
try {
......
......@@ -46,6 +46,7 @@ Options::Options() {
db1Name = "results";
db2Name = "previous";
visFilter = "1";
maxVisuals = ~0U;
selectedTests.resize(0);
overwrite = false;
quick = false;
......
......@@ -78,6 +78,8 @@ class Options {
// DrawingSurfaceFilter for description of
// contents.
unsigned int maxVisuals;// Max number of visuals to test
vector<string> selectedTests;
// Sorted list of tests to be executed.
......
......@@ -311,14 +311,14 @@ API2Test::renderQuadWithArrays(GLint attr, const GLfloat value[4],
};
glVertexPointer(3, GL_FLOAT, 0, vertcoords);
glEnable(GL_VERTEX_ARRAY);
glEnableClientState(GL_VERTEX_ARRAY);
glVertexAttribPointer_func(attr, 4, GL_FLOAT, GL_FALSE, 0, values);
glEnableVertexAttribArray_func(attr);
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
glDrawArrays(GL_POLYGON, 0, 4);
glDisable(GL_VERTEX_ARRAY);
glDisableClientState(GL_VERTEX_ARRAY);
glDisableVertexAttribArray_func(attr);
// read a pixel from lower-left corner of rendered quad
......
......@@ -288,7 +288,7 @@ public:
// Select the drawing configurations for testing
DrawingSurfaceFilter f(filter);
vector<DrawingSurfaceConfig*>
configs(f.filter(ws.surfConfigs));
configs(f.filter(ws.surfConfigs, environment.options.maxVisuals));
if (env->options.quick)
testOne = true;
......
......@@ -220,13 +220,13 @@ ClipFlatTest::drawArrays(GLenum mode, const GLfloat *verts, GLuint count)
{
glColorPointer(3, GL_FLOAT, 5 * sizeof(GLfloat), verts + 0);
glVertexPointer(2, GL_FLOAT, 5 * sizeof(GLfloat), verts + 3);
glEnable(GL_COLOR_ARRAY);
glEnable(GL_VERTEX_ARRAY);
glEnableClientState(GL_COLOR_ARRAY);
glEnableClientState(GL_VERTEX_ARRAY);
glDrawArrays(mode, 0, count);
glDisable(GL_COLOR_ARRAY);
glDisable(GL_VERTEX_ARRAY);
glDisableClientState(GL_COLOR_ARRAY);
glDisableClientState(GL_VERTEX_ARRAY);
}
......
......@@ -261,7 +261,8 @@ DepthStencilTest::readPixelsRate(GLenum format, GLenum type)
delete [] img;
double rate = width * height * iterations / elapsedTime;
double rate = width * height * (double) iterations / elapsedTime;
assert(rate > 0.0);
return rate; // pixels/second
}
......
......@@ -665,7 +665,7 @@ FBOTest::testRender2SingleTexture(void)
glDepthFunc(GL_ALWAYS);
switch (textureModes[mode]) {
case GL_TEXTURE_1D:
glBegin(GL_LINE);
glBegin(GL_LINES);
glVertex3f(TEXSIZE / 4, 0, 0.3);
glVertex3f(TEXSIZE * 5 / 8, 0, 0.3);
glEnd();
......@@ -695,7 +695,7 @@ FBOTest::testRender2SingleTexture(void)
GL_KEEP, GL_REPLACE);
switch (textureModes[mode]) {
case GL_TEXTURE_1D:
glBegin(GL_LINE);
glBegin(GL_LINES);
glVertex3f(TEXSIZE / 2, 0, 0.3);
glVertex3f(TEXSIZE * 7 / 8, 0, 0.3);
glEnd();
......@@ -726,7 +726,7 @@ FBOTest::testRender2SingleTexture(void)
switch (textureModes[mode]) {
case GL_TEXTURE_1D:
glBegin(GL_LINE);
glBegin(GL_LINES);
glVertex3f(0, 0, 0.2);
glVertex3f(TEXSIZE, 0, 0.2);
glEnd();
......
......@@ -118,6 +118,21 @@ static const FragmentProgram Programs[] = {
},
DONT_CARE_Z
},
{
"ADD with saturation",
"!!ARBfp1.0\n"
"PARAM p = program.local[1]; \n"
"TEMP t; \n"
"ADD t, p, p; \n"
"ADD_SAT result.color, t, p; \n"
"END \n",
{ CLAMP01(Param1[0] + Param1[0] + Param1[0]),
CLAMP01(Param1[1] + Param1[1] + Param1[1]),
CLAMP01(Param1[2] + Param1[2] + Param1[2]),
CLAMP01(Param1[3] + Param1[3] + Param1[3]),
},
DONT_CARE_Z
},
{
"CMP test",
"!!ARBfp1.0\n"
......@@ -561,6 +576,22 @@ static const FragmentProgram Programs[] = {
},
DONT_CARE_Z
},
{
"SUB with saturation",
"!!ARBfp1.0\n"
"PARAM p1 = program.local[1]; \n"
"PARAM bias = {0.1, 0.1, 0.1, 0.1}; \n"
"TEMP t; \n"
"SUB_SAT t, fragment.color, p1; \n"
"ADD result.color, t, bias; \n"
"END \n",
{ CLAMP01(FragColor[0] - Param1[1]) + 0.1,
CLAMP01(FragColor[1] - Param1[1]) + 0.1,
CLAMP01(FragColor[2] - Param1[2]) + 0.1,
CLAMP01(FragColor[3] - Param1[3]) + 0.1
},
DONT_CARE_Z
},
{
"SWZ test",
"!!ARBfp1.0\n"
......
......@@ -358,6 +358,21 @@ static const ShaderProgram Programs[] = {
FLAG_NONE
},
{
// This test targets SOA implementations where we have to
// check for SOA dependencies.
"Swizzle in-place",
NO_VERTEX_SHADER,
"void main() { \n"
" vec4 a = vec4(0.5, 0.2, 0.1, 0.8); \n"
" a = a.yxwz; \n"
" gl_FragColor = a; \n"
"} \n",
{ 0.2, 0.5, 0.8, 0.1 },
DONT_CARE_Z,
FLAG_NONE
},
{
"Swizzled swizzle",
NO_VERTEX_SHADER,
......@@ -2185,13 +2200,13 @@ static const ShaderProgram Programs[] = {
{
"function call with in, out params",
NO_VERTEX_SHADER,
"void half(in float x, out float y) { \n"
"void Half(in float x, out float y) { \n"
" y = 0.5 * x; \n"
"} \n"
"\n"
"void main() { \n"
" float a = 0.5, b = 0.1; \n"
" half(a, b); \n"
" Half(a, b); \n"
" gl_FragColor = vec4(b); \n"
"} \n",
{ 0.25, 0.25, 0.25, 0.25 },
......@@ -2256,10 +2271,31 @@ static const ShaderProgram Programs[] = {
FLAG_NONE
},
{
"function with early return (4)",
NO_VERTEX_SHADER,
"float val = 0.5; \n"
"void sub(in float x) { \n"
" if (x >= 0.3) \n"
" if (x >= 0.4) \n"
" return; \n"
" val = 1.0; \n"
"} \n"
"\n"
"void main() { \n"
" sub(gl_TexCoord[0].s); \n"
" gl_FragColor = vec4(val); \n"
"} \n",
{ 0.5, 0.5, 0.5, 0.5 },
DONT_CARE_Z,
FLAG_NONE
},
{
"nested function calls (1)",
NO_VERTEX_SHADER,
"float half(const in float x) { \n"
"float Half(const in float x) { \n"
" return 0.5 * x; \n"
"} \n"
"\n"
......@@ -2269,7 +2305,7 @@ static const ShaderProgram Programs[] = {
"\n"
"void main() { \n"
" float a = 0.5; \n"
" float b = square(half(1.0)); \n"
" float b = square(Half(1.0)); \n"
" gl_FragColor = vec4(b); \n"
"} \n",
{ 0.25, 0.25, 0.25, 0.25 },
......@@ -2280,12 +2316,12 @@ static const ShaderProgram Programs[] = {
{
"nested function calls (2)",
NO_VERTEX_SHADER,
"float half(const in float x) { \n"
"float Half(const in float x) { \n"
" return 0.5 * x; \n"
"} \n"
"\n"
"float square_half(const in float x) { \n"
" float y = half(x); \n"
" float y = Half(x); \n"
" return y * y; \n"
"} \n"
"\n"
......@@ -2302,13 +2338,13 @@ static const ShaderProgram Programs[] = {
{
"nested function calls (3)",
NO_VERTEX_SHADER,
"float half(const in float x) { \n"
"float Half(const in float x) { \n"
" return 0.5 * x; \n"
"} \n"
"\n"
"void main() { \n"
" float a = 0.5; \n"
" float b = half(half(a)); \n"
" float b = Half(Half(a)); \n"
" gl_FragColor = vec4(b); \n"
"} \n",
{ 0.125, 0.125, 0.125, 0.125 },
......@@ -3175,6 +3211,86 @@ static const ShaderProgram Programs[] = {
DONT_CARE_Z,
FLAG_VERSION_1_20
},
#if 0 // not working with Mesa yet
{
"GLSL 1.20 array constructor 3",
NO_VERTEX_SHADER,
"#version 120 \n"
"vec4 [] colors = vec4[2](vec4(0.5, 0.4, 0.3, 0.2), \n"
" vec4(0.7, 0.8, 0.9, 1.0)); \n"
"void main() { \n"
" gl_FragColor = colors[1]; \n"
"} \n",
{ 0.7, 0.8, 0.9, 1.0 },
DONT_CARE_Z,
FLAG_VERSION_1_20
},
{
"GLSL 1.20 array constructor 4",
NO_VERTEX_SHADER,
"#version 120 \n"
"vec4 [2] colors = vec4[](vec4(0.5, 0.4, 0.3, 0.2), \n"
" vec4(0.7, 0.8, 0.9, 1.0)); \n"
"void main() { \n"
" gl_FragColor = colors[1]; \n"
"} \n",
{ 0.7, 0.8, 0.9, 1.0 },
DONT_CARE_Z,
FLAG_VERSION_1_20
},
{
"GLSL 1.20 array constructor 5",
NO_VERTEX_SHADER,
"#version 120 \n"
"vec4 [] colors = vec4[](vec4(0.5, 0.4, 0.3, 0.2), \n"
" vec4(0.7, 0.8, 0.9, 1.0)); \n"
"void main() { \n"
" gl_FragColor = colors[1]; \n"
"} \n",
{ 0.7, 0.8, 0.9, 1.0 },
DONT_CARE_Z,
FLAG_VERSION_1_20
},
{
"GLSL 1.20 array constructor 6",
NO_VERTEX_SHADER,
"#version 120 \n"
"vec4 colors[] = vec4[](vec4(0.5, 0.4, 0.3, 0.2), \n"
" vec4(0.7, 0.8, 0.9, 1.0)); \n"
"void main() { \n"
" gl_FragColor = colors[1]; \n"
"} \n",
{ 0.7, 0.8, 0.9, 1.0 },
DONT_CARE_Z,
FLAG_VERSION_1_20
},
{
"GLSL 1.20 array constructor 7",
NO_VERTEX_SHADER,
"#version 120 \n"
"vec4 colors[2] = vec4[](vec4(0.5, 0.4, 0.3, 0.2), \n"
" vec4(0.7, 0.8, 0.9, 1.0)); \n"
"void main() { \n"
" gl_FragColor = colors[1]; \n"
"} \n",
{ 0.7, 0.8, 0.9, 1.0 },
DONT_CARE_Z,
FLAG_VERSION_1_20
},
{
"GLSL 1.20 array constructor 8",
NO_VERTEX_SHADER,
"#version 120 \n"
"vec4 colors[2] = vec4[2](vec4(0.5, 0.4, 0.3, 0.2), \n"
" vec4(0.7, 0.8, 0.9, 1.0)); \n"
"void main() { \n"
" gl_FragColor = colors[1]; \n"
"} \n",
{ 0.7, 0.8, 0.9, 1.0 },
DONT_CARE_Z,
FLAG_VERSION_1_20
},
#endif
{
"GLSL 1.20 const array constructor 1",
NO_VERTEX_SHADER,
......
......@@ -74,8 +74,7 @@ bool PBOTest::setup(void)
glReadBuffer(GL_FRONT);
// compute error tolerances (may need fine-tuning)
int
bufferBits[5];
int bufferBits[5];
glGetIntegerv(GL_RED_BITS, &bufferBits[0]);
glGetIntegerv(GL_GREEN_BITS, &bufferBits[1]);
......@@ -96,7 +95,7 @@ bool PBOTest::setup(void)
tolerance[4] = 1.0;
// Check if GL_ARB_pixel_buffer_object is supported
if (!strstr((char *) glGetString(GL_EXTENSIONS), "GL_ARB_pixel_buffer_object")) {
if (!GLUtils::haveExtension("GL_ARB_pixel_buffer_object")) {
//printf("GL_ARB_pixel_buffer_object is not supported\n");
usePBO = 0;
return false;
......@@ -315,8 +314,7 @@ bool PBOTest::testDrawPixels(void)
exp[2] = j % 256;
if (i < TEXSIZE && j < TEXSIZE) {
if (equalColors1(&pboPackMem[(j * windowSize + i) * 4], exp)
!= true) {
if (!equalColors1(&pboPackMem[(j * windowSize + i) * 4], exp)) {
REPORT_FAILURE("glDrawPixels failed");
printf(" got (%d, %d) = [%d, %d, %d], ", i, j,
pboPackMem[(j * windowSize + i) * 4],
......@@ -329,8 +327,7 @@ bool PBOTest::testDrawPixels(void)
}
}
else {
if (equalColors1(&pboPackMem[(j * windowSize + i) * 4],
black) != true) {
if (!equalColors1(&pboPackMem[(j * windowSize + i) * 4], black)) {
REPORT_FAILURE("glDrawPixels failed");
printf("(%d, %d) = [%d, %d, %d], ", i, j,
pboPackMem[(j * windowSize + i) * 4],
......@@ -544,8 +541,7 @@ bool PBOTest::testBitmap(void)
else
exp = white;
if (i < TEXSIZE && j < TEXSIZE) {
if (equalColors(&pboPackMem[(j * windowSize + i) * 3], exp)
!= true) {
if (!equalColors(&pboPackMem[(j * windowSize + i) * 3], exp)) {
REPORT_FAILURE("glBitmap failed");
printf(" got (%d, %d) = [%f, %f, %f], ", i, j,
pboPackMem[(j * windowSize + i) * 3],
......@@ -558,9 +554,8 @@ bool PBOTest::testBitmap(void)
}
}
else {
if (equalColors
(&pboPackMem[(j * windowSize + i) * 3],
black) != true) {
if (!equalColors(&pboPackMem[(j * windowSize + i) * 3],
black)) {
REPORT_FAILURE("glBitmap failed");
printf("(%d, %d) = [%f, %f, %f], ", i, j,
pboPackMem[(j * windowSize + i) * 3],
......@@ -719,7 +714,7 @@ bool PBOTest::testTexImage(void)
for (i = 0; i < TEXSIZE * TEXSIZE; i++) {
if (i == 0 && breakCOWTexture && useTexUnpackBuffer) {
GLfloat exp[3] = { 0.8, 0.8, 0.8 };
if (equalColors(&pboMem[i * 3], exp) != true) {
if (!equalColors(&pboMem[i * 3], exp)) {
REPORT_FAILURE("glGetTexImage failed");
printf(" got (%d) = [%f, %f, %f], ", i,
pboMem[i * 3],
......@@ -732,7 +727,7 @@ bool PBOTest::testTexImage(void)
}
else {
GLfloat exp[3] = { 1.0, 1.0, 0.0 };
if (equalColors(&pboMem[i * 3], exp) != true) {
if (!equalColors(&pboMem[i * 3], exp)) {
REPORT_FAILURE("glGetTexImage failed");
printf(" got (%d) = [%f, %f, %f], ", i,
pboMem[i * 3],
......@@ -765,6 +760,7 @@ bool PBOTest::testTexImage(void)
glTexCoord2f(0, 1);
glVertex2f(0, TEXSIZE);
glEnd();
glDisable(GL_TEXTURE_2D);
glReadPixels(0, 0, windowSize, windowSize, GL_RGB, GL_FLOAT,
buf);
......@@ -773,8 +769,7 @@ bool PBOTest::testTexImage(void)
if (i == 0 && j == 0 && breakCOWTexture
&& useTexUnpackBuffer) {
GLfloat exp[3] = { 0.8, 0.8, 0.8 };
if (equalColors(&buf[(j * windowSize + i) * 3], exp)
!= true) {
if (!equalColors(&buf[(j * windowSize + i) * 3], exp)) {
REPORT_FAILURE("glTexImage failed");
printf(" got (%d, %d) = [%f, %f, %f], ", i, j,
buf[(j * windowSize + i) * 3],
......@@ -787,8 +782,7 @@ bool PBOTest::testTexImage(void)
}
}
else if (i < TEXSIZE && j < TEXSIZE) {
if (equalColors(&buf[(j * windowSize + i) * 3], green)
!= true) {
if (!equalColors(&buf[(j * windowSize + i) * 3], green)) {
REPORT_FAILURE("glTexImage failed");
printf(" got (%d, %d) = [%f, %f, %f], ", i, j,
buf[(j * windowSize + i) * 3],
......@@ -801,8 +795,7 @@ bool PBOTest::testTexImage(void)
}
}
else {
if (equalColors(&buf[(j * windowSize + i) * 3], black)
!= true) {
if (!equalColors(&buf[(j * windowSize + i) * 3], black)) {
REPORT_FAILURE("glTexImage failed");
printf("(%d, %d) = [%f, %f, %f], ", i, j,
buf[(j * windowSize + i) * 3],
......@@ -897,7 +890,7 @@ bool PBOTest::testTexSubImage(void)
for (j = 0; j < windowSize; j++) {
for (i = 0; i < windowSize; i++) {
if (i < 10 && j < 10) {
if (equalColors(&buf[(j * windowSize + i) * 3], green) != true) {
if (!equalColors(&buf[(j * windowSize + i) * 3], green)) {
REPORT_FAILURE("glTexSubImage failed");
printf(" got (%d, %d) = [%f, %f, %f], ", i, j,
buf[(j * windowSize + i) * 3],
......@@ -910,7 +903,7 @@ bool PBOTest::testTexSubImage(void)
}
}
else {
if (equalColors(&buf[(j * windowSize + i) * 3], black) != true) {
if (!equalColors(&buf[(j * windowSize + i) * 3], black)) {
REPORT_FAILURE("glTexSubImage failed");
printf("(%d, %d) = [%f, %f, %f], ", i, j,
buf[(j * windowSize + i) * 3],
......@@ -1008,6 +1001,7 @@ bool PBOTest::testPolygonStip(void)
}
glEnable(GL_POLYGON_STIPPLE);
glColor4f(1.0, 1.0, 1.0, 0.0);
glBegin(GL_POLYGON);
glVertex2f(0, 0);
glVertex2f(10, 0);
......@@ -1030,8 +1024,7 @@ bool PBOTest::testPolygonStip(void)
else
exp = white;
if (i < 10 && j < 10) {
if (equalColors(&buf[(j * windowSize + i) * 3], exp) !=
true) {
if (!equalColors(&buf[(j * windowSize + i) * 3], exp)) {
REPORT_FAILURE("glGetPolygonStipple failed");
printf("(%d, %d) = [%f, %f, %f], ", i, j,
buf[(j * windowSize + i) * 3],
......@@ -1042,8 +1035,7 @@ bool PBOTest::testPolygonStip(void)
}
}
else {
if (equalColors(&buf[(j * windowSize + i) * 3], black) !=
true) {
if (!equalColors(&buf[(j * windowSize + i) * 3], black)) {
REPORT_FAILURE("glGetPolygonStipple failed");
printf("(%d, %d) = [%f, %f, %f], ", i, j,
buf[(j * windowSize + i) * 3],
......@@ -1123,11 +1115,12 @@ bool PBOTest::testFunctionality(MultiTestResult & r)
}
enum {
BLACK,
RED,
GREEN,
BLUE,
WHITE };
BLACK,
RED,
GREEN,
BLUE,
WHITE
};
GLfloat colors1[][4] = {
{0.0, 0.0, 0.0, 0.0},
......
......@@ -1441,10 +1441,9 @@ TexCombineTest::runOne(BasicResult& r, Window& w) {
// Test the availability of the DOT3 extenstion
haveDot3 = GLUtils::haveExtensions("GL_EXT_texture_env_dot3");
if (0 == haveDot3)
haveDot3 = GLUtils::haveExtensions("GL_ARB_texture_env_dot3");
haveCrossbar = GLUtils::haveExtensions("GL_ARB_texture_env_crossbar");
haveCrossbar = GLUtils::haveExtensions("GL_ARB_texture_env_crossbar")
&& GLUtils::haveExtensions("GL_ARB_texture_env_combine");
// compute RGB error tolerance
{
......
......@@ -1083,10 +1083,10 @@ VertexProgramTest::testBadProgram(MultiTestResult &result)
};
glVertexPointer(3, GL_FLOAT, 0, vertcoords);
glEnable(GL_VERTEX_ARRAY);
glEnableClientState(GL_VERTEX_ARRAY);
glDrawArrays(GL_POLYGON, 0, 4);
err = glGetError();
glDisable(GL_VERTEX_ARRAY);
glDisableClientState(GL_VERTEX_ARRAY);
if (err != GL_INVALID_OPERATION) {
env->log << "Unexpected OpenGL error state " << (int) err <<
......@@ -1095,7 +1095,7 @@ VertexProgramTest::testBadProgram(MultiTestResult &result)
result.numFailed++;
while (err != 0)
glGetError();
err = glGetError();
} else {
result.numPassed++;
}
......
......@@ -93,7 +93,7 @@ WindowSystem::WindowSystem(Options& o) {
// constraints provided by the user. (This makes it convenient
// to run tests on just a subset of all available configs.)
DrawingSurfaceFilter f(o.visFilter); // may throw an exception!
surfConfigs = f.filter(glxv);
surfConfigs = f.filter(glxv, o.maxVisuals);
} // WindowSystem::WindowSystem
#elif defined(__WIN__)
......@@ -135,7 +135,7 @@ WindowSystem::WindowSystem(Options& o) {
// constraints provided by the user. (This makes it convenient
// to run tests on just a subset of all available configs.)
DrawingSurfaceFilter f(o.visFilter); // may throw an exception!
surfConfigs = f.filter(glpf);
surfConfigs = f.filter(glpf, o.maxVisuals);
}
#elif defined(__BEWIN__)
......@@ -150,7 +150,7 @@ WindowSystem::WindowSystem(Options& o) {
glconfigs.push_back(new DrawingSurfaceConfig());
DrawingSurfaceFilter f(o.visFilter); // may throw an exception!
surfConfigs = f.filter(glconfigs);
surfConfigs = f.filter(glconfigs, o.maxVisuals);
}
......@@ -201,7 +201,7 @@ WindowSystem::WindowSystem(Options& o) {