https://bugs.freedesktop.org/show_bug.cgi?id=89068
Bug ID: 89068 Summary: glTexImage2D regression by texstore_rgba switch to _mesa_format_convert Product: Mesa Version: git Hardware: Other OS: All Status: NEW Severity: normal Priority: medium Component: Mesa core Assignee: mesa-dev@lists.freedesktop.org Reporter: brad.k...@kitware.com QA Contact: mesa-dev@lists.freedesktop.org VTK's nightly testing regressed due to a mesa update that bisects to: commit 8ec6534b266549cdc2798e2523bf6753924f6cde Author: Iago Toral Quiroga <ito...@igalia.com> Date: Wed Oct 15 13:42:11 2014 +0200 mesa: Use _mesa_format_convert to implement texstore_rgba. Notice that _mesa_format_convert does not handle byte-swapping scenarios, GL_COLOR_INDEX or MESA_FORMAT_YCBCR(_REV), so these must be handled separately. Also, remove all the code that goes unused after using _mesa_format_convert. Reviewed-by: Jason Ekstrand <jason.ekstr...@intel.com> The call in question from VTK is: glTexImage2D( GL_TEXTURE_2D, 0, GL_RGBA8, imageMemorySize[0], imageMemorySize[1], 0, GL_RGBA, GL_UNSIGNED_SHORT, static_cast<unsigned short *>(image) ); Unfortunately I do not have a deep understanding of the relevant code in VTK or Mesa. I will attach example test outputs from before and after the change. Somehow the background color tints the foreground image. In texstore_rgba, the code path taken prior to this change was: } else if (_mesa_get_format_max_bits(dstFormat) <= 8 && !_mesa_is_format_signed(dstFormat)) { return store_ubyte_texture(ctx, dims, baseInternalFormat, dstFormat, dstRowStride, dstSlices, srcWidth, srcHeight, srcDepth, srcFormat, srcType, srcAddr, srcPacking); and later in _mesa_pack_ubyte_rgba_rect: if (srcRowStride == width * 4 * sizeof(GLubyte) && dstRowStride == _mesa_format_row_stride(format, width)) { /* do whole image at once */ _mesa_pack_ubyte_rgba_row(format, width * height, (const GLubyte (*)[4]) src, dst); } After the change, _mesa_format_convert is called but none of the coe paths invoking _mesa_pack_ubyte_rgba_row is taken. Instead the path using compute_src2dst_component_mapping is taken and the result is different. -- You are receiving this mail because: You are the QA Contact for the bug. You are the assignee for the bug.
_______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev