Sign in to follow this  
Lary

Particle invisible in white background

Recommended Posts

Hi all,

How I can make particles (in red color) visible with white background (scene.clearColor = new BABYLON.Color4(1,1,1,1))?

Please find attached picture for details.

Thanks in advance.

particle.png.4fcbd03621c7a642981dd0c12a8c3c92.png

 

Share this post


Link to post
Share on other sites

If you are using shapes, you could set the blend mode to standard:

particleSystem.blendMode = BABYLON.ParticleSystem.BLENDMODE_STANDARD;

As you will probably see, the behavior is different when setting the blend mode, but it will work with white background

Share this post


Link to post
Share on other sites
2 minutes ago, RaananW said:

If you are using shapes, you could set the blend mode to standard:

particleSystem.blendMode = BABYLON.ParticleSystem.BLENDMODE_STANDARD;

As you will probably see, the behavior is different when setting the blend mode, but it will work with white background

Thank you so much RaananW, it works!!! But the particle color seems bit different under the two modes.

Share this post


Link to post
Share on other sites

yep, a different blend mode deals with transparency a bit different. if you use an image it will look very weird, but with a shape it is somehow acceptable. Maybe someone else has a better suggestion :)

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.