コード例 #1
0
 public void CopyToEffect(EffectTexture2D.Scalar2 dst, string name, XNAV2 defval)
 {
     dst.Texture   = UseChannelTexture(name);
     dst.Sampler   = UseChannelSampler(name);
     dst.Scale     = GetScaler(name, defval);
     dst.SetIndex  = GetTextureSet(name);
     dst.Transform = GetTransform(name);
 }
コード例 #2
0
 public PBRMetallicRoughnessEffect(GraphicsDevice device) : base(device, Resources.GetShaderByteCode("MetallicRoughnessEffect"))
 {
     _BaseColorMap      = new EffectTexture2D.Scalar4(device, this.Parameters, "Primary", 1);
     _MetalRoughnessMap = new EffectTexture2D.Scalar2(device, this.Parameters, "Secondary", 2);
 }