Gamestudio Links
Zorro Links
Newest Posts
Help with plotting multiple ZigZag
by degenerate_762. 04/30/24 23:23
M1 Oversampling
by 11honza11. 04/30/24 08:16
Trading Journey
by howardR. 04/28/24 09:55
Zorro Trader GPT
by TipmyPip. 04/27/24 13:50
Data from CSV not parsed correctly
by jcl. 04/26/24 11:18
Why Zorro supports up to 72 cores?
by jcl. 04/26/24 11:09
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
2 registered members (TipmyPip, AndrewAMD), 911 guests, and 3 spiders.
Key: Admin, Global Mod, Mod
Newest Members
firatv, wandaluciaia, Mega_Rod, EternallyCurious, howardR
19050 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 1 of 10 1 2 3 9 10
SSAO development thread #339229
08/25/10 12:54
08/25/10 12:54
Joined: Jul 2001
Posts: 6,904
H
HeelX Offline OP
Senior Expert
HeelX  Offline OP
Senior Expert
H

Joined: Jul 2001
Posts: 6,904
I decided to clean up the thread in the showcase and move all relevant development comments, bug reports and suggestion in a new thread in which I can actually *post* images smile please report problems here, etc.

So, I added now the following features (or fixed the following bugs):
  • Sky entities are automatically bound to the diffuse view so that AO isn't calculated anymore on the skybox (if visible)
  • Fog is now supported (emulated in the combine pass - I can not disable fog in specific views!)
  • particles are ignored
  • To support sprites with soft alpha textures, you can set a flag liek FLAG2 or so (is customizable!). This way they are discarded from the depthmap and therefore receive no AO, but you can see through them the AO of hidden surfaces, depending on the sprites' alpha texture (see image(s) below).


Here is how I deal with the soft alpha issue:

This is how it looks like at the moment:

I discard pixels with alha less than 50% and sample the depth of the sprites, like the plants in the Sponza Demo. This is wrong! The brightness of the sprite is drastically reduced and the (soft) alpha is cutted. We do not want this on effect sprites, like halos, lightshafts or drop shadows!

So, in the seperate view I sample once the depth of the scene without entities with FLAG2 on (the alpha sprites) and at the same time the alpha of these entities:


I use the depth map for AO and fog calculations. In the combine stage, I simply supress AO depending on the alpha mask and then I apply the fog:


A fellow here promised me beer and chips if I finish the soft alpha-sprite support very soon (due to a dead line for his project), so I delayed other requests to help him out. The pending list of features are these:

  • no blur on sky pixels and 100%-fogged pixels (better performance)
  • checking stencil shadows
  • checking blurred stencil shadows
  • dual AO calculation so that meshes with alpha will receive AO and you can see AO on hidden surfaces through their transparent parts
  • use static AO via 2nd UV set if provided (better performance)
  • seperate particle mask if fog is active
  • generate random vectors on startup (optional)
  • try other filtering options for the blur stage
  • enhance Sponza demo with effects to demonstrate features and support of pre-existing shaders


If something is missing, please tell me. I will add the first item of the todo-list (ignore sky- and 100%-fog pixels in the blur stage), clean it up and then I make a public release!

Last edited by HeelX; 12/19/10 18:32.
Re: Crytek's SSAO development thread [Re: HeelX] #339235
08/25/10 13:45
08/25/10 13:45
Joined: Jan 2004
Posts: 3,023
The Netherlands
Helghast Offline
Expert
Helghast  Offline
Expert

Joined: Jan 2004
Posts: 3,023
The Netherlands
If we ever meet (Dusmania, gamescom or any other meeting); help remind me to get you beer and chips as well wink

This is gonna be a very nice contribution, cant wait!

regards,


Formerly known as dennis_fantasy
Portfolio - http://www.designorhea.com/
Project - http://randomchance.cherrygames.org/
Re: Crytek's SSAO development thread [Re: Helghast] #340295
09/02/10 22:29
09/02/10 22:29
Joined: Jul 2001
Posts: 6,904
H
HeelX Offline OP
Senior Expert
HeelX  Offline OP
Senior Expert
H

Joined: Jul 2001
Posts: 6,904
Small update: I have now three demos

1.) Sponza as before
2.) new testscene - see images above, and
3.) one in which I demonstrate how to write a custom object shader to use my solution and deliver all necessary data

And I am also working on a fourth demo with a whole shader pipeline (object- and postprocessing), because I didn't tested it enough with "real" scenes.

So, sorry for the delays! smile

Re: Crytek's SSAO development thread [Re: HeelX] #340348
09/03/10 11:43
09/03/10 11:43
Joined: Oct 2002
Posts: 806
Zapan@work Offline
User
Zapan@work  Offline
User

Joined: Oct 2002
Posts: 806
We just want to show some screenshots of our upcoming game (without and with this greate shader):








I've asked some of our zombies some minutes ago, and they liked it laugh

Re: Crytek's SSAO development thread [Re: Zapan@work] #340486
09/04/10 16:48
09/04/10 16:48
Joined: Dec 2008
Posts: 1,218
Germany
Rackscha Offline
Serious User
Rackscha  Offline
Serious User

Joined: Dec 2008
Posts: 1,218
Germany
looks nice, but looks better with moving objects^^.


MY Website with news of my projects:
(for example my current
Muliplayer Bomberman,
GenesisPrecompiler for LiteC
and TileMaster, an easy to use Tile editor)
Sparetime-Development

Re: Crytek's SSAO development thread [Re: Rackscha] #340497
09/04/10 17:26
09/04/10 17:26
Joined: May 2009
Posts: 1,816
at my pc (duh)
darkinferno Offline
Serious User
darkinferno  Offline
Serious User

Joined: May 2009
Posts: 1,816
at my pc (duh)
can this work with other PP effects? what would need to be done to get it to do that

Re: Crytek's SSAO development thread [Re: darkinferno] #340528
09/05/10 08:04
09/05/10 08:04
Joined: Jul 2001
Posts: 6,904
H
HeelX Offline OP
Senior Expert
HeelX  Offline OP
Senior Expert
H

Joined: Jul 2001
Posts: 6,904
Well, as every post processing effect there is somewhere an output bitmap that is rendered to the screen. So, yes, you can place your PP chain afterwards.

But wait for the next release in which I include a demo which demonstrates how to do that in the integrated SSAO mode, maybe I have to write some additional code to make it even easier (like chopping of the combine stage so that you can tinker directly with the AO-, the transparency- and the diffuse-channel).

Re: Crytek's SSAO development thread [Re: HeelX] #340685
09/06/10 16:54
09/06/10 16:54
Joined: Jul 2001
Posts: 6,904
H
HeelX Offline OP
Senior Expert
HeelX  Offline OP
Senior Expert
H

Joined: Jul 2001
Posts: 6,904
Ok, two things happened:
1.) After finishing the base code for my new testscene I encountered that I have a too low fog resolution. But:
2.) JCL adds a NOFOG flag for views. As soon as the new beta is out I will adopt to this, and
3.) I realized that I --HAVE TO-- improve the visual quality of the SSAO because on very clean scenes with lots of rounded, planar surfaces ... it sucks like hell - in terms of AO bleeding!

So here is what I will do the next days:
a.) polish the changed code
b.) make a release

The fog support is currently done in the shader and as soon as I get the new beta I will switch the fog code. Then I focus on the AO bleeding and stuff... frown

Re: Crytek's SSAO development thread [Re: HeelX] #340887
09/08/10 11:21
09/08/10 11:21
Joined: Jul 2001
Posts: 6,904
H
HeelX Offline OP
Senior Expert
HeelX  Offline OP
Senior Expert
H

Joined: Jul 2001
Posts: 6,904
Maybe you have seen it already: I have released the source and the demos of the SSAO v0.3 in the showcase (I also updated the feature list und gallery images).

Have fun with it, and please post any stuff related to the release there (e.g. bugs) and dev-related stuff here :-)

Best regards and have a nice day,
-Chris



Last edited by HeelX; 09/08/10 11:26.
Re: Crytek's SSAO development thread [Re: HeelX] #340921
09/08/10 16:51
09/08/10 16:51
Joined: Nov 2008
Posts: 216
J
jane Offline
Member
jane  Offline
Member
J

Joined: Nov 2008
Posts: 216
Hi Chris,
deutsch: Habe bereits die Demos getestet, bei den neuen Demos hat alles
fehlerfrei funktioniert und sieht klasse aus. Bei der Sponza-Demo musste
ich die beiden defines (PP_SSAO_NOFOG und PP_SSAO_NOSOFTALPHA) ausklammern
damit die Scene ohne schwarze Artefakte im oberen und unteren Drittel
funktioniert.
Beim integrieren in mein Projekt stoße ich allerdings auf einige Probleme.
Sobald ich die "ppSsao.h" include bekomme ich die Malfunction W1507
mit dem Kommentar "video functions not available before first frame"
selbst wenn ssaoIntegrate(camera, true); ausgeklammert ist.
Wenn ich trotzdem OK drücke folgt der Error 1513 "script crash in
ppSsaoGenerateRandomVectors: sys". Mache ich trotzdem weiter öffnet das Level mit 0-1 frames, alles ist schwarz/weiss und der Rechner muss neu gestartet werden.

english: have tested the new demo, it work good and looks great. But at the SponZa demo I have to exclude (PP_SSAO_NOFOG and PP_SSAO_NOSOFTALPHA) to run the scene without black artifacts at the top and the bottom of the screen.

So... while including it in my project I get some issues:

When I include the "ppSsao.h" I get the Malfunction W1507 with
the description "video functions not available before first frame"
even when ssaoIntegrate(camera, true); is excluded.
When I press the ok Button the following error message is shown - Error 1513 "script crash in
ppSsaoGenerateRandomVectors: sys".

If I press Ok again the level runs with just 0-1 frames - its just in black and white and the PC needed a restart...


mfg Jane

Edit:

Habe eine wait(1); (im main-skript) hinter dem setzen von
video_mode, camera.arc usw. ausgeklammert, woraufhin das
Level zwar startet, nach wenigen Sekunden jedoch die Meldung
script-crash in bindsky kommt oder einen schwarzen screen,
der ein par mal wieder weg geht bis sich das ganze aufhängt
oder der Rechner abstürzt.

Um auszuschliessen, daß es am Rechner liegt:
Referenz-Rechner:
AMD Athlon 64X2 4800, Geforce 9800 GT, 4GB DDR3-Ram
Performance-Test-Rechner:
AMD Athlon 64 4000+, Geforce 7600 GT, 2GB DDR2-Ram

Last edited by jane; 09/08/10 19:40.
Page 1 of 10 1 2 3 9 10

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1