Esempio n. 1
0
        public void Update(IPluginIO pin, DX11RenderContext context)
        {
            if (generator == null)
            {
                generator = new TextureArraySetSlice(context);
            }

            if (this.FTexIn.PluginIO.IsConnected)
            {
                if (this.FReset[0])
                {
                    generator.Reset(this.FTexIn[0][context], this.Width[0], this.Height[0], this.Depth[0], this.Format[0]);
                    this.FOutTB[0][context] = generator.Result;
                }
                else if (this.FWrite[0])
                {
                    generator.Apply(this.FTexIn[0][context], this.Width[0], this.Height[0], this.Depth[0], this.Format[0], this.FSliceIndex[0]);
                    this.FOutTB[0][context] = generator.Result;
                }
            }
        }