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

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

51. 创建材质(JavaScript-3D基础(JS)-LayaAir3D之Material材质) [ 67%]

... false); //创建材质 var material = new Laya.BlinnPhongMaterial(); Laya.Texture2D.load("res/layabox.png", Laya.Handler.create(null, function(tex){ //纹理加载完成后赋值 material.albedoTexture = tex; })); //将材质赋值给自定义模型 box.meshRenderer.material = material; ``` ![](img...

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

52. 资源加载(ActionScript-3D基础(AS3)-LayaAir3D之资源加载) [ 66%]

...。 ![](img/2.png)(图2) #### 3. 纹理加载 ​ 加载单个纹理使用Texture2D.load方法。这里我们创建了一个正方体,并且将加载的纹理设置为他的纹理。这个操作实际上和3D简单示例的操作是相同的。 ```typescript //加载纹理 Texture2D.load("res/thre...

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

53. laya.d3.core.HeightMap_API3.0 [ 66%]

...寸。 Returns HeightMap Static createFromImage createFromImage(texture: Texture2D, minHeight: number, maxHeight: number): HeightMap Defined in laya/d3/core/HeightMap.ts:95 从图片生成高度图。 Parameters texture: Texture2D minHeight: number maxHeight: number 最大高度。 Returns HeightMap...

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

54. laya.net.Loader_API3.0 [ 65%]

...CHY IMAGE JSON MATERIAL MESH SOUND SPINE TERRAINHEIGHTDATA TERRAINRES TEXT TEXTURE2D TEXTURECUBE TTF VIDEO XML downloader extMap groupMap loadedMap preLoadedMap typeMap Accessors loading Methods cacheRes cancelLoadByUrl cancelLoadByUrls clearRes clearTextureRes clearUnLoaded event fetch getRes hasLi...

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

55. laya2.0 截图功能分享,直接截取屏幕上所有对象 [ 64%]

...戏正常可用 private static _sp: Laya.Sprite = null; private static tempTexture2D: Laya.Texture2D; private static tempTexture: Laya.Texture; /**截图 */ public static drawScreenshot(width, height, x, y) { if (!SwitchHelper.screenDraw) { return null; }  if (!this.tempTexture2D) { this.tempTextur...

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

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

...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

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

...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

58. Effect材质详解(JavaScript-3D基础(JS)-模型材质详解) [ 64%]

...材质 var material = new Laya.EffectMaterial(); //加载地球贴图 Laya.Texture2D.load("res/threeDimen/texture/earth.png", Laya.Handler.create(this, function(texture) { //设置纹理 material.texture = texture; })); earth.meshRenderer.material = material; ``` ![](img/1.gif)(图1)

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

59. Skeleton骨骼动画内存泄漏 [ 64%]

...f (this.bitmap.referenceCount===0){ this.bitmap.destroy(); // console.log("texture2d destory"); } this.bitmap=null; } if (this.url && this===Laya.loader.getRes(this.url)) Laya.loader.clearRes(this.url); } }增加的代码是 if (this.bitmap.referenceCount===0){ this.bitmap.destroy(); // con...

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

60. Effect材质详解(TypeScript-3D基础(TS)-模型材质详解) [ 64%]

...材质 var material = new Laya.EffectMaterial(); //加载地球贴图 Laya.Texture2D.load("res/threeDimen/texture/earth.png", Laya.Handler.create(this, function(texture) { //设置纹理 material.texture = texture; })); earth.meshRenderer.material = material; ``` ![](img/1.gif)(图12)

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