Paradox Game Engine  v1.0.0 beta06
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Events Macros Pages
EffectParameterResourceBinding.cs
Go to the documentation of this file.
1 // Copyright (c) 2014 Silicon Studio Corp. (http://siliconstudio.co.jp)
2 // This file is distributed under GPL v3. See LICENSE.md for details.
3 using System;
4 using SiliconStudio.Paradox.Shaders;
5 
6 namespace SiliconStudio.Paradox.Graphics.Internals
7 {
8  internal struct EffectParameterResourceBinding
9  {
10  public delegate void ApplyParameterWithUpdaterDelegate(GraphicsDevice graphicsDevice, ref EffectParameterResourceData resourceBinding, ShaderParameterUpdater updater);
11 
12  public delegate void ApplyParameterFromValueDelegate(GraphicsDevice graphicsDevice, ref EffectParameterResourceData resourceBinding, object value);
13 
14  public EffectParameterResourceData Description;
15 
16  public ApplyParameterWithUpdaterDelegate ApplyParameterWithUpdater;
17 
18  public ApplyParameterFromValueDelegate ApplyParameterDirect;
19 
20  public void ApplyParameter<T>(GraphicsDevice graphicsDevice, T value)
21  {
22  ApplyParameterDirect(graphicsDevice, ref Description, value);
23  }
24  }
25 }
Describes a shader parameter for a resource type.