1. A non-transitory program storage device, on which are stored instructions for execution by a data processing apparatus, comprising instructions for causing the data processing apparatus to: interpose a framework layer between an application and hardware resources of a data processing apparatus, wherein the framework layer comprises instructions that when executed cause the data processing apparatus to: receive, by the framework layer, display data that includes a hierarchically organized plurality of media objects from the application, wherein the media objects are indicative of an appearance of the display data after being rendered; identify, by the framework layer, a media type for each of the plurality of media objects; dynamically allocate, by the framework layer, at least some of the hardware resources to render the display data based on the media type for each of the plurality of media objects; configure, by the framework layer, the allocated hardware resources for rendering the display data; and render the display data with the configured hardware resources, wherein the display data does not describe how the display data should be rendered.