大约有 581 项符合查询结果, 库内数据总量为 31,560 项。 (搜索耗时: 0.0046 秒)
Laya_社区(357) Laya2.0_文档(64) Laya3.0_api(54) Laya_示例(32) Laya2.0_api(22) laya_api(20) Laya3.0_文档(19) Laya2.0_示例(13)
...基础,本篇从API到示例分别介绍Sprite.loadImage与Graphics.drawTexture两种显示图片的方法。 ## 1、用loadImage方法显示与切换图片 ### 1.1 loadImage API概述 在API文档中搜索laya.display.Sprite,可以找到loadImage()方法,如图1所示,我们先熟悉一下...
来源: Laya2.0_文档 发布时间: 20210715
... laya.display.Stage; import laya.resource.HTMLCanvas; import laya.resource.Texture; import laya.ui.Image; import laya.utils.Handler; import laya.webgl.WebGL; public class LayaAirDemo { private var img:Image; public function LayaAirDemo() { Laya.init(800, 600, WebGL); Laya.stage.alignV = Stage.ALIGN_...
来源: Laya_社区 发布时间: 20170704
...tor4`漫反射颜色。 `albedoIntensity:Number` 漫反射强度。 `albedoTexture:BaseTexture` 漫反射贴图。 `enableLighting:Boolean` 是否启用光照。 `normalTexture:BaseTexture` 法线贴图。 `renderMode:int` [write-only] 设置渲染模式。 `shininess:Number` 高光强度,范围为0...
来源: Laya2.0_文档 发布时间: 20210714
...LoadComplete)); } private function onSkinLoadComplete(e:*=null):void { var texture:Texture=Loader.getRes("ui/image.png"); var sp:Sprite=new Sprite(); sp.graphics.drawTexture(texture); Laya.stage.addChild(sp); } 2017-06-03 0 1 分享 微博 QZONE 微信 xiaojun 赞同来自: 是这个 2017-06-03 0 0 ...
来源: Laya_社区 发布时间: 20170603
...的png格式的图片,使用的同步的编程方式,及: this.img.texture = "ui/guide01.png"; 或者是 let tex = new Laya.Texture(); tex.load("ui/guide01.png", Laya.Handler.create(this, ()=>{ this.img.texture = tex; })); 但是如果使用ASTC纹理时就会报错,需要使用异...
来源: Laya_社区 发布时间: 20220919
...I DocumentationAll Packages | All Classes | Index | Frames No Frames TextureProperties | Methods | Events Packagelaya.resourceClasspublic class TextureInheritanceTexture EventDispatcher Object Texture 是一个纹理处理类。 Public Properties PropertyDefined By bitmap : Texture2D ...
来源: Laya2.0_api 发布时间: 20190513
...= Laya.Sprite; this.ape = new Sprite(); Laya.stage.addChild(this.ape); let texture = Laya.loader.getRes(apePath); this.ape.graphics.drawTexture(texture); this.ape.x = (Laya.stage.width - texture.width) / 2; this.ape.y = (Laya.stage.height - texture.height) / 2; } applayFilter() { // 创建一个模...
来源: Laya2.0_示例 发布时间: 20251130
...ar material: Laya.BaseMaterial = new WaterMaterial(); Laya.Texture2D.load("res/water1.png", Laya.Handler.create(null, function(tex:Laya.Texture2D) { // material.albedoTexture = tex; material.mainTexture = tex; })); Laya.Texture2D.load("res/FoamTexture.jpg", Laya.Handler.create(null, ...
来源: Laya_社区 发布时间: 20181030
...learRes("http://10.144.1.20:8081/files/ ... 6quot;); var test: Texture = Laya.loader.getRes("http://10.144.1.20:8081/files/ ... 6quot;); Laya.loader.load("http://10.144.1.20:8081/files/ ... ot%3B, Handler.create(this, function (): void { var t: Texture = Lay...
来源: Laya_社区 发布时间: 20170831
...准备好的图片放置项目资源目录下,并预加载资源,获取texture 准备好的图片head3.png 放置资源目录下 获取texture Laya.loader.load('head3.png',Handler.create(this,onTextureLoaded)); } private var texture:Texture; private function onTextureLoaded():void { texture=Load...
来源: Laya_社区 发布时间: 20170324