mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-02-17 13:43:48 +00:00
Org rework and postFX-setup WIP
This commit is contained in:
commit
ecad33c598
4 changed files with 169 additions and 49 deletions
|
|
@ -48,6 +48,10 @@
|
|||
#include "postFx/postEffectCommon.h"
|
||||
#endif
|
||||
|
||||
static U32 MAXPROBECOUNT = 50;
|
||||
|
||||
class PostEffect;
|
||||
|
||||
struct ProbeRenderInst : public SystemInterface<ProbeRenderInst>
|
||||
{
|
||||
LinearColorF mAmbient;
|
||||
|
|
@ -229,6 +233,17 @@ class RenderProbeMgr : public RenderBinManager
|
|||
|
||||
MaterialParameterHandle *probeCount;
|
||||
|
||||
//
|
||||
MaterialParameterHandle *numProbesSC;
|
||||
|
||||
MaterialParameterHandle *probePositionSC;
|
||||
MaterialParameterHandle *probeWorldToObjSC;
|
||||
MaterialParameterHandle *probeBBMinSC;
|
||||
MaterialParameterHandle *probeBBMaxSC;
|
||||
MaterialParameterHandle *probeUseSphereModeSC;
|
||||
MaterialParameterHandle *probeRadiusSC;
|
||||
MaterialParameterHandle *probeAttenuationSC;
|
||||
|
||||
ReflectProbeMaterialInfo(const String &matName, const GFXVertexFormat *vertexFormat);
|
||||
|
||||
virtual ~ReflectProbeMaterialInfo();
|
||||
|
|
@ -260,6 +275,13 @@ class RenderProbeMgr : public RenderBinManager
|
|||
GFXShaderRef mLastShader;
|
||||
ProbeShaderConstants* mLastConstants;
|
||||
|
||||
//
|
||||
//
|
||||
PostEffect* getProbeArrayEffect();
|
||||
|
||||
//
|
||||
SimObjectPtr<PostEffect> mProbeArrayEffect;
|
||||
|
||||
protected:
|
||||
|
||||
/// The current active light manager.
|
||||
|
|
@ -282,11 +304,27 @@ protected:
|
|||
GFXShaderConstBuffer *shaderConsts);
|
||||
|
||||
GFXTextureObject * mBrdfTexture;
|
||||
|
||||
//Array rendering
|
||||
|
||||
Vector<Point3F> probePositions;
|
||||
Vector<MatrixF> probeWorldToObj;
|
||||
Vector<Point3F> probeBBMin;
|
||||
Vector<Point3F> probeBBMax;
|
||||
Vector<float> probeUseSphereMode;
|
||||
Vector<float> probeRadius;
|
||||
Vector<float> probeAttenuation;
|
||||
Vector<GFXCubemapHandle> cubeMaps;
|
||||
Vector<GFXCubemapHandle> irradMaps;
|
||||
|
||||
GFXCubemapArrayHandle mCubemapArray;
|
||||
GFXCubemapArrayHandle mIrradArray;
|
||||
public:
|
||||
RenderProbeMgr();
|
||||
RenderProbeMgr(RenderInstType riType, F32 renderOrder, F32 processAddOrder);
|
||||
|
||||
// RenderBinMgr
|
||||
void _setupStaticParameters();
|
||||
void _setupPerFrameParameters(const SceneRenderState *state);
|
||||
virtual void addElement(RenderInst *inst);
|
||||
virtual void render(SceneRenderState * state);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue