[Bug 27584] New: MFC fillrect draws differently under wine
http://bugs.winehq.org/show_bug.cgi?id=27584 Summary: MFC fillrect draws differently under wine Product: Wine Version: 1.3.21 Platform: x86 OS/Version: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: gdi32 AssignedTo: wine-bugs(a)winehq.org ReportedBy: bailey937(a)yahoo.com Created an attachment (id=35259) --> (http://bugs.winehq.org/attachment.cgi?id=35259) sample program for reproducing FillRect bug I have a program that uses CPaintDC.FillRect() to draw histogram samples. It draws one-pixel wide vertical rectangles. Under wine, the bottom-most pixel is not drawn. I'm attaching a sample program. Under Windows7 (have 64bit pro), the red line is touching the black baseline and the black line on the right is touching the baseline also. When I run the program under wine, both the red vertical line on the left and the black vertical line on the right are floating one pixel above the baseline. I tried both 32bit Ubuntu 11.04 (wine 1.2.2) on a netbook and also Fedora 15 64bit (wine 1.3.21) under Virtualbox on my Windows machine. Both have the same problem. The relevant code for the test case is in CChildView::OnPaint() in ChildView.cpp -- Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email Do not reply to this email, post in Bugzilla using the above URL to reply. ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=27584 --- Comment #1 from bailey937(a)yahoo.com 2011-06-24 06:46:17 CDT --- The sample program was made in VC2005 standard -- Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email Do not reply to this email, post in Bugzilla using the above URL to reply. ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=27584 --- Comment #2 from Dan Kegel <dank(a)kegel.com> 2011-06-24 10:41:50 CDT --- Created an attachment (id=35261) --> (http://bugs.winehq.org/attachment.cgi?id=35261) testcase translated into plain C We generally like C examples without MFC, so I converted your example, see attachment. -- Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email Do not reply to this email, post in Bugzilla using the above URL to reply. ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=27584 Austin English <austinenglish(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |download, testcase -- Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email Do not reply to this email, post in Bugzilla using the above URL to reply. ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=27584 --- Comment #3 from bailey937(a)yahoo.com 2011-06-25 06:38:22 CDT --- Thank you for translating it. With the MS compiler, you need to move the declaration "int i = 0;" in onPaintBroken() up (it doesn't like variables being declared in the middle of a function in a .c file). I built your translated example, and it reproduces the bug just like my original sample. Thanks again. -- Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email Do not reply to this email, post in Bugzilla using the above URL to reply. ------- You are receiving this mail because: ------- You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=27584 --- Comment #4 from Bruno Jesus <00cpxxx(a)gmail.com> --- Created attachment 47424 --> https://bugs.winehq.org/attachment.cgi?id=47424 compiled testcase -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=27584 --- Comment #5 from Bruno Jesus <00cpxxx(a)gmail.com> --- Created attachment 47425 --> https://bugs.winehq.org/attachment.cgi?id=47425 XP screenshot -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=27584 Bruno Jesus <00cpxxx(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Ever confirmed|0 |1 --- Comment #6 from Bruno Jesus <00cpxxx(a)gmail.com> --- Still in wine 1.7.11. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=27584 Nikolay Sivov <bunglehead(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|MFC fillrect draws |FillRect() draws |differently under wine |differently under wine --- Comment #7 from Nikolay Sivov <bunglehead(a)gmail.com> --- This happens with 1.8-rc2 as well. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=27584 Thomas Faller <tfaller1(a)gmx.de> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |tfaller1(a)gmx.de --- Comment #8 from Thomas Faller <tfaller1(a)gmx.de> --- There is no pixel missing. The position of the baseline is wrong because bottom and top are swapped:
From the exampel source: ... void onPaintBroken(HDC hdc) ... r.bottom = 115+110; r.top = 115+110 + 1; ...
Windows does not care about this, wine does. All is correct if I swap bottom and top. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=27584 --- Comment #9 from Dmitry Timoshkov <dmitry(a)baikal.ru> --- Attached compiled test case matches the attached XP screenshot under wine-1.9.10 for me, please retest. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=27584 --- Comment #10 from Nikolay Sivov <bunglehead(a)gmail.com> --- It's not fixed in 1.9.16. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=27584 joaopa <jeremielapuree(a)yahoo.fr> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jeremielapuree(a)yahoo.fr --- Comment #11 from joaopa <jeremielapuree(a)yahoo.fr> --- Created attachment 67420 --> https://bugs.winehq.org/attachment.cgi?id=67420 screenshot showing the bug in Wine Bug still occurs with wine-5.10. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=27584 Damjan Jovanovic <damjan.jov(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |damjan.jov(a)gmail.com --- Comment #12 from Damjan Jovanovic <damjan.jov(a)gmail.com> --- There is a real bug here. FillRect() calls PatBlt(), passing it a negative width/height in the case of this app, and PatBlt() draws rectangles with negative width/height shifted 1 pixel too far right/down: Windows (0,0) +------+ |+-----++ || || || || ++-----+| +------+ Wine Patch with test sent: https://source.winehq.org/patches/data/195952 The testcase draws correctly with this patch. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=27584 KRosUser <kyle.kcsoftwares(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |kyle.kcsoftwares(a)gmail.com --- Comment #13 from KRosUser <kyle.kcsoftwares(a)gmail.com> --- Any recent test in Wine 10.10 ? -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=27584 --- Comment #14 from joaopa <jeremielapuree(a)yahoo.fr> --- You can test by yourself. Compiled Test is available. And yes it still occurs with wine-10.9. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=27584 Ken Sharp <imwellcushtymelike(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |patch, source -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
participants (2)
-
wine-bugs@winehq.org -
WineHQ Bugzilla