TTLG|Thief|Bioshock|System Shock|Deus Ex|Mobile
Page 2 of 98 FirstFirst 1234567121722273237424752 ... LastLast
Results 26 to 50 of 2446

Thread: Thief 1/2 & SShock 2: DDFix and Enhanced Resolution Patch - discussion

  1. #26
    Member
    Registered: Mar 2001
    Location: Ireland
    Oops, fixed now!
    Last edited by Nameless Voice; 20th Oct 2007 at 14:16.

  2. #27
    Quote Originally Posted by Nameless Voice
    I get this with the new version:
    oops..

    Fixed in 1.0.6.

    Quote Originally Posted by WET
    @Timeslip: Any chance of sharing the source code so that we can see the techniques being used? Along the same lines, how are you debugging all of this? I've been painstakingly single-stepping using a remote IDA Pro session but it sounds like you have some higher level tools to see the DirectDraw and D3D stuff directly. PM me if you've got the time and inclination.
    Source code is included with the non-installer version, in the src folder.

    ida pro wasn't involved, apart from looking at a few callback function to see which texture types thief was checking for. It's just a pile of fake DX interfaces, so they don't really care what thief is doing, just which DX functions it calls.

  3. #28
    Member
    Registered: Mar 2001
    Location: Ireland
    A few more:

    • Trying to start a game with the resolution ingame set to anything other than the resolution in the .ini will cause a crash. (I think you know that already)
    • Bringing up the console ( with shift+; ) makes the screen go black. You can't see the game or the console, until you hit return or esc.
    • ParticleFixTest=1 doesn't fix the particle bug.
    • DromEd issues are still present.
    • Setting the CPU speed to Highest instead of Adaptive (I'm using a laptop) has no effect on the massive slowdown.




    Edit: On another note: Bikerdude, it's really hard to find the link to the patch in your original post. Plus, you have a section in blue, which has an underlined section. Since links are underlined and blue on this forum, one automatically assumes it's a link and tries to click it - which, of course, doesn't work.
    Last edited by Nameless Voice; 20th Oct 2007 at 15:45.

  4. #29
    Member
    Registered: Feb 2003
    Fixed..

    Btw does anyone think its worth getting the admin's to making this thread a sticky..?

    NB. ive updated the 1st post to include the ongoing work by Timeslip.

    biker
    Last edited by bikerdude; 20th Oct 2007 at 17:35.

  5. #30
    Member
    Registered: Mar 2001
    Location: Ireland
    Not just yet, but maybe later.

  6. #31
    Member
    Registered: Jun 2000
    Location: Land of enchantment
    I suggest that sticky status should wait until ddfix is debugged and stable. Then the title can be changed. It might be worthwhile actually to start a new sticky thread when all is stable and leave all this debugging discussion out of it. It is up there and active anyway.

    @Timeslip,

    Two new issues and one question.

    I encountered an error in the GUI. Before install it said it needed .NET framework 2.0 or later but it couldn't find it. I already had .NET 2.0 SP2 installed at the time. I continued installing the GUI, and on launch it said "The application failed to initialize properly (0xc0000135)". I then ran a repair on the .NET 2 installation, and nothing changed. I then deinstalled .NET 2 and installed .NET 3 and it worked. Do you really require .NET 3? If yes, the error message is misleading. If no, then do you know why .NET 2 did not work for me?

    I have found something strange with the frame rates that may shed light on the performance hit some people are describing. I guess my system is fast enough that I don't have a performance issue in game, but I noticed another problem described below.

    First of all, before I installed ddfix, I used to let the application decide on vsync, and it worked just fine with Thief2.exe. Garrett ran at a normal speed with app controlled vsync. Now, with ddfix applied, application controlled vsync doesn't work. If I set both vwait=0 and LimitFPS=0, then Garrett runs very fast. I think this means that vsync is not working, which means that the application is not sending the control message to the driver. If, then, I go into the Nvidia control panel and force vsync to always on, then Garrett runs normally as he should. This seems all right in game, but then I notice a very stuttery response while in the Thief menu. The mouse-over effects are slow to react. Also, the resolution change on reading books is slow and jerky. So, something about forcing vsync on in the drivers is working badly in the ddfix version. I suspect that this issue may be affecting frame rate in-game for some.

    To check out this stuttering menu problem, I set vsync back to app controlled in the driver and, to prevent Garrett running fast, I set LimitFPS=1 for the game. Now Garrett runs normally again, and strangely, the menus and resolution changes are again quick to react. I also notice another small issue. Garrett's running motion is not totally smooth in this LimitFPS mode. There are small speed variations -- not enough to complain about, but noticeable compared with the way the driver's vsync used to work. I speculate that you might be controlling FPS by some time-wasting procedure that is adversely affecting performance for some people. I wonder if it might be worthwhile to bring back the old default behavior, where application-controled vsync worked, as an option. This might resolve performance problems, but I really don't know. In any case, it seems that that menu stuttering needs more study.

    Last and not least, do you have any word on the fog? I am waiting with bated breath.

    Thanks again for your work on this!

  7. #32
    Member
    Registered: Mar 2001
    Location: Ireland
    Quote Originally Posted by Bikerdude View Post
    DDfix version 1.0.6 onwards requires .Net
    Only if you use the GUI, I presume.
    I don't have the .NET 2 framework installed (I seem to have 1.1?) and it still worked. I didn't use the GUI, of course, since I already have my own patched .exe.

  8. #33
    Member
    Registered: Mar 2003
    Location: ...right behind youuu....BOOM!
    The installer works ok for me. I do have .NET framework 1.1, 2 & 3 installed + all service packs.

  9. #34
    Member
    Registered: Jan 2003
    Ok, 1.0.4 worked fine for me. but now when I try loading a game using 1.0.6 the game immediately crashes. This happens with both the GUI install and the manual hex editor install. I'm using an 8800GTX with 163.71 drivers in XP. AA/AF/Vsync are enabled through the Nvidia control panel, which worked fine for 1.0.4.

  10. #35
    Quote Originally Posted by smithpd View Post
    Before install it said it needed .NET framework 2.0 or later but it couldn't find it. I already had .NET 2.0 SP2 installed at the time. I continued installing the GUI, and on launch it said "The application failed to initialize properly (0xc0000135)". I then ran a repair on the .NET 2 installation, and nothing changed. I then deinstalled .NET 2 and installed .NET 3 and it worked. Do you really require .NET 3? If yes, the error message is misleading. If no, then do you know why .NET 2 did not work for me?
    I don't have .NET 3 installed, so it definately only needs 2. The installer checks HKLM\SOFTWARE\Microsoft\.NETFramework\policy\ to see which versions you have installed, and if the 2.0 entry was missing then no .NET programs would have worked properly anyway. A repair install should have fixed that though, so I have no idea.

    Quote Originally Posted by smithpd View Post
    Now, with ddfix applied, application controlled vsync doesn't work. If I set both vwait=0 and LimitFPS=0, then Garrett runs very fast.
    vwait=vsync. If you use application controlled vsync then ddfix's vwait setting will control whether thief uses it or not.

    The problem with menu's is that thief doesn't actually do any flipping, it just directly locks the frontbuffer. That isn't allowed in DX9, so I let it lock the backbuffer instead and then flip. Of course, that means it ends up being affected by vwait, and since the mouse curser and background are drawn in two seperate locks, they get treeted as seperate frames and so the background doesn't get updated while the mouse is moving.

    The best thing I could do is disabling vwait at menu's, but that requires a device reset, and I wanted to keep things as simple as possible...

    Quote Originally Posted by smithpd View Post
    I also notice another small issue. Garrett's running motion is not totally smooth in this LimitFPS mode. There are small speed variations -- not enough to complain about, but noticeable compared with the way the driver's vsync used to work. I speculate that you might be controlling FPS by some time-wasting procedure that is adversely affecting performance for some people.
    I used sleep() to wait for the next frame. Saves CPU power, but only accurate to 16 ms or so. I'll switch to a loop instead.

    Quote Originally Posted by smithpd View Post
    Last and not least, do you have any word on the fog? I am waiting with bated breath.
    Still not working. Still have no idea why.

    Edit:
    I suggest that sticky status should wait until ddfix is debugged and stable.
    Probably never going to happen. In my experience, trying to work around one graphics driver bug just causes another two to pop up. You just have to hope that they aren't as noticable as the original...

    It's a shame nvidia/ati value their 3D mark scores over compatibility, but to be fair, if nvidia released something that rendered everything pixel perfect compared to microsofts reference device, but was as big, hot and expensive as an 8800 and only ran at 20-40% of the speed, (which is what would happen without shader recompilers, deliberately throwing away detail in the corners of the screen etc.) I can't imagine anyone buying it.
    Last edited by Timeslip; 21st Oct 2007 at 02:49.

  11. #36
    Member
    Registered: Jun 2000
    Location: Land of enchantment
    Thanks for the explanation and the update. OK, so the software will never be completely debugged. No problem. I guess that is about true for all software. Basically, it is done when you declare victory.

  12. #37
    Member
    Registered: Jun 1999
    Location: Procrastination, Australia
    If it involves giving me a crash (refresher) course in how to use a hex editor, no one need bother, but I'd still like any ideas on why I can't see any reference to DDraw.dll in my Thief2.exe.
    I was hoping to try hacking it into SS2, but I can't find it in Shock2.exe either. I just did a search for the hex characters for 'dll' or 'DLL'. Lots of other dlls, no ddraw.

  13. #38
    Quote Originally Posted by Muzman View Post
    If it involves giving me a crash (refresher) course in how to use a hex editor, no one need bother, but I'd still like any ideas on why I can't see any reference to DDraw.dll in my Thief2.exe.
    I was hoping to try hacking it into SS2, but I can't find it in Shock2.exe either. I just did a search for the hex characters for 'dll' or 'DLL'. Lots of other dlls, no ddraw.
    Could be some sort of copy protection that uses an encrypted exe. What happens if you use the installer version?

    Edit:
    Made a quick 1.0.7 version with the menu vwait problem fixed. I removed limitfps, because I only added it in the first place because vwait was broken.

    There's also an unfinished DisableOverlay option which should (hopefully?) solve any fps problems. On the other hand, it will disable any in game text. It's unfinished because I intend for it to turn itself on/off when thief tries to render text, or if that isn't possible to add a toggle key.
    Last edited by Timeslip; 21st Oct 2007 at 04:53.

  14. #39
    Member
    Registered: Nov 2006
    Location: Moscow
    Tested on my Laptop with 8600GT on 158.28, works fine! Thank you!

  15. #40
    Member
    Registered: Feb 2003
    Hey TimeSlip

    Is the 1st thread ok btw..? would you like me to edit amend it?

    biker

  16. #41
    New Member
    Registered: Sep 2007
    [QUOTE=Timeslip;1659377]Could be some sort of copy protection that uses an encrypted exe. What happens if you use the installer version?

    I have the same problem as Muzman. My Thief2 is the official boxed version for Germany. Thief2.exe size is 250.438 Bytes, Thief2.icd 2.662.445 Bytes.
    Version says 1.18, but I already learned that there are actually different versions with this label. There is no reference to DDRAW.DLL in all files of my Thief2 program directory. Same applies to my boxed german version of System Shock 2. Also my Thief2 and System Shock 2 run under XP without having to set the compatibilty mode, and I have no other problems with NVidia 8800 GTS.

    Your installer is also clueless, it says "Could not locate code section to overwrite. Your version of Thief2 seems to be incompatible with this patch".

    The DLL reference has to be scrambled somewhere in the .exe or .icd file.

    The fixed exe from Nameless Voice (big THANK YOU) is 2.662.400 Bytes long and guessing from file size is like my .exe and .icd combined, but with much more DLL sections.

    By the way I find all the contributions in this forum just amazing. Thank you and respect.

  17. #42
    Member
    Registered: Mar 2001
    Location: Ireland
    Confirming that the patch also works with System Shock 2.
    For those without hex-editor lore, the fixed Shock2.exe is here:
    DDFix-Shock2.exe
    (Again, link expires in one week)

    I noticed a few issues.
    First of all, I get visible 'tearing' while moving; I can actually see where the frame is being drawn. This isn't something I can take a screenshot of, since if seems to finish rendering the frame before it takes a screenshot.

    Secondly, weapons are not properly rendered on top of everything else. Standing too close to a wall or object will make them disappear into that object:



    Another bug: sections of the inventory and user interface which should be black are transparent:




    Back to Thief 2, the DisableOverlay=1 option does indeed give a major performance boost - the game is actually playable again. It also seems to solve the black borders around particle effects. But, of course, the text overlay is gone. No labels on keys, no onscreen text, and I can't even check status/FPS.

    The DromEd problems still remain, though, which means that the supply of new FMs will probably dry up when the authors are stuck with DX10 cards...
    Last edited by Nameless Voice; 21st Oct 2007 at 08:47.

  18. #43
    Member
    Registered: Jan 2003
    Just installed 1.0.8 and the crashing is gone now. Thank you!

  19. #44
    Member
    Registered: Feb 2003

    Various issues: running update

    on my system:-

    XFX nForce 680i
    C2D E6600_2.4Ghz
    8800GTX
    DDR2-800
    Xfi XtremeMusic

    # Version 1.0.2:
    -textures closeup look like they do when Thief2 is in software mode
    -lurchy movment (eg. when Garret is moving),
    -when attempting to quit the game, it would go to desk then, you would have to go back into the game and quit.
    -the main menu animation would freeze when moving the mouse.

    #Version 1.0.4, same as above
    -textures closeup look like they do when Thief2 is in software mode
    -when attempting to quit the game, it would go to desk then, you would have to go back into the game and quit.
    -the main menu animation would freeze when moving the mouse.

    #Version 1.0.7:
    -textures closeup look like they do when Thief2 is in software mode
    -Cutscenese dont play correctly.

    #Version 1.0.8:
    -textures closeup look like they do when Thief2 is in software mode
    -Cutscenese dont play correctly.

    biker
    Last edited by bikerdude; 21st Oct 2007 at 15:36.

  20. #45
    Member
    Registered: Jun 2000
    Location: Land of enchantment
    Quote Originally Posted by Nameless Voice View Post
    Confirming that the patch also works with System Shock 2....
    Secondly, weapons are not properly rendered on top of everything else. Standing too close to a wall or object will make them disappear into that object
    I had similar issues with Thief Gold. It seems that the patch is not a blanket fix but is dependent on what program you are fixing. It's not at all surprising, but it is a bit unfortunate.

    The DromEd problems still remain, though, which means that the supply of new FMs will probably dry up when the authors are stuck with DX10 cards...
    This would be bad! I certainly hope this aspect can be fixed.

    Pondering a little, one approach might be to disclose all of this to Nvidia and hope that they can include some fundamental fixes in their drivers, as opposed to patches for individual applications. One problem is that Nvidia does not communicate with users.

    @Timeslip,
    Based on your understanding (which seems to be pretty deep), do you think that fundamental changes to the drivers are possible? I would guess that you have a certain standing now and you might be able to penetrate Nvidia's wall with help from the rest of us.

  21. #46
    New Member
    Registered: Sep 2002
    Quote Originally Posted by owl View Post
    Quote Originally Posted by Timeslip View Post
    Could be some sort of copy protection that uses an encrypted exe. What happens if you use the installer version?
    I have the same problem as Muzman. My Thief2 is the official boxed version for Germany. Thief2.exe size is 250.438 Bytes, Thief2.icd 2.662.445 Bytes.
    Version says 1.18, but I already learned that there are actually different versions with this label. There is no reference to DDRAW.DLL in all files of my Thief2 program directory. Same applies to my boxed german version of System Shock 2. Also my Thief2 and System Shock 2 run under XP without having to set the compatibilty mode, and I have no other problems with NVidia 8800 GTS.

    Your installer is also clueless, it says "Could not locate code section to overwrite. Your version of Thief2 seems to be incompatible with this patch".

    The DLL reference has to be scrambled somewhere in the .exe or .icd file.

    The fixed exe from Nameless Voice (big THANK YOU) is 2.662.400 Bytes long and guessing from file size is like my .exe and .icd combined, but with much more DLL sections.
    This is a direct consequence of the copy protection . Those who have versions of Thief (or SShock2) which use the loathsome SafeDiscV1 disk protection scheme (i.e. have an ICD file) are going to have this sort of problem. The main EXE is just the SafeDisc loader (basically a decryption program) which has nothing whatever to do with the game itself (the ICD file). Note that it is usually possible to decrypt ICD files using something like unSafedisc. (But you didn't hear that from me .)

    It is also particularly interesting that there are at least three categories of users: those for whom things just work on XP, those who need various minor tweaks, and those (like me) who have needed to perform major surgery to get things working. (I still can't run SShock2.) I wonder what the common thread is.

    On a related note: it would be a nice touch if we could arrange for a patch which didn't actually require changing the main binary at all. I think we could probably get away with arranging for a DLL to either pre-load or to be introduced earlier in the search path (e.g. Using the InjectDll, IgnoreLoadLibrary, and/or LoadLibraryCWD fixes from the Application Compatibility Toolkit). Then the patch could be version agnostic. If I read the 1.0.6 source properly, the only patch done directly to existing code is for the WindowFix: either we might find another way to work around that or else the patching could be done on-the-fly using pattern matching. (BTW what exactly is the WindowFix for?)

    We could also whittle down what the patch needs to do by leveraging the already existing Application Compatibility Toolkit technology. For example, it already includes patches for the multi-core issue, the disk space issue, and several others. (FWIW, I've wrapped up my stab at a useful set and put it up at http://neilschellenberger.googlepages.com/.)

    @Timeslip: I'd be happy to collaborate on this (or in any other way that I can). Just say the word.

    Quote Originally Posted by owl View Post
    By the way I find all the contributions in this forum just amazing. Thank you and respect.
    That goes double for me. The TTLG crowd is a terrific bunch! And, in particular, the hacker of the hour: Timeslip!

  22. #47
    Member
    Registered: Mar 2003
    Location: ...right behind youuu....BOOM!
    @Timeslip - i too am interested if a driver fix by Nvidia would be possible... so far, the only promising answer we've got from them was that they're aware of the issue and that they will fix it in the future (go here for to see the exact message i got from level 2 support: http://www.ttlg.com/forums/showthread.php?t=117468 )

    So, in your opinion, could these modifications be integrated in a future driver release by Nvidia?

    Btw, thanks again for all that you're doing! So far we've been hitting in the dark with little success (after a 10 page thread on the Nvidia forums + multiple complaints towards Customer Care all we got was the vague promise of a future fix mentioned above). Since you came along, things are finally starting to look a little more promising.

  23. #48
    Member
    Registered: Jan 2003
    Quote Originally Posted by Bikerdude View Post
    #Version 1.0.8:
    -textures closeup look like they do when Thief2 is in software mode
    -Cutscenese dont play correctly.
    That texture problem is starting to really bug me. I wonder what's causing it? The cutscenes not so much, since I can just play them outside the game.

    Another problem I've got with 1.0.8 is that when I press esc to bring up the game's menu, the cursor will be the white Windows arrow rather than Thief's gold arrow. If I click, the game will minimize to Windows and I need to bring it up again to get the game's gold arrow cursor working.

  24. #49
    Member
    Registered: Jan 2004
    I'd also like to confirm this works when running Thief2 in Linux using Wine - essentially it's just like Windows: better textures and sky, but no fog.

  25. #50
    Quote Originally Posted by Bikerdude
    textures closeup look like they do when Thief2 is in software mode
    What do you mean by that? Can I have a screenshot? Textures look fine here...


    Quote Originally Posted by Smithpd
    Based on your understanding (which seems to be pretty deep), do you think that fundamental changes to the drivers are possible? I would guess that you have a certain standing now and you might be able to penetrate Nvidia's wall with help from the rest of us.
    Dunno, I'm not a driver programmer. There's no reason why they couldn't do everything that I have in their driver; it's a case of whether they'd have to do it on a game by game basis, (in which case I doubt they'd bother,) or if they could do a blanket fix for everything that uses a 16 bit render target.

    Quote Originally Posted by WET
    On a related note: it would be a nice touch if we could arrange for a patch which didn't actually require changing the main binary at all. I think we could probably get away with arranging for a DLL to either pre-load or to be introduced earlier in the search path
    My usual method for these sort of patches is to just name the dll 'ddraw.dll'. Except when it's looking for a protected system dll, windows will check the application directory before the system folder, so my dll will get loaded instead of the real one. The problem with doing that here is that because of the interfaces thief tries to get, other DX dll's end up calling functions in ddraw.dll, and if they end up calling into my dll instead of the real one then thief crashes. afaik there is no windows api function to prevent the application directory being searched for dlls, or I could just remove it from the search path once my dll had loaded.

    Injecting the dll would probably require version specific code for every version of thief 2 I wanted to support.

    Quote Originally Posted by WET
    BTW what exactly is the WindowFix for?
    This:
    Quote Originally Posted by Slynt
    Another problem I've got with 1.0.8 is that when I press esc to bring up the game's menu, the cursor will be the white Windows arrow rather than Thief's gold arrow. If I click, the game will minimize to Windows and I need to bring it up again to get the game's gold arrow cursor working.

Page 2 of 98 FirstFirst 1234567121722273237424752 ... LastLast

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •