• 首页
  • 动态
  • 案例
  • 引擎社区
  • API
  • 文档
  • 示例
  • 引擎下载

大约有 23 项符合查询结果, 库内数据总量为 30,784 项。 (搜索耗时: 0.0034 秒)

11. 关联shader的uniform(JavaScript-3D基础(JS)-LayaAir3D之shader) [ 86%]

...tline.vs` 代码如下: ```c++ attribute vec4 a_Position; attribute vec3 a_Normal; uniform mat4 u_MvpMatrix; uniform float u_OutlineWidth; void main() { vec4 position = vec4(a_Position.xyz + a_Normal * u_OutlineWidth, 1.0); gl_Position = u_MvpMatrix * position; } ``` 片元着色器 `outline.fs` ...

来源: Laya2.0_文档 发布时间: 20210715

12. 关联shader的uniform(TypeScript-3D基础(TS)-LayaAir3D之Shader) [ 85%]

...tline.vs` 代码如下: ```c++ attribute vec4 a_Position; attribute vec3 a_Normal; uniform mat4 u_MvpMatrix; uniform float u_OutlineWidth; void main() { vec4 position = vec4(a_Position.xyz + a_Normal * u_OutlineWidth, 1.0); gl_Position = u_MvpMatrix * position; } ``` 片元着色器 `outline.fs` ...

来源: Laya2.0_文档 发布时间: 20210715

13. 关联shader的uniform(ActionScript-3D基础(AS3)-LayaAir3D之shader) [ 85%]

...tline.vs` 代码如下: ```c++ attribute vec4 a_Position; attribute vec3 a_Normal; uniform mat4 u_MvpMatrix; uniform float u_OutlineWidth; void main() { vec4 position = vec4(a_Position.xyz + a_Normal * u_OutlineWidth, 1.0); gl_Position = u_MvpMatrix * position; } ``` 片元着色器 `outline.fs` ...

来源: Laya2.0_文档 发布时间: 20210715

14. 分享水波一个shader [ 81%]

... = ` attribute vec4 a_Position; attribute vec2 a_Textcoord; attribute vec3 a_Normal; uniform mat4 u_WorldMat; uniform mat4 u_MvpMatrix;   varying vec2 v_textcoord; varying vec3 v_normal; varying vec4 v_wpos;   void main() { v_textcoord = a_Textcoord; v_normal = a_Normal; v_wpos = u_WorldMat * a_Po...

来源: Laya_社区 发布时间: 20190923

15. 继承自Laya.BaseMaterial并且自定义Shader的的自定义材质如何设置透明渲染 [ 81%]

...var attributeMap:Object = { 'a_Position': Laya.VertexMesh.MESH_POSITION0, 'a_Normal': Laya.VertexMesh.MESH_NORMAL0, 'a_Texcood0': Laya.VertexMesh.MESH_TEXTURECOORDINATE0 }; var uniformMap:Object = { 'u_MvpMatrix': Laya.Shader3D.PERIOD_SPRITE, 'u_WorldMat': Laya.Shader3D.PERIOD_SPRITE, 'u_MainTex': L...

来源: Laya_社区 发布时间: 20190814

16. 自定义shader-边缘光照shader [ 78%]

...ementUsage.BLENDWEIGHT0, 'a_Position': Laya.VertexElementUsage.POSITION0, 'a_Normal': Laya.VertexElementUsage.NORMAL0, 'a_Texcoord': Laya.VertexElementUsage.TEXTURECOORDINATE0 }; var uniformMap = { 'u_Bones': [Laya.SkinnedMeshSprite3D.BONES, Laya.Shader3D.PERIOD_RENDERELEMENT], 'u_CameraPos': [Laya....

来源: Laya_示例 发布时间: 20241123

17. laya.d3.shader.SubShader_API3.0 [ 74%]

..._COLOR0, ShaderDataType.Vector4] Defined in laya/d3/shader/SubShader.ts:48 a_Normal a_Normal: [number, Vector3] = [VertexMesh.MESH_NORMAL0, ShaderDataType.Vector3] Defined in laya/d3/shader/SubShader.ts:44 a_Position a_Position: [number, Vector4] = [VertexMesh.MESH_POSITION0, ShaderDataType.Vector4]...

来源: Laya3.0_api 发布时间: 20231102

18. 自定义shader-地形shader [ 64%]

...) { var attributeMap = { 'a_Position': Laya.VertexElementUsage.POSITION0, 'a_Normal': Laya.VertexElementUsage.NORMAL0, 'a_Texcoord0': Laya.VertexElementUsage.TEXTURECOORDINATE0, 'a_Texcoord1': Laya.VertexElementUsage.TEXTURECOORDINATE1 }; var uniformMap = { 'u_MvpMatrix': [Laya.Sprite3D.MVPMATRIX, L...

来源: Laya_示例 发布时间: 20241123

19. 一个简单的跑酷曲面shader分享 [ 51%]

...ar attributeMap: object = { "a_Position": Laya.VertexMesh.MESH_POSITION0, "a_Normal": Laya.VertexMesh.MESH_NORMAL0, "a_Textcoord": Laya.VertexMesh.MESH_TEXTURECOORDINATE0, "a_Textcorrd1": Laya.VertexMesh.MESH_TEXTURECOORDINATE1, "a_Tangent": Laya.VertexMesh.MESH_TANGENT0, "a_Color": Laya.VertexMesh....

来源: Laya_社区 发布时间: 20201009

20. SubShader介绍(JavaScript-3D基础(JS)-LayaAir3D之shader) [ 37%]

..._Position': VertexMesh.MESH_POSITION0, 'a_Color': VertexMesh.MESH_COLOR0, 'a_Normal': VertexMesh.MESH_NORMAL0, 'a_Texcoord0': VertexMesh.MESH_TEXTURECOORDINATE0, 'a_Texcoord1': VertexMesh.MESH_TEXTURECOORDINATE1, 'a_BoneWeights': VertexMesh.MESH_BLENDWEIGHT0, 'a_BoneIndices': VertexMesh.MESH_BLENDIN...

来源: Laya2.0_文档 发布时间: 20210714