Our Desktop AIR app (not a game) uses <rendermode>direct</rendermode> so that some large scrolling animations are smoother. When we set it to cpu mode, the animation framerates are low, so this was an easy fix. However, this has the nasty side effect of forcing Macbook Pros to use the discreet GPU, which consumes more battery life, and causes our users to complain. (This is especially true in Mavericks because it claims our app is using more energy.)
On Macbook Pros from 2011 on, they have two GPUs: Integrated and Discreet. Right now AIR always uses the discreet (high power) GPU, but they wouldn't have to. Apple specifies a way to let your app use the _integrated_ GPU (which would be plenty sufficient for our purposes) instead of forcing the use of the discreet GPU: https://developer.apple.com/library/mac/qa/qa1734/_index.html
You just have to add this to your app's plist:
<key>NSSupportsAutomaticGraphicsSwitching</key>
<true/>
Unfortunately, that doesn't work. AIR is still forcing the use of the discreet graphics card. That appears to be because the initialization of the context is not telling the Mac that it's okay to fall back on discreet graphics. Apple says that these are the steps you need to perform in order to allow for the use of integrated GPU:
https://developer.apple.com/library/mac/technotes/tn2229/_index.html
In particular, it looks like AIR would need to allocate the OpenGL context with the AllowOfflineRenderers flag. If the AIR developers do this, we desktop developers could choose to make our apps use the integrated GPU simply by adding the "NSSupportsAutomaticGraphicsSwitching" to our plist. If we did, then we'd be able to use integrated GPU. Otherwise, we could force it to use the discreet GPU.
Any chance AIR devs could add that flag (hoping that's all there is to it) in order to allow us to use the integrated GPU if available?