Described below are a method and a device for generating a complexity vector for at least one part of an SVG scene, and a method and a testing device for testing a playback suitability of at least one part of an SVG scene on a device.
The SVG standard (SVG—Scalable Vector Graphics) is a standard for the description of two-dimensional vector graphics in the XML syntax (XML—Extensible Markup Language). SVG supports three fundamentally different types of elements:
In this situation, the SVG scene describes one or more objects. Furthermore, the SVG scene can also have interactions or links to external information. An SVG document describes the SVG scene and in doing so comprises one or more of the aforementioned types. Further details on the SVG standard can be found for example in SVG—Scalable Vector Graphics, 1.1 Specification, W3C Recommendation, 14 Jan. 2003, which is available at www.w3.org/TR/2003/REC-SVG11-20030114/REC-SVG11-20030114.pdf. Thanks to the scalability of SVG, vector graphics can be tailored to the particular circumstances of a device, a PDA for example (PDA—Personal Digital Assistant) or a mobile radio device, whereby the vector graphics are rendered. Raster graphics on the other hand have a fixed resolution and need to be interpolated in the case of greater variations, which is also accompanied by a greater computing requirement in addition to a loss in quality. Specifically to satisfy the needs of lower power terminal devices, such as a mobile telephone for example, SVG has been restricted to a subset, the so-called SVGT (SVGT—SVG Tiny), a first profile of the mobile SVG standard, see Mobile SVG Profiles: SVG Tiny and SVG Basic, W3C Recommendation 14 Jan. 2003, available at www.w3.org/TR/SVGMobile/. In spite of the reduced functional scope of SVGT, demanding SVGT scenes can be generated which may overburden the resources of terminal devices. SVG is generally spoken of in the following, whereby this is understood to mean the SVG standard itself and one of the profiles of the mobile SVG standard.
One disadvantage with SVG is the fact that the terminal device may play back an SVG scene in a quality which is unacceptable to a user, the playback of individual SVG objects not being performed in real time for example. A second disadvantage is the fact that bandwidth is used when transferring the SVG document, for which a high price must be paid in the case of a mobile device although the SVG scene, deposited in the SVG document, cannot be played back perfectly on the terminal device.
An aspect therefore is to set down methods and devices which make it possible to avoid a transfer and also a playback of at least one part of an SVG scene which is unsuitable for a device.
The method relates to generating a complexity vector which represents a complexity of at least one part of an SVG scene, wherein a complexity variable associated with the respective element is determined for at least one element of a DOM tree (DOM—Document Object Model) of the SVG scene and the complexity vector is generated by the at least one of the complexity variables.
This method ensures that a complexity of an SVG scene or of a part of the SVG scene can be generated in a simple manner in the form of a complexity vector. This method is wherein the fact that it is executed once in order to generate the complexity vector and can be used again at any time if for example the desired SVG scene is retrieved by a device. In addition, the complexity of the SVG scene can be stored compactly in organized fashion with a low memory requirement through the complexity vector.
In an extension of the method, for the SVG scene which changes in time-related fashion the complexity vector is generated as a result of the fact that in each temporary instance of the DOM tree the respective complexity variable of the element is determined and a greatest value from the determined complexity variables of the element is assigned to the complexity vector.
This extension of the method takes into consideration the fact that the complexity variable of the respective elements of the SVG scene can change over time, namely dependent on temporary instances of the DOM tree. The result achieved by this extension is the fact that the complexity variables of the elements of the temporary instances are captured and compared with one another in order to then determine the greatest complexity variable for each element, which a terminal device must fulfill in order to be able to play back the present SVG graphics scene faultlessly.
In an alternative embodiment, the complexity vector is generated for the SVG scene which changes in time-related fashion as a result of the fact that
In this way, a weighting of the complexity variables can be performed, as a result of which a more precise ascertainment of a playback suitability of the SVG scene or of the part of the SVG scene is made possible.
In an extension of the method, at least one of the following elements and the associated complexity variables in each case are analyzed:
The complexity variables of the stated elements are characterized in particular by the fact that they can be determined in a simple manner from the SVG scene. Furthermore, through combination of complexity variables of one or more of the elements it is possible to achieve a granularity of the complexity of the SVG scene.
The device is used for generating a complexity vector which represents a complexity of at least one part of an SVG scene, whereby the device has a component which is designed to determine a complexity variable of at least one element of a DOM tree of the SVG scene and to generate the complexity vector through the at least one of the complexity variables. In an alternative extension, the device can be extended to the effect that it is additionally designed to execute at least part of the method for processing temporary instances of the DOM tree and a plurality of different elements of the SVG scene. The method can be implemented and executed with the aid of this device.
The method relates to testing a playback suitability of at least one part of an SVG scene for a device, wherein the playback suitability of the SVG scene is established on the device if, upon testing, none of the complexity variables of a complexity vector of the SVG scene is greater than the associated device complexity variable of a device complexity vector of the device, whereby a maximum complexity of the element of a DOM tree of the SVG scene is played back through the complexity variable and a maximum executable complexity of the element is played back on the device through the device complexity variable.
With the aid of this method for testing, it is possible in a simple manner by using the complexity vector of the SVG scene and the device complexity vector to determine whether the device is suitable for playing back the SVG scene faultlessly.
In an alternative development of the invention, the method for testing a playback suitability of at least one part of an SVG scene for a device can be performed in accordance with the following:
In this way it is possible to perform a weighting of the complexity variables, as a result of which a more precise determination of a playback suitability of the SVG scene or of the part of the SVG scene is made possible, particularly if the weighting takes account of specific properties of the device.
In an extension of the method for testing a playback suitability, at least one of the following elements and the associated complexity variable in each case are taken into consideration:
This extension has the advantage that on the one hand the reliability of the testing of a playback suitability can be scaled by testing a greater or smaller number of elements, whereby this scaling enables the testing to take place more quickly or to last longer.
Finally the invention also includes a testing device for testing a playback suitability of an SVG scene on a device, whereby the testing device has a testing unit which is designed to execute one of the two methods for testing the playback suitability. The testing device can furthermore be extended in such a manner that the testing unit is designed to execute the testing of one or more elements and the associated complexity variables in each case. The method for testing can be implemented and executed with the aid of this testing device.
These and other aspects and advantages will become more apparent and more readily appreciated from the following description of the exemplary embodiments, taken in conjunction with the accompanying drawings of which:
Reference will now be made in detail to the preferred embodiments, examples of which are illustrated in the accompanying drawings, elements having the same function and mode of operation are provided with the same reference characters.
The W3C (W3C—Worldwide Web Consortium, www.w3.org) has defined SVG as a language for two-dimensional graphics in XML. Graphical objects in SVG are based on simple primitives. In this situation, complex objects are composed of a plurality of simple objects. A path is the actual basic element in SVG and is specified as a quadratic or cubic Bézier curve. To this have been added the further objects circle, ellipse, rectangle, line, polyline, polygon to facilitate generation. In addition there are further graphical elements in the form of text and raster images, see SVG—Scalable Vector Graphics, 1.1 Specification and. A presentation mode for these elements can be controlled by way of attributes. Position information, width, height, radii, fill colors, stroke colors, stroke thickness, coverage of stroke and fill colors and also fill patterns can for example be specified in this situation.
SVG also enables graphical objects to be dynamically modified. This is described by specifying animation instructions which permit a time-related change in the following states: transformation, position, visibility, color and size. Alternatively, the possibility also exists through the use of script languages (for example Javascript, Pearl, PHP, JSP etc.) to manipulate a DOM structure (DOM—Document Object Model) of an SVG graphic or SVG scene and thus to permit interactions. To this end, either the script is placed for manipulation purposes in an SVG document, which describes the SVG scene, or it is referenced by way of an external file.
Audio and video objects are implemented in SVG by references to external files, the playback of which is controlled by way of associated attributes.
With the aid of
After the complexity variables G1 to G7 of the elements E1 to E7 of the SVG scene SVG_G have been captured, these are passed from step S1 to the following step S2. In step S2, one or more complexity variables are selected from the elements determined for the SVG scene, which form the complexity vector KV. In the present exemplary embodiment according to
The SVG scene SVG_G can change over time. In this case, the entire SVG scene is not analyzed all at once but in respective temporary instances T1_1, T1_2, T1_3 of the DOM tree DOM. As an example of the second complexity variable, in other words the line segment count G2 for the line segments E2, the respective line segment count G2_1, G2_2, G2_3 is formed for each temporary instance, for example G2_1 for TI_1, G2_2 for T1_2 etc. The complexity variables of the temporary instances per element are then subsequently tested to the effect that the complexity variable associated with the tested element having a greatest value, for example the complexity variable G2_2, is selected from the previously determined complexity variables G2_1, G2_2, G2_3 for the second element, in other words the required line segments E2 of the temporary instances, as the second complexity variable G2 to be used. This selected second complexity variable is then passed to the second processing step by analogy with the above example. In analogous fashion, further elements and associated complexity variables such as for example the letters E4 used per temporary instance T1_1, T1_2, T1_3 and the associated letter count can also be determined and evaluated, with the result that the fourth complexity variable, in other words letter count G4, can be determined by the first processing step S1.
In an alternative variant embodiment to the above, the complexity variables associated with the elements are first determined for each temporary instance. The complexity variables associated with the respective temporary instance are then linked through weighted addition, for example, to a complexity number KN1, KN2, KN3 associated with the respective instance. The weighted addition can multiply all linked complexity numbers by an identical factor, 1/10 for example, or take into account the respective weighting, such that a unit of one complexity variable demands a higher complexity, in other words for example computing power, than that of a different complexity variable, with the result that the weighting is all the greater than the complexity of the respective complexity variable. After an associated complexity number has been determined for each of the temporary instances, that complexity number which has a highest value is defined. In this way, that temporary instance which has the highest complexity is defined. Finally, the complexity vector is formed through one or more of the complexity variables of the temporary instance with the defined complexity number.
The aforementioned steps S1 and S2 are executed by component M1 of a device V.
Before the modified SVG document SVG_D′ is sent to a device X, for example a terminal device X designed in the form of a mobile telephone, a multimedia server for example tests whether the device X is capable of playing back the SVG scene SVG_G. To this end, recourse is had to a device complexity vector XKV which specifies for the device X which element E1, . . . , E7 of an SVG scene can be processed with which maximum complexity. This is represented in the following example according to
Since the associated device complexity variable per element is in each case greater than or equal to the associated complexity variable of the present SVG scene, this SVG scene can be played back completely and correctly by the device X. If for example XG6=2, then the present SVG graphics scene cannot be played back completely and correctly on the device X because XG6 is smaller than G6. It would be possible here for example by changing the SVG scene, such as through omitting a simultaneously executed animation, in other words a reduction to G6=2, to achieve a situation in which the device X is able to faultlessly play back the SVG scene.
In an alternative embodiment, a complexity number KNX is defined through a weighted addition of at least two of the complexity variables of the complexity vector KV. In this situation, in addition to an identical weighting of the complexity variables the weighting can also be undertaken in such a manner that a respective complexity variable, which represents an element of high complexity, receives a higher weighting factor than a complexity variable which represents a less complex element. This defined complexity number KNX is compared with a device complexity number XNX. If the defined complexity number KNX is smaller than or smaller than or equal to the device complexity number XNX, then the SVG scene can be played back on the device. The device complexity number represents a maximum complexity which can be played back on the device, for example a computing power in MIPS (MIPS—million instructions per second).
The aforementioned procedure for testing whether the device X is suitable for playing back the SVG scene is carried out using a testing device P including a testing unit MP.
The component M1 and also the testing unit MP can be implemented and executed in software, hardware or a combination of software and hardware. The method for generating and also the device for generating can for example be implemented in a video server. The complexity vector KV can also be stored separately from the SVG document SVG_D on the server for subsequent retrieval. Furthermore, the server can include the device for testing the playback suitability and also the testing device, or the testing unit. When a request is made by a mobile terminal device to transfer the SVG document, the server checks the playback suitability of the requested SVG scene. In the event that the playback suitability is established, identified by “J” in
A description has been provided with particular reference to preferred embodiments thereof and examples, but it will be understood that variations and modifications can be effected within the spirit and scope of the claims which may include the phrase “at least one of A, B and C” as an alternative expression that means one or more of A, B and C may be used, contrary to the holding in Superguide v. DIRECTV, 358 F3d 870, 69 USPQ2d 1865 (Fed. Cir. 2004).
Number | Date | Country | Kind |
---|---|---|---|
10 2007 032 812.7 | Jul 2007 | DE | national |
This application is the U.S. national stage of International Application No. PCT/EP2008/057064, filed Jun. 6, 2008 and claims the benefit thereof. The International Application claims the benefits of German Application No. 102007032812.7 filed on Jul. 13, 2007, both applications are incorporated by reference herein in their entirety.
Filing Document | Filing Date | Country | Kind | 371c Date |
---|---|---|---|---|
PCT/EP2008/057064 | 6/6/2008 | WO | 00 | 1/13/2010 |