Page 1 of 1

Fuzzy, lit, 3d sphere mesh smoke/dust particles

PostPosted: Fri Jan 18, 2019 5:45 am
by JayExbl
Hi,
I'm trying to create a shader for sphere mesh particles, the end goal being fuzzy, illuminated, shaded, shadow receiving spherical mesh particles.

Managed to get this half working with the particle template, but the particles weren't lit by a directional light, didn't receive shadows, etc, so I'm guessing I need to use the standard template? Or somehow adjust the particle shader to receive light and shadow?

My attempt with the standard shader was foiled as I couldn't get the fuzzy edge working for each sphere particle mesh.
I'm guessing I'd need to apply a fresnel-like gradient to each particle sphere in screen space? So essentially how the fresnel shader usually works for a sphere object, but in my case I'd like the fresnel on each sphere mesh particle.

Hope that made sense! Not sure where to start! Would appreciate any help.

Regards,
Jay

Re: Fuzzy, lit, 3d sphere mesh smoke/dust particles

PostPosted: Fri Jan 18, 2019 2:21 pm
by Amplify_Borba
Hello, thank you for getting in touch and for your support!

The Particle template does not support lighting as is and its meant to be used with quads rather that geometry, you'd have to create a custom template for this although that would require advanced shader knowledge.

Alternatively, you could use the Standard shader in order to take advantage of its lighting calculations, which was a correct assumption.

Regarding the specific effect you want to create, I would require more information in order to best help you, a screenshot or video of what you're envisioning would be perfect.

Re: Fuzzy, lit, 3d sphere mesh smoke/dust particles

PostPosted: Mon Jan 21, 2019 4:45 am
by JayExbl
I've actually managed to get some pretty nice looking lit, dithered smoke particles using Transparent Cutout/Alpha Test shader, which casts/receives shadows. Just can't use any kinda soft particles if I wanna keep shadow receiving which is a shame.

I now have a new problem, which is that I can only see my particles in-game if the scene view is looking at the particle emitter. Any idea why that might be?

*Edit If I make the particles Always Simulate, that fixes it... Not sure if this is a shader issue or not?

Thank you.

Re: Fuzzy, lit, 3d sphere mesh smoke/dust particles

PostPosted: Thu Jan 24, 2019 3:05 pm
by Amplify_Borba
I'm not entirely sure as I can't seem to replicate that behavior myself.

Does it also happen with a newly created particle system with its standard material and settings as well?