大约有 121 项符合查询结果, 库内数据总量为 31,560 项。 (搜索耗时: 0.0033 秒)
Laya_社区(51) laya_api(29) Laya2.0_api(27) Laya3.0_文档(4) Laya2.0_文档(3) Laya_示例(3) Laya2.0_示例(3) Laya3.0_api(1)
...意坐标系。 //设置陀螺仪的处理 Laya.Gyroscope.instance.on(Laya.Event.CHANGE, this, this.onOrientationChange); private onOrientationChange(absolute:Boolean, info: Laya.RotationInfo):void { if (info.alpha === null) { ...
来源: Laya_社区 发布时间: 20170925
陀螺仪和加速计使用问题 Laya.Gyroscope.instance.on(Laya.Event.CHANGE,this,this.onDeviceorientation); Laya.Accelerator.instance.on(Laya.Event.CHANGE,this,this.onMotoin); 官网陀螺仪和加速计例子中的上面两句运行时都报 Cannot read property 'instance' of undefined 的错...
来源: Laya_社区 发布时间: 20180413
...ight); Laya.stage.addChild(this.info); Laya.Gyroscope.instance.on(Laya.Event.CHANGE, this, onDeviceorientation); function onDeviceorientation(absolute, rotationInfo) { this.info.text = "alpha:" + Math.floor(rotationInfo.alpha) + '\n' + "beta :" + Math.floor(rotationInfo.beta) + '\n' + "gamma:" ...
来源: Laya2.0_文档 发布时间: 20210714
... } } event(Event.CHANGE); } 2017-06-01 0 0 分享 微博 QZONE 微信 a13121527420 - 哇啦哇啦哇啦! 赞同来自: 其实最完美的就是可以布局,然后还可以在前后加描述问题, 例如: 123...
来源: Laya_社区 发布时间: 20170601
...a.stage.height); Laya.stage.addChild(info); Gyroscope.instance.on(Event.CHANGE, this, onDeviceorientation); } private function onDeviceorientation(absolute:Boolean, rotationInfo:RotationInfo):void { info.text = "alpha:" + Math.floor(rotationInfo.alpha) + '\n' + "beta...
来源: Laya2.0_文档 发布时间: 20210714
...e.height); Laya.stage.addChild(this.info); Laya.Gyroscope.instance.on(Laya.Event.CHANGE, this, this.onDeviceorientation); } private onDeviceorientation(absolute: Boolean, rotationInfo: Laya.RotationInfo): void { this.info.text = "alpha:" + Math.floor(rotationInfo.alpha) + '\n' + "beta :" + Math.floo...
来源: Laya3.0_文档 发布时间: 20251010
...e.height); Laya.stage.addChild(this.info); Laya.Gyroscope.instance.on(Laya.Event.CHANGE, this, this.onDeviceorientation); } private onDeviceorientation(absolute: Boolean, rotationInfo: Laya.RotationInfo): void { this.info.text = "alpha:" + Math.floor(rotationInfo.alpha) + '\n' + "beta :" + Math.f...
来源: Laya2.0_文档 发布时间: 20210715
... this.changeSelectStatus(); this.event(/*laya.events.Event.CHANGE*/"change"); this.selectHandler && this.selectHandler.runWith(value); this.startIndex=this._startIndex; //} }); 20...
来源: Laya_社区 发布时间: 20180507
...er = Laya.Browser; var Handler = Laya.Handler; var WebGL = Laya.WebGL; var Event = Laya.Event; var compassImgPath = "../../res/inputDevice/kd.png"; var compassImg; var degreesText; var directionIndicator; var firstTime = true; (function() { Laya.init(700, 1024, WebGL); Laya.stage.scaleMode = Stage.S...
来源: Laya_示例 发布时间: 20251130
...ler.create(this, this.init)); } init() { const Gyroscope = Laya.Gyroscope, Event = Laya.Event; // 创建罗盘 this.createCompass(); // 创建方位指示器 this.createDirectionIndicator(); // // 画出其他UI this.drawUI(); // // 创建显示角度的文本 this.createDegreesText(); Gyroscope.ins...
来源: Laya2.0_示例 发布时间: 20251130