Game Development Community

T3D 1.1 Beta 3 - Additive Particle issue - LOGGED

by Daniel Eden · in Torque 3D Professional · 09/22/2010 (11:42 pm) · 5 replies

I'm having a few issues getting the particle effects working properly in my game. Whenever the particles are set to use additive blending, they don't seem to render properly against objects in the fore and middle grounds.

Around the 0:05 to 0:06 mark on this video you can see the issue in action: the thruster particle effects aren't really visible in front of the models, terrain, or the like -- but render fine against the scattersky.



Using the default particle datablocks in the beta 3 FPS demo, I get identical results. The following screenshots pretty much sum it up -- over buildings and so on in the foreground, the particles with additive blending become so faint they're almost invisible -- but against objects in the background they render fine.


www.cockhat.com/deden/screen0.jpgwww.cockhat.com/deden/screen1.jpgwww.cockhat.com/deden/screen2.jpg

Am I missing something here? Do I have the wrong handle on how additive blending should be working?

Here's the datablocks from script that are being used. They look fine to me...

datablock ParticleData(DefaultParticle)
{
   textureName = "core/art/defaultParticle";
   dragCoeffiecient = 0;
   gravityCoefficient = 0;
   inheritedVelFactor = 0.499022;
   constantAcceleration = 0.0;
   lifetimeMS = 1313;
   lifetimeVarianceMS = 1312;
   useInvAlpha = true;
   spinRandomMin = -360;
   spinRandomMax = 360;
   spinSpeed = 1;

   colors[0] = "0.992126 0.00787402 0.0314961 1";
   colors[1] = "1 0.834646 0 0.645669";
   colors[2] = "1 0.299213 0 0.330709";
   colors[3] = "0.732283 1 0 0";
   
   sizes[0] = 0;
   sizes[1] = 0.497467;
   sizes[2] = 0.73857;
   sizes[3] = 0.997986;
   
   times[0] = 0.0;
   times[1] = 0.247059;
   times[2] = 0.494118;
   times[3] = 1;
   
   animTexName = "core/art/defaultParticle";
   
   dragCoefficient = "0.498534";
};

datablock ParticleEmitterData(DefaultEmitter)
{
   ejectionPeriodMS = "50";
   ejectionVelocity = "1";
   velocityVariance = "0";
   ejectionOffset = "0.2";
   thetaMax = "40";
   particles = "DefaultParticle";
   blendStyle = "ADDITIVE";
   softParticles = "0";
   softnessDistance = "1000";
};

#1
09/23/2010 (4:31 pm)
That definitely looks like an issue...
In the case of the building it almost looks like they're behind the building...

Is this an advanced lighting issue possibly? Something with the way the transparencies are handled vs. the deferred rendering on the buildings/terrains (whereas the sky isn't lit)? Can you set your game to run in basic lighting and see if it's better or the same?

#2
09/23/2010 (8:42 pm)
Just had a run through with basic lighting and I couldn't get it to happen. So... Looks like it's a transparency issue of some kind. It's not really high on my list of things to look into, but I thought I'd mention it and see if anyone has some quick and easy fix.
#3
09/24/2010 (2:17 am)
Softness Distance shouldn't be that high ... but for some reason it's all coming out like that --- I think if it's set to zero it doesn't seem to show up if it's Additive.

Turn Softness Distance to 1.
Never have it set to 1000 it murders performance (not sure why it's setting itself to 1000).

Also put this thread in the 1.1.beta3 bug forum cos it's not right now and so might get missed for a QA logging.
#4
09/29/2010 (6:28 am)
From the looks of it, setting it much lower alleviates much of the problem. There's still occasional bits where it doesn't seem to render properly, but they're few and far between.

The 0-1000 range in the particle editor seems to be a result of the
"PEE_softnessDistance_slider" gui control having its range set that way.
#5
09/29/2010 (6:30 pm)
Bug Posted as TQA-1155