What is the easiest way to draw simple graphics using F# ?
I want to visualize a dynamic system (a simplified sample of my use case would be a red square going from one side of the screen to the other at a speed of one pixel per frame) so I need a way to draw simple geometric shapes.
As I will update the picture on a regular basis, a mechanism to avoid flickering will probably be needed.
The standard solution appears to be System.Drawing
.
I put together a working solution but the code is overly complex (it seems to require System.Windows.Forms
, is there no direct way to put graphics in a windows ?), not great for a simple task, which led me to think that a better tool probably exists.
Am I doing something wrong, is there a simple way to draw and update pictures with System.Drawing
? Or is there a library out there that better fits my needs ?
System.Drawing
is platform dependent element. But most likely you can get rid of the flicker. – Heathen