Page 1 of 1

Fastest interop with GDI?

PostPosted: Jan 7, 2009 @ 10:18pm
by Narin
What's the best way to combine GapiDraw and GDI? I have to use GDI to do some things like drawing text.

Right now I'm creating surfaces with the default settings and using GetDC to "ship" my surface to GDI and draw on it, then ReleaseDC when finished. This is pretty slow when drawing onto large surfaces (say 480x480 pixels). All my "final" compositing is done using GapiDraw and GapiDraw owns the final back buffer.

What's really happening when calling GetDC? Do GapiDraw surfaces live in a totally different spot than GDI surfaces? And copying back and forth is always slow?

I've tried telling my surfaces to live in system memory vs. video memory but it doesn't make any difference (and I don't fully understand the difference).

PostPosted: Jan 9, 2009 @ 8:38am
by Johan

PostPosted: Jan 11, 2009 @ 12:23am
by Narin

PostPosted: Jan 11, 2009 @ 4:11am
by Narin

PostPosted: Jan 11, 2009 @ 7:18pm
by Johan