(ded4a3e0a) v0.9.0.7
This commit is contained in:
@@ -0,0 +1,61 @@
|
||||
using Microsoft.Xna.Framework.Graphics;
|
||||
|
||||
namespace TwoMGFX
|
||||
{
|
||||
internal partial class ShaderData
|
||||
{
|
||||
public ShaderData(bool isVertexShader, int sharedIndex, byte[] bytecode)
|
||||
{
|
||||
IsVertexShader = isVertexShader;
|
||||
SharedIndex = sharedIndex;
|
||||
Bytecode = (byte[])bytecode.Clone();
|
||||
}
|
||||
|
||||
public bool IsVertexShader { get; private set; }
|
||||
|
||||
public struct Sampler
|
||||
{
|
||||
public MojoShader.MOJOSHADER_samplerType type;
|
||||
public int textureSlot;
|
||||
public int samplerSlot;
|
||||
public string samplerName;
|
||||
public string parameterName;
|
||||
public int parameter;
|
||||
public SamplerState state;
|
||||
}
|
||||
|
||||
public struct Attribute
|
||||
{
|
||||
public string name;
|
||||
public VertexElementUsage usage;
|
||||
public int index;
|
||||
#pragma warning disable 649
|
||||
public int location;
|
||||
#pragma warning restore 649
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// The index to the constant buffers which are
|
||||
/// required by this shader at runtime.
|
||||
/// </summary>
|
||||
public int[] _cbuffers;
|
||||
|
||||
public Sampler[] _samplers;
|
||||
|
||||
public Attribute[] _attributes;
|
||||
|
||||
public byte[] ShaderCode { get; set; }
|
||||
|
||||
|
||||
#region Non-Serialized Stuff
|
||||
|
||||
public byte[] Bytecode { get; private set; }
|
||||
|
||||
// The index of the shader in the shared list.
|
||||
public int SharedIndex { get; private set; }
|
||||
|
||||
#endregion // Non-Serialized Stuff
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user