How to render a grayscaled texture on Android?
I have a colored texture work as a menu button. Sometimes I w开发者_JAVA技巧ant to gray it out when it's disabled. How to do it without creating a new grayscaled texture? Can glBlendFunc do this for me? Thanks in advance.
To have a gray scale texture, you need to create such texture. For internal format set either luminance or intensity. See here for details : http://www.opengl.org/sdk/docs/man/xhtml/glTexImage2D.xml
Use a fragment shader. However, for ES 1.0, I am not sure.
精彩评论