Author Topic: Variance Shadow Maps (Soft shadows) WIP  (Read 8748 times)

0 Members and 1 Guest are viewing this topic.

Offline --Steve-O--

  • 28
  • I might be the last man on earth to use TS3.2
Re: Variance Shadow Maps (Soft shadows) WIP
I love HLP's wizards. It's like walking into a room and a crazy guy with a shotgun pops out from behind the couch and shoots you in the face, except that instead of the shot being made of lead, it's made of awesome.

quoted again for great justice

that shizz is funny yo
"And so they dwelled in filth, on worlds made of dirt and feces, and there they lay until they stumbled into the skies." --the Mad Prophet

 

Offline Bryan See

  • Has anyone really been far as decided to use even go want to do look more like?
  • 210
  • Trying to redeem, but under Tiger Parents
    • Skype
    • Steam
    • Twitter
Re: Variance Shadow Maps (Soft shadows) WIP
Swifty, how's your variance soft shadow maps going on? I'd like to see it committed to main trunk very soon.
Bryan See - My FreeSpace Wiki User Page (Talk, Contributions)

Full Projects:
Shattered Stars

Campaigns:
Lost in the Mist - Cyrene vs. Psamtik
FreeSpace: Reunited

Ships:
GTS Hygeia, GTT Argo, SC Raguel

Tools:
FSO TC/Game template

I've been under attack by Tiger Parents like Jennifer Pan...

 

Offline Swifty

  • 210
  • I reject your fantasy & substitute my own
Re: Variance Shadow Maps (Soft shadows) WIP
Well it's probably not something I'd immediately commit to trunk. I rewrote a lot of model rendering code so it'll probably be more prudent to do some bug testing. You'll probably start seeing it in the Test Builds section very soon.

 

Offline SypheDMar

  • 210
  • Student, Volunteer, Savior
    • Minecraft
Re: Variance Shadow Maps (Soft shadows) WIP
Remember when our coders said that this was impossible?

 :pimp:

 

Offline Zacam

  • Magnificent Bastard
  • Administrator
  • 211
  • I go Sledge-O-Matic on Spammers
    • Minecraft
    • Steam
    • Twitter
    • ModDB Feature
Re: Variance Shadow Maps (Soft shadows) WIP
Under the constraints of the previous times that it was brought up, it was. The engine didn't have any sort of framework for delivering this.

That started changing once Taylor introduced the shader pipeline and we got folks like Hery, The E, Valathil and Swifty involved into iterating on it. Because then it went from being impossible to plausible. Hell, it even took Triple-A a while to get into figuring out how to make it possible.

There's obviously still a good amount of progress to be made, especially in terms of making it something that will perform well. But we'll get there.
Report MediaVP issues, now on the MediaVP Mantis! Read all about it Here!
Talk with the community on Discord
"If you can keep a level head in all this confusion, you just don't understand the situation"

¤[D+¬>

[08/01 16:53:11] <sigtau> EveningTea: I have decided that I am a 32-bit registerkin.  Pronouns are eax, ebx, ecx, edx.
[08/01 16:53:31] <EveningTea> dhauidahh
[08/01 16:53:32] <EveningTea> sak
[08/01 16:53:40] * EveningTea froths at the mouth
[08/01 16:53:40] <sigtau> i broke him, boys

 

Offline SypheDMar

  • 210
  • Student, Volunteer, Savior
    • Minecraft
Re: Variance Shadow Maps (Soft shadows) WIP
We've done the impossible, and that makes us mighty shows how far we've gone. We couldn't have imagined this years ago, but it's becoming a reality.

Y'all make dreams come true.

 

Offline Swifty

  • 210
  • I reject your fantasy & substitute my own
Re: Variance Shadow Maps (Soft shadows) WIP
So, the technique I've implemented has been using something called variance shadow maps. Long story short, this let's us prefilter the shadow maps using a separable filter like gaussian blur to get the softness we need.

Data from testing is showing that the gaussian blur is hitting people's machines really hard. That's due the number of texture fetches required to implement gaussian blur. I'm using four shadow maps for four different cascades, all 1024x1024. So 2048x2048 texels times 5 texel fetches for the vertical pass times 5 texel fetches for the horizontal pass... That's a lot of texture fetches. It also doesn't help that variance shadow mapping requires fatter floating point textures so we also take on a texture bandwidth hit.

So, I think I'm going to ditch the variance shadow mapping technique now that I discovered cheaper ways to sample shadow maps with the filter sizes we need without sacrificing quality and reducing the frametime footprint.

 

Offline Bobboau

  • Just a MODern kinda guy
    Just MODerately cool
    And MODest too
  • 213
Re: Variance Shadow Maps (Soft shadows) WIP
so, just a small tangent, is the fixed function pipeline supported anymore at all? or is it as deprecated as the non-htl code?
Bobboau, bringing you products that work... in theory
learn to use PCS
creator of the ProXimus Procedural Texture and Effect Generator
My latest build of PCS2, get it while it's hot!
PCS 2.0.3


DEUTERONOMY 22:11
Thou shalt not wear a garment of diverse sorts, [as] of woollen and linen together

  

Offline Swifty

  • 210
  • I reject your fantasy & substitute my own
Re: Variance Shadow Maps (Soft shadows) WIP
Fixed function should still work even with how I refactor the model render functions. If it doesn't, it's a bug. A big bug.