I'm not a member of the fanclub for these prefixes in the enums, I think they obfuscate and clutter the simplicity of the engine:
Code:
struct ParticleEffectResData
{
/* Enum: ParticleEffectResData
The available ParticleEffect resource accessors.
E_ParticleEffect - General particle configuration
E_ChanMoveVel - Velocity channel
E_ChanRotVel - Angular velocity channel
E_ChanSize - Size channel
E_ChanColR - Red color component channel
E_ChanColG - Green color component channel
E_ChanColB - Blue color component channel
E_ChanColA - Alpha channel
PF_ParticleLifeMin - Minimum value of random life time (in seconds)
PF_ParticleLifeMax - Maximum value of random life time (in seconds)
PF_ChanStartMin - Minimum for selecting initial random value of channel
PF_ChanStartMax - Maximum for selecting initial random value of channel
PF_ChanEndRate - Remaining percentage of initial value when particle is dying
*/
enum List
{
E_ParticleEffect = 800,
E_ChanMoveVel,
E_ChanRotVel,
E_ChanSize,
E_ChanColR,
E_ChanColG,
E_ChanColB,
E_ChanColA,
PF_ParticleLifeMin,
PF_ParticleLifeMax,
PF_ChanStartMin,
PF_ChanStartMax,
PF_ChanEndRate
};
};
My suggestion would be to split it up:
Code:
struct ParticleEffectResElems
{
/* Enum: ParticleEffectResElems
The available ParticleEffect resource accessors.
ParticleEffect - General particle configuration
ChanMoveVel - Velocity channel
ChanRotVel - Angular velocity channel
ChanSize - Size channel
ChanColR - Red color component channel
ChanColG - Green color component channel
ChanColB - Blue color component channel
ChanColA - Alpha channel
*/
enum List
{
ParticleEffect = 800,
ChanMoveVel,
ChanRotVel,
ChanSize,
ChanColR,
ChanColG,
ChanColB,
ChanColA,
};
};
struct ParticleEffectResParams
{
/* Enum: ParticleEffectResParams
The available ParticleEffect resource accessors.
ParticleLifeMin - Minimum value of random life time (in seconds)
ParticleLifeMax - Maximum value of random life time (in seconds)
ChanStartMin - Minimum for selecting initial random value of channel
ChanStartMax - Maximum for selecting initial random value of channel
ChanEndRate - Remaining percentage of initial value when particle is dying
*/
enum List
{
ParticleLifeMin = 808,
ParticleLifeMax,
ChanStartMin,
ChanStartMax,
ChanEndRate
};
};
But I really think these enums should be changed to defines or consts altogether, some languages don't support enums so a binding needs
to define all these values as constants anyway.
I would rather see a more traditional:
#define H3D_ParticleEffectResElems_ParticleEffect 800
#define H3D_ParticleEffectResElems_ChanMoveVel 801
...
or even
const int h3d_ParticleEffectResElems_ParticleEffect = 800;
const int h3d_ParticleEffectResElems_ChanMoveVel = 801;
...