Lines Matching refs:spec
153 static void addTestIterations (gls::DrawTest* test, gls::DrawTestSpec& spec, TestIterationType type) in addTestIterations() argument
157 spec.primitiveCount = 1; in addTestIterations()
158 test->addIteration(spec, "draw count = 1"); in addTestIterations()
160 spec.primitiveCount = 5; in addTestIterations()
161 test->addIteration(spec, "draw count = 5"); in addTestIterations()
163 spec.primitiveCount = 25; in addTestIterations()
164 test->addIteration(spec, "draw count = 25"); in addTestIterations()
168 spec.instanceCount = 1; in addTestIterations()
169 test->addIteration(spec, "instance count = 1"); in addTestIterations()
171 spec.instanceCount = 4; in addTestIterations()
172 test->addIteration(spec, "instance count = 4"); in addTestIterations()
174 spec.instanceCount = 11; in addTestIterations()
175 test->addIteration(spec, "instance count = 11"); in addTestIterations()
181 static void genBasicSpec (gls::DrawTestSpec& spec, gls::DrawTestSpec::DrawMethod method) in genBasicSpec() argument
183 spec.apiType = glu::ApiType::es(3,1); in genBasicSpec()
184 spec.primitive = gls::DrawTestSpec::PRIMITIVE_TRIANGLES; in genBasicSpec()
185 spec.primitiveCount = 5; in genBasicSpec()
186 spec.drawMethod = method; in genBasicSpec()
187 spec.indexType = gls::DrawTestSpec::INDEXTYPE_LAST; in genBasicSpec()
188 spec.indexPointerOffset = 0; in genBasicSpec()
189 spec.indexStorage = gls::DrawTestSpec::STORAGE_LAST; in genBasicSpec()
190 spec.first = 0; in genBasicSpec()
191 spec.indexMin = 0; in genBasicSpec()
192 spec.indexMax = 0; in genBasicSpec()
193 spec.instanceCount = 1; in genBasicSpec()
194 spec.indirectOffset = 0; in genBasicSpec()
196 spec.attribs.resize(2); in genBasicSpec()
198 spec.attribs[0].inputType = gls::DrawTestSpec::INPUTTYPE_FLOAT; in genBasicSpec()
199 spec.attribs[0].outputType = gls::DrawTestSpec::OUTPUTTYPE_VEC2; in genBasicSpec()
200 spec.attribs[0].storage = gls::DrawTestSpec::STORAGE_BUFFER; in genBasicSpec()
201 spec.attribs[0].usage = gls::DrawTestSpec::USAGE_STATIC_DRAW; in genBasicSpec()
202 spec.attribs[0].componentCount = 4; in genBasicSpec()
203 spec.attribs[0].offset = 0; in genBasicSpec()
204 spec.attribs[0].stride = 0; in genBasicSpec()
205 spec.attribs[0].normalize = false; in genBasicSpec()
206 spec.attribs[0].instanceDivisor = 0; in genBasicSpec()
207 spec.attribs[0].useDefaultAttribute = false; in genBasicSpec()
209 spec.attribs[1].inputType = gls::DrawTestSpec::INPUTTYPE_FLOAT; in genBasicSpec()
210 spec.attribs[1].outputType = gls::DrawTestSpec::OUTPUTTYPE_VEC2; in genBasicSpec()
211 spec.attribs[1].storage = gls::DrawTestSpec::STORAGE_BUFFER; in genBasicSpec()
212 spec.attribs[1].usage = gls::DrawTestSpec::USAGE_STATIC_DRAW; in genBasicSpec()
213 spec.attribs[1].componentCount = 2; in genBasicSpec()
214 spec.attribs[1].offset = 0; in genBasicSpec()
215 spec.attribs[1].stride = 0; in genBasicSpec()
216 spec.attribs[1].normalize = false; in genBasicSpec()
217 spec.attribs[1].instanceDivisor = 0; in genBasicSpec()
218 spec.attribs[1].useDefaultAttribute = false; in genBasicSpec()
263 gls::DrawTestSpec spec; in init() local
265 spec.apiType = glu::ApiType::es(3,1); in init()
266 spec.primitive = m_primitive; in init()
267 spec.primitiveCount = 5; in init()
268 spec.drawMethod = m_method; in init()
269 spec.indexType = m_indexType; in init()
270 spec.indexPointerOffset = 0; in init()
271 spec.indexStorage = m_indexStorage; in init()
272 spec.first = 0; in init()
273 spec.indexMin = 0; in init()
274 spec.indexMax = 0; in init()
275 spec.instanceCount = 1; in init()
276 spec.indirectOffset = 0; in init()
278 spec.attribs.resize(1); in init()
280 spec.attribs[0].inputType = gls::DrawTestSpec::INPUTTYPE_FLOAT; in init()
281 spec.attribs[0].outputType = gls::DrawTestSpec::OUTPUTTYPE_VEC2; in init()
282 spec.attribs[0].storage = gls::DrawTestSpec::STORAGE_BUFFER; in init()
283 spec.attribs[0].usage = gls::DrawTestSpec::USAGE_STATIC_DRAW; in init()
284 spec.attribs[0].componentCount = 2; in init()
285 spec.attribs[0].offset = 0; in init()
286 spec.attribs[0].stride = 0; in init()
287 spec.attribs[0].normalize = false; in init()
288 spec.attribs[0].instanceDivisor = 0; in init()
289 spec.attribs[0].useDefaultAttribute = false; in init()
291 addTestIterations(test, spec, TYPE_DRAW_COUNT); in init()
299 gls::DrawTestSpec spec; in init() local
301 spec.apiType = glu::ApiType::es(3,1); in init()
302 spec.primitive = m_primitive; in init()
303 spec.primitiveCount = 5; in init()
304 spec.drawMethod = m_method; in init()
305 spec.indexType = m_indexType; in init()
306 spec.indexPointerOffset = 0; in init()
307 spec.indexStorage = m_indexStorage; in init()
308 spec.first = 0; in init()
309 spec.indexMin = 0; in init()
310 spec.indexMax = 0; in init()
311 spec.instanceCount = 1; in init()
312 spec.indirectOffset = 0; in init()
314 spec.attribs.resize(2); in init()
316 spec.attribs[0].inputType = gls::DrawTestSpec::INPUTTYPE_FLOAT; in init()
317 spec.attribs[0].outputType = gls::DrawTestSpec::OUTPUTTYPE_VEC2; in init()
318 spec.attribs[0].storage = gls::DrawTestSpec::STORAGE_BUFFER; in init()
319 spec.attribs[0].usage = gls::DrawTestSpec::USAGE_STATIC_DRAW; in init()
320 spec.attribs[0].componentCount = 4; in init()
321 spec.attribs[0].offset = 0; in init()
322 spec.attribs[0].stride = 0; in init()
323 spec.attribs[0].normalize = false; in init()
324 spec.attribs[0].instanceDivisor = 0; in init()
325 spec.attribs[0].useDefaultAttribute = false; in init()
327 spec.attribs[1].inputType = gls::DrawTestSpec::INPUTTYPE_FLOAT; in init()
328 spec.attribs[1].outputType = gls::DrawTestSpec::OUTPUTTYPE_VEC2; in init()
329 spec.attribs[1].storage = gls::DrawTestSpec::STORAGE_BUFFER; in init()
330 spec.attribs[1].usage = gls::DrawTestSpec::USAGE_STATIC_DRAW; in init()
331 spec.attribs[1].componentCount = 2; in init()
332 spec.attribs[1].offset = 0; in init()
333 spec.attribs[1].stride = 0; in init()
334 spec.attribs[1].normalize = false; in init()
335 spec.attribs[1].instanceDivisor = 0; in init()
336 spec.attribs[1].useDefaultAttribute = false; in init()
338 addTestIterations(test, spec, TYPE_DRAW_COUNT); in init()
346 gls::DrawTestSpec spec; in init() local
348 spec.apiType = glu::ApiType::es(3,1); in init()
349 spec.primitive = m_primitive; in init()
350 spec.primitiveCount = 5; in init()
351 spec.drawMethod = m_method; in init()
352 spec.indexType = m_indexType; in init()
353 spec.indexPointerOffset = 0; in init()
354 spec.indexStorage = m_indexStorage; in init()
355 spec.first = 0; in init()
356 spec.indexMin = 0; in init()
357 spec.indexMax = 0; in init()
358 spec.instanceCount = 1; in init()
359 spec.indirectOffset = 0; in init()
361 spec.attribs.resize(3); in init()
363 spec.attribs[0].inputType = gls::DrawTestSpec::INPUTTYPE_FLOAT; in init()
364 spec.attribs[0].outputType = gls::DrawTestSpec::OUTPUTTYPE_VEC2; in init()
365 spec.attribs[0].storage = gls::DrawTestSpec::STORAGE_BUFFER; in init()
366 spec.attribs[0].usage = gls::DrawTestSpec::USAGE_STATIC_DRAW; in init()
367 spec.attribs[0].componentCount = 4; in init()
368 spec.attribs[0].offset = 0; in init()
369 spec.attribs[0].stride = 0; in init()
370 spec.attribs[0].normalize = false; in init()
371 spec.attribs[0].instanceDivisor = 0; in init()
372 spec.attribs[0].useDefaultAttribute = false; in init()
375 spec.attribs[1].inputType = gls::DrawTestSpec::INPUTTYPE_FLOAT; in init()
376 spec.attribs[1].outputType = gls::DrawTestSpec::OUTPUTTYPE_VEC2; in init()
377 spec.attribs[1].storage = gls::DrawTestSpec::STORAGE_BUFFER; in init()
378 spec.attribs[1].usage = gls::DrawTestSpec::USAGE_STATIC_DRAW; in init()
379 spec.attribs[1].componentCount = 2; in init()
380 spec.attribs[1].offset = 0; in init()
381 spec.attribs[1].stride = 0; in init()
382 spec.attribs[1].normalize = false; in init()
383 spec.attribs[1].instanceDivisor = 1; in init()
384 spec.attribs[1].useDefaultAttribute = false; in init()
385 spec.attribs[1].additionalPositionAttribute = true; in init()
388 spec.attribs[2].inputType = gls::DrawTestSpec::INPUTTYPE_FLOAT; in init()
389 spec.attribs[2].outputType = gls::DrawTestSpec::OUTPUTTYPE_VEC2; in init()
390 spec.attribs[2].storage = gls::DrawTestSpec::STORAGE_BUFFER; in init()
391 spec.attribs[2].usage = gls::DrawTestSpec::USAGE_STATIC_DRAW; in init()
392 spec.attribs[2].componentCount = 3; in init()
393 spec.attribs[2].offset = 0; in init()
394 spec.attribs[2].stride = 0; in init()
395 spec.attribs[2].normalize = false; in init()
396 spec.attribs[2].instanceDivisor = 1; in init()
397 spec.attribs[2].useDefaultAttribute = false; in init()
399 addTestIterations(test, spec, TYPE_INSTANCE_COUNT); in init()
407 gls::DrawTestSpec spec; in init() local
409 spec.apiType = glu::ApiType::es(3,1); in init()
410 spec.primitive = m_primitive; in init()
411 spec.primitiveCount = 5; in init()
412 spec.drawMethod = m_method; in init()
413 spec.indexType = m_indexType; in init()
414 spec.indexPointerOffset = 0; in init()
415 spec.indexStorage = m_indexStorage; in init()
416 spec.first = 0; in init()
417 spec.indexMin = 0; in init()
418 spec.indexMax = 0; in init()
419 spec.instanceCount = 1; in init()
420 spec.indirectOffset = 0; in init()
422 spec.attribs.resize(2); in init()
424 spec.attribs[0].inputType = gls::DrawTestSpec::INPUTTYPE_FLOAT; in init()
425 spec.attribs[0].outputType = gls::DrawTestSpec::OUTPUTTYPE_VEC2; in init()
426 spec.attribs[0].storage = gls::DrawTestSpec::STORAGE_BUFFER; in init()
427 spec.attribs[0].usage = gls::DrawTestSpec::USAGE_STATIC_DRAW; in init()
428 spec.attribs[0].componentCount = 2; in init()
429 spec.attribs[0].offset = 0; in init()
430 spec.attribs[0].stride = 0; in init()
431 spec.attribs[0].normalize = false; in init()
432 spec.attribs[0].instanceDivisor = 0; in init()
433 spec.attribs[0].useDefaultAttribute = false; in init()
452 spec.attribs[1].inputType = iopairs[ioNdx].input; in init()
453 spec.attribs[1].outputType = iopairs[ioNdx].output; in init()
454 spec.attribs[1].storage = gls::DrawTestSpec::STORAGE_BUFFER; in init()
455 spec.attribs[1].usage = gls::DrawTestSpec::USAGE_STATIC_DRAW; in init()
456 spec.attribs[1].componentCount = iopairs[ioNdx].componentCount; in init()
457 spec.attribs[1].offset = 0; in init()
458 spec.attribs[1].stride = 0; in init()
459 spec.attribs[1].normalize = false; in init()
460 spec.attribs[1].instanceDivisor = 0; in init()
461 spec.attribs[1].useDefaultAttribute = true; in init()
463 test->addIteration(spec, desc.c_str()); in init()
507 gls::DrawTestSpec spec; in init() local
508 genBasicSpec(spec, m_method); in init()
510 spec.indexStorage = gls::DrawTestSpec::STORAGE_BUFFER; in init()
520 spec.indexType = indexTest.type; in init()
525 spec.indexPointerOffset = indexTest.offsets[iterationNdx]; in init()
526 test->addIteration(spec, iterationDesc.c_str()); in init()
574 gls::DrawTestSpec spec; in init() local
575 genBasicSpec(spec, m_method); in init()
577 spec.indexStorage = gls::DrawTestSpec::STORAGE_BUFFER; in init()
587 spec.indexType = indexTest.type; in init()
592 spec.baseVertex = indexTest.baseVertex[iterationNdx]; in init()
593 test->addIteration(spec, iterationDesc.c_str()); in init()
629 gls::DrawTestSpec spec; in init() local
630 genBasicSpec(spec, m_method); in init()
638 spec.first = firsts[firstNdx]; in init()
640 addTestIterations(test, spec, TYPE_DRAW_COUNT); in init()
2148 gls::DrawTestSpec spec; in init() local
2150 spec.apiType = glu::ApiType::es(3,1); in init()
2151 …spec.primitive = random.chooseWeighted<gls::DrawTestSpec::Primitive> (DE_ARRAY_BEGIN(primitives… in init()
2152 …spec.primitiveCount = random.chooseWeighted<int, const int*, const float*> (DE_ARRAY_BEGIN(primi… in init()
2153 …spec.drawMethod = random.chooseWeighted<gls::DrawTestSpec::DrawMethod> (DE_ARRAY_BEGIN(drawMeth… in init()
2155 if (spec.drawMethod == gls::DrawTestSpec::DRAWMETHOD_DRAWARRAYS_INDIRECT) in init()
2157 else if (spec.drawMethod == gls::DrawTestSpec::DRAWMETHOD_DRAWELEMENTS_INDIRECT) in init()
2165 …spec.indexType = random.chooseWeighted<gls::DrawTestSpec::IndexType> (DE_ARRAY_BEGIN(indexTypes… in init()
2166 …spec.indexPointerOffset = random.chooseWeighted<int, const int*, const float*> (DE_ARRAY_BEGIN(in… in init()
2167 spec.indexStorage = gls::DrawTestSpec::STORAGE_BUFFER; in init()
2168 …spec.first = random.chooseWeighted<int, const int*, const float*> (DE_ARRAY_BEGIN(firsts), D… in init()
2169 …spec.indexMin = random.chooseWeighted<int, const int*, const float*> (DE_ARRAY_BEGIN(indexMins)… in init()
2170 …spec.indexMax = random.chooseWeighted<int, const int*, const float*> (DE_ARRAY_BEGIN(indexMaxs)… in init()
2171 …spec.instanceCount = random.chooseWeighted<int, const int*, const float*> (DE_ARRAY_BEGIN(instan… in init()
2172 …spec.indirectOffset = random.chooseWeighted<int, const int*, const float*> (DE_ARRAY_BEGIN(indir… in init()
2173 …spec.baseVertex = random.chooseWeighted<int, const int*, const float*> (DE_ARRAY_BEGIN(baseVert… in init()
2176 if (!spec.valid()) in init()
2196 valid = attribSpec.valid(spec.apiType); in init()
2205 spec.attribs.push_back(attribSpec); in init()
2211 if (spec.primitive != gls::DrawTestSpec::PRIMITIVE_POINTS) in init()
2212 spec.attribs[0].instanceDivisor = 0; in init()
2217 …if (spec.drawMethod == gls::DrawTestSpec::DRAWMETHOD_DRAWELEMENTS_RANGED && spec.indexMin == spec.… in init()
2219 if (spec.attribs[0].useDefaultAttribute && spec.primitive != gls::DrawTestSpec::PRIMITIVE_POINTS) in init()
2223 …if (spec.primitive == gls::DrawTestSpec::PRIMITIVE_TRIANGLES || spec.primitive == gls::DrawTestSpe… in init()
2225 if (spec.attribs[0].componentCount == 1) in init()
2227 …if (spec.attribs[0].outputType == gls::DrawTestSpec::OUTPUTTYPE_FLOAT || spec.attribs[0].outputTyp… in init()
2229 …if (spec.drawMethod == gls::DrawTestSpec::DRAWMETHOD_DRAWELEMENTS_RANGED && (spec.indexMax - spec.… in init()
2236 deUint32 hash = spec.hash(); in init()
2238 hash = (hash << 2) ^ (deUint32)spec.attribs[attrNdx].hash(); in init()
2243 if (spec.isCompatibilityTest() != gls::DrawTestSpec::COMPATIBILITY_UNALIGNED_OFFSET && in init()
2244 spec.isCompatibilityTest() != gls::DrawTestSpec::COMPATIBILITY_UNALIGNED_STRIDE) in init()
2245 …s::DrawTest(m_testCtx, m_context.getRenderContext(), spec, de::toString(insertedCount).c_str(), sp… in init()