Managed C# graphics libraries for .NET

  • Thread starter Nicholas Witchey
  • Start date
N

Nicholas Witchey

Does anyone know of a set of graphics libraries written
in C#?

My goal is to create a set of graphics images in memory then
dump them to a file or network stream in any format. Unfortunately
the System.Drawing classes all resolve down to calls in gdiplus.dll
which are implemented natively. Basically, I would like to use
the System.Drawing namespace, classes, and methods to manipulate
bitmaps in memory but not have any fundamental platform dependencies.
The images will never be displayed locally (i.e. they will be served
up from a web server).

I am aware of the following open source projects:

Mono
DotGnu
Portable DotGnu

These seems to all target some graphics platform such as OpenGL, SDL,
and so forth. Mono uses Cairo and maybe that would work.

The library must be written completely in managed code and not
have any platform dependencies. Execution speed is not an issue
since the images will be small.

Thanks in advance!

Nick
 
R

Rob Teixeira [MVP]

All the open source projects you mentioned also use a native library for
graphics.
None have a completely managed graphics solution, AFAIK.
You could build your own, but what's the point? What are you trying to
accomplish here?

-Rob Teixeira [MVP]
 
D

Dmitriy Lapshin [C# / .NET MVP]

Nicholas,

System.Drawing calls do use GDI+ behind the scenes, but only on Windows and
most likely only in the Microsoft implementation of the .NET Framework. I
think Mono uses what's appropriate for systems it is running on (Cairo as
you have said), but you still can use the same high-level System.Drawing
functionality, provided that Mono, DotGnu or whichever implementation you
choose has complete support for the System.Drawing namespace.

In other words - the System.Drawing namespace contains high-level classes
and interfaces. Users of the classes and the interfaces are actually
insulated from the concrete implementation and should, in general, make no
assumptions of the implementation. It's the underlying framework's task to
map these high-level calls to calls to the low-level graphics engine, be it
Windows GDI, OpenGL, Cairo or whatever.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top