Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the invention, the technical scheme in the embodiment of the invention is clearly and completely described, obviously, described embodiment only is the present invention's part embodiment, rather than whole embodiment.Based on the embodiment among the present invention, those of ordinary skills belong to the scope of protection of the invention not making the every other embodiment that is obtained under the creative work prerequisite.
In the play handling method of embodiment of the invention e-magazine and device, mainly be by definition and expansion to synchronous and asynchronous label in the smil language, be implemented in the e-magazine support to the synchronous and asynchronous broadcast of content of multimedia.Smil is the abbreviation of synchronous multimedia integrate language (Synchronized Multimedia IntegrationLanguage), and it is the multimedia manipulation language by 3W (World Wide Web Consortium) organization prescribed.The Smil language is a carrier with XML, uses simple text label to define time, space and synchronous and asynchronous mode that multimedia segment (sound, video file, picture, literal etc.) is play.3GPP is according to the specific (special) requirements of portable terminal, the smil language corresponding adjustment and normalized definition have been carried out, its grammer and semanteme are reused in permission in other the language based on XML, so the smil language is particularly suitable for and wishes to describe sequential combining with the language of synchronous expression behaviour.
According to the above-mentioned feature of smil language, as shown in Figure 1, the embodiment of the invention one provides a kind of play handling method of e-magazine, comprises the steps:
Step 11, under the synchronous and asynchronous label of synchronous multimedia integrate language, expanded definition is formed the content of multimedia of e-magazine.
Wherein, described content of multimedia can comprise text, sound clip, audio frequency and video fragment etc.The content of multimedia of forming e-magazine can be used as the front cover of this e-magazine, catalogue page, and first page, perhaps other pages or leaves are perhaps as back cover.And in this step, the content of multimedia of expanded definition composition e-magazine comprises the property parameters of the described content of multimedia of expanded definition, as display mode, and file format or the like.
The synchronous and asynchronous label of step 12, the described synchronous multimedia integrate language of parsing.
In the smil language, by defining asynchronous (in proper order) and the synchronous playing of two distinctive " seq ", " par " label realization multimedia element.Wherein, " seq ", " par " label are defined as follows:
(1) the seq label is defined as follows:
<seq?dur=″indefinite″>.........</seq>
It is played in order that " seq " label defines its contained element, and has defined the time span that label is play.Be interpreted as in official hour (value of dur attribute), all elements presents in proper order, and the concluding time of previous element is defaulted as the time started of next element.Its element can be " par " label, or a plurality of multimedia file such as text, image, audio frequency and video etc.
(2) the par label is defined as follows:
<par?dur=″indefinite″>.........</par>
It is synchronous playing that " par " label defines its contained element, and has defined the time span that label is play.Be interpreted as in official hour (value of dur attribute), contained element is carried out synchronously.Its element can be " seq " label or a plurality of multimedia file such as text, image, audio frequency and video etc.
Content of multimedia is being carried out in the process of synchronous and asynchronous processing, according to the definition of smil linguistic labels, processing mode is as follows:
When parsing obtains asynchronous label, under described asynchronous label, realize the content of multimedia asynchronous play; When parsing obtains sync tag, under described sync tag, realize the content of multimedia synchronous playing; When parsing obtains sync tag and is the daughter element of asynchronous label, under described asynchronous label, realize the content of multimedia asynchronous play, under described sync tag, realize the content of multimedia synchronous playing; When parsing obtains asynchronous label and is the daughter element of sync tag, under described sync tag, realize the content of multimedia synchronous playing, under described asynchronous label, realize the content of multimedia asynchronous play.
Because the processing modes such as synchronous and asynchronous broadcast of smil language support multimedia file itself, so the embodiment of the invention one has realized support to the synchronous and asynchronous broadcast of content of multimedia by the definition to the smil label.
Step 13, according to the analysis result of described synchronous and asynchronous label, to described content of multimedia synchronously and/or asynchronous play.
Certainly, described e-magazine comprises one page under simple situation, but as a rule, e-magazine generally all includes multipage.Therefore, in the embodiment of the invention one described method, as shown in Figure 2, before above-mentioned steps 12, also can comprise:
Step 110, described content of multimedia is carried out paging handle.
In the process of making e-magazine, according to the smil Characteristics of Language, can be with the opening flag of " seq " label as the e-magazine content, the daughter element under this label is as the sequence of page or leaf; " par " label is as the sign of page or leaf, and the daughter element under this label is the page or leaf internal information of showing synchronously.Each " par " in " seq " label or a plurality of multimedia element sequence have been formed each page or leaf of magazine like this.
In concrete application process, when content of multimedia being carried out paging and handles, can be at first with under described asynchronous label, each content of multimedia that order is presented is as independent one page.For sync tag,, the content of multimedia under the described sync tag is formed every page content of described e-magazine if described sync tag is the daughter element of described asynchronous label.For described asynchronous label, not under sync tag and with the single content of multimedia of described sync tag peer, can form independent one page.Form the inside of page or leaf at sync tag, when containing asynchronous label sub-element, the content of asynchronous label is play as the order of elements in this page.
After having carried out above-mentioned paging processing, content of multimedia is being carried out in the process of synchronous and asynchronous broadcast, be unit promptly with the page or leaf, carry out synchronous and asynchronous playback process at each paging.
In addition, in order to realize forming the diversified presentation mode of content of multimedia, in the embodiment of the invention one, also can be by expanded definition to the synchronous and asynchronous label of smil language, manual page turning, the redirect formula that realizes content of multimedia read, focus is switched and interactive mode is read, the convergent-divergent of image shows functions such as roll display.
State in realization in the process of function, both can utilize the existing tag attributes of smil language to realize, also can realize by tag attributes to expansion smil language.
Read this function for manual type page turning and redirect formula, carried out the paging processing according to step 110 pair content of multimedia after, can be with every page of component chained list of e-magazine.Current page is to a node that should the element chained list, then according to the difference between the page object and the current page page number, find this page object pairing node in the element chained list, and jump to the page or leaf at this corresponding node place, realize manual page turning or click element in the page, by hyperlink, realize the reading of redirect formula.
For example, the form of supposing this element chained list is T3-〉T4-〉T5-〉T6-〉T7-〉T8, if current page is the page or leaf at T6 node place, when selecting to go up page turn over operation, then search for previous node forward, navigate to the T5 node and play the page turn over operation of realization page up.If current page is the page or leaf at T6 node place, if search a back node T7, then redirect and play the page or leaf at T7 node place and page turning under realizing; If current page is the page or leaf at T6 node place, if wish to jump to first page, then can obtain first page with T6 node place pages 4 between page number difference be 3, search forward by the T6 node then that to differ with the T6 node be 3 node T3, redirect is also play the page or leaf at T3 node place, realizes the reading of redirect formula.
In existing smil language, by the link information of " area " label definition multimedia file.The Area label is defined as follows:
<area?href=″#pagel″coords=″25%,26%,87%,31%″/>
Wherein, the anchor point of href properties point link can be the anchor point or the external file of file inside, and the coords attribute is for activating the rectangular area of this link anchor point.Therefore, in realizing the process that focus is switched, by statistics page link element link area or need resident zone, and the zone is defined, set up the focus information chained list, activate the focus that contains link, realize that focus switches.And read for interactive mode, the embodiment of the invention is by the color of expanded definition smil language " fontColor " text label attribute, scroll bar " scrollColor " text label attribute and border color " rectColor " text label attribute, and definition can resident focus the zone, by clicking or button operation realizes.When convergent-divergent demonstration that realizes image and roll display function, be to realize by automatic rolling " autoscroll " attribute of expanded definition smil language.
In addition, for the realization of the zooming display function of image,, utilize " fit " attribute tags of smil language to realize that the convergent-divergent of image shows when the viewing area of image fixedly the time.And, realize by expanded definition automatic rolling " autoscroll " attribute in synchronous multimedia integrate language in embodiments of the present invention for the dynamic demonstration of image.
By as can be seen above, the play handling method of the e-magazine of the embodiment of the invention is based on the making that e-magazine realized in the smil language.Because the processing modes such as synchronous and asynchronous broadcast of multimedia file supported in smil language itself, so the embodiment of the invention has realized the support of e-magazine to the synchronous and asynchronous broadcast of content of multimedia by the definition to the smil label.
Below with one section concrete smil LISP program LISP section, specifically describing is the realization that how to realize the making of e-magazine and various functions.
Utilize the block of smil language description as follows:
<body> T1
<seq> T2
<par id=″fengmian″dur=″indefinite″> T3
<img src=″images/main/fengmian.png″/>
</par>
<par id=″content″dur=″indefinite″> T4
<img src=″images/content/contentl.jpg″>
<area?href=″#pagel″coords=″25%,26%,87%,31%″/>
<area?href=″#page2″coords=″25%,31%,87%,54%″/>
<area?href=″#page3″coords=″25%,54%,87%,64%″/>
<area?href=″#page4″coords=″25%,65%,87%,74%″/>
</img>
</par>
<par id=″pagel″dur=″100″> T5
<img src=″images/1.png″/>
<text src=″txts/1.txt″left=″5″top=″5″width=″220″
height=″200″>
<param?name=″fontColor″value=″white″/>
<param?name=″scrollColor″value=″white″/>
</text>
</par>
<par id=″page2″dur=″indefinite″> T6
<img src=″images/2.png″>
<param?name=″autoscroll″value=″true″/>
</img>
</par>
<img id=″page3″src=″images/3.png″dur=″indefinite″/> T7
</sep>
<par id=″page4″dur=″indefinite″> T8
<seq>
<img src=″images/4.png″/dur=″10″>
<viedo?src=″video/4.wmv″/>
</seq>
<audio?src=″audio/4.mp3″/>
</par>
</body>
By above description as can be seen,<body〉beginning of sign e-magazine content, this label is must exist during smil describes and unique.Child node is defaulted as played in order under this label, shown in the T1 section.
<seq〉child node is a played in order under the label.Child node can be<par 〉, also can be independent multimedia element, each child node is carried out played in order as one page.If playback period is endless dur=" indefinite ", then must just can switch to the beginning of next node, shown in the T2 section by mutual.Certainly,<seq〉also can be used as<par the daughter element of label forms one page, the order of elements in the sign page or leaf is play, thus the variation of abundant page or leaf interior element, shown in the T8 section.At<par〉each element synchronous playing under the label.
And, by top block as can be seen, in this e-magazine, defined front cover (fengmian), catalogue (content), first page (pagel), second page (page2), the 3rd page (page3), the 4th page (page4) composition respectively.And the assigned catalogue playback period is infinitely great among the T4, and all have only manual page turning just can enter down one page.And the T5 section specifies first page to play 100 seconds, and then system can play second page automatically playing first page after 100 seconds.In the 4th page, audio file and seq label synchronous playing, but picture in the seq label and video file can played in order, promptly first playing pictures 10 seconds, displaying video afterwards, and audio file synchronous playing always.By first element of each page, the component chained list generates paging and statistical information, and chained list is as follows:
T3->T4->T5->T6->T7->T8。
Wherein, in front cover, include image.
In catalogue, include picture, wherein utilize the area tag attributes to define link information in this e-magazine, shown in the T4 section.Comprise 4 link area<area in the T4 section〉definition, then according to descriptor, registration focus area (coords can be absolute or relative location definition), form the focus area chained list, according to the input key assignments, realize moving up and down of focus, click and determine then to enter corresponding link anchor point, realize the redirect of the page.
In first page, comprise image and text, wherein defined wide, the high attribute of text, and utilize " fontColor ", " scrollColor " to define the color attribute and the scroll bar color attribute of text, shown in the T5 section.If when text display surpasses define regional in the T5 section, then can generate scroll bar and action button automatically, defining operation button rectangle region switches just can realize focus, when upwards button obtains focus, can carry out the forward direction of text and read; When knob down obtained focus, text rolled backward.
In second page, comprise picture, and utilize " autoscroll " to define automatic rolling bar attribute, shown in the T6 section.In the T6 section, " autoscroll " is set to " true ", indicate the roll screen demonstration automatically of this picture, if the picture original size is 240*600, and the target viewing area is 240*320, then this figure sector-meeting shows automatically from left to right or from the right circulating rolling of dextrad, thus the displaying that makes things convenient for image with simplify the operation course.
In the 3rd page, include picture, shown in the T7 section; In the 4th page, include picture, video and audio frequency, shown in the T8 section.
By carrying out top program, the paging of e-magazine, every page playback process have been finished, as image zoom, focus switching and link etc.Therefore, utilize the technical scheme of the embodiment of the invention one, realized the complicated presentation mode of e-magazine content.
And in the manufacturing process of the e-magazine of reality, because different designers' mentality of designing difference, thereby cause e-magazine may present different broadcast modes.But no matter how complicated broadcast mode all can regard the combination of the defined processing mode of some statement in the said procedure as.
One of ordinary skill in the art will appreciate that all or part of flow process that realizes in the foregoing description method, be to instruct relevant hardware to finish by computer program, described program can be stored in the computer read/write memory medium, this program can comprise the flow process as the embodiment of above-mentioned each side method when carrying out.Wherein, described storage medium can be magnetic disc, CD, read-only storage memory body (Read-Only Memory, ROM) or at random store memory body (Random Access Memory, RAM) etc.
As shown in Figure 3, the embodiment of the invention two provides a kind of playback process device of e-magazine, comprising:
Content is provided with unit 21, is used under the synchronous and asynchronous label of synchronous multimedia integrate language, and expanded definition is formed the content of multimedia of e-magazine;
Label resolution unit 22 is used to resolve the synchronous and asynchronous label of described synchronous multimedia integrate language,
Playback process unit 23 is used for the analysis result according to described label resolution unit, and described content of multimedia is carried out synchronously and/or asynchronous play.
With describe among the embodiment one identical, described e-magazine is comprising one page under simple situation, but as a rule, e-magazine generally all includes multipage.Therefore, as shown in Figure 4, also can comprise: paging processing unit 24 is used for that described content of multimedia is carried out paging and handles, and the result that paging is handled sends to described playback process unit.
Wherein, described paging processing unit 24 can comprise: the paging module, be used under asynchronous label, with each content of multimedia of presenting of order as independent one page, or will be at described asynchronous label, not under sync tag and with the single content of multimedia of described sync tag peer, form independent one page; Content of pages is provided with module, is used for when sync tag is the daughter element of asynchronous label, the content of multimedia under the described sync tag is formed every page content of described e-magazine.
In order to enrich the presentation mode of e-magazine content, as shown in Figure 5, the embodiment of the invention two described devices also can comprise:
Manually page processing unit 25 is used for realizing the manual page turning of the content of multimedia under the described synchronous and asynchronous label according to the analysis result to described synchronous and asynchronous label.
Redirect formula read unit 26 is used for according to the analysis result to described synchronous and asynchronous label, realizes that the redirect formula of the content of multimedia under the described synchronous and asynchronous label is read.
Focus switch unit 27 is used for according to the analysis result to described synchronous and asynchronous label, realizes that the focus of the content of multimedia under the described synchronous and asynchronous label is switched and interactive the reading.
Image zoom rolling unit 28 is used for according to the analysis result to described synchronous and asynchronous label, realizes that the convergent-divergent of the image in the content of multimedia under the described synchronous and asynchronous label shows and/or roll display.
Above-mentioned manual page processing unit 25, redirect formula read unit 26, focus switch unit 27 and image zoom rolling unit 28 can be selected as required, to realize the combination of different Presentation Functions.
In sum, the play handling method of the e-magazine of the embodiment of the invention and device are based on that the smil language realizes.Because the processing modes such as synchronous and asynchronous broadcast of multimedia file supported in smil language itself, so the embodiment of the invention has realized the support of e-magazine to the synchronous and asynchronous broadcast of content of multimedia by the definition to the smil label.
The above; only be the specific embodiment of the present invention, but protection scope of the present invention is not limited thereto, anyly is familiar with those skilled in the art in the technical scope that the present invention discloses; can expect easily changing or replacing, all should be encompassed within protection scope of the present invention.Therefore, protection scope of the present invention should be as the criterion with the protection range of described claim.