public SpriteEffect(GraphicsDevice graphicsDevice) : base( graphicsDevice, "SpriteVS", "SpritePS", null, CreatePipelineLayoutDescription()) { _textureConstantBuffer = DynamicBuffer <TextureConstants> .Create(graphicsDevice, BufferUsageFlags.ConstantBuffer); }
public ParticleEffect(GraphicsDevice graphicsDevice) : base( graphicsDevice, "ParticleVS", "ParticlePS", CreateVertexDescriptor(), CreatePipelineLayoutDescription()) { _transformConstantBuffer = DynamicBuffer <ParticleTransformConstants> .Create(graphicsDevice, BufferUsageFlags.ConstantBuffer); }
public TerrainEffect(GraphicsDevice graphicsDevice, int numTextures) : base( graphicsDevice, "TerrainVS", "TerrainPS", CreateVertexDescriptor(), CreatePipelineLayoutDescription(numTextures)) { _transformConstantBuffer = AddDisposable(DynamicBuffer <TransformConstants> .Create(graphicsDevice, BufferUsageFlags.ConstantBuffer)); _lightingConstantBuffer = AddDisposable(DynamicBuffer <LightingConstants> .Create(graphicsDevice, BufferUsageFlags.ConstantBuffer)); }
public MeshEffect(GraphicsDevice graphicsDevice) : base( graphicsDevice, "MeshVS", "MeshPS", CreateVertexDescriptor(), CreatePipelineLayoutDescription()) { _transformConstantBuffer = AddDisposable(DynamicBuffer <MeshTransformConstants> .Create(graphicsDevice, BufferUsageFlags.ConstantBuffer)); _lightingConstantBuffer = AddDisposable(DynamicBuffer <LightingConstants> .Create(graphicsDevice, BufferUsageFlags.ConstantBuffer)); _perDrawConstantBuffer = AddDisposable(DynamicBuffer <PerDrawConstants> .Create(graphicsDevice, BufferUsageFlags.ConstantBuffer)); }