Re: XForms: Blit to a glCanvas.

Steve Lamont (spl@szechuan.ucsd.edu)
Tue, 10 Nov 98 12:11:06 PST

# To subscribers of the xforms list from spl@szechuan.ucsd.edu (Steve Lamont) :

> I would like to ask to the users of OpenGL if anybody knows a fast way to
> blit (copy) an image from memory to the glCanvas. I have tried with the
> glDrawPixels function but i found it is as slow as doing a double 'for'
> and drawing each pixel independently! I think there must be a better way
> since the swapping of the buffers is done instantly, and I think that's
> basically the same principle, isn't it?

Yes, OpenGL's glDrawPixels() reeks to high heaven.

What I do is to texture map the image onto a rectangle and draw the
rectangle. This speeds things up considerably.

OpenGL is terrible for pushing pixels, IMHO.

spl
_________________________________________________
To unsubscribe, send the message "unsubscribe" to
xforms-request@bob.usuf2.usuhs.mil or see
http://bob.usuf2.usuhs.mil/mailserv/xforms.html
XForms Home Page: http://bragg.phys.uwm.edu/xforms
List Archive: http://bob.usuf2.usuhs.mil/mailserv/list-archives/