Browse Source

Text,TextureTools: more SwiftShader XFAILs.

Do I look like I want to deal with broken software on a Sunday? Exactly.
pull/674/head
Vladimír Vondruš 1 year ago
parent
commit
c848b65768
  1. 18
      src/Magnum/Text/Test/DistanceFieldGlyphCacheGLTest.cpp
  2. 4
      src/Magnum/TextureTools/Test/DistanceFieldGLTest.cpp

18
src/Magnum/Text/Test/DistanceFieldGlyphCacheGLTest.cpp

@ -545,11 +545,17 @@ void DistanceFieldGlyphCacheGLTest::setImageArray() {
/* The format may be three-component, consider just the first channel */
Containers::StridedArrayView3D<const char> pixels = actual.pixels();
{
#ifdef MAGNUM_TARGET_GLES
CORRADE_EXPECT_FAIL_IF(data.sourceOffset.z() != 0 && GL::Context::current().detectedDriver() >= GL::Context::DetectedDriver::SwiftShader,
"SwiftShader is trash and doesn't implement reading from non-zero array layers.");
#endif
CORRADE_COMPARE_WITH((Containers::arrayCast<2, const UnsignedByte>(pixels.prefix({pixels.size()[0], pixels.size()[1], 1})).exceptPrefix(data.offset)),
Utility::Path::join(TEXTURETOOLS_DISTANCEFIELDGLTEST_DIR, "output.tga"),
/* Same threshold as in TextureTools DistanceFieldGLTest */
(DebugTools::CompareImageToFile{_manager, 1.0f, 0.178f}));
}
}
#endif
void DistanceFieldGlyphCacheGLTest::setImageEdgeClamp() {
@ -603,9 +609,15 @@ void DistanceFieldGlyphCacheGLTest::setImageEdgeClamp() {
/* On the left side the pixels should be completely zero, without the right
side leaking for example due to accidental repeat clamp */
{
#if defined(MAGNUM_TARGET_GLES) && !defined(MAGNUM_TARGET_GLES2)
CORRADE_EXPECT_FAIL_IF(GL::Context::current().detectedDriver() >= GL::Context::DetectedDriver::SwiftShader,
"SwiftShader is trash and wraps around out-of-bounds texelFetch().");
#endif
CORRADE_COMPARE(dst[0][0], '\x00');
CORRADE_COMPARE(dst[1][0], '\x00');
}
}
#ifndef MAGNUM_TARGET_GLES2
void DistanceFieldGlyphCacheGLTest::setImageEdgeClampArray() {
@ -652,9 +664,15 @@ void DistanceFieldGlyphCacheGLTest::setImageEdgeClampArray() {
/* On the left side the pixels should be completely zero, without the right
side leaking for example due to accidental repeat clamp */
{
#ifdef MAGNUM_TARGET_GLES
CORRADE_EXPECT_FAIL_IF(GL::Context::current().detectedDriver() >= GL::Context::DetectedDriver::SwiftShader,
"SwiftShader is trash and wraps around out-of-bounds texelFetch().");
#endif
CORRADE_COMPARE(dst[0][0], '\x00');
CORRADE_COMPARE(dst[1][0], '\x00');
}
}
#endif
const UnsignedByte InputData[]{

4
src/Magnum/TextureTools/Test/DistanceFieldGLTest.cpp

@ -412,6 +412,10 @@ void DistanceFieldGLTest::run() {
else
pixels = Containers::arrayCast<2, UnsignedByte>(pixels3);
#ifdef MAGNUM_TARGET_GLES
CORRADE_EXPECT_FAIL_IF(data.layer != 0 && GL::Context::current().detectedDriver() >= GL::Context::DetectedDriver::SwiftShader,
"SwiftShader is trash and doesn't implement reading from non-zero array layers.");
#endif
CORRADE_COMPARE_WITH(
pixels,
Utility::Path::join(_testDir, "output.tga"),

Loading…
Cancel
Save