
opengl
文章平均质量分 72
nsthing
北上广深漂了七年的老司机
展开
-
shader内置常量变量
3、shader 变量的qualifier: 默认:无修饰符,普通变量读写, 与外界无连接; const:常量 const vec3 zAxis = vec3(0.0, 0.0, 1.0); attribute: 申明传给vertex shader的变量;只读;不能为array或struct;attribute vec4 position;转载 2015-03-07 20:00:40 · 1890 阅读 · 1 评论 -
ndk opengles2.0 配置
AndroidManifest.xml ******************************************************************** Android.mk LOCAL_PATH := $(call my-dir) include $(CL原创 2015-03-07 20:13:15 · 499 阅读 · 0 评论 -
贴图
************************************************************* void glGenTextures(GLsizei n, GLuint *textures) n 指定产生的贴图对象的数量 textures 一个存储着贴图对象Id 值的无符号矩阵 *************************************转载 2015-03-07 20:03:15 · 335 阅读 · 0 评论 -
shader内置函数
shader内置函数: discard 片段着色器终止。 一般默认都用弧度; radians(degree) : 角度变弧度; degrees(radian) : 弧度变角度; sin(angle), cos(angle), tan(angle) asin(x): arc sine, 返回弧度 [-PI/2,转载 2015-03-07 20:01:04 · 2452 阅读 · 1 评论 -
缓冲区
GL_DEPTH24_STENCIL8_OES width 渲染缓冲区以像素为单位的高度; 必须 <= GL_MAX_RENDERBUFFER_SIZE. height 渲染缓冲区以像素为单位的高度; 必须 ******************************************** void glGenFramebuffers(GLsizei n,转载 2015-03-07 20:01:27 · 405 阅读 · 0 评论