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

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

11. 从图集中创建Texture2D问题 [ 82%]

从图集中创建Texture2D问题 我在做物品的掉落渲染,需要用到Texture2D对象。我本以为Texture与Texture2D是一样的,但当我通过Texture2Dload方法获取物品图集中的图片时遇到了问题:获取出的图片不是我某个物品的,而是整个物品图...

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

12. BlinnPhong材质详解(TypeScript-3D基础(TS)-模型材质详解) [ 82%]

...cript var material = new Laya.BlinnPhongMaterial(); //漫反射贴图 Laya.Texture2D.load("res/threeDimen/texture/earth.png", Laya.Handler.create(this, function(texture) { //设置材质纹理 material.albedoTexture = texture; })); earth2.meshRenderer.material = material; ``` ![](img/4.png)(图4) ##...

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

13. 请问Texture2D如何用base64字符串构建对象 [ 80%]

请问Texture2D如何用base64字符串构建对象 给模型贴图的时候需要用base64位字符串。官方api中Texture2Dload方法的参数说明为 : Texture2D地址 。这个地址好像只能传入图片的绝对路径,如何使用base64加载呢?   附件 : --> 2018-05-18 添...

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

14. 材质-BlinnPhong-漫反射贴图 [ 80%]

...Laya.BlinnPhongMaterial(); //漫反射贴图 material.albedoTexture = Laya.Texture2D.load("../../res/threeDimen/texture/earth.png"); earth2.meshRender.material = material; Laya.timer.frameLoop(1, this, function () { earth1.transform.rotate(this.rotation, false); earth2.transform.rotate(this.rotation...

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

15. rigidBody.applyForce 对刚体应用力,物体没有移动 [ 79%]

...a.BlinnPhongMaterial;         //添加漫反射贴图         Laya.Texture2D.load("res/threeDimen/Physics/rocks.jpg", Laya.Handler.create(this, function (tex) {             this.mat1.albedoTexture = tex;         }));         Laya.Texture2D.load("res/threeDimen/Physics/plywood.j...

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

16. 材质-BlinnPhong-高光贴图 [ 78%]

....skinnedMeshRender.materials[i]; //高光贴图 mat.specularTexture = Laya.Texture2D.load(this.specularMapUrl[i]); } Laya.timer.frameLoop(1, this, function () { dude1.transform.rotate(this.rotation); dude2.transform.rotate(this.rotation); }); }class BlinnPhong_SpecularMap { private scene:Laya.Scene;...

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

17. 材质-BlinnPhong-法线贴图 [ 78%]

...Sprite3D.meshRender.material; //法线贴图 material.normalTexture = Laya.Texture2D.load(this.normalMapUrl[i]); } Laya.timer.frameLoop(1, this, function () { monster1.transform.rotate(this.rotation); monster2.transform.rotate(this.rotation); }); }class BlinnPhong_NormalMap { private scene:Laya.Scen...

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

18. skydome可以替换贴图吗? [ 78%]

...al: SkyPanoramicMaterial = new SkyPanoramicMaterial();         Texture2D.load("res/jfb.jpg", Handler.create(null, function (tex: Texture2D) {             material.panoramicTexture = tex;             skymat.material = material;         })); 2020-03...

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

19. Unlit材质详解(TypeScript-3D基础(TS)-模型材质详解) [ 77%]

...Unlit材质 var material2 = new Laya.UnlitMaterial(); //加载纹理 Laya.Texture2D.load("res/threeDimen/texture/earth.png", Laya.Handler.create(this, function(texture) { //设置反照率贴图 material2.albedoTexture = texture; })); earth2.meshRenderer.material = material2; ``` ![](img/1.png)(图1...

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

20. Unlit材质详解(JavaScript-3D基础(JS)-模型材质详解) [ 77%]

...Unlit材质 var material2 = new Laya.UnlitMaterial(); //加载纹理 Laya.Texture2D.load("res/threeDimen/texture/earth.png", Laya.Handler.create(this, function(texture){ //设置反照率贴图 material2.albedoTexture = texture; })); earth2.meshRenderer.material = material2; ``` ![](img/1.png)(图1)...

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