Allow automatic graphics switching

Implemented to allow mpv to use integrated graphics unit.
Based on https://developer.apple.com/library/mac/qa/qa1734/_index.html