Shows how to implement a reaction-diffusion simulation by using WPF and the WriteableBitmap class.
For details, see Using WriteableBitmap to Display a Procedural Texture.
- The ReactionDiffusionControl is a XAML control that uses WriteableBitmap to render a dynamic texture. In a real-world app, you should probably prefer writing an HLSL shader, which runs on the GPU and is immensely faster.
- The off-thread work is performed by a BackgroundWorker instance. Although this works fine, it's an archaic way to do asynchronous operations. Nowadays, you should prefer using the async and await keywords. See Asynchronous programming (Windows Runtime apps) for details.