Jump to content


Photo

Proof-of-concept: Alpha-blended fog-of-war ( PST )


  • Please log in to reply
10 replies to this topic

#1 aqrit

aqrit
  • Member
  • 132 posts

Posted 06 July 2013 - 08:59 PM

threw this proxy dll together:
http://bitpatch.com/...ads/pst_fog.zip ( src included )

It doesn't actually do any alpha-blending ( someone want to code something up for that ? )
It currently just darkens the tiles that are completly covered by the fog-of-war ( tiles not completly covered, currently still use color-keying )

Have fun..

Edit: This is meant to address the "shimmer" that occurs when the widescreen mod is used on Planescape: Torment with very high resolutions

Edited by aqrit, 06 July 2013 - 09:12 PM.


#2 aqrit

aqrit
  • Member
  • 132 posts

Posted 10 July 2013 - 04:06 PM

uploaded the next iteration ( same link as above )

All fog-of-war drawing is now hooked ( no color-keying )
( so if anyone wants to remove all fog and black mask it is just few edits-away )

Game is rendered entirely in software
then using OpenGL :lol2: it is up-converted to 32-bit color and displayed with vsync! ( which should also improve win8 performance? )
( currently only fullscreen works )

--
Fixed crash caused by a non-functioning allocator
Moved all the interesting stuff to torment.cpp

 

--

edit: Fixed another crash... mark surfaces as offscreen... I don't know how it was working for me before :(


Edited by aqrit, 20 July 2013 - 08:27 PM.


#3 The Imp

The Imp

    Not good, see EVIL is better. You'll LIVE.

  • Member
  • 5150 posts

Posted 21 July 2013 - 01:34 AM

Is there a screenshots you could show, just curious on hot it's going to look like ? PS:

[img=http-address]

Use the Imageshacks direct link or similar site thing as the "http-address".


Yep, Jarno Mikkola. my Mega Mod FAQ. Use of the BWS, and how to use it(scroll down that post a bit). 
OK, desert dweller, welcome to the sanity, you are free to search for the limit, it's out there, we drew it in the sand. Ouh, actually it was still snow then.. but anyways.


#4 aqrit

aqrit
  • Member
  • 132 posts

Posted 21 July 2013 - 09:16 AM

The tiles are darkened by 50% because that is the fastest thing to do ( Right-shift and mask off )
Half shaded tiles were dropped so corner tiles could be shaded at 45 degrees...
Shading the corners at 45 degrees creates the semi-rare issue shown below:
Trmnt000.png

for a zoomed out view (~1.25 MB):
click here

===
The FOGOWAR.BAM you posted previously crashes Torment.
In NearInfinity it looks the same as the original ... but the file size is much reduced.

#5 The Imp

The Imp

    Not good, see EVIL is better. You'll LIVE.

  • Member
  • 5150 posts

Posted 21 July 2013 - 10:17 AM

The FOGOWAR.BAM you posted previously crashes Torment.
In NearInfinity it looks the same as the original ... but the file size is much reduced.

Ahh, the reason for that is that the file was exported wrongly.


Yep, Jarno Mikkola. my Mega Mod FAQ. Use of the BWS, and how to use it(scroll down that post a bit). 
OK, desert dweller, welcome to the sanity, you are free to search for the limit, it's out there, we drew it in the sand. Ouh, actually it was still snow then.. but anyways.


#6 -Solovyev-

-Solovyev-
  • Guest

Posted 23 July 2013 - 06:26 PM

Ive been having huge issues with the fog of war flicker, downscaling resolutions didnt help and it appeared as if the issue was occuring on vanilla install (gog) as well.

 

Until I found your little mod.. no more flicker.

 

Thanks man :)



#7 aqrit

aqrit
  • Member
  • 132 posts

Posted 06 September 2013 - 07:34 PM

very minor update ...

( all my projects move at a snails pace :( )

 

fogged tiles are now 25% darker instead of 50%

movie stretching is now done by this mod ( probably the best place to do this. )

tiles with overlapped triangles are now drawn as squares ( which is probably nearest to what they looked like originally anyways )

 

which leaves still to be done:

research OpenGL PBO

upscaling movies using OpenGL instead of ddraw

windowed mode

anything else?

 

for best results

this mod depends on the (unreleased) new vesion of the widescreen mod

and some ( partially done ) tweaks for Ghostdog's UI...

 

---

edit: fixed some bugs... sighs


Edited by aqrit, 07 September 2013 - 06:34 AM.


#8 aqrit

aqrit
  • Member
  • 132 posts

Posted 29 October 2013 - 08:51 AM

updated:

 

fixed crash with stretch movies

added scale2x to stretch movies ( off by default )

added command line options to toggle stuff

moved source to github

PBO's showed no noticable speed up but switching away from glDrawPixels got a 2x speedup



#9 -One-

-One-
  • Guest

Posted 28 November 2013 - 02:49 PM

Do you think it might be possible to make this compatible with the DDraw Fix? The DDraw Fix corrects the issue with the pointer trails but it does not fix the issue with the flickering fog of war. I have tested these mods together but they do not appear to be compatible with each other. When I have both mods installed the cursor trails reappear, so if it's possible to make these two mods compatible somehow then both issues would be solved.

 

 



#10 -Mamba-

-Mamba-
  • Guest

Posted 30 September 2015 - 10:09 AM

Almost two years have passed, but I would like to repeat the request above - I checked numerous solutions and various ddraw fixes to get rid of the fog of war flickering in PST (at 1920x1080, Windows 7 64-bit), but nothing helped. The from the archive in the OP is the only thing that helps... but after using it the cursor trails return. At the moment I have to choose between playing with flickering fog of war, or with cursor trails, or in 1600x900 (which makes flickering less annoying, but still visible), which is a shame, seeing Torment: Tides of Numenera approaches and getting to know the main inspiration would be wise. Cheers!



#11 -Mamba, again-

-Mamba, again-
  • Guest

Posted 30 September 2015 - 10:10 AM

Fixed!

 

The DLL file from the archive in the OP is the only thing that helps...