Jump to content
You must now use your email address to sign in [click for more info] ×

Affinity Photo running on Linux with Bottles


aronkvh

Recommended Posts

@Wanesty @ElementalWarrior

If you can really do this on Linux, I'll pay you instead of Serif!

I was considering switching back to Win10 a few moments ago after finally switching to Linux for a year.

I'm proud to see some real Linux warriors here.

Edited by SevenStart
spelling Spelling mistakes, English is not my first language
Link to comment
Share on other sites

6 hours ago, ElementalWarrior said:

If I recall correctly it pops up a dialog to say you need dotnet 4.8. Not sure if it was on install or just running the application.

 

from my testing i believe it just print this error because Mono being installed doesn't add as much/the same Registry keys as the dotnet48 installer. (only .net framework 4.701-- and lots other missing)
imma try it by editing the reg and let you guys know because i'm convinced mono can run it.

Edit : mono probably can, but because of how it behave it doesn't know where to look for the winmd files, and thus mono would require similar modification to those made by ElementalWarrior in the wintypes.dll file.
Edit 2 : not worth it, dotnet48 runs fine don't waste your time..

up to date guide for the Affinity Suite on Linux :  codeberg.org/affinity-wine-docs

Link to comment
Share on other sites

21 hours ago, ElementalWarrior said:

Alright I've figured out the magic incantations to get it to run.

- Build and use this version of wine, it includes numerous patches to get it to run: https://gitlab.winehq.org/ElementalWarrior/wine/-/tree/affinity-photo2
- Download the msix version of affinity photo
- Unzip with the unzip command
- Run winetricks dotnet48 renderer=vulkan corefonts
- Copy all the winmd files from a proper install of windows to .wine/drive_c/windows/system32/WinMetadata/Windows.Services.winmd

I think that should be it. It runs shockingly well. Its not as performant as on windows. But it works.

My branch is based off of wine 8.3. Which is the latest release as of like yesterday. It will not get through setup or start properly without changes from my branch linked above.

Thank you for all your good work that you have put in thus far and you clearly deserve a gold medal for your valiant and productive efforts:

goldmedal.jpg

Link to comment
Share on other sites

On 3/7/2023 at 2:33 AM, ElementalWarrior said:

Alright I've figured out the magic incantations to get it to run.

- Build and use this version of wine, it includes numerous patches to get it to run: https://gitlab.winehq.org/ElementalWarrior/wine/-/tree/affinity-photo2
- Download the msix version of affinity photo
- Unzip with the unzip command
- Run winetricks dotnet48 renderer=vulkan corefonts
- Copy all the winmd files from a proper install of windows to .wine/drive_c/windows/system32/WinMetadata/Windows.Services.winmd

I think that should be it. It runs shockingly well. Its not as performant as on windows. But it works.

My branch is based off of wine 8.3. Which is the latest release as of like yesterday. It will not get through setup or start properly without changes from my branch linked above.

How much of a performance dip are we talking about, you think? Really cool of you to be working on this. :27_sunglasses:

Link to comment
Share on other sites

12 hours ago, Frozen Death Knight said:

How much of a performance dip are we talking about, you

pretty significant like a 10fps canvas in Vulkan rendering and ~40fps in openGL but with some rendering artifacts (ui not redrawing often enough)
(this is likely due to wine's vulkan rendered being just based on Zink or similar GL to Vulkan translation layer)

would you guys be interested in me doing a step by step install "guide" ? (in a new thread too since making it work with bottles isn't easy (?))

up to date guide for the Affinity Suite on Linux :  codeberg.org/affinity-wine-docs

Link to comment
Share on other sites

$ WINEDEBUG=-all,+fps WINEPREFIX=~/.wine5 ~/projects/wine-fresh/build-64/wine  ~/.wine5/drive_c/photo_msix/App/Photo.exe
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 0.00fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 1.74fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 9.28fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 10.50fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 11.67fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 9.69fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 8.79fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 7.16fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 19.21fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 1.43fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 20.35fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 20.60fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 20.39fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 20.58fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 20.61fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 8.90fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 2.54fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 0.41fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 0.54fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 20.74fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 2.85fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 19.70fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 20.35fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 20.54fps
0224:trace:fps:wined3d_cs_exec_present 00000000008B9260 @ approx 0.47fps

 

Wine reports 20 fps when I'm panning around. Seems suspiciously stable 🤔 at 20.

Link to comment
Share on other sites

After running

winetricks renderer=gl

I get

$ WINEDEBUG=-all,+fps WINEPREFIX=~/.wine5 ~/projects/wine-fresh/build-64/wine  ~/.wine5/drive_c/photo_msix/App/Photo.exe
0168:trace:fps:wglSwapBuffers @ approx 0.00fps, total 0.00fps
0168:trace:fps:wined3d_cs_exec_present 00007FFFFEA68D20 @ approx 0.00fps
0168:trace:fps:wined3d_cs_exec_present 00007FFFFEB99470 @ approx 0.00fps
0168:trace:fps:wglSwapBuffers @ approx 12.25fps, total 12.89fps
0168:trace:fps:wined3d_cs_exec_present 00007FFFFEB99470 @ approx 7.30fps
0168:trace:fps:wined3d_cs_exec_present 00007FFFFEA68D20 @ approx 3.93fps
0220:trace:fps:wglSwapBuffers @ approx 2.46fps, total 6.52fps
0220:trace:fps:wined3d_cs_exec_present 00007FFFFED0AD00 @ approx 0.00fps
0168:trace:fps:wined3d_cs_exec_present 00007FFFFEA68D20 @ approx 0.66fps
0168:trace:fps:wined3d_cs_exec_present 00007FFFFEEC85C0 @ approx 0.00fps
016c:trace:fps:wined3d_cs_exec_present 00007FFFFEF0DF90 @ approx 0.00fps
016c:trace:fps:wglSwapBuffers @ approx 27.30fps, total 13.50fps
0220:trace:fps:wined3d_cs_exec_present 00007FFFFED0AD00 @ approx 25.31fps
016c:trace:fps:wined3d_cs_exec_present 00007FFFFEF0DF90 @ approx 33.16fps
0220:trace:fps:wglSwapBuffers @ approx 213.53fps, total 53.67fps
0220:trace:fps:wined3d_cs_exec_present 00007FFFFED0AD00 @ approx 106.10fps
016c:trace:fps:wined3d_cs_exec_present 00007FFFFEF0DF90 @ approx 109.04fps
016c:trace:fps:wglSwapBuffers @ approx 171.50fps, total 74.22fps
0220:trace:fps:wined3d_cs_exec_present 00007FFFFED0AD00 @ approx 85.48fps
016c:trace:fps:wined3d_cs_exec_present 00007FFFFEF0DF90 @ approx 55.63fps
016c:trace:fps:wglSwapBuffers @ approx 50.89fps, total 70.89fps
0220:trace:fps:wined3d_cs_exec_present 00007FFFFED0AD00 @ approx 36.96fps
016c:trace:fps:wined3d_cs_exec_present 00007FFFFEF0DF90 @ approx 42.44fps
016c:trace:fps:wglSwapBuffers @ approx 87.27fps, total 73.24fps
016c:trace:fps:wined3d_cs_exec_present 00007FFFFEF0DF90 @ approx 20.99fps
016c:trace:fps:wglSwapBuffers @ approx 6.57fps, total 65.30fps
016c:trace:fps:wined3d_cs_exec_present 00007FFFFEF0DF90 @ approx 5.04fps
0220:trace:fps:wined3d_cs_exec_present 00007FFFFED0AD00 @ approx 17.93fps
016c:trace:fps:wglSwapBuffers @ approx 33.98fps, total 62.28fps
016c:trace:fps:wined3d_cs_exec_present 00007FFFFEF0DF90 @ approx 28.59fps
0220:trace:fps:wined3d_cs_exec_present 00007FFFFED0AD00 @ approx 26.89fps
016c:trace:fps:wglSwapBuffers @ approx 35.37fps, total 59.51fps
016c:trace:fps:wined3d_cs_exec_present 00007FFFFEF0DF90 @ approx 34.80fps
0220:trace:fps:wined3d_cs_exec_present 00007FFFFED0AD00 @ approx 34.12fps
0220:trace:fps:wglSwapBuffers @ approx 190.54fps, total 69.95fps
016c:trace:fps:wined3d_cs_exec_present 00007FFFFEF0DF90 @ approx 78.03fps
0220:trace:fps:wined3d_cs_exec_present 00007FFFFED0AD00 @ approx 77.38fps
016c:trace:fps:wglSwapBuffers @ approx 84.40fps, total 71.10fps
016c:trace:fps:wined3d_cs_exec_present 00007FFFFEF0DF90 @ approx 57.26fps
0220:trace:fps:wined3d_cs_exec_present 00007FFFFED0AD00 @ approx 53.71fps
016c:trace:fps:wglSwapBuffers @ approx 65.80fps, total 70.73fps
016c:trace:fps:wined3d_cs_exec_present 00007FFFFEF0DF90 @ approx 11.92fps
0220:trace:fps:wined3d_cs_exec_present 00007FFFFED0AD00 @ approx 11.41fps
016c:trace:fps:wglSwapBuffers @ approx 50.39fps, total 69.41fps
0220:trace:fps:wglSwapBuffers @ approx 11.89fps, total 64.87fps
0220:trace:fps:wined3d_cs_exec_present 00007FFFFED0AD00 @ approx 17.24fps
016c:trace:fps:wined3d_cs_exec_present 00007FFFFEF0DF90 @ approx 17.43fps
016c:trace:fps:wglSwapBuffers @ approx 6.78fps, total 61.40fps
016c:trace:fps:wined3d_cs_exec_present 00007FFFFEF0DF90 @ approx 4.39fps
016c:trace:fps:wglSwapBuffers @ approx 0.41fps, total 56.34fps
016c:trace:fps:wined3d_cs_exec_present 00007FFFFEF0DF90 @ approx 0.41fps
016c:trace:fps:wglSwapBuffers @ approx 1.04fps, total 47.35fps
016c:trace:fps:wined3d_cs_exec_present 00007FFFFEF0DF90 @ approx 1.04fps
0220:trace:fps:wined3d_cs_exec_present 00007FFFFED0AD00 @ approx 0.41fps
016c:trace:fps:wglSwapBuffers @ approx 223.18fps, total 54.51fps
016c:trace:fps:wined3d_cs_exec_present 00007FFFFEF0DF90 @ approx 111.93fps
0220:trace:fps:wined3d_cs_exec_present 00007FFFFED0AD00 @ approx 110.74fps
016c:trace:fps:wglSwapBuffers @ approx 112.76fps, total 56.86fps
016c:trace:fps:wined3d_cs_exec_present 00007FFFFEF0DF90 @ approx 57.35fps

 

I used to get rendering issues when running GL, but I don't any longer.

Although using gl did end up stuttering quite a bit briefly.

Link to comment
Share on other sites

7 minutes ago, ElementalWarrior said:

I used to get rendering issues when running GL, but I don't any longer

yea GL visual bugs aren't as bad as they were in v1 and previous version,

however i believe the viewport is rendered using directX, i also believe the current wine version is using their old dxvk and vkd3d translation layer instead of Steam Proton new version, which might explain the low framerate while panning the viewport and while editing files

so i tried the proton's dxvk quickly but i believe your implementation of dxcore.dll (and thus dxgi if i understood your code correctly) is only compatible with wine's native dxvk dlls
 

7 minutes ago, ElementalWarrior said:

$ WINEDEBUG=-all,+fps WINEPREFIX=~/.wine5 ~/projects/wine-fresh/build-64/wine  ~/.wine5/drive_c/photo_msix/App/Photo.exe

you might want to try this : https://gitlab.com/xkero/rum

up to date guide for the Affinity Suite on Linux :  codeberg.org/affinity-wine-docs

Link to comment
Share on other sites

13 minutes ago, Wanesty said:

your implementation of dxcore.dll (and thus dxgi

this might be fixable by using doitsujin's dxvk instead of wine's : https://github.com/doitsujin/dxvk
and proton's vkd3d12 : https://github.com/HansKristian-Work/vkd3d-proton

EDIT : ☝️🤓 erm i might be wrong about wine not using this version of dxvk but i honestly have no idea since their naming are so descriptive (edit 2 : no they seem different)

Edited by Wanesty

up to date guide for the Affinity Suite on Linux :  codeberg.org/affinity-wine-docs

Link to comment
Share on other sites

12 minutes ago, Wanesty said:

yea GL visual bugs aren't as bad as they were in v1 and previous version,

however i believe the viewport is rendered using directX, i also believe the current wine version is using their old dxvk and vkd3d translation layer instead of Steam Proton new version, which might explain the low framerate while panning the viewport and while editing files

so i tried the proton's dxvk quickly but i believe your implementation of dxcore.dll (and thus dxgi if i understood your code correctly) is only compatible with wine's native dxvk dlls
 

you might want to try this : https://gitlab.com/xkero/rum

I end up creating a half dozen prefixes because I'm testing something aha. I just use Ctrl+r in the terminal, so its not much of an issue.

My implementation of dxcore just stubs create adapter factory. Dxcore is from my understanding just a wrapper around dxgi anyway.

I'm pretty sure my dxcore code works at all is because they defensively code around it and use more legacy methods to set up graphics libs, because my dxcore literally does nothing aha.

Link to comment
Share on other sites

14 minutes ago, Wanesty said:

i believe it only redirects calls to dxgi, wouldn't it be possible to bind the ext-ms-win-dxcore-l1-1-0 to dxgi ? (as an apiset instead of with a placeholder dll doing it)

Its similar to dxgi but different. I believe ext-ms-win-dxcore-l1-1-0 is an apiset to dxcore. Not to dxgi. dxcore has slightly different classes and class methods.I did briefly try passing back a dxgi ref in dxcore. but it launched with just the error response 🤷‍♂️.

d3d programming and win32 programming is a bit of the deep end for me aha.

Link to comment
Share on other sites

7 hours ago, PSDfield said:

I will not rely but definity try this out

yes, i don't believe ElementalWarrior nor I consider it ready enough if you use affinity products in a professional environment, however not having to reboot or start a VM just to preview and quickly edit a file is such a breeze

up to date guide for the Affinity Suite on Linux :  codeberg.org/affinity-wine-docs

Link to comment
Share on other sites

  • 2 weeks later...
On 3/7/2023 at 2:33 AM, ElementalWarrior said:

Alright I've figured out the magic incantations to get it to run.

- Build and use this version of wine, it includes numerous patches to get it to run: https://gitlab.winehq.org/ElementalWarrior/wine/-/tree/affinity-photo2
- Download the msix version of affinity photo
- Unzip with the unzip command
- Run winetricks dotnet48 renderer=vulkan corefonts
- Copy all the winmd files from a proper install of windows to .wine/drive_c/windows/system32/WinMetadata/Windows.Services.winmd

I think that should be it. It runs shockingly well. Its not as performant as on windows. But it works.

My branch is based off of wine 8.3. Which is the latest release as of like yesterday. It will not get through setup or start properly without changes from my branch linked above.

did you try it with v1 as well?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.