2012年9月20日 星期四

AGAL quick reference guide

AGAL 教學 備忘

Vertex Shader:
va0-va7:vertex attribute registers, set with context3D.setVertexBufferAt(...)
vc0-vc127:vertex constant registers, set with context3D.setProgramConstantsFromMatrix/Vector(Context3DProgramType.VERTEX, ...)
vt0-vt7:vertex temporary registers with xyzw component (ex: add vt0, va0, vc0)
v0-v7:varying registers, pass values to the fragment shader (ex: mov v0, va0)
op:output point (ex: mov op, va0)

Fragment Shader:
fc0-fc127:fragment constants set with context3D.setProgramConstantsFromMatrix/Vector(Context3DProgramType.FRAGMENT,...)
fs0-fs7:fragment(texture) sampler, set with context3D.setTextureAt(__sampler, __textureBmpd)
v0-v7:varying registers, values passed from the vertex shader (ex: mov oc, v0)
ft0-ft7:fragment temporary registers with xyzw component (ex: tex ft0, v0, fs0<2d,linear,nomip,repeat>)
oc:output color (ex: mov oc, ft0)

沒有留言:

張貼留言