Create a scrolling wave form that has a low overhead (WPF)
Huge bitmaps are not accepted by Image.Source Smaller (but still very big bitmaps) are accepted but overall UX is terrible.
Memory conservation Scrolling must be at 60fps
Problems encountered :
Used GPU memory amount is insane ! (400 to 800 Mb each 10 seconds)
So here's what I did :
I am rendering that bitmap through an Image.Source that I created with Imaging.CreateBitmapSourceFromMemorySection (which type is InteropBitmap).
I have loaded that big bitmap in memory and every time I need to update, I do a CopyMemory then I do InteropBitmap.Invalidate(), so far it's perfect and performance is excellent.
That particular type of BitmapSource is said to be the fastest, and it is actually; but after some profiling, it litterally eats GPU memory, as said above.
It seems that InteropBitmap never recycles GPU memory, or caches it, I don't know...
On my Win7 x64 machine, I have 4Gb of which up to 1.5Gb can be used by the GPU. (Laptop is a Thinkpad T61p with dual-core at 2.5Ghz and a Quadro FX570M with 256Mb)
My first and safer solution was to use a WriteableBitmap which works good but no 60 fps here,
What do you suggest ?
Shall I go WinForms for required performance ?
Thanks for your help !
View Complete Post