Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

新渲染系统 #643

Merged
merged 183 commits into from
Apr 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
183 commits
Select commit Hold shift + click to select a range
105965c
refactor: 重命名部分类
Blinue Jun 5, 2023
a9d85dd
chore: 删除现有代码
Blinue Jun 5, 2023
03a1ace
chore: 重命名部分类
Blinue Jun 5, 2023
6be8260
feat: 创建缩放窗口
Blinue Jun 6, 2023
f07972b
fix: 优化缩放窗口样式
Blinue Jun 6, 2023
a68083c
feat: 添加 Renderer 和 DeviceResources
Blinue Jun 6, 2023
df9813c
feat: 创建 D3D 设备
Blinue Jun 6, 2023
65d1f62
refactor: 降低耦合性
Blinue Jun 6, 2023
3711e54
Merge branch 'dev' into render-system
Blinue Jun 6, 2023
d65b810
feat: 检查前台窗口
Blinue Jun 7, 2023
696c34d
Merge branch 'dev' into render-system
Blinue Jun 8, 2023
192d94c
Merge branch 'dev' into render-system
Blinue Jun 11, 2023
bf65b43
Merge branch 'dev' into render-system
Blinue Jun 11, 2023
3e80bf5
feat: MagpieFX v4
Blinue Jun 11, 2023
68b9656
feat: 编译效果
Blinue Jun 11, 2023
3ed697c
feat: Graphics Capture
Blinue Jun 11, 2023
11f9f69
feat: 初始化捕获
Blinue Jun 11, 2023
c05720b
feat: EffectDrawer
Blinue Jun 11, 2023
5755edd
chore: 修正注释
Blinue Jun 11, 2023
8453f71
refactor: 拆分 EffectDrawer::Initialize
Blinue Jun 12, 2023
09251b2
feat: 后端渲染
Blinue Jun 12, 2023
1e8c4c7
fix: 修复编译
Blinue Jun 12, 2023
3b03cdf
feat: 前端渲染
Blinue Jun 12, 2023
c2dafa0
Merge branch 'dev' into render-system
Blinue Jun 13, 2023
3a5c8a6
feat: 内置 Nearest 和 Bilinear
Blinue Jun 13, 2023
a051caa
feat: 内置 Bicubic
Blinue Jun 13, 2023
20886bb
feat: 删除默认降采样效果选项
Blinue Jun 13, 2023
019b065
feat: 默认降采样效果始终为 Catmull-Rom
Blinue Jun 13, 2023
d2a2432
fix: 稍微优化代码
Blinue Jun 13, 2023
1e5c702
perf: 降低渲染延迟
Blinue Jun 14, 2023
58085a1
feat: 移动光标则绘制新的帧
Blinue Jun 14, 2023
12a2fd9
Merge branch 'dev' into render-system
Blinue Jun 15, 2023
8933403
feat: MagpieFX 不再支持 GENERIC_DOWNSCALER
Blinue Jun 15, 2023
0d0111f
feat: 检测 MPO 支持
Blinue Jun 15, 2023
5bd1cb6
chore: 添加注释
Blinue Jun 15, 2023
b6b12d1
feat: 更新几个效果为v4
Blinue Jun 16, 2023
c82c0dd
feat: 添加 CursorManager
Blinue Jun 16, 2023
78a35a0
feat: 捕获光标
Blinue Jun 16, 2023
8ccf7b4
fix: 显示光标时重启捕获
Blinue Jun 16, 2023
607ff88
chore: 修复编译
Blinue Jun 16, 2023
bced075
feat: 添加 CursorDrawer
Blinue Jun 18, 2023
4608dc7
feat: 实现彩色光标绘制
Blinue Jun 18, 2023
9364113
perf: 优化低帧率的流畅度
Blinue Jun 18, 2023
071603e
Merge branch 'dev' into render-system
Blinue Jun 18, 2023
80ae6e3
feat: 实现彩色掩码光标和单色光标的渲染
Blinue Jun 18, 2023
f0ce6ff
feat: 添加 StepTimer
Blinue Jun 19, 2023
0b43a42
perf: 优化渲染延迟
Blinue Jun 19, 2023
b073d16
Revert "perf: 优化渲染延迟"
Blinue Jun 20, 2023
3254aea
feat: 删除垂直同步选项
Blinue Jun 20, 2023
5e3a206
feat: 添加帧率限制选项
Blinue Jun 20, 2023
900cadf
feat: 实现帧率限制选项
Blinue Jun 20, 2023
00f5631
feat: 更新部分效果
Blinue Jun 22, 2023
338dae1
feat: 更新更多效果
Blinue Jun 22, 2023
45ec721
feat: 更新几个效果
Blinue Jun 23, 2023
9ebfc35
feat: 处理后端初始化失败
Blinue Jun 23, 2023
885b3b6
chore: 更新依赖
Blinue Jun 24, 2023
8a8522f
perf: 提高时钟精度,降低 CPU 占用
Blinue Jun 25, 2023
698fd50
perf: 优化流畅度
Blinue Jun 25, 2023
281a511
feat: 添加 GDI 捕获
Blinue Jun 25, 2023
848069c
feat: 实现 USE_DYNAMIC
Blinue Jun 26, 2023
caf48fe
feat: 更新部分效果
Blinue Jun 26, 2023
b0598f3
fix: 提高 StepTimer 的精度
Blinue Jun 26, 2023
d6ef27a
feat: 检测重复帧,和前一阵相同时不再重复渲染
Blinue Jun 27, 2023
74d241b
perf: 优化检测重复帧的性能
Blinue Jun 27, 2023
ebaadad
perf: 优化检测重复帧的性能
Blinue Jun 27, 2023
2e844d0
perf: 稍微优化着色器
Blinue Jun 27, 2023
e4728e1
chore: DuplicateFramesCS->DuplicateFrameCS
Blinue Jun 27, 2023
7329ac3
feat: 适配动态效果
Blinue Jun 28, 2023
f84571c
fix: 重复帧不计入帧率
Blinue Jun 28, 2023
773395d
fix: 修复 GDI 捕获
Blinue Jun 28, 2023
6841677
Merge branch 'dev' into render-system
Blinue Jun 28, 2023
7e681f7
Merge branch 'dev' into render-system
Blinue Jun 28, 2023
4900d57
refactor: ScalingWindow 作为全局状态
Blinue Jul 3, 2023
636817f
feat: 叠加层
Blinue Jul 9, 2023
9b16c52
chore: 更新依赖
Blinue Jul 9, 2023
fd06ecc
fix: 修复叠加层不会立刻显示的问题
Blinue Jul 9, 2023
e293bcd
refactor: 使用 CursorManager 获取光标信息
Blinue Jul 9, 2023
a9414a6
feat: 优化光标逻辑
Blinue Jul 10, 2023
1d8b856
feat: 叠加层初步支持鼠标
Blinue Jul 10, 2023
383901c
Merge branch 'dev' into render-system
Blinue Jul 18, 2023
55e1f4a
fix: 修复编译
Blinue Jul 18, 2023
420049e
Merge branch 'dev' into render-system
Blinue Jul 24, 2023
098bb40
Merge branch 'dev' into render-system
Blinue Jul 24, 2023
c6feb08
Merge branch 'dev' into render-system
Blinue Nov 19, 2023
16f6e09
chore: 修复编译警告
Blinue Nov 19, 2023
7e69583
Merge branch 'dev' into render-system
Blinue Nov 21, 2023
5b3cf0d
chore: 删除 Magpie.Core 的 conanfile
Blinue Nov 21, 2023
e74d974
Merge branch 'dev' into render-system
Blinue Nov 22, 2023
c8f4e84
Merge branch 'dev' into render-system
Blinue Nov 26, 2023
454975b
Merge branch 'dev' into render-system
Blinue Nov 29, 2023
5cd6360
chore: 更新依赖
Blinue Dec 3, 2023
cd22e96
perf: 优化 ScalingRuntime 的原子操作性能
Blinue Dec 3, 2023
0a9cabd
优化窗口框架 (#773)
Blinue Dec 8, 2023
490a4ea
移植 SettingsControls (#771)
Blinue Dec 12, 2023
18adc08
Merge branch 'dev' into render-system
Blinue Dec 12, 2023
14b54bb
chore: 修复编译
Blinue Dec 12, 2023
e6afe2a
UI: 优化 SettingsExpander 的动画
Blinue Dec 12, 2023
eb98b25
优化 SettingsExpander 的性能 (#777)
Blinue Dec 14, 2023
58cda95
fix: 修复空字符串导致 SettingsCard 崩溃的问题 (#778)
Blinue Dec 15, 2023
26d74f1
重构 SettingsGroup (#781)
Blinue Dec 16, 2023
903c2cb
Merge branch 'dev' into render-system
Blinue Dec 16, 2023
e50b562
chore: 删除无用资源
Blinue Dec 16, 2023
ca1a412
添加 SimpleStackPanel:没有间距错误的轻量级 StackPanel (#783)
Blinue Dec 17, 2023
9dde4da
Merge branch 'dev' into render-system
Blinue Dec 17, 2023
202e00f
chore: 修复编译
Blinue Dec 17, 2023
52997ee
Merge branch 'dev' into render-system
Blinue Dec 19, 2023
5b39630
chore: 重命名模板控件的资源防止冲突
Blinue Dec 19, 2023
c076b13
chore: 优化项目结构
Blinue Dec 19, 2023
f9a258a
动态决定是否检测重复帧 (#787)
Blinue Dec 22, 2023
dc66fb2
fix: 修复显示叠加层时的光标渲染错误
Blinue Dec 22, 2023
40efd12
fix: 优化上边框
Blinue Dec 26, 2023
40a5e1e
优化叠加层渲染性能 (#790)
Blinue Dec 29, 2023
63b2e73
支持 ARM64 架构 (#795)
Blinue Dec 31, 2023
b60ff12
chore: 定义 DISABLE_XAML_GENERATED_MAIN
Blinue Dec 31, 2023
8dadcfe
feat: 光标移动到叠加层时释放捕获
Blinue Jan 2, 2024
7e60cfb
支持 XAML 热重载 (#810)
Blinue Jan 13, 2024
4f3414a
chore: 更新 cppwinrt
Blinue Jan 13, 2024
6ef731e
fix: 修复负坐标的 _destRect 计算错误
Blinue Jan 13, 2024
9625f46
Merge branch 'dev' into render-system
Blinue Jan 14, 2024
4838a9d
fix: 修复跨越多个屏幕的错误
Blinue Jan 14, 2024
e7324c9
chore: 修复编译警告
Blinue Jan 14, 2024
611415c
Fix generation of effect source files in subdirectories (#814)
hauuau Jan 19, 2024
2886841
Add v4 effects from the port of mpv-prescalers (#806)
hauuau Jan 22, 2024
0313905
Merge branch 'dev' into render-system
Blinue Jan 22, 2024
ceefeb2
chore: 更新依赖
Blinue Jan 22, 2024
fcfec25
chore: 重新禁用 Up-to-date 检查,以及杂项优化
Blinue Feb 12, 2024
abf58e8
chore: 修复编译
Blinue Feb 12, 2024
e3dc41b
refactor: XamlWindow 禁止子类直接访问成员
Blinue Feb 15, 2024
3a7d507
chore: 微小优化
Blinue Feb 19, 2024
cc105a3
Merge branch 'dev' into render-system
Blinue Feb 19, 2024
701b5cc
feat: 移植 Anime4K_Upscale_GAN_x3_L 1
Blinue Feb 20, 2024
dd04820
feat: 移植 Anime4K_Upscale_GAN_x3_L 2
Blinue Feb 21, 2024
cec40f7
feat: 移植 Anime4K_Upscale_GAN_x2_M
Blinue Feb 22, 2024
7117a80
Merge branch 'dev' into render-system
Blinue Mar 11, 2024
df92b35
在叠加层中显示效果处理时间 (#821)
Blinue Mar 14, 2024
dc367a7
Merge branch 'render-system' into fix-cursor-on-overlay
Blinue Mar 14, 2024
16cbc77
Add CuNNy-NVL upscaler (#848)
cunnyplapper Mar 14, 2024
fc28ea1
Merge branch 'render-system' into fix-cursor-on-overlay
Blinue Mar 14, 2024
e4abc72
perf: 延迟加载 d3dcompiler_47.dll 和 Magnification.dll
Blinue Mar 17, 2024
835e3ef
feat: 调试模式不再捕获光标,且缩放窗口可以拦截鼠标点击
Blinue Mar 17, 2024
3e2dc96
feat: 实现 3D 游戏模式
Blinue Mar 18, 2024
3b56159
feat: 初步实现 FPS 显示
Blinue Mar 19, 2024
9da3c6c
feat: 优化 FPS 显示
Blinue Mar 19, 2024
30452b8
chore: 删除不再使用的字符串
Blinue Mar 19, 2024
0062c8d
feat: 叠加层上显示帧率
Blinue Mar 19, 2024
b119c5e
fix: 避免 3D 游戏模式下意外激活源窗口
Blinue Mar 19, 2024
6ae0a57
fix: 修复 FPS 无法拖动的问题
Blinue Mar 19, 2024
bcdef3d
fix: 删除一个不再需要的 hack
Blinue Mar 19, 2024
735f05b
feat: 实现光标缩放选项
Blinue Mar 19, 2024
a80ad81
fix: 修复叠加层上出现两个光标的问题
Blinue Mar 19, 2024
21a15b4
feat: 将几个效果移植到 v4
Blinue Mar 20, 2024
d4fa443
feat: 完成移植到 v4
Blinue Mar 20, 2024
c5542d8
feat: 实现 DwmSharedSurface 捕获
Blinue Mar 20, 2024
fe3d29b
feat: 实现 DesktopDuplication 捕获
Blinue Mar 20, 2024
fe66e86
fix: 提高时钟精度
Blinue Mar 20, 2024
d4744a3
feat: 优化 DesktopDuplication
Blinue Mar 21, 2024
3cdf2c2
优化双线性插值下单色光标和彩色掩码光标的渲染效果 (#855)
Blinue Mar 24, 2024
190655c
Merge branch 'dev' into render-system
Blinue Mar 24, 2024
2c3216f
fix: 提高时钟分辨率
Blinue Mar 24, 2024
6f4eb75
feat: 不再内置 Bicubic
Blinue Mar 25, 2024
1e69c91
feat: 实现关闭 DirectFlip
Blinue Mar 25, 2024
c425761
chore: 将 tray icon 表述改为 notify icon,更新设置文件版本号
Blinue Mar 25, 2024
849409b
feat: 实现截屏时隐藏光标
Blinue Mar 25, 2024
40a8b2b
feat: 实现模拟独占全屏
Blinue Mar 25, 2024
0a7331b
feat: 优化对源窗口的检测
Blinue Mar 25, 2024
c32148b
feat: 源窗口移动或调整大小后自动重新缩放
Blinue Mar 25, 2024
f919666
fix: 修复有时退出缩放光标不立刻显示的问题
Blinue Mar 26, 2024
1de35ab
简化 ScalingRuntime 状态 (#862)
Blinue Mar 26, 2024
c24f628
fix: 修复忘记释放键盘钩子
Blinue Mar 26, 2024
b167cd1
优化窗口边框的裁剪 (#864)
Blinue Mar 28, 2024
6f0e5ea
fix: 修复无法缩放全屏窗口
Blinue Mar 28, 2024
197d80e
支持非矩形窗口,以及优化鼠标行为 (#865)
Blinue Mar 29, 2024
fc54423
修复光标移动到叠加层或其他窗口时有时会跳跃的问题 (#866)
Blinue Mar 30, 2024
4a3f255
chore: 注释
Blinue Mar 30, 2024
77a989e
[fx] feat: 不支持 OUTPUT 作为输入
Blinue Mar 31, 2024
496961c
feat: 禁止缩放完整性级别更高的窗口 (#867)
Blinue Mar 31, 2024
293b3e6
feat: 当前台窗口捕获了光标,避免造成光标跳跃
Blinue Mar 31, 2024
307edb9
feat: 优化日志记录
Blinue Apr 1, 2024
85c489a
feat: 自行实现 SourceLocation,没有冗长的函数名
Blinue Apr 1, 2024
72d4660
chore: 添加注释
Blinue Apr 1, 2024
98e324f
docs: 更新文档
Blinue Apr 3, 2024
db82516
docs: 更新文档
Blinue Apr 3, 2024
ba421b5
多个性能优化 (#871)
Blinue Apr 3, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
11 changes: 7 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ on:
jobs:
build:
runs-on: windows-latest
strategy:
matrix:
platform: ["x64", "ARM64"]

steps:
- uses: actions/checkout@v4
Expand All @@ -24,10 +27,10 @@ jobs:
uses: actions/cache@v4
with:
path: ~/.conan2/p
key: ${{ runner.os }}-conan-${{ hashFiles('src/**/conanfile.txt') }}
key: Conan-${{ hashFiles('src/**/conanfile.txt') }}-${{ matrix.platform }}

- name: Build
run: python publish.py
run: python publish.py ${{ matrix.platform }}

- name: Save hash
id: hash
Expand All @@ -36,5 +39,5 @@ jobs:
- name: Store build
uses: actions/upload-artifact@v4
with:
name: Magpie-dev-${{ steps.hash.outputs.sha_short }}
path: ./publish
name: Magpie-dev-${{ steps.hash.outputs.sha_short }}-${{ matrix.platform }}
path: ./publish/${{ matrix.platform }}
55 changes: 48 additions & 7 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,13 @@ on:
required: true
type: boolean
jobs:
release:
build:
runs-on: windows-latest

outputs:
tag: ${{ steps.tag.outputs.tag }}
strategy:
matrix:
platform: ["x64", "ARM64"]
steps:
- uses: actions/checkout@v4

Expand All @@ -42,13 +46,50 @@ jobs:
with:
path: ~/.conan2/p
key: ${{ runner.os }}-conan-${{ hashFiles('src/**/conanfile.txt') }}

- name: Generate tag
id: tag
run: |
$tag = "${{ inputs.tag }}" -eq "" ? "v${{ inputs.major }}.${{ inputs.minor }}.${{ inputs.patch }}" : "${{ inputs.tag }}"
echo "tag=$tag" >> $env:GITHUB_OUTPUT

- name: Publish release
run: python publish.py
- name: Build
run: python publish.py ${{ matrix.platform }}
env:
MAJOR: ${{ inputs.major }}
MINOR: ${{ inputs.minor }}
PATCH: ${{ inputs.patch }}
TAG: ${{ inputs.tag }}
PRERELEASE: ${{ inputs.prerelease }}
ACCESS_TOKEN: ${{ secrets.CONTENTS_ACCESS_TOKEN }}
TAG: ${{ steps.tag.outputs.tag }}

- name: Store artifacts
uses: actions/upload-artifact@v4
with:
name: Magpie-${{ steps.tag.outputs.tag }}-${{ matrix.platform }}
path: publish/${{ matrix.platform }}
release:
runs-on: windows-latest
needs: build
steps:
- uses: actions/checkout@v4

- uses: actions/setup-python@v5
with:
python-version: '3.11'

- name: Setup Requests
run: pip install requests

- name: Restore artifacts
uses: actions/download-artifact@v4
with:
path: publish

- name: Publish release
run: python ci/release.py
env:
MAJOR: ${{ inputs.major }}
MINOR: ${{ inputs.minor }}
PATCH: ${{ inputs.patch }}
TAG: ${{ needs.build.outputs.tag }}
PRERELEASE: ${{ inputs.prerelease }}
ACCESS_TOKEN: ${{ secrets.CONTENTS_ACCESS_TOKEN }}
1 change: 0 additions & 1 deletion Magpie.sln
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution
src\Common.Pre.props = src\Common.Pre.props
Directory.Build.props = Directory.Build.props
src\extract_winui_runtime.py = src\extract_winui_runtime.py
src\fix_resfiles.py = src\fix_resfiles.py
src\HybridCRT.props = src\HybridCRT.props
src\WinUI.props = src\WinUI.props
EndProjectSection
Expand Down
158 changes: 158 additions & 0 deletions ci/release.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,158 @@
import sys
import os
import subprocess
import shutil
import requests
import hashlib
import json

try:
# https://docs.github.com/en/actions/learn-github-actions/variables
if os.environ["GITHUB_ACTIONS"].lower() == "true":
# 不知为何在 Github Actions 中运行时默认编码为 ANSI,并且 print 需刷新流才能正常显示
for stream in [sys.stdout, sys.stderr]:
stream.reconfigure(encoding="utf-8")
except:
pass

majorVersion = os.environ["MAJOR"]
minorVersion = os.environ["MINOR"]
patchVersion = os.environ["PATCH"]
tag = os.environ["TAG"]
isPrerelease = os.environ["PRERELEASE"].lower() == "true"
githubAccessToken = os.environ["ACCESS_TOKEN"]
repo = os.environ["GITHUB_REPOSITORY"]
actor = os.environ["GITHUB_ACTOR"]

subprocess.run("git config user.name " + actor)
subprocess.run(f"git config user.email {actor}@users.noreply.github.com")

subprocess.run(
f"git remote set-url origin https://{githubAccessToken}@github.com/{repo}.git"
)

# 打标签
if subprocess.run(f"git tag -a {tag} -m {tag}").returncode != 0:
raise Exception("打标签失败")

if subprocess.run("git push origin " + tag).returncode != 0:
raise Exception("推送标签失败")

print("已创建标签 " + tag, flush=True)

headers = {
"Accept": "application/vnd.github+json",
"Authorization": "Bearer " + githubAccessToken,
"X-GitHub-Api-Version": "2022-11-28",
}

# 获取前一个发布版本来生成默认发行说明
prevReleaseTag = None
try:
if isPrerelease:
# 发布预发行版与最新的版本(无论是正式版还是预发行版)对比
response = requests.get(
f"https://api.github.com/repos/{repo}/releases",
json={"per_page": 1},
headers=headers,
)
if response.ok:
prevReleaseTag = response.json()[0]["tag_name"]
else:
# 发布正式版则与最新的正式版对比
# 由于可以自己选择最新版本,此接口可能不会返回时间上最新发布的版本,不是大问题
response = requests.get(
f"https://api.github.com/repos/{repo}/releases/latest", headers=headers
)
if response.ok:
prevReleaseTag = response.json()["tag_name"]
except:
# 忽略错误
pass

# 发布 release
if prevReleaseTag == None:
body = ""
else:
# 默认发行说明为比较两个 tag
body = f"https://github.com/{repo}/compare/{prevReleaseTag}...{tag}"

response = requests.post(
f"https://api.github.com/repos/{repo}/releases",
json={
"tag_name": tag,
"name": tag,
"prerelease": isPrerelease,
"body": body,
"discussion_category_name": "Announcements",
},
headers=headers,
)
if not response.ok:
raise Exception("发布失败")

uploadUrl = response.json()["upload_url"]
uploadUrl = uploadUrl[: uploadUrl.find("{")] + "?name="

os.chdir(os.path.dirname(__file__) + "\\..\\publish")

pkgInfos = {}
for platform in ["x64", "ARM64"]:
# 打包成 zip
pkgName = "Magpie-" + tag + "-" + platform
shutil.make_archive(pkgName, "zip", pkgName)
pkgName += ".zip"

# 上传资产
with open(pkgName, "rb") as f:
# 流式上传
# https://requests.readthedocs.io/en/latest/user/advanced/#streaming-uploads
response = requests.post(
uploadUrl + pkgName,
data=f,
headers={**headers, "Content-Type": "application/zip"},
)

if not response.ok:
raise Exception("上传失败")

# 计算哈希
f.seek(0, os.SEEK_SET)
md5 = hashlib.file_digest(f, hashlib.md5).hexdigest()

pkgInfos[platform] = (pkgName, md5)

print("已发布 " + tag, flush=True)

# 更新 version.json
# 此步应在发布版本之后,因为程序使用 version.json 检查更新
os.chdir("..")
with open("version.json", "w", encoding="utf-8") as f:
json.dump(
{
"version": f"{majorVersion}.{minorVersion}.{patchVersion}",
"tag": tag,
"binary": {
"x64": {
"url": f"https://github.com/{repo}/releases/download/{tag}/{pkgInfos['x64'][0]}",
"hash": pkgInfos["x64"][1],
},
"ARM64": {
"url": f"https://github.com/{repo}/releases/download/{tag}/{pkgInfos['ARM64'][0]}",
"hash": pkgInfos["ARM64"][1],
},
},
},
f,
indent=4,
)

# 提交对 version.json 的更改
if subprocess.run("git add version.json").returncode != 0:
raise Exception("git add 失败")

if subprocess.run('git commit -m "Update version.json"').returncode != 0:
raise Exception("git commit 失败")

if subprocess.run("git push").returncode != 0:
raise Exception("git push 失败")
13 changes: 8 additions & 5 deletions docs/Built-in effects.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ Magpie ships with a handful of effects that can be used in combinations. Most of
* Parameter:
* Strength: Denoise magnitude

* Anime4K_Restore_S, Anime4K_Restore_M, Anime4K_Restore_L, Anime4K_Restore_VL, Anime4K_Restore_UL, Anime4K_Restore_Soft_S, Anime4K_Restore_Soft_M, Anime4K_Restore_Soft_L, Anime4K_Restore_Soft_VL, Anime4K_Restore_Soft_UL: Algorithms to restore the lines in animations. In increasing order of demand for computing power. The Soft variants are more conservative in sharpening.
* Anime4K_Restore family: Algorithms to restore the lines in animations. In increasing order of demand for computing power. The Soft variants are more conservative in sharpening.
* Output size: the same as the input

* Anime4K_Thin_HQ: Algorithm to clarify lines in animations provided by Anime4K.
Expand All @@ -27,7 +27,7 @@ Magpie ships with a handful of effects that can be used in combinations. Most of
* Strength: The strength in each iteration.
* Iterations: The number of iterations. Decreasing strength and increasing iterations improves the quality of the images, but will lower the processing speed.

* Anime4K_Upscale_S, Anime4K_Upscale_L, Anime4K_Upscale_Denoise_S, Anime4K_Upscale_Denoise_L, and Anime4K_Upscale_GAN_x2_S: Anime-style scaling algorithms provided by Anime4K. The denoise variant includes denoise functionality. The GAN variant, which keeps more details, is still under experiment.
* Anime4K_Upscale family: Anime-style scaling algorithms provided by Anime4K. The denoise variant includes denoise functionality. The GAN variant, which keeps more details, is still under experiment.
* Output size: twice that of the input

* Bicubic: Interpolation algorithms. The lite variant is fast, but at the cost of quality degradation, Suitable for users will weak graphics cards.
Expand Down Expand Up @@ -124,6 +124,9 @@ Magpie ships with a handful of effects that can be used in combinations. Most of
* Bloom Amount
* Filter Kernel Shape

* CuNNy family:Suitable for visual novel-style images. The DS variants offer a subtle denoise effect. Provided by [CuNNy](https://github.com/cunnyplapper/CuNNy)
* Output size: twice that of the input

* Deband
* Output size: the same as the input
* Parameters
Expand Down Expand Up @@ -221,7 +224,7 @@ Magpie ships with a handful of effects that can be used in combinations. Most of
* Sharpness
* Note: Only supports upscaling.

* NNEDI3_nns16_win8x4 and NNEDI3_nns64_win8x6:These shaders originally designed for deinterlacing and are also high-quality interpolation algorithms. NNEDI3_nns64_win8x6 produces higher quality results, but slower.
* NNEDI3 family:These shaders originally designed for deinterlacing and are also high-quality interpolation algorithms. NNEDI3_nns64_win8x6 produces higher quality results, but slower.
* Output size: twice that of the input

* NVSharpen: Port of NVSharpen that was published along with NIS.
Expand All @@ -232,10 +235,10 @@ Magpie ships with a handful of effects that can be used in combinations. Most of
* Pixellate: Scale with the Pixellate algorithm. Suitable for upscaling pixel arts.
* Output size: determined by scale configuration

* RAVU_Lite_R3: Port of ravu-lite-r3
* RAVU family: Ported from https://github.com/bjin/mpv-prescalers
* Output size: twice that of the input

* RAVU_Zoom_R3: Port of ravu-zoom-r3
* RAVU_Zoom family: Ported from https://github.com/bjin/mpv-prescalers
* Output size: determined by scale configuration
* Note: Only supports upscaling.

Expand Down
6 changes: 2 additions & 4 deletions docs/Comparison of capture methods.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,14 @@
Magpie provides several capture methods. They have their pros and cons in different scenarios.
Magpie provides several capture methods. They have their pros and cons in different scenarios. For general purposes, it's recommended to use Graphics Capture, as it provides the best compatibility and smoothness.

| | Graphics Capture | Desktop Duplication | GDI | DwmSharedSurface |
| :---: | :---: | :---: | :---: |:---: |
| Supports DirectComposition (e.g. UWP) | Yes | Yes | No | No |
| Supports recording/streaming | No under extreme conditions<sup>[1]</sup> | No | Yes | Yes |
| Support the source window to span multiple screens | No under extreme conditions<sup>[1]</sup> | No | Yes | Yes |
| Ignores DPI virtualization<sup>[2]</sup> | No | No | Yes| Yes |
| Notes | The most recommended capture method | Requires Win10 v2004, suitable for games with more static frames<sup>[3]</sup>, could capture pop-ups | | Low VRAM usage |
| Notes | The most recommended capture method | Requires Win10 v2004 | | Low VRAM usage |


[1]: (1) The source window does not support regular window capture. (2) The operating system is Windows 11.

[2]: The system will perform bicubic interpolation upscaling to windows that do not support DPI scaling. The capture methods supporting this options captures the images before such scaling.

[3]: The Desktop Duplication mode effectively reduces the power consumption if there are many static frames.
Loading