示例#1
0
        void listBox1_SelectedIndexChanged(object sender, EventArgs e)
        {
            if (listBox1.SelectedIndex == -1)
            {
                return;
            }

            if (shaderRenderer1.shader != null)
            {
                shaderRenderer1.OnStop += shaderRenderer1_OnStop;
                ShaderRenderer.Stop();
            }
            else
            {
                shaderRenderer1_OnStop(sender, e);
            }
        }
示例#2
0
        protected override void OnClosing(CancelEventArgs e)
        {
            base.OnClosing(e);

            ShaderRenderer.Stop();
        }