Lines Matching defs:target
85 static void deleteTexture(deqp::Context& context, glw::GLenum target, glw::GLuint name);
87 static bool isTargetMultilayer(glw::GLenum target);
88 static bool isTargetMultilevel(glw::GLenum target);
89 static bool isTargetMultisampled(glw::GLenum target);
91 static glw::GLuint generateTexture(deqp::Context& context, glw::GLenum target);
103 static void makeTextureComplete(deqp::Context& context, glw::GLenum target, glw::GLuint id, glw::GLint base_level,
106 static glw::GLuint prepareCompressedTex(deqp::Context& context, glw::GLenum target, glw::GLenum internal_format);
108 static glw::GLuint prepareMultisampleTex(deqp::Context& context, glw::GLenum target, glw::GLsizei n_samples);
112 static glw::GLuint prepareTex16x16x6(deqp::Context& context, glw::GLenum target, glw::GLenum internal_format,
115 static void prepareTexture(deqp::Context& context, glw::GLuint name, glw::GLenum target,
120 static glw::GLenum transProxyToRealTarget(glw::GLenum target);
121 static glw::GLenum transRealToBindTarget(glw::GLenum target);
503 * @param target Image target
506 void Utils::deleteTexture(deqp::Context& context, GLenum target, GLuint name)
510 if (GL_RENDERBUFFER == target)
1104 /** Check if target supports multiple layers
1106 * @param target Texture target
1108 * @return true if target is multilayered
1110 bool Utils::isTargetMultilayer(GLenum target)
1114 switch (target)
1131 /** Check if target supports multiple level
1133 * @param target Texture target
1135 * @return true if target supports mipmaps
1137 bool Utils::isTargetMultilevel(GLenum target)
1141 switch (target)
1156 /** Check if target is multisampled
1158 * @param target Texture target
1162 bool Utils::isTargetMultisampled(GLenum target)
1166 switch (target)
1182 * @param target Target of texture
1186 glw::GLuint Utils::generateTexture(deqp::Context& context, GLenum target)
1191 switch (target)
1210 * @param target GLenum representing target of texture that should be created
1215 void Utils::makeTextureComplete(deqp::Context& context, GLenum target, GLuint id, GLint base_level, GLint max_level)
1219 if (GL_RENDERBUFFER == target)
1225 target = transRealToBindTarget(transProxyToRealTarget(target));
1227 gl.bindTexture(target, id);
1231 if (GL_TEXTURE_BUFFER != target)
1233 gl.texParameteri(target, GL_TEXTURE_BASE_LEVEL, base_level);
1236 gl.texParameteri(target, GL_TEXTURE_MAX_LEVEL, max_level);
1243 if (GL_TEXTURE_2D_MULTISAMPLE != target && GL_TEXTURE_2D_MULTISAMPLE_ARRAY != target)
1245 gl.texParameteri(target, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
1246 if (GL_TEXTURE_RECTANGLE != target)
1248 gl.texParameteri(target, GL_TEXTURE_MIN_FILTER, GL_NEAREST_MIPMAP_NEAREST);
1253 gl.texParameteri(target, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
1260 gl.bindTexture(target, 0);
1264 /** Generate and initialize texture for given target
1267 * @param target GLenum representing target of texture that should be created
1272 GLuint Utils::prepareMultisampleTex(deqp::Context& context, GLenum target, GLsizei n_samples)
1285 switch (target)
1288 gl.bindTexture(target, name);
1291 gl.texImage2DMultisample(target, n_samples, internal_format, width, height, GL_FALSE /* fixedsamplelocation */);
1297 gl.bindTexture(target, name);
1300 gl.texImage3DMultisample(target, n_samples, internal_format, width, height, depth,
1311 gl.bindTexture(target, 0);
1317 /** Generate and initialize texture for given target
1348 /** Generate and initialize texture for given target
1351 * @param target GLenum representing target of texture that should be created
1359 GLuint Utils::prepareTex16x16x6(deqp::Context& context, GLenum target, GLenum internal_format, GLenum format,
1369 name = generateTexture(context, target);
1371 prepareTexture(context, name, target, internal_format, format, type, level, width, height, depth, pixels,
1381 * @param target GLenum representing target of texture that should be created
1394 void Utils::prepareTexture(deqp::Context& context, GLuint name, GLenum target, GLenum internal_format, GLenum format,
1405 target = transProxyToRealTarget(target);
1408 switch (target)
1411 gl.bindRenderbuffer(target, name);
1414 gl.renderbufferStorage(target, internal_format, width, height);
1417 gl.bindRenderbuffer(target, 0);
1423 gl.bindTexture(target, name);
1426 gl.texImage1D(target, level, internal_format, width, border, format, type, pixels);
1435 gl.bindTexture(target, name);
1439 gl.texImage2D(target, level, internal_format, width, height, border, format, type, pixels);
1446 gl.bindTexture(target, name);
1449 gl.texImage2DMultisample(target, samples, internal_format, width, height, GL_FALSE /* fixedsamplelocation */);
1456 gl.bindTexture(target, name);
1459 gl.texImage3DMultisample(target, samples, internal_format, width, height, depth,
1469 gl.bindTexture(target, name);
1473 gl.texImage3D(target, level, internal_format, width, height, depth, border, format, type, pixels);
1515 /* Change target to CUBE_MAP, it will be used later to change base and max level */
1516 target = GL_TEXTURE_CUBE_MAP;
1517 gl.bindTexture(target, name);
1545 << ". Target: " << glu::getTextureTargetStr(target)
1551 if (GL_RENDERBUFFER != target)
1554 gl.bindTexture(target, 0);
1561 * @param target Target to be converted
1563 * @return Converted target for proxies, <target> otherwise
1565 GLenum Utils::transProxyToRealTarget(GLenum target)
1567 switch (target)
1570 target = GL_TEXTURE_1D;
1573 target = GL_TEXTURE_1D_ARRAY;
1576 target = GL_TEXTURE_2D;
1579 target = GL_TEXTURE_2D_ARRAY;
1582 target = GL_TEXTURE_2D_MULTISAMPLE;
1585 target = GL_TEXTURE_2D_MULTISAMPLE_ARRAY;
1588 target = GL_TEXTURE_3D;
1591 target = GL_TEXTURE_CUBE_MAP;
1594 target = GL_TEXTURE_CUBE_MAP_ARRAY;
1597 target = GL_TEXTURE_RECTANGLE;
1603 return target;
1608 * @param target Target to be converted
1610 * @return Converted target for cube map faces, <target> otherwise
1612 GLenum Utils::transRealToBindTarget(GLenum target)
1614 switch (target)
1617 target = GL_TEXTURE_CUBE_MAP;
1620 target = GL_TEXTURE_CUBE_MAP;
1623 target = GL_TEXTURE_CUBE_MAP;
1626 target = GL_TEXTURE_CUBE_MAP;
1629 target = GL_TEXTURE_CUBE_MAP;
1632 target = GL_TEXTURE_CUBE_MAP;
1638 return target;
2649 * @param target Target of image
2657 void FunctionalTest::calculateDimmensions(GLenum target, GLuint level, GLuint width, GLuint height, GLuint* out_widths,
2663 const bool is_multi_layer = Utils::isTargetMultilayer(target);
2684 if (GL_TEXTURE_3D == target)
2754 /* Src and rb shares differs only on target */
3624 const GLenum target = s_valid_targets[tgt_id];
3626 if (true == Utils::isTargetMultisampled(target))
3631 const testCase test_case = { target, GL_RGBA32UI, GL_RGBA_INTEGER, GL_UNSIGNED_INT };
3791 /* Src and rb shares differs only on target */
4120 "Test verifies if INVALID_ENUM is generated when invalid target is provided to CopyImageSubData")
4247 << ". Source target: " << glu::getTextureTargetStr(test_case.m_src_target)
4248 << ", destination target: " << glu::getTextureTargetStr(test_case.m_dst_target) << tcu::TestLog::EndMessage;
4293 "Test verifies if INVALID_ENUM is generated when target provided to CopyImageSubData does not match texture")
4300 /* Wrong dst target */
4301 for (GLuint target = 0; target < s_n_valid_targets; ++target)
4306 const GLenum src_target = s_valid_targets[target];
4307 const GLenum tex_target = s_valid_targets[target];
4332 /* Wrong src target */
4333 for (GLuint target = 0; target < s_n_valid_targets; ++target)
4337 const GLenum dst_target = s_valid_targets[target];
4339 const GLenum tex_target = s_valid_targets[target];
4425 << ". Texture target: " << glu::getTextureTargetStr(test_case.m_tex_target)
4426 << ". Source target: " << glu::getTextureTargetStr(test_case.m_src_target)
4427 << ", destination target: " << glu::getTextureTargetStr(test_case.m_dst_target) << tcu::TestLog::EndMessage;
4478 for (GLuint target = 0; target < s_n_valid_targets; ++target)
4480 const GLenum tex_target = s_valid_targets[target];
4573 << ". Texture target: " << glu::getTextureTargetStr(test_case.m_tex_target)
4627 for (GLuint target = 0; target < s_n_valid_targets; ++target)
4629 const GLenum tex_target = s_valid_targets[target];
4644 for (GLuint target = 0; target < s_n_valid_targets; ++target)
4646 const GLenum tex_target = s_valid_targets[target];
4661 for (GLuint target = 0; target < s_n_valid_targets; ++target)
4663 const GLenum tex_target = s_valid_targets[target];
4678 for (GLuint target = 0; target < s_n_valid_targets; ++target)
4680 const GLenum tex_target = s_valid_targets[target];
4695 for (GLuint target = 0; target < s_n_valid_targets; ++target)
4697 const GLenum tex_target = s_valid_targets[target];
4772 << ". Texture target: " << glu::getTextureTargetStr(test_case.m_tex_target)
4945 << ". Source target: " << glu::getTextureTargetStr(test_case.m_src_target)
4947 << ", destination target: " << glu::getTextureTargetStr(test_case.m_dst_target)
4985 for (GLuint target = 0; target < s_n_valid_targets; ++target)
4987 const GLenum tex_target = s_valid_targets[target];
5085 << ". Texture target: " << glu::getTextureTargetStr(test_case.m_tex_target)
5120 "Test verifies if INVALID_VALUE is generated when object & target provided to CopyImageSubData do not match")
5240 << ". Destination target: " << glu::getTextureTargetStr(test_case.m_dst_target)
5242 << ". Source target: " << glu::getTextureTargetStr(test_case.m_dst_target)
5300 for (GLuint target = 0; target < s_n_valid_targets; ++target)
5302 const GLenum tex_target = s_valid_targets[target];
5391 << ". Texture target: " << glu::getTextureTargetStr(test_case.m_tex_target)
5446 for (GLuint target = 0; target < s_n_valid_targets; ++target)
5448 const GLenum tex_target = s_valid_targets[target];
5566 << ". Texture target: " << glu::getTextureTargetStr(test_case.m_tex_target) << ", source: ["