大约有 323 项符合查询结果, 库内数据总量为 30,935 项。 (搜索耗时: 0.0036 秒)
Laya_社区(98) Laya3.0_api(64) Laya2.0_api(59) laya_api(55) Laya2.0_示例(16) Laya_示例(15) Laya2.0_文档(12) Laya3.0_文档(4)
...ateApe(); applayFilter(); } function createApe() { ape = new Sprite(); ape.loadImage(apePath); var texture = Laya.loader.getRes(apePath); ape.x = (Laya.stage.width - texture.width) / 2; ape.y = (Laya.stage.height - texture.height) / 2; Laya.stage.addChild(ape); } function applayFilter() { //创建...
来源: Laya_示例 发布时间: 20250312
...eApe(); showDragRegion(); } function createApe() { ape = new Sprite(); ape.loadImage(ApePath); Laya.stage.addChild(ape); var texture = Laya.loader.getRes(ApePath); ape.pivot(texture.width / 2, texture.height / 2); ape.x = Laya.stage.width / 2; ape.y = Laya.stage.height / 2; ape.on(Event.MOUSE_DOWN, ...
来源: Laya_示例 发布时间: 20250312
...ePic() { const Sprite = Laya.Sprite; let shakePic = new Sprite(); shakePic.loadImage("res/inputDevice/shake.png"); Laya.stage.addChild(shakePic); } showConsoleText() { const Text = Laya.Text; console = new Text(); Laya.stage.addChild(console); console.y = picH + 10; console.width = Laya.stage.width;...
来源: Laya2.0_示例 发布时间: 20250312
...prite = Laya.Sprite, Event = Laya.Event; this.ape = new Sprite(); this.ape.loadImage(ApePath); Laya.stage.addChild(this.ape); let texture = Laya.loader.getRes(ApePath); this.ape.pivot(texture.width / 2, texture.height / 2); this.ape.x = Laya.stage.width / 2; this.ape.y = Laya.stage.height / 2; this....
来源: Laya2.0_示例 发布时间: 20250312
...init(); } public init ():void { this.bg_img.loadImage("ui/bg.jpg",0,0,Laya.stage.width,Laya.stage.height,Laya.Handler.create(this,this.onComplete)); Laya.stage.on(Laya.Event.RESIZE,this,this.onResize); } onComplete():void { this...
来源: Laya_社区 发布时间: 20161116
...交 2 个回复 浪货界扛把子 赞同来自: cuixueying 给精灵设置loadimage后不能直接获取它的大小; 问题:是不是只有加载完图片在能真正获取他的width和height? 本人当前解决方法:提前加载资源,在回调中进行操作设置 text_load_wid...
来源: Laya_社区 发布时间: 20170118
...() { this.ape = new Laya.Sprite(); Laya.stage.addChild(this.ape); this.ape.loadImage("res/apes/monkey2.png"); this.ape.pivot(55, 72); // this.ape.pos( Laya.stage.width / 2, Laya.stage.height / 2); this.ape.x = Laya.stage.width / 2; this.ape.y = Laya.stage.height / 2; this.scaleDelta = 0; Laya.timer....
来源: Laya2.0_示例 发布时间: 20250312
iPhone6 webgl渲染下sprite.loadimage加载不出canvas.toDateUrl $("#ewm").qrcode({render:"canvas",width:parseInt(1136*0.3),height:parseInt(1136*0.3),correctLevel:0,text:textDz});//生成二维码图案 var t = new Texture(); t.load($("#ewm canvas")[0].toDataURL()); ewmSprit.graphics.drawTexture(...
来源: Laya_社区 发布时间: 20160928
...pe.y = secondChild.y; } function createApe() { var ape = new Sprite(); ape.loadImage("../../res/apes/monkey2.png"); Laya.stage.addChild(ape); return ape; } })(); ``` 在上面的代码中,我们创建了一个原始位图、一个红色滤镜效果位图、一个灰色滤镜效果位图。运行...
来源: Laya2.0_文档 发布时间: 20210714
...pe.y = secondChild.y; } function createApe() { var ape = new Sprite(); ape.loadImage("../../res/apes/monkey2.png"); Laya.stage.addChild(ape); return ape; } })();module laya { import Sprite = Laya.Sprite; import Stage = Laya.Stage; import ColorFilter = Laya.ColorFilter; import Texture = Laya.Texture;...
来源: Laya_示例 发布时间: 20250312