Sign in to follow this  
Boemer

Vector Drawing

Recommended Posts

Hello everyone, I was just wondering what you people are using, when you want to draw on textures or surfaces? I'm doing something like WPF (the vector part, not the xml part), but I can't use WPF, because of the missing vsync. And the extreme resource hunger. They say it works in very well in Windows 7, but it will be atleast a few years before manybe people are using it... I'm using gdi+ at the moment to draw on textures/surfaces using a Graphics instance (.NET), but it isn't that fast, you can't use it to draw 30 or 60 frames/sec. I was thinking if it was possible to use Qt, because they say they have very fast drawing routines. Xara Xtreme also says they are much faster that Gdi, but it is a drawing program, don't know if it is possible to use the drawing engine for something else. Any other suggestions? I need fonts, animation, 2d graphics (lines, shapes, etc), anti-aliasing, the usual...

Share this post


Link to post
Share on other sites
Since you posted in the DirectX forum, I would suggest you use D3D. With hardware support, you can draw very fast. Or are you looking for something more high-level? All the features you need can certainly be implemented with D3D in an efficient manner.

Share this post


Link to post
Share on other sites
Quote:
Original post by B_old
Since you posted in the DirectX forum, I would suggest you use D3D. With hardware support, you can draw very fast. Or are you looking for something more high-level? All the features you need can certainly be implemented with D3D in an efficient manner.


I'm using DirectX (SlimDX), but the most I see people doing is using some Vectors and put an image on it. The Problem is I can't make images before the program is started.

So I'm looking at some library/routines/ideas, with which I can make rectangles / circles / triangles stars, other polygons etc, fill them with some color (transparency / from one color to an other), give them a nice border.

I know these things are possible with gdi, or with wpf. One Problem is, when I draw it with gdi on a texture, I can move the texture at 60frames a second from one place to another, and it looks very good. But I can't change the texture, at least not 60 times a second. With gdi I can manage something like 10-20 frames, depending on how complex it is.

I can't use wpf, because of the missing vsync, memory leaks and huge resource demandings.

I was wondering what people use to do such things, would you just use a vectorbuffer draw the polygon with lets say 100 points, draw it twice one for the contents one for the border ?

If I make a routine myself, it won't have hardware acceleration, making it very fast just as slow as gdi...

Any hints? or examples, where should I look for something like that?

Share this post


Link to post
Share on other sites
Quote:
Original post by Boemer
I was wondering what people use to do such things, would you just use a vectorbuffer draw the polygon with lets say 100 points, draw it twice one for the contents one for the border ?

That's how I would do it. At least if I understand the problem you're trying to solve. It should be pretty fast, too.
Why would you like to change the texture 60 times per second? I guess you probably wouldn't be able to see anything.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this