mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-03-06 14:00:39 +00:00
commit
0f8d4d30ab
6 changed files with 2 additions and 35 deletions
|
|
@ -82,13 +82,6 @@ const F32 ScatterSky::smEarthRadius = (6378.0f * 1000.0f);
|
|||
const F32 ScatterSky::smAtmosphereRadius = 200000.0f;
|
||||
const F32 ScatterSky::smViewerHeight = 1.0f;
|
||||
|
||||
GFXImplementVertexFormat( ScatterSkyVertex )
|
||||
{
|
||||
addElement( "POSITION", GFXDeclType_Float3 );
|
||||
addElement( "NORMAL", GFXDeclType_Float3 );
|
||||
addElement( "COLOR", GFXDeclType_Color );
|
||||
}
|
||||
|
||||
ScatterSky::ScatterSky()
|
||||
{
|
||||
mPrimCount = 0;
|
||||
|
|
@ -761,7 +754,7 @@ void ScatterSky::_initVBIB()
|
|||
F32 zOffset = -( mCos( mSqrt( 1.0f ) ) + 0.01f );
|
||||
|
||||
mVB.set( GFX, mVertCount, GFXBufferTypeStatic );
|
||||
ScatterSkyVertex *pVert = mVB.lock();
|
||||
GFXVertexP *pVert = mVB.lock();
|
||||
if(!pVert) return;
|
||||
|
||||
for ( U32 y = 0; y < vertStride; y++ )
|
||||
|
|
|
|||
|
|
@ -57,14 +57,6 @@ class TimeOfDay;
|
|||
class CubemapData;
|
||||
class MatrixSet;
|
||||
|
||||
|
||||
GFXDeclareVertexFormat( ScatterSkyVertex )
|
||||
{
|
||||
Point3F point;
|
||||
VectorF normal;
|
||||
GFXVertexColor color;
|
||||
};
|
||||
|
||||
class ScatterSky : public SceneObject, public ISceneLight
|
||||
{
|
||||
typedef SceneObject Parent;
|
||||
|
|
@ -228,7 +220,7 @@ protected:
|
|||
|
||||
// Prim buffer, vertex buffer and shader for rendering.
|
||||
GFXPrimitiveBufferHandle mPrimBuffer;
|
||||
GFXVertexBufferHandle<ScatterSkyVertex> mVB;
|
||||
GFXVertexBufferHandle<GFXVertexP> mVB;
|
||||
GFXShaderRef mShader;
|
||||
|
||||
GFXStateBlockRef mStateBlock;
|
||||
|
|
|
|||
|
|
@ -36,14 +36,9 @@ float vernierScale(float fCos)
|
|||
}
|
||||
|
||||
in vec4 vPosition;
|
||||
in vec3 vNormal;
|
||||
in vec4 vColor;
|
||||
in vec2 vTexCoord0;
|
||||
|
||||
// This is the shader input vertex structure.
|
||||
#define IN_position vPosition
|
||||
#define IN_normal vNormal
|
||||
#define IN_color vColor
|
||||
|
||||
// This is the shader output data.
|
||||
out vec4 rayleighColor;
|
||||
|
|
|
|||
|
|
@ -39,10 +39,6 @@ struct Vert
|
|||
{
|
||||
// .xyz = point
|
||||
float4 position : POSITION;
|
||||
|
||||
float3 normal : NORMAL;
|
||||
|
||||
float4 color : TEXCOORD0;
|
||||
};
|
||||
|
||||
// This is the shader output data.
|
||||
|
|
|
|||
|
|
@ -36,14 +36,9 @@ float vernierScale(float fCos)
|
|||
}
|
||||
|
||||
in vec4 vPosition;
|
||||
in vec3 vNormal;
|
||||
in vec4 vColor;
|
||||
in vec2 vTexCoord0;
|
||||
|
||||
// This is the shader input vertex structure.
|
||||
#define IN_position vPosition
|
||||
#define IN_normal vNormal
|
||||
#define IN_color vColor
|
||||
|
||||
// This is the shader output data.
|
||||
out vec4 rayleighColor;
|
||||
|
|
|
|||
|
|
@ -39,10 +39,6 @@ struct Vert
|
|||
{
|
||||
// .xyz = point
|
||||
float4 position : POSITION;
|
||||
|
||||
float3 normal : NORMAL;
|
||||
|
||||
float4 color : TEXCOORD0;
|
||||
};
|
||||
|
||||
// This is the shader output data.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue