#922162 mesa: Assertion triggered in texcompress_etc.c: _mesa_texstore_etc2_rgba8_eac from glGenerateMipmap()

#922162#5
Date:
2019-02-12 19:57:15 UTC
From:
To:
Dear Maintainer,

    After updating my bgfx-based renderer throws assertions.

    src/mesa/main/texcompress_etc.c:1130: _mesa_texstore_etc2_rgba8_eac:
Assertion `0' failed.

    from glGenerateMipmap() for any of the following texture formats:
    GL_ETC1_RGB8_OES
    GL_COMPRESSED_RGB8_ETC2
    GL_COMPRESSED_RGBA8_ETC2_EAC
    GL_COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2

    Code roughly, look at (or better execute)
https://github.com/bkaradzic/bgfx/blob/7464fd16ab689a3bd736b6808a3ce9fbbeae3412/src/renderer_gl.cpp#L1461
    ```cpp
    glGenTextures(1, &id);
    glBindTexture(target, id);
    glTexStorage3D(target, ...);
    glCompressedTexImage3D(target, ...);
    glGenerateMipmap(target); /* ASSERT TRIGGERED */
    ```

    [bgfx]: https://github.com/bkaradzic/bgfx

    I guess the simplest way to replicate is to check out and run any of
    the bgfx examples.

    Might this be related to the change of the used assert macro in

https://gitlab.freedesktop.org/mesa/mesa/commit/bfcdb843830bba0190e00e35e3c5c18c4bdb5de1
    (although that is 3 years old)

#922162#10
Date:
2019-10-22 18:05:25 UTC
From:
To:
Dear maintainer,

this bug seems to be fixed after updating mesa to v19.2.1-1.