glblendfunc

glPoint Alpha Blending issue

我怕爱的太早我们不能终老 提交于 2019-12-02 08:09:32
I am having issues alpha blending glPoints. The alpha blending works correctly when the glPoint is over the background but when a glPoint overlaps another glPoint the background color is visible rather then the underlying glPoint. // create texture GLuint tex; glGenTextures(1, &tex); glBindTexture(GL_TEXTURE_2D, tex); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST); glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, width, height, 0, GL_RGBA, GL_UNSIGNED_BYTE, spriteData); // Draw glEnable(GL_DEPTH_TEST); glEnable(GL_BLEND); glBlendFunc (GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);

Why does OpenGL blending not work on HTC Desire?

杀马特。学长 韩版系。学妹 提交于 2019-12-01 06:30:56
Does anyone know how to enable blending in OpenGL (android) on a HTC Desire. I am trying to draw colored triangles and using the alpha value of the color buffer to blend them with the background (or another triangle). It works both on the emulator (2.1) and on a htc hero 2.1 but not on my desire with 2.2. Is there some hardware difference between a hero and a desire that causes this? The main stuff from the code is (not in order): gl.glClear(GL10.GL_COLOR_BUFFER_BIT | GL10.GL_DEPTH_BUFFER_BIT); gl.glEnable(GL10.GL_BLEND); gl.glBlendFunc(GL10.GL_SRC_ALPHA, GL10.GL_ONE_MINUS_SRC_ALPHA); private

Why does OpenGL blending not work on HTC Desire?

家住魔仙堡 提交于 2019-12-01 04:05:15
问题 Does anyone know how to enable blending in OpenGL (android) on a HTC Desire. I am trying to draw colored triangles and using the alpha value of the color buffer to blend them with the background (or another triangle). It works both on the emulator (2.1) and on a htc hero 2.1 but not on my desire with 2.2. Is there some hardware difference between a hero and a desire that causes this? The main stuff from the code is (not in order): gl.glClear(GL10.GL_COLOR_BUFFER_BIT | GL10.GL_DEPTH_BUFFER_BIT

Opengl Render To Texture With Partial Transparancy (Translucency) And Then Rendering That To The Screen

孤街醉人 提交于 2019-11-28 08:41:35
I've found a few places where this has been asked, but I've not yet found a good answer. The problem: I want to render to texture, and then I want to draw that rendered texture to the screen IDENTICALLY to how It would appear if I skipped the render to texture step and were just directly rendering to the screen. I am currently using a blend mode glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA). I have glBlendFuncSeparate to play around with as well. I want to be able to render partially transparent overlapping items to this texture. I know the blend function is currently messing up the RGB

Opengl Render To Texture With Partial Transparancy (Translucency) And Then Rendering That To The Screen

强颜欢笑 提交于 2019-11-27 02:22:21
问题 I've found a few places where this has been asked, but I've not yet found a good answer. The problem: I want to render to texture, and then I want to draw that rendered texture to the screen IDENTICALLY to how It would appear if I skipped the render to texture step and were just directly rendering to the screen. I am currently using a blend mode glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA). I have glBlendFuncSeparate to play around with as well. I want to be able to render partially