Coder Social home page Coder Social logo

blinue / magpie Goto Github PK

View Code? Open in Web Editor NEW
8.0K 68.0 459.0 26.38 MB

An all-purpose window upscaler for Windows 10/11.

License: GNU General Public License v3.0

HLSL 91.52% C++ 8.31% C 0.04% Python 0.13%
magnifier hlsl capture fsr anime4k cppwinrt super-resolution windows fluent-design xaml-islands

magpie's Introduction


Logo

Magpie

License build All Contributors GitHub all releases

🌍 English | 简体中文

Magpie is a lightweight window scaling tool that comes equipped with various efficient scaling algorithms and filters. Its primary purpose is to enhance game graphics and enable non-fullscreen games to display in fullscreen mode.

We are using Weblate for localization work and would appreciate your help in translating Magpie into more languages.

Translation status

👉 Download

👉 FAQ

👉 Built-in effects

👉 Compilation guide

👉 Contributing

Features

  • Scale any window to fullscreen
  • Numerous built-in algorithms, including Lanczos, Anime4K, FSR, Adaptive Sharpen, various CRT shaders, and more
  • WinUI-based user interface with support for light and dark themes
  • Create configuration profiles for specific windows
  • Multi-monitor support

How to use

  1. Configuring scaling modes

    Magpie provides some simple scaling modes by default, but it is recommended to configure them according to your specific use case. Then, change the global scaling mode on the "Profiles"-"Defaults" page.

  2. Scaling a window

    To scale a window, bring the desired window to the foreground and press the shortcut key (default is Win+Shift+A) to display it in fullscreen mode. Note that the window to be scaled must be in windowed mode, not maximized or fullscreen mode. You can also use the "Scale after xs" button on the "Home" page, and Magpie will automatically scale the foreground window after a few seconds.

  3. Creating profiles for windows

    This allows you to save configurations specific to a particular window. Magpie also supports automatically activate scaling when that window is brought to the foreground.

  4. Customizing effects

    Magpie uses Direct3D compute shader to implement effects, but the syntax has been extended to define resources and organize multiple passes. For more information, please refer to MagpieFX. Those with experience in shader writing can easily create custom effects.

Screenshots

Main window

System requirements

  1. Windows 10 v1903+ or Windows 11
  2. DirectX feature level 11

Hints

  1. If you have set DPI scaling and the window you want to scale does not support high DPI (which is common in older games), it is recommended to first enter the program's compatibility settings and set "High DPI scaling override" to "Application".

  2. Some games support zooming the window, but with extremely naive algorithms. Please set the resolution to the built-in (best) option.

Acknowledgement ✨

Thanks go to these wonderful people:

Xu
Xu

🚧 💻 👀 📖 💬
hooke007
hooke007

📖 💬 📓 💻
Pal Lockheart
Pal Lockheart

📓
Steve Donaghy
Steve Donaghy

💻 🌍
gyro永不抽风
gyro永不抽风

💻
ButtERRbrod
ButtERRbrod

🌍
NightFox
NightFox

🌍
Tzugimaa
Tzugimaa

💻
WHMHammer
WHMHammer

🌍
kato-megumi
kato-megumi

💻
Mike Wang
Mike Wang

📓
Sammy Hori
Sammy Hori

🌍
NeilTohno
NeilTohno

🌍
a0193143
a0193143

🌍
soulset001
soulset001

🌍
WluhWluh
WluhWluh

🎨
Serdar Sağlam
Serdar Sağlam

🌍
Andrus Diaz German
Andrus Diaz German

🌍
Kefir2105
Kefir2105

🌍
animeojisan
animeojisan

🌍
MuscularPuky
MuscularPuky

🌍
Zoommod
Zoommod

🌍
fil08
fil08

🌍
攸羚
攸羚

💻
OHaiiBuzzle
OHaiiBuzzle

🌍
Rastadu23
Rastadu23

🌍
hauuau
hauuau

💻
nellydocs
nellydocs

🌍
cunnyplapper
cunnyplapper

💻

This project follows the all-contributors specification. Contributions of any kind are welcome!

magpie's People

Contributors

0x4e69676874466f78 avatar a0193143 avatar allcontributors[bot] avatar animeojisan avatar ayanami-desu avatar blinue avatar butterrbrod avatar dependabot[bot] avatar eltociear avatar gamepp avatar hauuau avatar hooke007 avatar imgbot[bot] avatar imgbotapp avatar isaiasyang avatar jeffersonqin avatar kato-megumi avatar neiltohno avatar neokushan avatar ohaiibuzzle avatar ps1freak26 avatar sammyhori avatar tzugimaa avatar weblate avatar whmhammer avatar wluhwluh avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

magpie's Issues

[feature request] English translation

Please make a translation, google translate would be good enough.

I could probably use Capture2text until there's a translation, but not having one will limit the userbase and hurt search results.

关于延迟、性能损失和画面效果

我最近尝试了LosslessScaling的FSR缩放,相比较Magpie,它有着更低的延迟,但是相同的是,都有一定的性能损失。相对于原生游戏的FSR,它整个改变了游戏中所有渲染的分辨率,特别是和后处理抗锯齿一同使用时的效果,改用MSAA会好一点,但是通常需要很高的MSAA倍数来维持画面效果。事实上,可能目前缩放类软件的FSR效果甚至差于虚幻4引擎自带的TAAU,加上性能损失帧数提升也只接近TAAU。

我按照Reddit讨论的帖子调整进程优先级和利用监控类插件同步帧数的方式降低了Magpie的延迟和性能损失,现在它和LosslessScaling延迟接近(但是对于游戏玩家来说依旧有反应延迟),提升了一点性能。

另外,Magpie在双显卡电脑上还需要设置独显启动。

原谅我的吹毛求疵,因为原生的FSR带给我的效果实在太过惊艳,我现在有点迷恋它了。

conanbuildinfo.props

我完全不熟悉这个Conan...但是现版本缺乏多个文件 conanbuildinfo.props 导致无法编译,我看了下上级目录被gitignore处理掉了...

关于性能方面一个可行的妥协方法

在使用Magpie的时候 我尝试让他用集显来进行画面捕获 而游戏则是用独显进行游戏(对于笔记本来说) 我发现这种情况下 Magpie的开销基本都在集显上 而独显不会受到影响 从而不会导致帧数比原生帧数还低 有没有一种方法 能够直接集成在程序中 可以选择性的让它决定用独显还是集显 这样就不用到图形设置或者控制面板来进行切换

Capture mode: Injection Error when using GDI + nothing happens with WinRT Capture

Hi there, first and foremost thank you for the awesome program but I experienced these problems:

1). There is an error when trying to launch with the capture mode set to 'GDI' instead of WinRT Capture
image

2). Also, when using Capture mode 'WinRT Capture':-
When I activate the assigned hotkey to perform the injection, the window will auto-closes itself and the targeted application (.exe) does not go into full screen mode (i.e. nothing happens). If nothing happens, that means the injection did not go through or something is blocking the injection that causes the game/application to NOT go into full screen.

Settings I used:-
image

I performed all of the actions on the main monitor, but nothing seemed to work.

I'm not sure if these helps but My setup:-
[x] Dual Monitor setup
[x] Nvidia GPU scaling settings:

  • Hardware scaling instead of GPU scaling
  • Override the scaling mode set by games & programs
    [x] Disabled Antivirus/windows defender
    [x] Disabled Nvidia GeForce Experience in-game overlay

"Adjusting the cursor speed when zooming" does not work

On the desktop, the mouse speed is normal, and in the game in the zoom is somewhere twice as slow. This option should help in theory, but it is not enabled. I turn it on, exit the settings, go back there, and the option is turned off again. Perhaps this option was added by 7Brandyn7, but it seems that he only translated your program into English. If he really added this option, then I'm sorry. Sorry in advance for possible bad English.

v0.4计划

  • 支持像素缩放
  • 使用自适应锐化改进Anime4K缩放效果
  • 移植DarkLines和ThinLines改进Anime4K缩放效果
  • 改进着色器间传递数据的压缩方法
  • 改进DarkLines效果
  • 整理注释和文档
  • 优化光标渲染(仍不支持渲染动态光标)
  • 提高GDI抓取模式的流畅度
  • 更新演示图像(不再使用演示图像)

鼠标事件的映射

目前没有找到完美的解决方案。

  • 方案一:全屏窗口接收鼠标事件,然后将该事件“转发”给目标窗口。存在以下问题:
    • SendMessage 无法使用,大多数窗口不吃这一套。我们不应对目标窗口作任何假设
    • SendInput 可以使用,但存在问题:向目标窗口发送事件时时会有一瞬间的光标移动,观感不好。可以在移动之前隐藏光标,这样会造成光标闪烁。而且因为SendInput时光标会移动,此方案无法转发 MOUSE_MOVE
  • 方案二:全屏窗口对鼠标事件“透明”。无需转发,对鼠标而言,仿佛全屏窗口不存在,可以直接在目标窗口上操作。主要的问题是光标的位置:
    • 我们期望将光标的位置映射到全屏窗口,因为全屏窗口展示时原来的窗口在视觉上被遮住,虽然依然可以正常使用,但用户无法得到光标在窗口上移动的视觉反馈
    • 一个解决方案是全局隐藏光标(使用透明的光标替代系统光标),然后在全屏窗口的对应位置处自己绘制光标。存在的问题如下:
      • 太多的hack。替换系统光标的行为很危险,如果程序非正常退出,可能无法替换回去
      • 光标不能平滑的移动。光标只能在每一帧里渲染一次,在帧数不足时效果不好
      • 一些系统光标(如“文本选择”光标)无法以图像的形式绘制(可能存在解决方案)
      • 对使用自定义光标的窗口无能为力

(Not really a issue) How do I download the new version?

7Brandyn7 updated the patch to the English translation, where he updated the sources from August 11. I want to download the original (from you), but I can't find this new version. Where can I download it? Thank you in advance!

Crash with every setting combination on mac bootcamp.

Hi
Program worked excellently on my desktop computer, but refuse to work on my macbook running bootcamp.
It just silently crash no matter setting combination (WinRT or GDI, Injection or not).

Is there any way I can check and/or debug the problem?

Spec is MacBook 16inch (2019) 9980HK 5300M

[feature request] Work with Reshade

Would you mind adding a way to use Reshade with Magpie so, upscaled games can have Reshade shaders at upscaled resolutions?

For Example:
Game resoltuion = 1920x1080
Magpie upscales to = 3840x2160
Reshade runs on Magpie and,
Reshade effects (like FXAA) = 3840x2160

This way a game can have 2 Reshades. One operates at the game's own resolution, the other one operates on Magpie at higher (upscaled) resolution.

Thank you for this nice software, BTW.

Originally posted by @canceralp in #12 (comment)

Anime4KxDeblur 会花屏

如图
Snipaste_2021-06-13_01-02-02

json部分应该是没写错

    "name": "A4K",
    "model": [
      {
        "effect": "scale",
        "type": "Anime4KxDeblur"
      }

Program always crashes when using WinRT, only works with GDI

Hi,

I'm using Windows 10 1903 and a 1080p screen. The program works fine with GDI but every time I use WinRT, the program just closes after a few seconds, no matter the upscaling algorithm I use.

Is there any way I can check where the problem comes from ?

Thank you for your work.

v0.3计划

  • 优化用户界面
  • 添加使用WinRT Capture API抓取窗口的功能
  • 添加倒计时放大窗口的功能
  • 添加导入自定义缩放效果(json)的功能
  • 优化性能
  • 优化缩放效果

Cursor can't move freely between monitors

I'm using two monitors.
It seems that the mouse cannot move to the second monitor unless I leave the fullscreen.
Is it possible to make the cursor move freely between monitors while in fullscreen?
I tried using 3rd party tools to achieve this but it didn't work.

v0.2计划

  • 改善光标响应性
  • 支持自定义光标(并非完美)
  • 添加计算帧率的功能
  • 向用户界面添加更多选项
  • 探索其他抓取窗口的方式

HDR support

Currently MagPie can not be used with HDR enabled content.
I suppose that this is due to a lack of support from WinRT and GDI so it would be awesome to add the support of HDR to one of those.
Cyberpunk 2077 with HDR (FSR and WinRT):
image

Cyberpunk 2077 without HDR (FSR and WinRT):
image

Vermintide 2 with auto HDR (windows 11 feature) (FSR and WinRT):
image

Vermintide 2 without HDR (FSR and WinRT):
image

Crash when use WinRT on windows 1809

I use windows 1809 and i faced problem with winRT. When the application starts, an error appears when opening full-screen mode using WinRT. According microsoft, winRT supported by windows since 1803.
P.s. sorry for my english i am from Belarus

Program crashes when i using WinRT

Hello!

The program does not work in any application, due to the following error -
Failed to load DLL "Runtime": The specified module was not found (HRESULT Exception: 0x8007007E)

Windows 10 Pro 21H1, v0.6

v0.6计划

  • 使用WPF重构用户界面
  • 关于
  • 开机启动
  • 监视ScaleModels.json的更改
  • 将C++依赖迁移到Conan
  • 增加版本号管理
  • 支持在源窗口重获焦点时自动进入全屏
    #16
  • 支持英语(English support)
    #10
    #33
  • 改进现有着色器,缓解压缩造成的精度损失(暂时不修复)
  • 改进错误处理,添加日志记录(Runtime无日志,因为计划在下个版本重写)

The recovery of mouse DPI

在放大时,magpie 的进程若意外结束,鼠标的DPI会始终保持结束前的样子。
重启程序无法恢复,只能重启系统。

Performance problem

Discussed in #22

Originally posted by Koteusz August 2, 2021
The magpie uses a lot of resources. It is able to take 8% - 20% of the processor in the task manager. It also causes visible latency. In video upscaling it is not a problem, but in games (a lot of people are here for that) it’s useless.
It would be great, if you can do something about that problem. My processor is ryzen 7 4800u.
Also GDI seems to be working better with little to no latency.
Zrzut ekranu 2021-08-02 142206

Can be used on multiplayer games ?

Hello . first of all , thank you for this awesome release !

i have a question , does this works with online multiplayer games ?
or does anticheats catch this as a cheat ?

v0.1 计划

  • 鼠标映射
  • 简易用户界面,预置不同场景下的 Effect 组合
  • 检测源窗口的状态,在该窗口状态改变时自动关闭全屏窗口
  • 完善异常系统
  • 可以最小化至系统托盘
  • 至少换个图标🔍
  • 性能优化
  • 更新README

Windows 11窗口圆角导致游戏窗口超分后左下/右下角模糊

在reddit看到当前只要硬件支持,这个特性是无法由用户设置关闭的,这意味着其发布后这可能成为一个普遍问题。不知有没有办法获取圆角前的原始数据,否则就只能注入用户窗口去opt-out这个DWM属性了。
相关文档:https://docs.microsoft.com/en-us/windows/apps/desktop/modernize/apply-rounded-corners

另外想问一下,当前对Borderless Window进行FSR时,是否实际上源/目标是同一个分辨率,相当于跳过了EASU直接进行RCAS?看FSR的文档是不推荐这样的(推荐改为直接用CAS),看代码里实际上已经实现了FFX CAS,是否可以对这种情况特殊处理一下?

How do you use it ( new to Github and stuff )

Hello.

Recently I've read about Magpie on Tom's Hardware, and wanted to give this a try, have few games that I would want to have FSR in, but it is what it is, so I tried to download this, pressed "< > Code " then green button with "Code" and " download as ZIP ".

BUT... how do I use it? tried opening everything i saw as " Application " but nothing would work, It's my first time on Github and completely lost already. Not sure if I write this in the right thread but this is too advance for me

It does not switch to full screen on a 32:9 monitor.

Thank you for the good program.

If you use Magpie for games with a resolution of 3840x1080 (32:9), the full screen will not be applied with an EndDraw (HRESULT=0x88990027) error. However, most 16:9 or 21:9 resolution programs work fine.
If possible, I would also like the 32:9 ratio to be applied.

In addition, my monitor has a resolution of 5120x1440.

Magpie error when alt+f11 on games

When i try to do the command and the settings: FSR + winrt + injection at runtime/ no injection MAGPIE returns error and cursor dissapears, so you don't know where it is.
Excamples of games with this issue:
Raceroom racing experience
WRC9

Would it be possible to fix Magpie's FPS to the source window?

I have zero knowledge about programming but I know that Reshade does it. In a way, Reshade is an extra layer on top of the game's window and it works as injecting itself into the game's exe. And Reshade update itself only when the game's window updates itself. So, their FPSs are exactly same. Magpie has an injection solution, too. Would it be possible to do the same approach so they both act together at the same FPS, eliminating any (or most of the) performance issues?

I don't know if what I ask would be a DirectX/Vulkan/OpenGL specific solution, because 2D elements may be drawn differnetly but maybe Magpie can have a performance oriented injection way for games.

I hope it is not too much to ask but your FSR implementation is already becoming popular. BTW, I made a video of Magpie working at 1080p and upscaling to 1440p vs 1440p native with Assassin's Creed Valhalla. Can I share it (and possibly more) on Youtube? Of course, I'll be mentioning the names and giving the appropiate links.

edit: typo

[feature request] Alt-tab support, fake full-screen support option.

Hello, thank you for this amazing program.
Here are few suggestions:

  1. Would be nice to have the ability to alt-tab (switch to another windows) without magpie stopping working
  2. Maybe add fake full screen option (Fake fullscreen is a borderless window that is the same size as your desktop resolution. You can pop up your start menu or open some other window and it will sit on top of the game.) Also works for suggestion №1.
    Thanks!

Error creating window

image
Happens with every game/version that i try to access.
Upd.
Ryzen 1600
rx 570
1809

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.