The title speaks for itself... I've tried to find another question like it but must have missed it if it exists. I'm looking for anything, from a core library replacing GAPI to a .net wrapper... It's for building a nice UI so no 3D needed...
-
The System.Drawing classes in .NET are a lot more powerful than people realize. The only thing missing (which is actually really important in 2D graphics) is the ability to read and write individual pixels. This is technically possible using the GetPixel and SetPixel methods on the Bitmap object, but these methods are unimaginably slow.
Fortunately, there is a super-fast alternative that you can implement by calling LockBits on a bitmap and then accessing the bitmap's byte data directly. I've used this to good effect. In fact, I've spent the last week creating a fisheye lens effect entirely in .NET (no libraries or PInvoke calls at all).
This JPEG is kind of crappy, but it shows what's possible using just .NET:
-
IMO I would suggest getting hold of the frame buffer somehow and drawing to it directly if possible or using D3DM or use the drawing services provided by the Native Platform (GDI) through APIs like DrawGradient() etc from coredll.dll and since you are on WM you might be able to leverage aygshell.dll to draw widgets.
Here are some links...
1)Using gradient fill from dot net
2)Using gradient fill directly
3)Other native GDI functions -
Take a look at WMGL http://www.mobilityflow.com/products/wmgl/
0 comments:
Post a Comment