Top.Mail.Ru
The C++ Community's Journal -- Day
? ?
The C++ Community's Journal -- Day [entries|friends|calendar]
The C++ Community

[ userinfo | livejournal userinfo ]
[ calendar | livejournal calendar ]

Anti-aliased vectors [16 Feb 2006|12:35am]
[ mood | Image confused ]

I seem to have gotten stuck in a quagmire: a problem that sounds simple keeps turning into unbounded complexity no matter which way I look.

I want to develop a GUI for some simple games — 2D, at most trivial animation, graphic rendering speed not a problem on modern PCs — that resizes as the window is resized. To do this without ugliness I need to be able to draw anti-aliased vector graphics.

I’m working in Windows, but I’d like to keep as much of my code as possible OS-independent, and I want to be able to [L]GPL the results. That would seem to make GDI+ a bad fit. I thought of defining the graphic elements as SVGs... but where is there a straightforward SVG renderer? OpenGL appears staggeringly complex, and looks like massive overkill. I keep searching for a simple way to render anti-aliased lines, arcs and Bézier curves and their enclosed regions to an in-storage bitmap (I’m pretty sure it would then be trivial to use that as DIB-section data in Windows), but I’m just not finding it. Everything I come across is extraordinarily complicated, involves multiple strange support libraries and/or isn’t [L]GPL-friendly.

Does anyone have any suggestions? Do I just bite the bullet and figure out how to swat this fly with the sledgehammer of OpenGL? do I write an anti-aliased curve/region renderer from scratch (that sounds like it could be many months’ work in and of itself)? or is there a better way?

18 comments|post comment

navigation
[ viewing | February 16th, 2006 ]
[ go | previous day|next day ]
Image