A web page that is received by an electronic device for rendering can include various different elements. Examples of such elements include a Flash element (containing Flash content), an applet element (e.g. Java applet element), or a script element (e.g. a JavaScript element). Rendering rich media content associated with certain types of elements (such as those listed above) can be resource-intensive. If the rich media content associated with multiple elements have to be rendered concurrently, then performance in displaying such rich media content can suffer if resources of the electronic device become overloaded.
Some embodiments are described with respect to the following figures:
A web page can include various types of elements, including text elements, image elements, audio elements, video elements, multimedia elements, and so forth. A multimedia element refers to an element that is associated with some combination of the following types of content: audio content, image content, video content, and text content. The processing of certain types of elements of a web page, especially richer elements such as audio elements, video elements, and multimedia elements, can involve use of media decoding resources (such as audio/video decoding resources). In the ensuing discussion, an element of a web page (or other input data to be rendered) that has to be processed by a media decoding resource prior to rendering of such element is referred to as a “media element.”
Note that a media element is considered to be part of a web page (or other input data) if respective tags and a reference (such as a pointer or link) to the content of the media element is contained in the web page (or other input data). In other words, the actual content corresponding to the media element does not have to be embedded in the web page (or other input data) for the media element to be considered part of the web page (or other input data).
If multiple media elements have to be processed at the same time, the media decoding resources of the electronic device may become overloaded. In some examples, a web page can include a first media element that corresponds to a multimedia advertisement, and a second media element that corresponds to actual content that is of interest to the user (e.g., game content, a movie, etc.). In the ensuing discussion, such actual content of interest to a user is referred to as “user content.”
If each of the above media elements (advertisement and user content) were treated with equal priority, then if the media decoding resources of the electronic device become overloaded, the user may experience reduced performance when interacting with the user content. For example, if the user content is game content, then the quality of the game experience can be degraded as media decoding resources of the electronic device are also concurrently being consumed for rendering the advertisement.
In accordance with some embodiments, different priorities are assigned to different media elements of a web page (or other input data). The allocation of media decoding resources to process the media elements can be according to the assigned priorities. The media decoding resources can include different types of media decoders (e.g. audio/video decoders), such as a hardware media decoder, a hardware-assisted software media decoder, and a software media decoder. The hardware media decoder generally has better performance than the software media decoder, while the hardware-assisted software media decoder has a performance that falls between the performances of the hardware media decoder and the software media decoder.
In some examples, a media decoder can include a decoder to process data encoded according to an MPEG (Moving Pictures Experts Group) format. Different versions of the MPEG format are defined by various different standards promulgated by the ISO/IEC Moving Pictures Experts Group. In other examples, a media decoder can process data encoded according to other formats.
In accordance with some embodiments, when there is competition for the media decoders for processing content associated with different media elements of a web page (or other input data), the priorities of the media elements are used to assign a higher-performance media decoder to a higher priority media element, and to assign a lower-performance media decoder to a lower priority media element. For example, user content would be assigned a higher priority than advertisement content, so that user experience in interacting with the user content would not be degraded due to concurrent processing of the advertisement content.
In alternative embodiments, different media decoding resources of an electronic device can further include different instances of a particular media decoder, such as a software media decoder. The different instances of the particular media decoder can be used to process respective media elements.
The remote system 106 is connected to a public or private network 110, while the remote systems 108 are coupled to the public or private network 110 through a firewall 112. There can also be various remote systems coupled to a public switched telephone network (PSTN) 114 with which the electronic devices 100 can communicate.
The remote systems 106 and 108 (or other systems not shown) are capable of delivering data to the electronic devices 100. Moreover, the electronic devices 100 are also able to communicate data with each other.
The electronic device 100 further includes a media player 210, which can cooperate with the browser 202 to display certain media elements of the web page 204. As an example, the media player 210 can be a Flash® player, or other type of player configured to play (render) audio content, video content, multimedia content, or any other content according to a predefined format. A Flash® player is configured to cooperate with the browser 202 to render Flash content, which adds animation, video, and interactivity to web content. Although just one media player 210 is shown in
The media player 210 can be a plug-in module to the browser 202. Alternatively, the media player 210 can be an external module that can be invoked by the browser 202. As yet another example, the media player 210 can be integrated into the browser 202, or alternatively, the functionalities of the media player 210 can be provided by the browser 202.
The electronic device 100 has various media decoder resources 212 that can be employed by the media player 210 to render respective media elements of the web page 204.
As further shown in
The electronic device also includes one or more input/output (I/O) devices 312 (e.g. user input device, I/O port interface, etc.), and a network interface 314 to allow the electronic device 100 to communicate over a network. In some examples, the network interface 314 is connected to an antenna 316 to allow the electronic device 100 to perform wireless communications. Alternatively, the network interface 314 can be configured for wired communications over a wired network.
In addition, the electronic device 100 includes a hardware media decoder 318, which can be implemented with a graphics processing unit (GPU), a digital signal processor (DSP), or other type of hardware processing element. The hardware media decoder 318 can be considered to be a dedicated hardware media decoder 318, since it is dedicated to perform decoding tasks for one media element at a time.
The various hardware components of the electronic device 100 are coupled to an interconnect 320, which can represent one or multiple buses of the electronic device 100. Communications among the hardware components occur over the interconnect 320.
The electronic device 100 also includes an operating system 322, which can be initially stored on the flash memory 308 or on the secondary storage device 310, and loaded for execution on the processor(s) 302. Additionally, other software layers of the electronic device 100 include various programs 324, which can include the browser 202, a software media decoder 326, and a hardware-assisted software media decoder 328. The software media decoder 326 is executable on the processor(s) 302 to perform media decoding tasks. The hardware-assisted media decoder 328 is also executable on the processor(s) 302, except that the hardware-assisted media decoder 328 can leverage hardware resources (e.g., a DSP or other type of hardware processing resource) to enhance media decoding performance.
The software media decoder 326, hardware-assisted software media decoder 328, and hardware media decoder 318 are examples of the media decoder resources 212 shown in
To enhance rendering performance of the user content media element 406, the user content media element 406 is assigned a higher priority than that of the advertisement media element 404 by the prioritizer 216 of the browser 202 (
The rendered web page content 208 of
The HTML code of
The HTML code of
Note that in other examples, other tags can be used for defining the media elements 404 and 406 of
The prioritizer 216 of the browser 202 prioritizes (at 506) the media elements such that a first media element is assigned a higher priority and a second media element is assigned a lower priority. More generally, the media elements are prioritized such that the multiple media elements are assigned different priorities.
Next, the allocator (218 or 220 of
The multiple media elements are rendered (at 510). In the example of
The rendered data is then output (at 518) for display by the display device of the electronic device.
As further shown in
Also, the multiple instances of the software decoding resources can be assigned individual scheduling priorities in the operating system of the electronic device such that the instances, too, can be used to provide varied quality experiences for different media elements. For example, in a system where only a software media decoder is present (or amongst media elements where only the software media decoder is applicable), the different software decoder instances (having different priorities) can be assigned to the respective media elements. For example, one software decoder instance for processing a first media element can be assigned 20% of the system CPU time, and another software decoder instance for processing a second media element can be assigned 80% of the system CPU time. In other examples, a ratio of CPU time usage can be defined for the different software media decoder instances, since other system operations may have to use some portion of the CPU time as well. This approach can also be applicable to other media decoder types that are capable of multitasking across multiple media elements.
In
Another structure that is depicted in
The markup language code of a web page can be matched to one or more advertisement patterns in the advertisement pattern database 604. Upon detecting a match, the browser 202 can determine that an advertisement media element has been identified and thus will set the priority of such media element accordingly. Although not shown, other pattern databases can be provided for storing patterns in markup language code associated with other types of content, including different types of user content (e.g. games, movies, music, etc.).
Settings/tuning parameters 606 can also be associated with the browser 202. This can allow a user or other application to control the setting of priorities of various different types of media elements. For example, the settings/tuning parameter 606 can specify that advertisement media elements are to only be assigned the software media decoder if the software media decoder is available; otherwise, the advertisement media element is not rendered until the software media decoder becomes available. Also, the settings/tuning parameters 606 can specify that certain types of user content media elements (e.g. games) are to be assigned higher priority over other types of user content media elements (e.g. music).
As further shown in
The priority hints 702 can be in the form of indicators associated with respective media elements that are sent from the browser 202 to the media player 210 for rendering. Using the priority hints 702, the allocator 220 of the media player assigns media decoding resources to render respective media elements. In the example of
Note that prioritization can be based on a consideration of any one or combination of the foregoing factors.
Task 906 checks for an advertisement pattern in the markup language code. For example, in
In addition, task 912 checks the size of the media element, task 914 checks the location of the media element, task 916 checks the amount of previous interaction with the media element, and task 918 checks the amount of time since last interaction with the media element.
By using techniques or mechanisms according to some implementations, more effective usage of resources of an electronic device in rendering media elements of a web page can be provided. By assigning higher performance media decoding resources to higher priority media elements, user experience is enhanced.
Machine-readable instructions of various modules described above (such as 202, 210, 214, 216, 218, 220, 326, 328) are executed on a processor or processors (such as 302 in
Data and instructions are stored in respective storage devices, which are implemented as one or more computer-readable or machine-readable storage media. The storage media include different forms of memory including semiconductor memory devices such as dynamic or static random access memories (DRAMs or SRAMs), erasable and programmable read-only memories (EPROMs), electrically erasable and programmable read-only memories (EEPROMs) and flash memories; magnetic disks such as fixed, floppy and removable disks; other magnetic media including tape; optical media such as compact disks (CDs) or digital video disks (DVDs); or other types of storage devices. Note that the instructions discussed above can be provided on one computer-readable or machine-readable storage medium, or alternatively, can be provided on multiple computer-readable or machine-readable storage media distributed in a large system having possibly plural nodes. Such computer-readable or machine-readable storage medium or media is (are) considered to be part of an article (or article of manufacture). An article or article of manufacture can refer to any manufactured single component or multiple components. The storage medium or media can be located either in the machine running the machine-readable instructions, or located at a remote site from which machine-readable instructions can be downloaded over a network for execution.
In the foregoing description, numerous details are set forth to provide an understanding of the subject disclosed herein. However, implementations may be practiced without some or all of these details. Other implementations may include modifications and variations from the details discussed above. It is intended that the appended claims cover such modifications and variations.
Number | Date | Country | Kind |
---|---|---|---|
11166074.2 | May 2011 | EP | regional |