大约有 112 项符合查询结果, 库内数据总量为 31,722 项。 (搜索耗时: 0.0042 秒)
Laya.loader.clearTextureRes回收纹理会导致其他绘制的纹理重新加载 我只把灰色那块灰色了,最下面的也跟着闪了一下 附件 : --> 2020-10-14 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提交 2 ...
来源: Laya_社区 发布时间: 20201014
...切换的时候 如何把当前场景下的资源销毁掉呢 Laya.loader.clearTextureRes("res/fighter.atlas") 这一步 销毁的是图集所保护的所有资源吗?还是说 需要 把所有用到的小图地址都销毁一遍 比如 Laya.loader.clearTextureRes("res/re1.jpg"); Laya.loader.clear...
来源: Laya_社区 发布时间: 20171122
...回复 Monica - 知识达人 赞同来自: 1.7.12beta版本新增了一个clearTextureRes接口,如果你不确定之后是否会用到这张资源的话可以用Laya.loader.clearTextureRes("url")进行销毁。 关于clearTextureRes: 销毁Texture使用的图片资源,保留texture壳,如...
来源: Laya_社区 发布时间: 20171103
...ts.Keyboard; import laya.utils.Stat; import laya.webgl.WebGL; public class ClearTextureResTest { private var sp:Sprite; public function ClearTextureResTest() { WebGL.enable(); Laya.init(1000, 800); //显示一个图片 sp = Sprite.fromImage("res/bg.jpg"); Laya.stage.addChild(sp); //显示一个动...
来源: Laya2.0_文档 发布时间: 20210714
...ts.Keyboard; import laya.utils.Stat; import laya.webgl.WebGL; public class ClearTextureResTest { private var sp:Sprite; public function ClearTextureResTest() { WebGL.enable(); Laya.init(1000, 800); //显示一个图片 sp = Sprite.fromImage("res/bg.jpg"); Laya.stage.addChild(sp); //显示一个动...
来源: Laya2.0_文档 发布时间: 20200929
...athBg = "res/bg2.png", PathFly = "res/fighter/fighter.atlas"; class Loader_ClearTextureRes { constructor() { const Browser = Laya.Browser, WebGL = Laya.WebGL, Stage = Laya.Stage, Stat = Laya.Stat, Handler = Laya.Handler; // 不支持WebGL时自动切换至Canvas Laya.init(Browser.clientWidth, Browse...
来源: Laya2.0_示例 发布时间: 20260303
...aniFly.visible = false; //销毁 Texture 使用的图片资源 Laya.loader.clearTextureRes(this.PathBg); Laya.loader.clearTextureRes(this.PathFly); this.isDestroyed = true; this.txt.text = "恢复"; } }; return GameMain; }()); new GameMain(); })(leo || (leo = {}));namespace leo { import Sprite = lay...
来源: Laya_示例 发布时间: 20260303
...要一清除,所有的该图片都失效,引用计数不是有多处?clearTextureRes方法,可解决该问题,但会导致现有的图片重新渲染闪一下,并不完美。 2018-02-27 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相...
来源: Laya_社区 发布时间: 20180227
... taskView = null; Laya.loader.clearTextureRes("res/atlas/task.atlas"); } } private function onLoaded():void { //实例UI界面 ta...
来源: Laya_社区 发布时间: 20180425
...exture使用的图片资源不存在,则会自动恢复 相比clearRes,clearTextureRes只是清理texture里面使用的图片资源,并不销毁texture,再次使用到的时候会自动恢复图片资源 而clearRes会彻底销毁texture,导致不能再使用;clearTextureRes能确保立...
来源: Laya_社区 发布时间: 20190312