Vousk-prod. Posted March 16, 2015 Share Posted March 16, 2015 Is there a way to change SSAO strength ? In some cases it's a bit too soft and we barely see what the effect is adding to the scene. Quote Link to comment Share on other sites More sharing options...
RaananW Posted March 16, 2015 Share Posted March 16, 2015 The ratio parameter in the constructor can be either a number or an object.The object can contain two values:var ratio = { ssaoRatio : 0.75, combineRatio : 0.75}Maybe try playing with the combineRatio, might be what you are looking for. leave the ssaoRatio the same as the ratio you are using now. Quote Link to comment Share on other sites More sharing options...
julien-moreau Posted March 16, 2015 Share Posted March 16, 2015 Hello Vousk In addition to the ratio, I'm going to do it for you were you'll only have to set "ssao.strength" to the value you want.I think I'll opt for a better customization for SSAO too Quote Link to comment Share on other sites More sharing options...
Vousk-prod. Posted March 16, 2015 Author Share Posted March 16, 2015 RaananW, I've already played with those values but without noticable effect (maybe I did something wrong). Luaacro, what a great news!And do you think there is a way, regarding WebGL limitiation, to reduce the "textile effect" that superimposes above whole canvas when activating SSAO ? Quote Link to comment Share on other sites More sharing options...
julien-moreau Posted March 16, 2015 Share Posted March 16, 2015 The SSAO uses 2 passes :- SSAO pass- Combine pass (that combines the SSAO pass with the original scene color) Invar ratio = { ssaoRatio : 0.75, combineRatio : 0.75}ssaoRatio represents the ratio of the SSAO post-process (that is usually done in a lower ratio)combineRatio is the the ratio of the Combine post-process.If you set the ssaoRatio lower than 1.0, you'll win performances In the SSAO pipeline there is 2 blur post-processes : Horizontal and Vertical.To remove the "textile effect" you can get the blur post-processes using getBlurVPostProcess or getBlurHPostProcess and modify the blur width and/or direction etc Quote Link to comment Share on other sites More sharing options...
julien-moreau Posted March 17, 2015 Share Posted March 17, 2015 You can now set the SSAO radius and strength : https://github.com/BabylonJS/Babylon.js/blob/master/Babylon/PostProcess/babylon.ssaoRenderingPipeline.ts Vousk-prod. 1 Quote Link to comment Share on other sites More sharing options...
Vousk-prod. Posted March 17, 2015 Author Share Posted March 17, 2015 Ooh that's so coool. Thanks! Quote Link to comment Share on other sites More sharing options...
Vousk-prod. Posted March 17, 2015 Author Share Posted March 17, 2015 Hmm, don't know if your change has already been sent to the PG, but the SSAO is now a bit strange there...http://www.babylonjs-playground.com/?24 It's not acting as SSAO anymore... Quote Link to comment Share on other sites More sharing options...
julien-moreau Posted March 17, 2015 Share Posted March 17, 2015 Oh, I think it wasn't. I just fixed an issue on SSAO shader yesterday and my result at home is good todayI'll ask Deltakosh to update the PG file and repair my fault ^^ Quote Link to comment Share on other sites More sharing options...
Vousk-prod. Posted March 17, 2015 Author Share Posted March 17, 2015 ah ok Quote Link to comment Share on other sites More sharing options...
julien-moreau Posted March 19, 2015 Share Posted March 19, 2015 Deltakosh repaired ! You can see the result in the playground. To modify the strength, change the value of "ssao.totalStrength". The default value is 1.0You can also change other values like "radius", "area", etc. I'll write an article on how to customize SSAO and I'll share you Quote Link to comment Share on other sites More sharing options...
Vousk-prod. Posted March 19, 2015 Author Share Posted March 19, 2015 Woaaah good news!We now have usual SSAO params to play with! Thanks Luaacro. Quote Link to comment Share on other sites More sharing options...
Vousk-prod. Posted October 21, 2015 Author Share Posted October 21, 2015 Hm, I saw many thing to discuss in the SSAO post effect. I'll send you a PM Luaacro. julien-moreau 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.