cai567890 / pcsx2

Automatically exported from code.google.com/p/pcsx2
1 stars 0 forks source link

[GSDX] Sakura Wars - lighting partially broken in hardware mode #643

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
1) Did the game ever work correctly (i.e. not have this problem) on the
Official PCSX2 build or an earlier version of PCSX2 playground?
No. I tried a few svn revisions and the last official beta.

2) What steps will reproduce the problem?
1. Play the game until you reach the first segment with 3D graphics.

3) What exactly happens when you experience this issue (listing any console
errors or screen output you receive)?
Using hardware rendering some (most) objects are not lit brightly enough --
see attached screenshots. Software mode fixes the problem.

4) What version of PCSX2 are you using? On what operating system? Plugins?
Revision 2802 on Windows 7, latest GSDX.
The problem happens in both DirectX 9 and 11 modes.
Alpha/Offset hacks or skipdraw changes do not affect the problem.

5) Please provide any additional information below.
The shadows are also missing in hardware mode, but that's a much smaller
problem. The ghosting around the characters is eliminated by enabling the
alpha hack.

6) Attachments.
Hardware mode:
http://www.abload.de/img/gsdx_20100407000924scir.png
Software mode:
http://www.abload.de/img/gsdx_20100407000928vfda.png

Original issue reported on code.google.com by peter.0x...@gmail.com on 6 Apr 2010 at 10:24

GoogleCodeExporter commented 9 years ago
Here's a .gs dump for easier debugging:

http://www.megaupload.com/?d=E04LFZ7T

Original comment by peter.0x...@gmail.com on 8 Apr 2010 at 5:21

GoogleCodeExporter commented 9 years ago
I don't remember the game being brown as seen in the screenshots above, it was 
quite
colorful, it could just be my memory though (time of the day?), or another 
issue.

Regardless it also happens in the japanese version (Sakura Taisen V - Saraba 
Itoshiki
Hito Yo), tried with older versions (0.1.4) and ZeroGS, seems the issue was 
present
since ever, it's the same output regarding the ambient light.

http://img511.imageshack.us/i/gsdx20100408190801.png/ [2819 / HW]
http://img101.imageshack.us/i/gsdx20100408190858.png/ [2819 / SW]

Original comment by shadow0...@mail.com on 8 Apr 2010 at 10:48

GoogleCodeExporter commented 9 years ago
After getting some basic understanding of how gsdx works and mucking around 
with the
debugger a lot, I found a hack that fixes this problem.

Obviously this is not a real fix, but it's good enough for me to return to 
playing
the game ;)

Around line 125 of GSRendererDX.h (in Draw(rt, ds, tex)) I added this:
  [...]
  if(!IsOpaque())
  {
    if(tex==0) return; // Durante Sakura Wars hack
    om_bsel.abe = PRIM->ABE || PRIM->AA1 && m_vt.m_primclass == GS_LINE_CLASS;
    [...]

From my limited understanding it seems like some transparent (untextured?) 
object is
being drawn over much of the screen, maybe it's even the (missing) character 
shadows!
Obviously I do not yet fully understand how everything in GSDX works (after 
just a
few hours of looking at it) so I'm fishing in the dark here.

Original comment by peter.0x...@gmail.com on 9 Apr 2010 at 11:30

GoogleCodeExporter commented 9 years ago
As far as im aware this has been fixed (im a similar manner) so closing now.

Original comment by refraction on 5 Apr 2013 at 11:57