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

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

171. 鼠标交互-修正交互区域 [ 83%]

...= Laya.Sprite, Event = Laya.Event; let coralRect = new Sprite(); coralRect.graphics.drawRect(0, 0, Laya.stage.width, Laya.stage.height / 2, "#FF7F50"); //设置名称 coralRect.name = "珊瑚色容器"; coralRect.size(Laya.stage.width, Laya.stage.height / 2); Laya.stage.addChild(coralRect); coralRec...

来源: Laya2.0_示例 发布时间: 20240930

172. 被遮罩的对象的子显示对象再添加遮罩,子显示对象的遮罩显示不正确 [ 83%]

...ask则正常显示。 let bigMask:Laya.Sprite = new Laya.Sprite(); bigMask.graphics.drawRect(0, 0, 300, 200, "#ffffff"); this.mask = bigMask; // let imgMask:Laya.Sprite = new Laya.Sprite(); imgMask.graphics.drawRect(0, 0, 100, 300, "#ffffff"); this.img.mask = imgMask; Laya.Tween.to(this.img, {x:100}...

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

173. Sprite-切换纹理 [ 83%]

...var textureUrl = (flag = !flag) ? texture1 : texture2; // 更换纹理 ape.graphics.clear(); var texture = Laya.loader.getRes(textureUrl); ape.graphics.drawTexture(texture, 0, 0); // 设置交互区域 ape.size(texture.width, texture.height); } })();module laya { import Sprite = Laya.Sprite; import ...

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

174. 关于大量绘制 draw的性能优化问题 [ 83%]

...nt.MOUSE_MOVE, this, mousemove); function  mousemove(e) {     drawLayer.graphics.drawCircle(e.target.mouseX,e.target.mouseY,20,"#ffffff")     drawLayer.cacheAsBitmap; }   我的思路是每一次move都把对应的圆形区域绘制到一个容器上,这样一来drawcall就不会一直增加...

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

175. Laya2.0绘制扇形遮罩,显示到部分角度时显示会有部分缺失(demo已上传) [ 83%]

... = 0 Laya.timer.loop(100, this, () => { if (r >= 360) r = 0; r++; sp.graphics.clear(true); sp.graphics.drawPie(0, 0, 50, 0, r, "#00ff1e"); sp2.graphics.clear(true); sp2.graphics.drawPie(0, 0, 50, 0, r, "#00ff1e"); }) 附件 : --> test.zip 2019-07-01 添加评论 免费帖 --> 分享 微博 QZO...

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

176. Sprite-切换纹理 [ 82%]

... let monkey = (this.flag = !this.flag) ? monkey1Res : monkey2Res; this.ape.graphics.clear(); this.ape.graphics.drawTexture(monkey, 0, 0); this.ape.size(monkey.width, monkey.height); } } new Sprite_SwitchTexture();module laya { import Sprite = Laya.Sprite; import Stage = Laya.Stage; import Texture = ...

来源: Laya2.0_示例 发布时间: 20240930

177. 绘制背景帧 [ 82%]

...为透明 新建View及背景图片自适应大小如何设置 如何清除graphics绘制的矢量图 ios 背景音乐需要手动点一下屏幕才能播放 Graphic.drawTextures,第二个参数 pos:Array — 绘制次数和坐标,怎么写啊, webgl 绘制graphics出报错 问题状态 最新...

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

178. laya.d3.renderobjs.nativeobj.NativeVertexBuffer3D_API3.0 [ 82%]

...anRead(): boolean Inherited from VertexBuffer3D.canRead Defined in laya/d3/graphics/VertexBuffer3D.ts:33 是否可读。 Returns boolean instanceBuffer get instanceBuffer(): boolean set instanceBuffer(value: boolean): void Overrides VertexBuffer.instanceBuffer Defined in laya/d3/RenderObjs/NativeOBJ...

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

179. 坐标系原点 [ 82%]

...博 QZONE 微信 mrchenx 赞同来自: var _parent = new Sprite(); _parent.graphics.drawRect(0, 0, 500, 500, '#ff0000'); Laya.stage.addChild(_parent); var _child = new Sprite(); _child.graphics.drawRect(0, 0, 50, 50, '#336699'); _parent.addChild(_child);就像上面那样,我需要在addChild的...

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

180. 水漫填充算法(floodfill) [ 82%]

...法或算法。 有没有四元数右乘三维向量的算法? 现在的graphics 填充色透明度还不可以设置吗? 或者说和背景混合呢? 使用setsubpixel函数对图片进行纹理像素填充,安卓端微信不正常 关于graphics.fillTexture,该api只能填充矩形的,...

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