http://bugs.winehq.org/show_bug.cgi?id=27798
Summary: GTA3 & GTAVC rendering is messed up Product: Wine Version: 1.3.23 Platform: x86 OS/Version: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: directx-d3d AssignedTo: wine-bugs@winehq.org ReportedBy: b7.10110111@gmail.com
See http://i.imgur.com/EigrV.png Works correctly in 1.3.22, appears in 1.3.23, remains in 1.3.24.
Reproducible on my intel (EEE PC 901) video: Intel Corporation Mobile 945GME Express Integrated Graphics Controller (rev 03) , but NOT on nvidia gtx460.
Will try to do regression testing, but... well, intel Atom...
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #1 from Ruslan b7.10110111@gmail.com 2011-07-15 17:56:57 CDT --- Also, performance has significantly degraded on machine where this bug reproduces.
http://bugs.winehq.org/show_bug.cgi?id=27798
Wylda wylda@volny.cz changed:
What |Removed |Added ---------------------------------------------------------------------------- Keywords| |regression CC| |wylda@volny.cz
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #2 from Wylda wylda@volny.cz 2011-07-16 00:31:42 CDT ---
I tried this, but can't reproduce such regression in wine-1.3.24-174-g4b4dd30. There are some smudgy colors, but these shows up since 1.1.10. Tried many different wine versions in between. * wine-1.3.24-174-g4b4dd30 * OpenGL renderer string: GeForce GT 240/PCI/SSE2 * OpenGL version string: 3.3.0 NVIDIA 275.09.07 * OpenGL shading language version string: 3.30 NVIDIA via Cg compiler * Debian Squeeze 32bit
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #3 from Ruslan b7.10110111@gmail.com 2011-07-16 05:52:56 CDT --- Wylda, yes, as i said, the bug doesn't reporoduce on nvidia video cards.
So, now results of regression testing:
dafd31861ae6e86745ee61de2674528845af983b is the first bad commit commit dafd31861ae6e86745ee61de2674528845af983b Author: Stefan Dösinger stefan@codeweavers.com Date: Sat Jun 11 16:18:45 2011 +0200
wined3d: Use GL_ARB_draw_elements_base_vertex if available.
:040000 040000 8cc4276ab2fb1b2e1adb6fd4f3a496e9b2fc983b fe7a9b6f9341e91a649678019620a17d5209be18 M dlls
I've tried adding GL_ARB_draw_elements_base_vertex to DisabledExtensions string, it didn't seem to work. Seems wine doesn't check list of available extensions to determine if extension is available. But, reverting this commit did make things work, so the result looks reliable.
Just in case, maybe this is an intel video bug: client glx vendor string: Mesa Project and SGI OpenGL renderer string: Mesa DRI Intel(R) 945GME GEM 20091221 2009Q4 x86/MMX/SSE2 OpenGL version string: 1.4 Mesa 7.7.1
Still, if this commit gets fixed in for rendering, but not for performance, i'd like to be able to disable GL_ARB_draw_elements_base_vertex usage.
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #4 from Ruslan b7.10110111@gmail.com 2011-07-16 06:59:02 CDT --- Just tried using SW rendering, the problem remains. Disabling the extension on a lower level allows to work around this bug: MESA_EXTENSION_OVERRIDE="-GL_ARB_draw_elements_base_vertex" wine gta-vc.exe
Another indication of this bug being present: http://i.imgur.com/6JFEw.png
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #5 from Henri Verbeet hverbeet@gmail.com 2011-07-16 07:56:47 CDT --- (In reply to comment #3)
OpenGL version string: 1.4 Mesa 7.7.1
That version of Mesa is over a year old, please try with a more recent version like (soon to be released) 7.11 or current git.
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #6 from Ruslan b7.10110111@gmail.com 2011-07-16 08:32:12 CDT --- (In reply to comment #5)
(In reply to comment #3)
OpenGL version string: 1.4 Mesa 7.7.1
That version of Mesa is over a year old, please try with a more recent version like (soon to be released) 7.11 or current git.
Newer mesa (7.10.2-ubuntu) is even more buggy (almost no textures are applied, for example), but still, this bug is also visible - the same distortion of vertices and performance degradation.
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #7 from Ruslan b7.10110111@gmail.com 2011-07-16 09:50:21 CDT --- In fact those of you who have nvidia, can reproduce it using Mesa SW renderer (e.g. starting Xorg with nv or vesa driver (or nouveau, but i haven't been able to check it yet))
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #8 from Ruslan b7.10110111@gmail.com 2011-07-19 04:11:59 CDT --- OK, just tested with Mesa 7.11-devel from Ubuntu unstable. The same bug appears. Also, it is reproducible with nouveau, though to a lesser extent.
http://bugs.winehq.org/show_bug.cgi?id=27798
Henri Verbeet hverbeet@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Regression SHA1| |dafd31861ae6e86745ee61de267 | |4528845af983b
http://bugs.winehq.org/show_bug.cgi?id=27798
Bruni earns.61@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |earns.61@gmail.com
--- Comment #9 from Bruni earns.61@gmail.com 2011-08-23 07:47:32 CDT --- @Ruslan Why not to CC Stefan? Perhaps he doesn't even know about the bug.
http://bugs.winehq.org/show_bug.cgi?id=27798
Ruslan b7.10110111@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |stefan@codeweavers.com
--- Comment #10 from Ruslan b7.10110111@gmail.com 2011-08-23 07:49:33 CDT --- @Bruni Hmm, you're right :)
http://bugs.winehq.org/show_bug.cgi?id=27798
Stefan Dösinger stefandoesinger@gmx.at changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |stefandoesinger@gmx.at
--- Comment #11 from Stefan Dösinger stefandoesinger@gmx.at 2011-08-23 08:03:30 CDT --- Nope, I wasn't aware of this bug. Looks like I should get the Software on the systems with Mesa-supported GPUs up to date...
http://bugs.winehq.org/show_bug.cgi?id=27798
Benjamin Hodgetts ben@xnode.org changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |ben@xnode.org
--- Comment #12 from Benjamin Hodgetts ben@xnode.org 2011-08-24 05:50:11 CDT --- For the record, In GTA3 I'm not getting this issue on my laptop with either the nVidia card (GT540M) or the Intel card (HD3000 Sandybridge) so it isn't globally affecting all Intel/Mesa drivers.
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #13 from Stefan Dösinger stefandoesinger@gmx.at 2011-08-24 16:56:38 CDT --- I have r300g from Mesa git set up on one of my machines now, and I am downloading GTA 3 from Steam. In the meantime I tested Trackmania Nations(http://trackmaniaforever.com/nations/), which also uses the base vertex index. Can those who see the bug in GTA give trackmania a try? It would provide another data point about the bug.
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #14 from Stefan Dösinger stefandoesinger@gmx.at 2011-08-24 17:26:01 CDT --- The gta3 download finished, and I can confirm that the game doesn't work properly. Instead of corrupted graphics I get a crash right after beginning a new game. Prior to the crash the driver complains that it cannot allocate a buffer:
radeon: Failed to allocate a buffer: radeon: size : -81920 bytes radeon: alignment : 16 bytes radeon: domains : 2
This error appears right before the crash. I'll attach the backtrace as an attachment.
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #15 from Stefan Dösinger stefandoesinger@gmx.at 2011-08-24 17:34:22 CDT --- Created an attachment (id=36095) --> (http://bugs.winehq.org/attachment.cgi?id=36095) Crash backtrace with mesa git
This is the crash I get right before entering the game. The crash goes away if I disable GL_ARB_draw_elements_base_vertex. The "Failed to allocate a buffer" error message goes away if I disable VBOs but keep GL_ARB_draw_elements_base_vertex. Without VBOs the crash still occurs, but with a different backtrace.
The game might be setting an out of range base vertex index value and pass indices that put the effective indices into a valid range again.
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #16 from Stefan Dösinger stefandoesinger@gmx.at 2011-08-24 18:10:00 CDT --- With a glut test case I spotted a difference between Mesa and Nvidia binary regarding handling of negative indices(or actually integer overflows when adding index + base vertex index), but I doubt that this affects GTA 3.
As far as I can see the app doesn't do anything crazy. In the draw that crashes here the base vertex index is 326, the indices from the buffer are between 0 and 123. I see no obvious way for the driver to screw up here.
Assuming my crash following the failure to allocate a buffer is the same issue as your incorrect drawing I think the only way to figure this out is to dive into the Mesa code to see what is going on.
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #17 from Ruslan b7.10110111@gmail.com 2011-08-24 23:42:28 CDT --- (In reply to comment #13)
I have r300g from Mesa git set up on one of my machines now, and I am downloading GTA 3 from Steam. In the meantime I tested Trackmania Nations(http://trackmaniaforever.com/nations/), which also uses the base vertex index. Can those who see the bug in GTA give trackmania a try? It would provide another data point about the bug.
Just tried trackmania, it doesn't seem to be affected by the bug.
http://bugs.winehq.org/show_bug.cgi?id=27798
Stefan Dösinger stefan@codeweavers.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |j.suarez.agapito@gmail.com
--- Comment #18 from Stefan Dösinger stefan@codeweavers.com 2011-10-15 09:00:54 CDT --- *** Bug 27609 has been marked as a duplicate of this bug. ***
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #19 from Stefan Dösinger stefan@codeweavers.com 2012-02-12 11:02:00 CST --- I cannot reproduce this bug any longer on r300g with Mesa git. The game is working fine(except the broken intro video) without disabling any extensions. Can you retest the game with your card(s) and report the result?
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #20 from Ruslan b7.10110111@gmail.com 2012-02-13 13:43:51 CST --- (In reply to comment #19) I can't easily test mesa git (because of too slow CPU to compile), but with Mesa 7.11-0ubuntu3 and wine 1.4-rc2 (from ubuntu ppa) the bug is still present.
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #21 from Stefan Dösinger stefan@codeweavers.com 2012-02-14 04:12:35 CST --- Yeah, I'm not surprised that Mesa 7.11 still has the bug - with that version I saw the bug on r300g too.
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #22 from Ruslan b7.10110111@gmail.com 2012-04-08 07:27:15 CDT --- This bug is still present on Ubuntu Precise (amd64) with libgl1-mesa-glx 8.0.2-0ubuntu3 and wine-1.4 from ubuntu-wine ppa, so Mesa 8.0 doesn't fix this.
http://bugs.winehq.org/show_bug.cgi?id=27798
joaopa jeremielapuree@yahoo.fr changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |jeremielapuree@yahoo.fr
--- Comment #23 from joaopa jeremielapuree@yahoo.fr 2012-06-02 17:03:12 CDT --- INVALID. Intel driver bug.
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #24 from Ruslan b7.10110111@gmail.com 2012-08-18 14:12:04 CDT --- Still present in wine-1.5.10 and Mesa 8.0.2, tested on i915 video.
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #25 from jack.weirdy@googlemail.com 2012-09-06 10:39:07 CDT --- Created attachment 41591 --> http://bugs.winehq.org/attachment.cgi?id=41591 Image showing rendering issues
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #26 from jack.weirdy@googlemail.com 2012-09-06 10:40:22 CDT --- The issue with the main menu can be solved by enabling S3TC support;
Install the DriConf utility (Available in the software center in Ubuntu), install it, and in the Image Quality tab check the box for S3TC support.
I am still struggling with poor graphics rendering in-game; as you can in the attachment I made a minute ago.
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #27 from Ruslan b7.10110111@gmail.com 2012-09-06 10:47:24 CDT --- (In reply to comment #26)
I am still struggling with poor graphics rendering in-game; as you can in the attachment I made a minute ago.
Workaround from comment 4 still works.
http://bugs.winehq.org/show_bug.cgi?id=27798
Brandon Corujo haku08879@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |haku08879@gmail.com
http://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #28 from Stefan Dösinger stefan@codeweavers.com 2013-01-06 15:02:17 CST --- I retested this bug with various mesa drivers:
* i965 is fixed by Mesa git(Mesa 9.0.1 is still affected) * r200 does not support GL_ARB_base_vertex_index. * r300g works. See comment 19. * r600g works. Not sure if it was ever affected by this bug.
I don't have the necessary hardware to test i915 and i915g, and I don't have Nouveau set up. If someone confirms that i915 is fixed, or files a Mesa bug if it is still broken, this bug can be closed.
http://bugs.winehq.org/show_bug.cgi?id=27798
Ruslan b7.10110111@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |RESOLVED Resolution| |INVALID
--- Comment #29 from Ruslan b7.10110111@gmail.com 2013-01-07 03:53:15 CST --- (In reply to comment #28) OK, I don't reproduce artifacts on i915 with Mesa 9.0. Still, performance is slower than with extension disabled, but I guess it's still a bug in Mesa. So I close this bug as invalid.
http://bugs.winehq.org/show_bug.cgi?id=27798
Austin English austinenglish@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Resolution|INVALID |UPSTREAM
--- Comment #30 from Austin English austinenglish@gmail.com 2013-01-08 16:59:07 CST --- (In reply to comment #29)
(In reply to comment #28) OK, I don't reproduce artifacts on i915 with Mesa 9.0. Still, performance is slower than with extension disabled, but I guess it's still a bug in Mesa. So I close this bug as invalid.
UPSTREAM
http://bugs.winehq.org/show_bug.cgi?id=27798
Henri Verbeet hverbeet@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #31 from Henri Verbeet hverbeet@gmail.com 2013-01-24 05:39:45 CST --- Closing UPSTREAM.
https://bugs.winehq.org/show_bug.cgi?id=27798
--- Comment #32 from Ruslan Kabatsayev b7.10110111@gmail.com --- For users to be informed, this upstream bug has now been reported to Mesa (after so many years it's still not fixed there): https://bugs.freedesktop.org/show_bug.cgi?id=97351
This should affect all Mesa-driven GPUs with software T&L (but swrast isn't affected for some reason). Might also reproduce with RADEON_NO_TCL environment variable set for radeon, r200, and r300g, but I have no ATI/AMD GPUs to check.