public override void SetDeclarations(ref ShaderVariables shaderVars)
        {
            Matrix3 rot = new Matrix3();

            rot.MakeFromRPY(_Rotation.x, _Rotation.y, _Rotation.z);
            mat3 glRot = rot.GetGLMat3();

            shaderVars.Add("fracScale" + _Iteration, _Scale);
            shaderVars.Add("fracRot" + _Iteration, glRot);
            shaderVars.Add("fracMinRad" + _Iteration, (float)_MinRadius);
        }
Example #2
0
        public override void SetDeclarations(ref ShaderVariables shaderVars)
        {
            Matrix3 preRot = new Matrix3();

            preRot.MakeFromRPY(_PreRotation.x, _PreRotation.y, _PreRotation.z);
            mat3    glPreRot = preRot.GetGLMat3();
            Matrix3 postRot  = new Matrix3();

            postRot.MakeFromRPY(_PostRotation.x, _PostRotation.y, _PostRotation.z);
            mat3 glPostRot = postRot.GetGLMat3();

            shaderVars.Add("fracScale" + _Iteration, (float)_Scale);
            shaderVars.Add("fracOffset" + _Iteration, _Offset);
            shaderVars.Add("fracPreRot" + _Iteration, glPreRot);
            shaderVars.Add("fracPostRot" + _Iteration, glPostRot);
        }