View Full Version : Gradient Background
07-06-2001, 05:34 AM
Hi. I am using Visual C++ and MFC (i'm too new to know if this matters) and would like to know if there is anyway to have a gradient background in an app without drawing a big gradient rectangle that fills my window...i know there is OGL code out there to do this, but this is not what i want...any suggestions?
07-06-2001, 05:40 AM
Uh, kind of a strange request. I believe most people on this board would likely only tell you the OpenGL way of doing it seeing as this is an OpenGL forum. But I can tell you that there is a way to do that in GDI as well, which you could use, assuming your app is not using double buffering.
[This message has been edited by DFrey (edited 07-06-2001).]
07-06-2001, 05:47 AM
thanks for your reply, DFrey
i'm sorry, i should clarify...it's not that i don't want to use OpenGL to do this...i am just wondering if there is another way, using OpenGL, to create a gradient background with out drawing a big polygon...i only mentioned VC++ and MFC just in case there is no way to accomplish this using OpenGL
07-06-2001, 06:01 AM
The only other way to draw a gradient background using OpenGL, that I can think of offhand, is to draw a gradient bitmap using glDrawPixels, but that is going to be a whole lot slower (and more complex) than just drawing the rectangle.
Powered by vBulletin® Version 4.2.3 Copyright © 2016 vBulletin Solutions, Inc. All rights reserved.