示例#1
0
        private void Update(EvaluationContext context)
        {
            // This will execute the input
            if (!IsEnabled.GetValue(context))
            {
                UpdateCommand.DirtyFlag.Clear();
                BufferWithViews.DirtyFlag.Clear();
                return;
            }

            UpdateCommand.GetValue(context);
            Output2.Value = BufferWithViews.GetValue(context);
        }
        private void Update(EvaluationContext context)
        {
            var bufferWithViews = BufferWithViews.GetValue(context);

            if (bufferWithViews != null)
            {
                Buffer.Value              = bufferWithViews.Buffer;
                ShaderResourceView.Value  = bufferWithViews.Srv;
                UnorderedAccessView.Value = bufferWithViews.Uav;
            }
            else
            {
                Buffer.Value              = null;
                ShaderResourceView.Value  = null;
                UnorderedAccessView.Value = null;
            }
        }