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

大约有 289 项符合查询结果, 库内数据总量为 31,560 项。 (搜索耗时: 0.0047 秒)

51. 如何加载使用从服务器下载的图片 [ 78%]

...load()方法之后使用URL.basePath方法。 例如:   material.diffuseTexture = Laya.Texture2D.load("res/layabox.png");box.meshRender.material = material;Laya.URL.basePath = "https://XXXX.com";//请把XXXX换成自己的真实网址;//在此之下,再使用load加载资源,都会自动加...

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

52. getimagedata 和putimagedata问题 [ 77%]

...edata 无法直接获取, 需要通过 drawToCanvas 然后再 new 一个texture 然后 texture.getPixels() 这 每次都要重新这样获取像素? 2. 在webgl 的情况下,上面的那个方法无效 3. 获取到了像素,但是putimagedata 又不生效 由于官方提供的 texture.getP...

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

53. 火狐花屏问题 [ 77%]

...(type !== "nativeimage") {                         image = new Texture2D();                         var alpha = Laya.Browser.onFirefox;                         image.loadImageSource(imageData,alpha);                     }                     _t...

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

54. laya.ui.Dialog_API3.0 [ 76%]

...ation scaleX scaleY scene scene3D scrollRect skewX skewY stage staticCache texture timer top transform url viewport visible width x y zOrder manager root Methods _initialize _processActive addChild addChildAt addChildren addComponent addComponentInstance bubbleEvent callLater clearTimer close contai...

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

55. 代码里能控制图片的锚点吗? [ 76%]

...r = "role/herohead"+Hero.getHeadID()+".png"; m_herohead = new Image(); var texture = Laya.loader.getRes(heroidstr); m_herohead.graphics.drawTexture(texture); m_herohead.anchorX = 0.5; m_herohead.anchorY = 1; m_herohead.pos(m_heroPosX,m_heroPosY); m_mapbg.addChild(m_herohead);     我在代码里...

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

56. laya.ui.AdvImage [ 76%]

...资源加载完成后,会自动缓存至资源库中。 Image source : Texture 对象的纹理资源。 Image stage : Stage[read-only] 对舞台 stage 的引用。Sprite staticCache : Boolean设置cacheAs为非空时此值才有效,staticCache=true时,子对象变化时不会自动更新缓...

来源: Laya2.0_api 发布时间: 20190513

57. RenderTexture: unkonw depth format [ 75%]

RenderTexture: unkonw depth format 版本: Laya 2.0 问题:只要使用遮罩滤镜就会出现 RenderTexture: unkonw depth format,如果遮罩较多,直接崩溃。   2019-05-25 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链...

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

58. [LayaAirIDE3]3.3.1 UI点击区域异常,mouseThrough属性失效 [ 75%]

...ough为true,而后设置了node2的子节点0(GWidget的实例)纹理texture为new Laya.Texture。设置纹理之后,mouseThrough的设置就无效了,可以参考Laya.Sprite的mouseThrogh的注释,如下所示: /** * @en For non-UI component display object nodes (container objects or ...

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

59. [0]Laya3.0.3 的VideoNode不支持在微信浏览器中播放 [ 75%]

...浏览器无任何显示。 let mat = new Laya.UnlitMaterial(); mat.albedoTexture = videoNode.videoTexture; this.owner.xxx.getChildByName('Scene3D').getChildByName('Plane').getComponent(Laya.MeshRenderer).sharedMaterial = mat; // 上面代码在3D场景中播放则无任何问题,包括微信浏...

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

60. UI皮肤怎么动态设置图片资源,有时候需要更换整个文件夹的图片,有什么好的方法么 [ 75%]

...改变图片大小? 求问shader中的attribute变量怎么动态修改 Texture图片能否进行翻转? 配置layaAir需要注意的 路径是对的,但老是,调试控制台提示:错误,图片是IDE自带的,也不显示 图片添加点击事件 有的不生效 LayaNative ios上js...

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