Embodiment
Set up the corresponding relation of real name of resource, audio-frequency information sign and at least one download address in the multimedia resource in embodiments of the present invention in the server, and the above-mentioned relation of setting up is kept in the index data base, after user end to server sends the index request, server is according to the index request that receives, the coupling real name of resource, the real name of resource corresponding download address that the match is successful is offered client, and client is obtained multimedia resource according to the download address that receives from server or other clients.
Wherein, the corresponding relation of setting up real name of resource and audio-frequency information sign in the index data base comprises, the multimedia resource that will have identical audio-frequency information sign, at least one corresponding real name of resource is determined at least one optimum real name of resource according to the real name of resource selection rule of setting up, and preserves the corresponding relation of definite optimum real name of resource and audio-frequency information sign.And, real name of resource is the title of multimedia resource, can obtain different real name of resource according to different modes for a multimedia resource, but the real name of resource of choosing in the embodiment of the invention should be the title that can describe the content of multimedia resource, and the method for choosing can have a variety of, for example adopts the method for priority to select real name of resource etc.Therefore, when same audio-frequency information identifies corresponding a plurality of real name of resource, can utilize aforesaid way to select optimum real name of resource, set up the corresponding relation of real name of resource and audio-frequency information sign.
Wherein, the index request comprises, searching request, download request or Streaming Media request, and the index request can also comprise other request modes to multimedia resource.
Simultaneously, also set up the corresponding relation of multimedia resource sound intermediate frequency message identification and at least one file identification in embodiments of the present invention, and set up the corresponding relation of each file identification and at least one download address, the described relation of setting up is kept in the index data base, promptly in index data base, set up real name of resource, the audio-frequency information sign, the corresponding relation of at least one file identification and at least one download address, the corresponding different file identification of wherein same audio-frequency information sign, can be understood as different file identifications and have identical audio-frequency information sign, simultaneously, the corresponding different download address of identical file sign, can be understood as same multimedia resource can download on different servers or client.
Wherein, file identification comprises the title of multimedia resource or the uniform resource position mark URL or the resource content signature of multimedia resource, wherein, resource content signature calculates the back by pre-defined algorithm to the content-data of scale-of-two resource and obtains, and described pre-defined algorithm is for to handle the algorithm that obtains different results to the content-data of different scale-of-two resources; The setting up procedure of audio-frequency information sign comprises: video information in the multimedia resource is separated with audio-frequency information, obtain the audio-frequency information in the described multimedia resource, calculate described audio-frequency information sign according to described audio-frequency information.
For each multimedia resource, mainly comprise audio-frequency information and video information two parts, wherein, the shared resource of video information is bigger, and consideration is for various reasons usually carried out various processing to the video information of multimedia resource, handle comprising compression, sharpness to the multimedia resource picture impacts like this, simultaneously, because variation has also taken place in the file identification that influences multimedia file of compression; Simultaneously owing in the process that the video information of multimedia resource is handled, usually can not handle the sound of multimedia resource, promptly can not change the audio-frequency information in the multimedia resource, so exist on the internet and much have identical audio-frequency information, but video information difference, be the different multimedia resource of image quality, the multimedia resource that promptly has different file identifications can have identical audio-frequency information sign.Therefore, the multimedia resource index that will have identical audio-frequency information in embodiments of the present invention, utilize the specific practice of the index of audio-frequency information to be, the audio-frequency information of multimedia resource is separated with video information, obtain audio-frequency information wherein, and calculate this audio-frequency information sign, utilize this audio-frequency information sign as index value, all have the multimedia resource of this audio-frequency information sign index, comprise multimedia resource with the different file identification of having of different compression degrees, when the user searches for like this, can search and have identical audio-frequency information, but image sharpness may be different multimedia resource, enlarged user search result's scope.
Below be the method for a kind of index multi-media resource of providing of the embodiment of the invention, referring to shown in Figure 1, key step is as follows:
The download address of S11, acquisition multimedia resource and this multimedia resource;
Web Spider automatically grabs server database with the URL information on the webpage and its corresponding descriptor such as text message by network, server arrives its corresponding multimedia resource according to this URL download of information again, and extract descriptor in the text message, more excellent, can determine the real name of resource of this multimedia resource by text message.
S12, determine multimedia file identification and this multimedia resource sound intermediate frequency message identification;
Sign be content signature (Content Identity, CID).CID calculates the back according to the algorithm that is provided with to the content-data of scale-of-two resource to obtain.The algorithm that is provided with can be that the content-data of different scale-of-two resources is handled the arbitrary algorithm that obtains different results, its result (be content signature) but unique identification scale-of-two resource, perhaps, also can be that the result repetition rate is extremely low, the algorithm in tolerance interval.
Wherein, the method of obtaining the content signature comprises: the uniquely identified algorithm that employing can be calculated resource content calculates the content signature, perhaps, also can be to adopt the result repetition rate extremely low, algorithm in tolerance interval calculates, and for example, the content-data of each scale-of-two resource is carried out Hash operation, obtain the cryptographic hash of resource content, the cryptographic hash of this resource content can this scale-of-two resource content information of unique representative.Hash algorithm can adopt md5-challenge MD (Message-Digest Algorithm) 5, MD4 etc., Secure Hash Algorithm SHA (Secure Hash Algorithm), SHS (Secure Hash Standard) etc.; Or,
Select the object of calculating, for example, can calculate all binary data contents of resource; Also can choose in the resource at least two sections binary data contents arbitrarily calculates, and the length of every section binary data content choosing is any, for example can calculate, also can calculate the initial 10K byte information of resource, middle 10K byte information and ending 10K byte information to the initial 20K byte information of resource, middle 20K byte information; Or,
The mode that result after calculating is synthesized.When choosing arbitrarily that at least two sections binary data contents are calculated in the resource, can adopt but be not limited to following mode the result who draws after calculating and synthesize: for example adopt the MD5 algorithm computation, the content of synthetic this resource that each the MD5 value that draws after calculating can be joined end to end is signed and is signed as content; The result who also can be again draws after to aforementioned calculating with the MD5 algorithm calculates again, draws the content signature, as the content signature of this resource.
Utilize said method to calculate the sign of multimedia resource, and the audio-frequency information of multimedia resource separated from this multimedia resource, can obtain binary data, preserve this binary data, calculate this audio-frequency information sign about this multimedia resource sound intermediate frequency information.For example can adopt the spliter in the directshow technology of Microsoft that the video information and the audio-frequency information of a multimedia resource are separated, and calculate this multimedia resource sound intermediate frequency message identification.Wherein, the method for calculating audio-frequency information sign also can be utilized the computing method of foregoing signature.
S13, set up the corresponding relation of real name of resource in the multimedia resource, audio-frequency information sign, file identification and download address, form index data base, use for the multimedia file index.
Wherein, when identifying corresponding different real name of resource for same audio-frequency information, for the index convenience, from a plurality of real name of resource, choose an optimum real name of resource, set up the corresponding relation of optimum real name of resource and audio-frequency information sign, the method of choosing optimum real name of resource has multiple, comprise, the method of priority is for example determined priority for the source of real name of resource, and the real name of resource of choosing the highest source correspondence of priority is as optimum real name of resource, also comprise, according to the number of times that the different speech of real name of resource kind occurs, reach the form calculating priority level of real name of resource, determine optimum real name of resource etc.
Also exist simultaneously, the situation that has different audio-frequency information signs for same real name of resource, for example having versions such as Chinese sounding, English sounding for a film " lord of the rings ", is different audio-frequency information signs for different language, but corresponding real name of resource.Therefore, also can set up the multimedia resource with same asset real name in embodiments of the present invention, the relation of corresponding different audio-frequency informations sign is carried out the index of multimedia resource according to this relation.
Below be a kind of method that multimedia resource is provided that the embodiment of the invention provides,, comprise the steps: referring to shown in Figure 2
S21, terminal to server send the index request;
The index request that S22, server receiving terminal send;
S23, the index request that receives according to key word are mated, determine the real name of resource that the match is successful, according to the key word real name of resource of setting up, with the corresponding relation of multimedia resource sound intermediate frequency message identification, file identification, download address, above-mentioned real name of resource is offered client to deserved download address; Obtain multimedia resource sound intermediate frequency message identification;
The download address that S24, terminal reception server provide is obtained multimedia resource according to above-mentioned download address.
When the index request is searching request, show that search is to trigger by the key word of automatic generation or the key word of terminal input from terminal interface, behind the key word that server reception client provides, the key word that receives is mated in index data base, search real name of resource corresponding audio message identification with this keyword matching success, determine the audio-frequency information that multimedia resource comprised that client is searched, this audio-frequency information sign may be one or more.For example, the key word of client input be " assemble number ", the audio-frequency information that server can be comprised to a plurality of films " assembly number " according to this keyword search, and as national language, Guangdong language, English etc., different audio-frequency informations has different audio-frequency informations and identifies;
According to the audio-frequency information sign that finds, in index data base, search the file identification that has corresponding relation with this audio-frequency information sign, promptly search the multimedia resource that all comprise this audio-frequency information; Obtain the download address of the multimedia resource searched according to this document sign.
Below be in the embodiment of the invention when the index request is download request, server provides the process of multimedia resource, as shown in Figure 3, this process may further comprise the steps:
S31, user end to server send download request;
S32, server receive the download request of client, according to the download address that client provides, according to the corresponding relation of the download address of setting up in the index data base, file identification and audio-frequency information sign, determine download address corresponding audio message identification;
When user end to server sends download request, for example from download engine application program downloaded resources, by the downloaded software client download address information is sent to server, server is after receiving the download address of client, because this download address is at corresponding file identification in index data base, and the corresponding audio-frequency information sign of this file identification, so can search the download address corresponding audio message identification that client sends by this corresponding relation.
S33, server are according to the audio-frequency information sign of determining, according to the corresponding relation of audio-frequency information sign, at least one file identification and at least one download address set up in the index data base, at least one corresponding download address of above-mentioned identical audio-frequency information sign is offered client;
After server has been determined download address corresponding audio message identification that client provides, according to the corresponding relation of setting up in the index data base, all a plurality of download address with multimedia resource of this audio-frequency information sign, different file identifications are offered client.Because, there is different resource versions in the multimedia resource that has identical audio-frequency information in server, the different resource of image quality for example, perhaps has only the resource of audio-frequency information etc., so, exist different file identifications corresponding with it for same audio-frequency information sign, each download address of each file identification correspondence of correspondence is offered client.
The download address that S34, client reception server provide, according to the download address that receives from the downloaded multimedia resource.
Be the process that multimedia resource is provided under the situation of index request for download request above, when the index request is the Streaming Media request, this process comprises: server is according to this Streaming Media browse request coupling real name of resource, determine the corresponding audio message identification according to the real name of resource that the match is successful, and according to the definite corresponding a plurality of download address of this audio-frequency information sign, simultaneously, server is adjusted according to the pressure condition of each download address corresponding server, and the media stream of the server that selection pressure is low weight offers client.Wherein, the low weight server of pressure comprises in the embodiment of the invention, server or client of information etc. is provided to other clients.Comprise that also server is according to the browse request of client to Streaming Media, the coupling real name of resource is determined the corresponding audio message identification, and server provides the image quality download address of multimedia resource preferably according to the network condition of client to client.
For example: " assemble number " high-resolution version is because the user who watches is too much, so the pressure of server is bigger certainly, when " assemble number " watched in other users request, streaming media server finds this Streaming Media corresponding audio message identification according to user's request, obtains including all multimedia resources of this audio-frequency information according to this audio-frequency information sign.Special nature according to multimedia resource: the identical then video content of audio frequency is much the same, video definition may be different in these streaming media resources, captions may be different, other signs or the like also may have been added, but the audio-frequency information of these Streaming Medias must be identical, at this moment server can compare the pressure size of each streaming media server, and the pairing streaming media resource of the streaming media server address that pressure ratio is less returns to client, and the user utilizes this address to watch.Perhaps, the user is watching the bad Internet resources of image quality, but the network condition of client is better at this moment, and then server provides picture multimedia resource corresponding download address preferably to client, watches for the user.
In the embodiment of the invention, have unique audio-frequency information sign for each multimedia file, and have unique file identification.The content that comprises at the multimedia resource with identical audio-frequency information is identical, multimedia resource is divided according to the audio-frequency information that has, foundation has the corresponding relation of the multimedia resource of the different file identification of identical audio-frequency information sign, and the different multimedia resource with identical audio-frequency information sign is provided to client.
The embodiment of the invention provides a kind of device of index multi-media resource, as shown in Figure 4, comprises memory module 410 and index module 420.Wherein, memory module 410 is used for preserving the corresponding relation of multimedia resource real name of resource, audio-frequency information sign and at least one download address; Index module 420 is used for according to the index to multimedia resource, according to the described corresponding relation of preserving, the described multimedia resource of index.
Described memory module 410 comprises that corresponding relation is set up unit 411, first storage unit 412 and second storage unit 413.Wherein, corresponding relation is set up unit 411, is used for setting up the corresponding relation of multimedia resource real name of resource, audio-frequency information sign and at least one download address; First storage unit 412 is used to preserve the corresponding relation of real name of resource and audio-frequency information sign; Second storage unit 413 is used to preserve the corresponding relation of multimedia resource sound intermediate frequency message identification and at least one file identification, and preserves the corresponding relation of each file identification and at least one download address.And described corresponding relation is kept in the index data base.
Described corresponding relation is set up unit 411 and is comprised, audio-frequency information sign determining unit 414, optimum real name of resource determining unit 415 and first corresponding relation are set up unit 416.Wherein, audio-frequency information sign determining unit 414 is used for the multimedia resource video information is separated with audio-frequency information, obtains the audio-frequency information in the described multimedia resource, calculates described audio-frequency information sign according to described audio-frequency information; Optimum real name of resource determining unit 415 is used for determining at least one optimum real name of resource according to the real name of resource selection rule that is provided with; First corresponding relation is set up unit 416, is used for setting up the corresponding relation of real name of resource and audio-frequency information sign according to the described audio-frequency information sign of determining, described optimum real name of resource.
The embodiment of the invention provides a kind of system that multimedia resource is provided, and as shown in Figure 5, comprises the server and client side.Wherein, server, be used for index request,, at least one download address of the real name of resource correspondence of coupling offered described client according to the corresponding relation of the real name of resource of setting up in the index data base, audio-frequency information sign and at least one download address according to client; Client is used for sending the index request to described server, receives the described download address that described server sends, and obtains multimedia resource according to described download address.
The embodiment of the invention provides a kind of server, as shown in Figure 6, comprises receiver module 600 and module 610 is provided.Wherein, receiver module 600 is used to receive the index request that client sends; Module 610 is provided, be used for according to described index request, according to the corresponding relation of the real name of resource of setting up in the index data base, audio-frequency information sign and at least one download address, at least one download address of the real name of resource correspondence of coupling is offered described client.
The described module 610 that provides comprises, storage unit 611 and unit 612 is provided.Wherein, storage unit 611 is used for preserving the corresponding relation of multimedia resource real name of resource, audio-frequency information sign and at least one download address; Unit 612 is provided, is used for,, at least one download address of the real name of resource correspondence of coupling is offered described client according to the described corresponding relation of preserving according to described index request.
Described storage unit 611 comprises that corresponding relation is set up unit 613, first storage unit 614 and second storage unit 615.Wherein, corresponding relation is set up unit 613, is used for setting up the corresponding relation of multimedia resource real name of resource, audio-frequency information sign and at least one download address; First storage unit 614 is used to preserve the corresponding relation of real name of resource and audio-frequency information sign; Second storage unit 615 is used to preserve the corresponding relation of multimedia resource sound intermediate frequency message identification and at least one file identification, and preserves the corresponding relation of each file identification and at least one download address.And the described relation that will set up is kept in the index data base.
The described unit 612 that provides comprises that first provides subelement 619 and second that subelement 620 is provided.Wherein, first provides subelement 619, be used for corresponding relation according to the download address of setting up, file identification and audio-frequency information sign, determine index request corresponding audio message identification, according to the corresponding relation of audio-frequency information, at least one file identification and at least one download address set up, at least one corresponding download address of described audio-frequency information sign is offered client; Second provides subelement 620, be used for corresponding relation according to the real name of resource that is provided with, audio-frequency information sign, at least one file identification and at least one download address, determine index request corresponding audio message identification, identical audio-frequency information is identified pairing download address offer client.
Described corresponding relation is set up unit 613 and is comprised, audio-frequency information sign determining unit 616, optimum real name of resource determining unit 617 and first corresponding relation are set up unit 618.Wherein, audio-frequency information sign determining unit 616 is used for the multimedia resource video information is separated with audio-frequency information, obtains the audio-frequency information in the described multimedia resource, calculates described audio-frequency information sign according to described audio-frequency information; Optimum real name of resource determining unit 617 is used for determining at least one optimum real name of resource according to the real name of resource selection rule that is provided with; First corresponding relation is set up unit 618, is used for according to the described audio-frequency information sign of determining, described optimum real name of resource the corresponding relation of real name of resource and audio-frequency information sign being set.
The method, system and device that multimedia resource is provided that the embodiment of the invention provides, corresponding relation according to the real name of resource, audio-frequency information sign, file identification and the download address that are provided with, to have the multimedia resource that identical audio-frequency information identifies different file identifications and offer client, increase the quantity of the multimedia resource that the user can search, improved user's experience.
Obviously, those skilled in the art can carry out various changes and modification to the present invention and not break away from the spirit and scope of the present invention.Like this, if of the present invention these are revised and modification belongs within the scope of claim of the present invention and equivalent technologies thereof, then the present invention also is intended to comprise these changes and modification interior.