w3c / compute-pressure

A web API proposal that provides information about available compute capacity
https://www.w3.org/TR/compute-pressure/
Other
69 stars 10 forks source link

Use-case: provide a battery draining rate indication for application #126

Closed taste1981 closed 2 months ago

taste1981 commented 2 years ago

Application not well optimized/configured may have higher power consumption and drains battery quicker.

If compute-pressure API could provide indication on how fast your app is draining battery (by estimated battery life if the application keeps running), this will help application update configuration at runtime (for example, decide whether to use HW encoder or SW encoder for a video conferencing app.).

Current PressureState definition uses battery level as one of the factor for reporting pressure. However, battery draining speed should also be considered.

If you set a quota that you expect your application to run continuously on the platform, PressureState will switch accordingly on draining rate and expected battery draining out time.

kenchris commented 2 years ago

This is related to #119

arskama commented 1 year ago

Would this also involve that compute-pressure API would be per process (app)?

arskama commented 2 months ago

closed as duplicate of #119