Add backend support for reducing energy use#5780
Conversation
This commit will: - Add a new reduceEnergyUse setting to Preferences - Add a new configureEnergyUse method to PlayerCore - Change PlayerCore.startMPV to call the new configureEnergyUse method When the reduceEnergyUse setting is enabled the configureEnergyUse method will apply mpv's builtin fast profile to reduce the energy used by mpv. As the fast profile does not support restoring the old values of the options set by the profile, changes to the reduceEnergyUse setting require IINA to be restarted.
|
This PR only provides the backend support for this feature. I did not include UI as it would generate merge conflicts with some outstanding PRs. This can be tested by enabling the feature using the See issue #5697 for details on the need for this change. |
|
Is there a user request for this? I'm not sure if it's appropriate to treat them as equivalent, because MPV has many profiles, but this setting only has two options (reduce energy use or not). A user conf file can also override this, and the user might not know what's happening just looking at the name of this setting. Perhaps a profile selector would be better? |
|
Good point about expanding this to be a general profile settings. This is about issue #5697 where users with old Macs are complaining because the increase in energy use is noticeable for them and the improvement in picture quality, not so much. This is a regression for these users. This is not for advanced users who know mpv and can create a I was expecting we'd add a One of the users thought IINA ought to just do this by default for Intel Macs. I'm thinking that would not be appropriate for the newer more powerful Intel Macs. Anyway, I only coded up the backend as I wanted advice on how to handle this. Thoughts? |
This commit will:
reduceEnergyUsesetting toPreferencesconfigureEnergyUsemethod toPlayerCorePlayerCore.startMPVto call the newconfigureEnergyUsemethodWhen the
reduceEnergyUsesetting is enabled theconfigureEnergyUsemethod will apply mpv's builtinfastprofile to reduce the energy used by mpv.As the
fastprofile does not support restoring the old values of the options set by the profile, changes to thereduceEnergyUsesetting require IINA to be restarted.Description: