Exemplo n.º 1
0
        public static void ChangeActiveShader(Type shaderType, IShader shader)
        {
            ShaderInOutMap[] inoutMaps = ShaderInterpreter <TStage> .GetInterpretedInOut(shaderType);

            Instance._currentInputMap  = inoutMaps[0];
            Instance._currentOutputMap = inoutMaps[1];

            Instance._currentShader = (TStage)shader;
        }
Exemplo n.º 2
0
        public static void ChangeActiveShader(Type shaderType, IShader shader)
        {
            if (_activeShaderType == shaderType)
            {
                return;
            }

            SubPatternStruct <TPattern>[] inout = ShaderInterpreter <TStage, TPattern> .GetInterpretedInOut(shaderType);

            ActiveInputMap    = inout[0];
            ActiveOutputMap   = inout[1];
            _activeShader     = (TStage)shader;
            _activeShaderType = shaderType;
        }