Skip to content

Scrcpy Mask v0.8.1

Choose a tag to compare

@github-actions github-actions released this 12 Jun 14:35
· 35 commits to master since this release

更新说明

v0.8.1 是一次较大的功能更新,重点改进了映射随机化、脚本系统、scrcpy 投屏性能、窗口控制和设备连接体验。

映射与触控

  1. 新增点击、滑动、方向轮盘和施法类映射的随机化能力,支持随机落点、曲线轨迹和多段路径。#100 #120
  2. 新增 DirectionPad 上方向 boost,可用于类似 W 行走、W + Shift 奔跑的配置。#120
  3. 新增 Observation 最大半径限制,用于限制移动视角映射本身的范围。#120
  4. 新建映射时自动分配 Pointer ID,并增加 Pointer ID 说明和指针调试开关,减少多键同时按下时的触点冲突。#119 #120

窗口与设备

  1. 新增可拖动标题栏、置顶按钮、标题栏显示/隐藏,以及窗口大小和位置持久化。#72 #110
  2. 改进窗口缩放和逻辑坐标处理,减少缩放后映射位置错位的问题。#72 #110
  3. 改进 Linux、Wayland 和部分显卡环境下透明窗口兼容性。#118 #114
  4. 新增无线 ADB 连接地址记忆功能,连接成功后下次会自动填回。

脚本系统

  1. 新增脚本 hooks,可在映射动作执行前后运行脚本;例如进入轮盘前退出 FPS 模式,结束后再恢复 FPS 模式。#120
  2. 新增脚本运行模式控制,支持通过脚本进入/退出 FPS 模式。
  3. 新增脚本运行状态存储,可在同一脚本映射的按下、按住、抬起或 hooks 之间保存状态。
  4. 改进脚本语言工具链,支持语法/语义校验、错误定位、上下文提示和编辑器内联反馈。
  5. 映射设置中显示配置 ID,方便在脚本中引用指定映射。

投屏性能

  1. 重做 scrcpy 投屏渲染路径,视频帧现在直接以 YUV 纹理上传到 GPU,并通过 shader 完成颜色转换。
  2. 优化视频帧投递流程,只保留最新帧,减少帧堆积带来的延迟。
  3. 投屏性能已明显提升,实际体验接近直接使用 scrcpy。

修复问题

  1. 修复调整蒙版大小时仍可能发出触摸事件的问题。
  2. 修复方向轮盘相反方向同时按下时可能错误抬起触点的问题。
  3. 修复滚动后映射菜单定位、脚本按钮遮挡、Web 静态资源缓存等问题。
  4. 修复设备连接后窗口未激活/未聚焦的问题。
  5. 恢复 Apache-2.0 LICENSE 文件。

Update Notes

v0.8.1 is a major feature update focused on mapping randomization, the scripting system, scrcpy screen mirroring performance, window controls, and device connection experience.

Mapping and Touch Control

  1. Added randomization for taps, swipes, DirectionPad, and cast mappings, including random offsets, curved trajectories, and multi-segment paths. #100 #120
  2. Added DirectionPad up-direction boost for setups such as W walking and W + Shift running. #120
  3. Added Observation max radius to limit the movement range of view-control mappings. #120
  4. New mappings now get Pointer IDs automatically, with clearer Pointer ID hints and pointer debugging controls. #119 #120

Window and Device

  1. Added a draggable titlebar, always-on-top control, titlebar visibility control, and window size/position persistence. #72 #110
  2. Improved window resizing and logical coordinate handling to reduce mapping offset issues. #72 #110
  3. Improved transparent window compatibility on Linux, Wayland, and some GPU environments. #118 #114
  4. Added wireless ADB address persistence.

Script System

  1. Added script hooks, allowing scripts to run before and after mapping actions; for example, exiting FPS mode before opening a wheel and restoring FPS mode afterwards. #120
  2. Added script runtime mode controls, including entering and exiting FPS mode from scripts.
  3. Added script state storage, so pressed, held, released scripts and hooks can share state within the same mapping.
  4. Improved the script language tooling with syntax/semantic validation, error locations, contextual hints, and inline editor feedback.
  5. Mapping config IDs are now shown in settings, making it easier to reference specific mappings from scripts.

Screen Mirroring Performance

  1. Reworked the scrcpy screen mirroring render path. Video frames are now uploaded as YUV textures and converted on the GPU with a shader.
  2. Optimized video frame delivery to keep only the latest frame and reduce latency caused by frame backlog.
  3. Screen mirroring performance is significantly improved and is now close to using scrcpy directly.

Bug Fixes

  1. Fixed touch events being emitted while resizing the mask window.
  2. Fixed DirectionPad touch-up behavior when opposite directions are pressed together.
  3. Fixed mapping menu positioning after scrolling, script button overlap, and web asset cache behavior.
  4. Fixed window activation/focus after device connection.
  5. Restored the Apache-2.0 LICENSE file.