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

Fix multi-GPU support for Nvidia #147

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

PlasmaPower
Copy link

This PR has two commits to fix running aquamarine against multiple Nvidia GPUs which provide different output monitors:

  • A small commit to not force linear allocation on devices which don't support it, even if multigpu is enabled. This is necessary as Nvidia doesn't support the linear format.
  • A Renderer commit to, if creating an EGL image from the source buffer fails, instead copy it to an intermediate buffer on the CPU memory first, then copy that intermediate buffer to the output buffer. This fixes Nvidia multigpu because Nvidia doesn't support attaching another gpu's buffer as an EGL image, so instead this PR first reads the source buffer into CPU memory using the primary renderer's EGL context, and then does the rest of the blit as normal on the secondary GPU which writes to the output buffer.

@vaxerski
Copy link
Member

I am a bit torn on the second one. That copy is very slow. Will it not lag into oblivion?

@PlasmaPower
Copy link
Author

It manages 55 fps on a 4k display on my system which is not great, not terrible. Mutter does the same copy from what I can see and I'm not aware of an alternative.

@vaxerski
Copy link
Member

It manages 55 fps on a 4k display on my system which is not great, not terrible. Mutter does the same copy from what I can see and I'm not aware of an alternative.

alright.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants