Click here to Skip to main content
15,889,096 members
Home / Discussions / Graphics
   

Graphics

 
QuestionHow to use OnPaint() ??? :( Pin
Chintan.Desai5-Jun-07 21:28
Chintan.Desai5-Jun-07 21:28 
AnswerRe: How to use OnPaint() ??? :( Pin
Mark Salsbery6-Jun-07 6:29
Mark Salsbery6-Jun-07 6:29 
QuestionOpenGL slection/picking(mouse based) HEELP? Pin
Raza56805-Jun-07 5:18
Raza56805-Jun-07 5:18 
AnswerRe: OpenGL slection/picking(mouse based) HEELP? Pin
XTAL2565-Jun-07 19:07
XTAL2565-Jun-07 19:07 
GeneralRe: OpenGL slection/picking(mouse based) HEELP? Pin
tomitron21-Jun-07 5:57
tomitron21-Jun-07 5:57 
QuestionVideo encoder suggestion Pin
C. Tam4-Jun-07 15:12
C. Tam4-Jun-07 15:12 
QuestionVirtual camera recommendation Pin
C. Tam4-Jun-07 14:58
C. Tam4-Jun-07 14:58 
QuestionOpenGL alpha transparency Pin
XTAL2564-Jun-07 14:08
XTAL2564-Jun-07 14:08 
Until now i used the blend function glBlendFunc(GL_SRC_ALPHA,GL_ONE) to use transparency. But the problem with that is that although it blends black with the background to make it transparent it also blends all colours. That is, it adds the colour with the background colour so black becomes transparent but red blended with green(?) will give white.
The point is that i don't want to blend all colours but simply make a vertex/poly transparent if i set the colour to glColor4f(red, green, blue, alpha) so that the image will have the colour (red,green,blue) but also transparent, instead of blending red, green and blue if you know what i mean.
Here are the params i set on init (if it helps):
glShadeModel(GL_SMOOTH);
glClearDepth(1.0f);
glEnable(GL_DEPTH_TEST);
glBlendFunc(GL_SRC_ALPHA,GL_ONE);
glDepthFunc(GL_LEQUAL);
glEnable(GL_COLOR_MATERIAL);
glHint(GL_PERSPECTIVE_CORRECTION_HINT, GL_FASTEST);

Can anyone help me please?

----------------------------------
Customer in computer shop: "Can you copy the Internet onto this disk for me?"

AnswerRe: OpenGL alpha transparency Pin
El Corazon7-Jun-07 9:31
El Corazon7-Jun-07 9:31 
GeneralRe: OpenGL alpha transparency Pin
XTAL25615-Jun-07 18:13
XTAL25615-Jun-07 18:13 
GeneralRe: OpenGL alpha transparency Pin
El Corazon17-Jun-07 18:42
El Corazon17-Jun-07 18:42 
GeneralRe: OpenGL alpha transparency Pin
XTAL25619-Jun-07 18:05
XTAL25619-Jun-07 18:05 
GeneralRe: OpenGL alpha transparency Pin
El Corazon21-Jun-07 9:30
El Corazon21-Jun-07 9:30 
GeneralRe: OpenGL alpha transparency Pin
XTAL25621-Jun-07 18:00
XTAL25621-Jun-07 18:00 
QuestionProblem extracting full palette from 8bit image Pin
Sepharo4-Jun-07 7:47
Sepharo4-Jun-07 7:47 
AnswerRe: Problem extracting full palette from 8bit image Pin
Mark Salsbery4-Jun-07 8:05
Mark Salsbery4-Jun-07 8:05 
GeneralRe: Problem extracting full palette from 8bit image Pin
Sepharo4-Jun-07 8:26
Sepharo4-Jun-07 8:26 
GeneralRe: Problem extracting full palette from 8bit image Pin
Mark Salsbery4-Jun-07 8:37
Mark Salsbery4-Jun-07 8:37 
GeneralRe: Problem extracting full palette from 8bit image Pin
Sepharo4-Jun-07 8:41
Sepharo4-Jun-07 8:41 
GeneralRe: Problem extracting full palette from 8bit image Pin
Sepharo4-Jun-07 8:59
Sepharo4-Jun-07 8:59 
GeneralRe: Problem extracting full palette from 8bit image Pin
Mark Salsbery4-Jun-07 9:22
Mark Salsbery4-Jun-07 9:22 
GeneralRe: Problem extracting full palette from 8bit image Pin
Mark Salsbery4-Jun-07 9:16
Mark Salsbery4-Jun-07 9:16 
GeneralRe: Problem extracting full palette from 8bit image Pin
Sepharo4-Jun-07 9:23
Sepharo4-Jun-07 9:23 
GeneralRe: Problem extracting full palette from 8bit image Pin
Mark Salsbery4-Jun-07 9:28
Mark Salsbery4-Jun-07 9:28 
GeneralRe: Problem extracting full palette from 8bit image Pin
Sepharo4-Jun-07 9:40
Sepharo4-Jun-07 9:40 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.