Outerra forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

Download Outerra Tech Demo. Unofficial Outerra Discord server, MicroProse Discord server for OWS.

Author Topic: Grass shadowing  (Read 17470 times)

cameni

  • Brano Kemen
  • Outerra Administrator
  • Hero Member
  • *****
  • Posts: 6721
  • No sense of urgency.
    • outerra.com
Grass shadowing
« on: July 30, 2012, 05:25:38 am »

With the old shadow rendering pipeline it was problematic to shadow the grass without getting a serious performance hit, and there were also several shadowing artifacts. The new reworked rendering pipeline now fixes both issues, allowing for effective grass shadows.



This algorithm shades the whole blades by testing whether the ground from which they stem lies in shadow, so up close you can see it's not entirely correct. This algorithm is very fast, for better cards we will be adding another method. However, even this method looks ok when you aren't blade-picking :)


Logged

Luishi5k0

  • Full Member
  • ***
  • Posts: 157
  • newbie
Re: Grass shadowing
« Reply #1 on: July 30, 2012, 09:12:12 am »

It looks very nice! I can hardly notice the "problem" with it! Does the new shadow system also fix the problems with them bending at different angles and the clipping they had?
Logged

cameni

  • Brano Kemen
  • Outerra Administrator
  • Hero Member
  • *****
  • Posts: 6721
  • No sense of urgency.
    • outerra.com
Re: Grass shadowing
« Reply #2 on: July 30, 2012, 09:25:21 am »

You would notice the problem in motion, whole blades lighted or shadowed. Actually, in the meantime I experimented with a different method that samples the shadow map at the blade segment points and interpolates in between, resulting in smooth shading.

First the per-blade shadowing:



Per-segment interpolated shadowing:



The new shadowing system is not yet completed, and the change in itself does not fix the two issues. Clipping is actually not a problem of the shadowing itself, but a problem of not rendering objects using the shadow frustum. We are working on that too.
Logged

Philpax

  • Newbie
  • Posts: 6
  • newbie
Re: Grass shadowing
« Reply #3 on: July 30, 2012, 10:36:33 am »

Impressive! I love the steady work on Outerra. It keeps getting better and better by the day  :)
Logged

monks

  • Full Member
  • ***
  • Posts: 212
Re: Grass shadowing
« Reply #4 on: July 30, 2012, 12:38:30 pm »

Looking awesomer!!

monks
Logged

Steve.Wilson

  • Full Member
  • ***
  • Posts: 176
  • Home Cockpit Builder
Re: Grass shadowing
« Reply #5 on: July 30, 2012, 12:56:28 pm »

Sick. The good kind of "sick."   8)  Nice work, Brano!

Makes me want to give up flight sim and just drive around the countryside......but I think I'll get over that.

Love the purple truck.  Too much "LDS?"
« Last Edit: July 30, 2012, 12:58:39 pm by WarpeD »
Logged

cameni

  • Brano Kemen
  • Outerra Administrator
  • Hero Member
  • *****
  • Posts: 6721
  • No sense of urgency.
    • outerra.com
Re: Grass shadowing
« Reply #6 on: July 30, 2012, 01:12:13 pm »

Love the purple truck.  Too much "LDS?"
What's LDS? Been looking at the list of possible abbreviations, but nothing there would explain purple trucks. Maybe the Latter-day Saints? :D

No, no LSD either. I was experimenting with a dyeing of object colors in run-time, in order to quickly change colors of models without a skin (for some game purposes where you want objects and vehicles to have a single set of colors by which you are recognizable), when in the middle of it I got an idea to try a different method for the grass shadows. And I didn't bother to revert the colorizer code for that :)
Logged

Steve.Wilson

  • Full Member
  • ***
  • Posts: 176
  • Home Cockpit Builder
Re: Grass shadowing
« Reply #7 on: July 30, 2012, 01:34:09 pm »

Sorry 'bout that....obscure reference to Star Trek IV. ;)  Thanks for the explanation, though....sounds like inspiration had a good day.  :D
Logged

cameni

  • Brano Kemen
  • Outerra Administrator
  • Hero Member
  • *****
  • Posts: 6721
  • No sense of urgency.
    • outerra.com
Re: Grass shadowing
« Reply #8 on: July 30, 2012, 01:56:29 pm »

Aha, so it's the old times again :)

Found it [noembed]http://www.youtube.com/watch?v=pgHxFNFWlZc[/noembed]
Logged

ZeosPantera

  • ||>>-Z-<<||
  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2520
  • #1 Outerra Fan Boy
    • My Youtube
Re: Grass shadowing
« Reply #9 on: July 30, 2012, 02:54:15 pm »

It is funny. I didn't notice the purple truck because the grass shadows had me mesmerized. Then I read LSD when it is obviously net spelled that way.
« Last Edit: July 30, 2012, 02:56:27 pm by ZeosPantera »
Logged
"Fear accompanies the possibility of death, Calm shepherds its certainty" - General Ka Dargo

ZeosPantera

  • ||>>-Z-<<||
  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2520
  • #1 Outerra Fan Boy
    • My Youtube
Re: Grass shadowing
« Reply #10 on: July 31, 2012, 12:44:21 am »

Hrm.. I have been flipping through the two screens. The one with full blade and the one with per segment and the full blade looks better and I know why. Because the shadow line on the per-segment is being rendered based on our eye position and not relative to the sun and truck. if it did segment blending from that orientation it would be a better balance of smooth shadow and lit blades over the shadow.
Logged
"Fear accompanies the possibility of death, Calm shepherds its certainty" - General Ka Dargo

cameni

  • Brano Kemen
  • Outerra Administrator
  • Hero Member
  • *****
  • Posts: 6721
  • No sense of urgency.
    • outerra.com
Re: Grass shadowing
« Reply #11 on: July 31, 2012, 01:44:23 am »

Yes, shadow is projected to the ground and it's then missing that zigzag pattern. The grass would need to be added to shadow prepass, but that would be a costlier performance penalty. There are other tricks, but all of them will cut the perf a bit. Whereas the first full-blade shadowing tech seems to not impart it at all, so it's going to be the default.
Logged

Timmo

  • Member
  • **
  • Posts: 77
Re: Grass shadowing
« Reply #12 on: July 31, 2012, 10:41:10 pm »

Both look good- To be honest I would take the first option with more performance....it looks more 'natural' to my eye even though the interpolated segment shadows are more 'correct'. Unless you are really looking, the second option reminds of a simple shadow plane overlaid on bare terrain (a-la FSX) rather than on top of/through the grass blades.
Logged