I've subclassed Canvas
so that I can override its Render
function. I need to know how I can load a bitmap in WPF and render that to the canvas. I'm completely new to WPF and I haven't found any tutorials that show you how to do something so seemingly trivial. Step-by-step instructions with examples would be great.
In WPF it is a rare case that you would need to override OnRender
especially if all you wanted to do was draw a BMP to a background:
<Canvas>
<Canvas.Background>
<ImageBrush ImageSource="Resources\background.bmp" />
</Canvas.Background>
<!-- ... -->
</Canvas>