Closed rebb closed 1 year ago
Thanks for the report. It looks like an extra line is getting copied here for some reason. I will look at this in a little while.
Thank you :)
I forgot to mention the INI settings used, here they are.
[Compatibility]
Dd7to9=1
[d3d9]
EnableWindowMode=1
The problem also shows in fullscreen mode though.
Looks like the fix is very simple. I noticed it only happened on sprites that "looked the other way". The code in CopySurface inverts the pixel read for mirrored sprites, but is apparently off-by-one.
Changing the instances of
IsMirrorLeftRight ? DestRectWidth - x : x
to
IsMirrorLeftRight ? DestRectWidth - x - 1 : x
fixed the problem here.
Good catch! It looks like there are 4 lines with that same issue. If you want to create a pull request I will merge it.
Ok :)
Btw, should the BuildNo.rc be included in the Pull Request or left out ?
Edit : Well, left it out for now. Pull Request is #220
Yes, I just bump the build number so that I can keep track of it if I give out a build to someone. It doesn't need to be updated. Thanks!
BTW: I implemented it correctly here, which is why it worked in the official release.
The character sprites in Baldurs Gate 2 ( not the Enhanced Edition ) are showing visual artifacts with the latest dxwrapper code. These artifacts are absent in the official dxwrapper release from 2021.
Here's a picture of the problem.
Notice the glitchy 1 pixel wide vertical bars running along the character sprites. ( Not the rain drops ;) )
I investigated this a bit and it seems that changes in commit a38c6d11 introduced the problem.
It's somewhere in the CopySurface() function, but i have no idea at the moment on how to possibly fix this, and it's late so i'll drop an issue report just in case :)
DdrawFixByteAlignment=1 does not seem to help unfortunately