Replies: 2 comments
-
The whole thing seems a bit perverse, lots of verticals for something so simple, could you just not use a texture to provide the colour gradient? As for what might be wrong, you don't say anything about how you intend the geometry data connected together as primitives, but I for sure a POLYGON won't be the answer - it maps to GL_POLYGON. Please look up OpenGL docs on GL_POLYGON. |
Beta Was this translation helpful? Give feedback.
-
If you want the alpha channel to be applied, you'd better use |
Beta Was this translation helpful? Give feedback.
-
Hello, everyone!
I try to draw a circle filled by gradient color using OSG3.4.0. I want to achieve this effect via binding different gradient transparency for the points in different level. However, I don't get the result as expected. It seems that the gradient points are not the postion I set.
Below is my code.
And this is the running result
I set the gradient point at the 70% of the circle radius. So I think the gradient shuold appear at that point. But the running result is not like this.
Why?
If you know something about this, please give me some tips! thanks very much.
Beta Was this translation helpful? Give feedback.
All reactions