Score:1

How do I run flatpak apps on discrete GPU by default?

jp flag
Pss

I want some flatpak apps to run on my discrete Nvidia GPU by default. I can always right-click on the app and launch via discrete graphics but that's tedious.

I followed these steps but it did not work.

To force a Flatpak application to use discrete graphics by default on a system with dual graphics (integrated and discrete), you can follow these steps:

Determine the application ID: Open a terminal and run the following command to list all installed Flatpak applications along with their IDs:

flatpak list

Find the application for which you want to set the default GPU and note down its application ID.

Create a new configuration file: In the terminal, run the following command to create a new configuration file for the application:

sudo nano /etc/environment.d/flatpak.conf

This command will open a text editor (nano) to edit the configuration file.

Add environment variable: In the nano text editor, add the following line to the configuration file, replacing with the application ID you noted down in Step 1:

__NV_PRIME_RENDER_OFFLOAD=<app-id>

Save and exit: Press Ctrl + X to exit nano. When prompted to save the changes, type Y and then press Enter to confirm and save the file.

Reboot the system: Restart your computer to apply the changes.

After following these steps, the specified Flatpak application should use the discrete graphics by default when launched.

I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.