Exemple #1
0
 private void OnBindMaterialTextures(DeviceContextProxy context, PixelShader shader)
 {
     if (shader.IsNULL)
     {
         return;
     }
     shader.BindTexture(context, texStripeXSlot, textures[0]);
     shader.BindTexture(context, texStripeYSlot, textures[1]);
     shader.BindSampler(context, samplerDiffuseSlot, sampler);
 }
            private void OnBindMaterialTextures(RenderContext context, DeviceContextProxy deviceContext, PixelShader shader)
            {
                if (shader.IsNULL)
                {
                    return;
                }
                var idx = shader.ShaderStageIndex;

                shader.BindTexture(deviceContext, texDiffuseSlot, textureResources[DiffuseIdx]);
                shader.BindTexture(deviceContext, texNormalSlot, textureResources[NormalIdx]);
                shader.BindTexture(deviceContext, texAlphaSlot, textureResources[AlphaIdx]);
                shader.BindTexture(deviceContext, texSpecularSlot, textureResources[SpecularColorIdx]);
                shader.BindTexture(deviceContext, texEmissiveSlot, textureResources[EmissiveIdx]);
                shader.BindSampler(deviceContext, samplerDiffuseSlot, surfaceSampler);
            }
Exemple #3
0
        private void BindBillboardTexture(DeviceContextProxy context, PixelShader shader)
        {
            var buffer = billboardBuffer;

            shader.BindTexture(context, shaderTextureSlot, buffer.TextureView);
            shader.BindSampler(context, textureSamplerSlot, textureSampler);
        }
Exemple #4
0
        private void OnBindMaterialTextures(RenderContext context, DeviceContextProxy deviceContext, PixelShader shader)
        {
            if (shader.IsNULL)
            {
                return;
            }
            int idx = shader.ShaderStageIndex;

            shader.BindTexture(deviceContext, texDiffuseSlot, TextureResources[DiffuseIdx]);
            shader.BindTexture(deviceContext, texNormalSlot, TextureResources[NormalIdx]);
            shader.BindTexture(deviceContext, texAlphaSlot, TextureResources[AlphaIdx]);

            shader.BindSampler(deviceContext, samplerDiffuseSlot, SamplerResources[DiffuseIdx]);
            shader.BindSampler(deviceContext, samplerNormalSlot, SamplerResources[NormalIdx]);
            shader.BindSampler(deviceContext, samplerAlphaSlot, SamplerResources[AlphaIdx]);
        }
        private void OnBindMaterialTextures(RenderContext context, DeviceContextProxy deviceContext, PixelShader shader)
        {
            if (shader.IsNULL)
            {
                return;
            }
            int idx = shader.ShaderStageIndex;

            shader.BindTexture(deviceContext, texDiffuseSlot, TextureResources[AlbedoMapIdx]);
            shader.BindTexture(deviceContext, texNormalSlot, TextureResources[NormalMapIdx]);
            shader.BindTexture(deviceContext, texRMASlot, TextureResources[RMAMapIdx]);
            shader.BindTexture(deviceContext, texEmissiveSlot, TextureResources[EmissiveMapIdx]);
            shader.BindTexture(deviceContext, texIrradianceSlot, TextureResources[IrradianceMapIdx]);

            shader.BindSampler(deviceContext, samplerSurfaceSlot, SamplerResources[SurfaceSamplerIdx]);
            shader.BindSampler(deviceContext, samplerIBLSlot, SamplerResources[IBLSamplerIdx]);
        }
            private void OnBindMaterialTextures(DeviceContextProxy context, PixelShader shader)
            {
                if (shader.IsNULL)
                {
                    return;
                }
                int idx = shader.ShaderStageIndex;

                shader.BindTexture(context, texDiffuseSlot, TextureResource);
                shader.BindSampler(context, samplerDiffuseSlot, SamplerResource);
            }