Video generation method, device, storage medium and electronic device
By obtaining and matching the duration sequence of video materials, the problem of low video generation efficiency in the prior art is solved, automated video generation is realized, user creation process is simplified, and video generation efficiency and user experience are improved.
Patent Information
- Application Number
- CN202211617558.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-12-15
- Publication Date
- 2024-12-06
- Estimated Expiration
- 2042-12-15
AI Technical Summary
Existing video generation methods require manual collection and editing of video materials, resulting in inefficiency and often no corresponding material is found when generating videos of specific content, reducing user enthusiasm.
By obtaining the duration sequence and multiple candidate video materials, matching the target video materials for each period of time, and determining the order of the materials according to the duration order, the video is generated. This method does not require manual collection and editing of materials, and uses the sequence of time sequences and target materials to achieve video generation.
It improves the efficiency of video generation, simplifies the user's creative process, enables users to quickly generate video content that meets expectations, and improves the convenience of secondary creation.
Smart Images

Figure CN116095422B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the fields of computer technology and video processing technology, and in particular to a video generation method, device, storage medium and electronic device. Background Art
[0002] In recent years, short videos have developed rapidly and become widely popular. More and more users want to share the video content they want to share by making their own short videos. Using existing stock footage, modifying, editing and composing music to create secondary creation videos is one of the ways to make short videos.
[0003] Most existing video generation methods rely on manually collecting video materials, editing, and producing videos. However, manually collecting video materials requires a lot of time or energy, which greatly reduces the efficiency of video generation. Moreover, when users want to generate videos with specific content, they often cannot find the corresponding video materials, which reduces the enthusiasm of users to produce short videos. Summary of the invention
[0004] The embodiments of the present application provide a video generation method, device, storage medium and electronic device to solve the problems existing in the related technologies. The technical solutions are as follows:
[0005] In a first aspect, an embodiment of the present application provides a video generation method, including:
[0006] Obtain a time sequence, where the time sequence includes multiple time segments in a sequential order;
[0007] Acquire multiple candidate video materials;
[0008] From the multiple candidate video materials, match the target video material for each duration respectively, so as to obtain multiple target video materials corresponding to the multiple durations;
[0009] According to the sequence of multiple time segments, the sequence of multiple target video materials is determined; based on the multiple target video materials and the sequence of the multiple target video materials, a video is generated.
[0010] In a second aspect, an embodiment of the present application provides a video generation method, including:
[0011] Sending element information, where the element information is used to indicate the characteristic elements that need to be included in the generated video, so that the server generates the video based on the element information;
[0012] Receive the video returned by the server.
[0013] In a third aspect, an embodiment of the present application provides a video generating device, including:
[0014] A duration sequence acquisition module is used to acquire a duration sequence, where the duration sequence includes multiple durations in a sequential order;
[0015] A material acquisition module, used to acquire multiple candidate video materials;
[0016] A material matching module, used to match target video materials for each duration from multiple candidate video materials, thereby obtaining multiple target video materials corresponding to multiple durations;
[0017] A sequence determination module, used to determine the sequence of multiple target video materials according to the sequence of multiple durations;
[0018] The video generation module is used to generate a video based on multiple target video materials and the sequence of the multiple target video materials.
[0019] In a fourth aspect, an embodiment of the present application provides a video generating device, including:
[0020] An element configuration module, used to send element information, where the element information is used to indicate the characteristic elements that need to be included in the generated video, so that the server generates the video based on the element information;
[0021] The video receiving module is used to receive the video returned by the server.
[0022] In a fifth aspect, an embodiment of the present application provides an electronic device, comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor so that the at least one processor can execute the above-mentioned video generation method.
[0023] In a sixth aspect, an embodiment of the present application provides a computer-readable storage medium, which stores computer instructions. When the computer instructions are executed on a computer, the method in any one of the above-mentioned embodiments is executed.
[0024] The advantages or beneficial effects of the above technical solution include at least:
[0025] The technical solution of the embodiment of the present application obtains multiple candidate video materials, and obtains video materials matching each duration in the duration sequence from the multiple candidate video materials as target video materials for each duration, thereby generating videos based on the multiple durations and the corresponding target video materials. There is no need to manually collect and edit video materials, which facilitates the user's secondary creation and improves the efficiency of secondary creation.
[0026] The above summary is for illustrative purposes only and is not intended to be limiting in any way. In addition to the illustrative aspects, embodiments and features described above, further aspects, embodiments and features of the present application will be readily apparent by reference to the accompanying drawings and the following detailed description. BRIEF DESCRIPTION OF THE DRAWINGS
[0027] In the accompanying drawings, unless otherwise specified, the same reference numerals throughout the multiple drawings represent the same or similar parts or elements. These drawings are not necessarily drawn to scale. It should be understood that these drawings only depict some embodiments disclosed in the present application and should not be regarded as limiting the scope of the present application.
[0028] Figure 1 The following schematically shows an environmental application diagram according to an embodiment of the present application.
[0029] Figure 2 A schematic flow chart of a video generation method according to an embodiment of the present application is shown.
[0030] Figure 3 An exemplary flowchart of a video generation method according to an embodiment of the present application is shown.
[0031] Figure 4 4 is a flowchart of a video generation method according to another embodiment of the present application.
[0032] Figure 5 is a schematic diagram of a video generating device according to an embodiment of the present application.
[0033] Figure 6 FIG. 4 is a schematic diagram of a video generating device according to another embodiment of the present application.
[0034] Figure 7 It is a block diagram of an electronic device used to implement the video generation method of an embodiment of the present application. DETAILED DESCRIPTION
[0035] In order to make the purpose, technical solutions and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not intended to limit the present application. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in the field without making creative work are within the scope of protection of the present application.
[0036] It should be noted that the descriptions involving "first", "second", etc. in the embodiments of the present application are only for descriptive purposes and cannot be understood as indicating or implying their relative importance or implicitly indicating the number of technical features indicated. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one of the features. In addition, the technical solutions between the various embodiments can be combined with each other, but they must be based on the ability of ordinary technicians in the field to implement them. When the combination of technical solutions is contradictory or cannot be implemented, it should be deemed that such combination of technical solutions does not exist and is not within the scope of protection required by this application.
[0037] Existing video generation methods have the following defects: they need to manually collect video materials, edit them into required video clips, and synthesize them to make the desired video. Manually collecting video materials requires a lot of time or energy, which greatly reduces the efficiency of video generation; and often when you want to generate a video with specific content, you can't find the corresponding video materials, which reduces the enthusiasm of users to make short videos.
[0038] The present application provides multiple embodiments to solve the above-mentioned defects, please refer to the following for details.
[0039] In the description of the present application, it should be understood that the numerical labels before the steps do not indicate the order in which the steps are executed, but are only used to facilitate the description of the present application and to distinguish each step, and therefore should not be understood as a limitation on the present application.
[0040] The following is the explanation of terms and related technical background of this application:
[0041] MAD (Movie+Anime+Drama, secondary creative image): A secondary creative video made by modifying and editing existing stock footage and adding music.
[0042] Slicing: For existing original videos, segments with specific content need to be extracted and marked, thereby extracting the behavior of the video segments.
[0043] Video material: Video clips stored in the material library. Each video clip is edited and contains one or more specific contents. The video clips in the material library can be managed to facilitate video generation. For example, the same repeated video clips can be removed; when a high-definition video clip is obtained, the blurred clips of the same content in the material library can be replaced; each video clip can be limited to include a specific content, etc.
[0044] Entries: A collection of words that can be used interchangeably and have relationships such as inclusion in the context of the two-dimensional culture.
[0045] Stuck point: It means to lock the exact time point. By switching the screen at the stuck point in the video, the effect of transition switching can be achieved, so that the generated video can contain a variety of different scenes and enrich the video content.
[0046] Figure 1 The following schematic diagram shows an environmental application diagram according to an embodiment of the present application. Figure 1 As shown:
[0047] The provider network 2 may connect a plurality of mobile terminals 6 via the network 4. The provider network 2 may provide content services.
[0048] Content services may include content streaming services such as Internet Protocol video streaming services. Content streaming services may be configured to distribute content via various transmission technologies. Content services may be configured to provide content such as video, audio, text data, combinations thereof, and the like. Content may include content streams (e.g., video streams), content files (e.g., video files), and / or other data.
[0049] The provider network 2 can implement a video generation service, which is configured to allow users to create video content. The creation page and the video content generated by the creation can be presented on the display interface or playback screen of the web page.
[0050] Provider network 2 may be located in a data center such as a single location, or distributed across different geographic locations (e.g., at multiple locations). Provider network 2 may provide services via one or more networks 4. Network 4 includes various network devices, such as routers, switches, multiplexers, hubs, modems, bridges, repeaters, firewalls, proxy devices, and / or the like. Network 4 may include physical links, such as coaxial cable links, twisted pair cable links, fiber optic links, combinations thereof, and the like. Network 4 may include wireless links, such as cellular links, satellite links, Wi-Fi links, and the like.
[0051] The plurality of mobile terminals 6 may be configured to access content and services of the provider network 2. The plurality of mobile terminals 6 may include any type of electronic device, such as a mobile device, a tablet device, a laptop computer, a workstation, a virtual reality device, a gaming device, a set-top box, a digital streaming device, a vehicle terminal, a smart TV, a set-top box, etc.
[0052] Multiple mobile terminals 6 can output (e.g., display, render, present) content (video, creation page, etc.) to the user. In other embodiments, the mobile terminal 6 can also obtain relevant information required for video generation, such as obtaining video materials; and can also obtain a video creation page to input element information, create a video project, etc.
[0053] The video generation scheme will be described below through multiple embodiments. The scheme can be implemented by a computer device 1300 , which can be a provider network 2 or a computing node thereof, or a mobile terminal 6 .
[0054] Embodiment 1
[0055] Figure 2 FIG. 1 is a flow chart showing a video generation method according to an embodiment of the present application. Figure 2 As shown, the video generation method may include:
[0056] S210, obtaining a duration sequence, where the duration sequence includes a plurality of durations in a sequential order.
[0057] A duration sequence can be used to generate a video. In a duration sequence, the total duration of multiple durations corresponds to the duration of the generated video.
[0058] A time sequence is divided into multiple time segments, so that corresponding video content can be obtained for each time segment. The video content corresponding to the multiple time segments can be video content in multiple different stock footages, or video content in multiple different time periods in one stock footage.
[0059] A time sequence can be divided into multiple time segments by using card points. The video generated based on the time sequence can achieve transitions at the card points.
[0060] Among the multiple durations, the durations of different durations may be the same or different, and the durations of some durations may be the same.
[0061] Videos generated through multiple durations may include video content with a variety of different themes, different keywords or different tags, so that the generated video content is rich and fully expresses the ideas of the secondary creator.
[0062] The time sequence can be obtained by various technical solutions known to ordinary technicians in the field now and in the future, for example, by obtaining it through background music, by editing corresponding parameters, and by obtaining the time sequence of similar short videos.
[0063] S220, obtaining multiple candidate video materials.
[0064] In the embodiment of the present application, multiple candidate video materials can be obtained from a specified material library, multiple candidate video materials can be obtained from specified multiple material libraries, or multiple candidate video materials can be searched from the network. The material library can be stored in a network server or a storage server to facilitate searching and obtaining video materials from the material library.
[0065] The number of the multiple candidate video materials is greater than the number of the multiple durations, or greater than a preset multiple of the number of the multiple durations, so that the multiple candidate video materials obtained can meet the requirement of generating videos of multiple durations in the duration sequence.
[0066] The candidate video materials may be obtained by tag matching, by duration matching, by subject matching, or by person or role matching.
[0067] In one example, the candidate video material may be obtained by classifying the video material in the material library into multiple video files for storage by subject classification or character classification. When obtaining multiple candidate video materials, the video material may be obtained from the video files of the corresponding subject.
[0068] In the embodiment of the present application, the video material in the material library can be a video material after deduplication, so that each video material in the material library is unique, avoiding obtaining multiple video materials with duplicate contents when obtaining multiple candidate video materials, which affects the efficiency of video generation.
[0069] In one example, the video materials in the material library can be managed to obtain video materials more accurately, quickly and conveniently, thereby further improving the efficiency of video generation. For example, the same repeated video clips can be removed; when a high-definition video clip is obtained, the blurred clips of the same content in the material library can be replaced; each video clip can be limited to include a specific content, etc.
[0070] S230, matching target video materials for each duration from the multiple candidate video materials, thereby obtaining multiple target video materials corresponding to the multiple durations.
[0071] The target video material is matched for each duration respectively, so that the corresponding target video material can be filled into each duration in the duration sequence respectively to generate a video.
[0072] In one example, there may be a situation where one or more time segments do not have corresponding target video materials. When generating a video, the time segments without target video materials are deleted.
[0073] In one example, if no corresponding target video material is obtained for two consecutive durations, the two durations are merged, and video material matching the merged duration is obtained from the material library as a candidate video material, and then the target video material corresponding to the merged duration is obtained. When generating a video, the target video material corresponding to the merged duration and the target video materials of other durations are used to generate a video.
[0074] A video material is obtained from multiple candidate video materials as the target video material. The video material whose video duration is compatible with the time length of the duration can be matched from multiple candidate video materials according to the time length of the duration, and is obtained as the target video material.
[0075] In an example, when there are multiple video materials whose video duration is compatible with the time length of the duration, one of the video materials can be obtained as the target video material according to a preset first rule.
[0076] In one example, when the time lengths of multiple durations are the same, multiple video materials are obtained and, according to a preset second rule, corresponding video materials are respectively allocated to the multiple durations with the same time length, so that the corresponding target video materials of the multiple durations with the same time length are not repeated.
[0077] S240, determining the sequence of the multiple target video materials according to the sequence of the multiple durations.
[0078] By determining the sequence of multiple target video materials according to the sequence of multiple durations in the duration sequence, the target video materials can be imported into the position of the corresponding duration when generating the video, so that the generated video can achieve transition according to the duration and sequence in the duration sequence.
[0079] In the embodiment of the present application, the sequence of target video materials is determined to facilitate the location of the target video materials when generating a video.
[0080] S250, generating a video based on the multiple target video materials and the sequence of the multiple target video materials.
[0081] In one example, a video project may be created, a time sequence may be imported, and then target video materials may be imported in sequence according to the order of multiple time segments in the time sequence to generate a video. Each time segment may have a corresponding ID (Identification), and when the ID is read, the target video material corresponding to the ID is imported.
[0082] In an example, the acquired multiple target video materials and the sequence of the multiple target video materials may be used to generate a video according to a preset video generation rule.
[0083] The embodiment of the present application obtains multiple candidate video materials, and obtains video materials that match each duration in the duration sequence from the multiple candidate video materials as target video materials for each duration, thereby generating MAD videos based on the multiple durations and the corresponding target video materials. There is no need to manually collect and edit video materials, which provides convenience for users' secondary creation and improves the efficiency of secondary creation.
[0084] In one embodiment, step S210 includes: acquiring target music; identifying multiple card points of the target music, wherein the multiple card points include rhythm mutation points of the target music; and generating a duration sequence including multiple durations based on the multiple card points.
[0085] The target music can also be used as background music when generating a video. By using the card points of the background music to generate a time sequence, the effect of integrating the background music with the transition of the video content can be achieved.
[0086] The target music can be obtained from a music library stored in a server, or from a network music library connected to a network. According to a category label such as a singer or a style input by a user, popular songs belonging to the category label can be obtained as the target music. It can also be determined as the target music according to the song title input by the user, or determined as the target music according to the music link input by the user.
[0087] Identify multiple card points of the target music, where the card points can be identified based on the rhythm of the music, and the points with greater rhythm changes are identified as card points. That is, by identifying the rhythm mutation points in the target music, they are determined as card points.
[0088] In one example, a plurality of different target music may be stored in the music library, and each target music has a card point identifier, so that the card point of the target music can be obtained by obtaining the target music.
[0089] In one example, the music library may include multiple identical target music pieces, and the same target music pieces may have different numbers of card points. The number of card points may be identified for the target music pieces. According to the card point number information input by the user, the target music pieces with the corresponding number of card points may be obtained. Thus, a video may be produced according to the card point number requirement of the user.
[0090] In one example, after obtaining the target music, all the card points of the target music can be obtained; then according to the card point quantity information input by the user, card points of a corresponding number are selected from all the card points, and a duration sequence including multiple durations is generated with the card points of the corresponding number.
[0091] Selecting the corresponding number of checkpoints from all checkpoints may be performed by deleting the checkpoints according to a preset rule, for example, deleting one checkpoint every one or more checkpoints.
[0092] In one example, the total number of all the checkpoints can be calculated based on the checkpoint quantity information input by the user to determine the number of checkpoints required to delete a checkpoint.
[0093] In one example, the card points can be deleted according to the minimum duration input by the user. For example, if the minimum duration input by the user is 15 seconds, then one of the card points whose interval between adjacent card points in the target music is less than 15 seconds is deleted. Which card point among the adjacent card points to delete can be determined according to a preset deletion rule.
[0094] In one implementation, step S210 includes: acquiring configuration parameters; and generating a duration sequence including multiple durations based on the configuration parameters.
[0095] In the embodiment of the present application, a duration sequence is generated by configuring parameters. The configuration parameters may include: durations arranged in sequence. For example, the configuration parameters are: 3, 5, 12, 10, 6, 10, 8; then the identifier generates a duration sequence including 7 durations, the first duration is 3s, ... the seventh duration is 8s.
[0096] In one example, the configuration parameters may include: duration segments and duration range. The duration segments are used to determine the number of segments in the duration sequence, and the duration range is used to randomly match the length of each duration within the duration range. For example, if the configuration parameters are 7 segments and the duration range is 5-13s, then the random duration sequence that can be generated is: 5, 8, 9, 13, 7, 6, 9.
[0097] In the embodiment of the present application, configuration parameters are used to generate a duration sequence, and the number of segments of the duration sequence and the length of each segment can be freely selected based on the user's will.
[0098] In the embodiment of the present application, the configuration parameters are used to generate the duration sequence, so that the generated video can play the original sound of the video material. In addition, when the duration sequence is obtained by using the target music, after the video is generated, the video reason can be selected so that the generated video can play the original sound of the video material.
[0099] In one example, after the time sequence is generated using the configuration parameters, background music can be matched for each time segment before the video is generated, so that in the generated video, both the music and the picture content are transitioned.
[0100] In one embodiment, before step S210, the process further includes: receiving element information. The element information is information input by a user from a user terminal to indicate a plurality of characteristic elements that the generated video needs to include. The element information may include: album name, scene, emotion, and other contents.
[0101] Step S220 includes: acquiring a plurality of candidate video materials from a material library based on the element information.
[0102] By obtaining multiple candidate video materials from the material library according to the element information, the video content required by the user can be generated according to the personalized needs of the user. The element information may include multiple different entries.
[0103] In one embodiment, the element information includes key terms, auxiliary terms, and exclusion terms.
[0104] Based on the element information, a plurality of candidate video materials are obtained from the material library, including: based on the keyword, a first type of video material whose tag information matches the keyword is obtained from the material library.
[0105] Keyword entries may be mandatory to provide the necessary guidance for the video to be created.
[0106] Keyword entries may include guiding words, such as film or TV show titles or character names.
[0107] Guiding words may include fixed guiding words and optional guiding words. For example, the name of a film or TV show is a fixed guiding word; a character name can be a fixed guiding word; the three guiding words of emotion, style and scene can be three-choice guiding words, and the user enters the entry corresponding to the guiding word when selecting one of the guiding words. Exemplarily, the three-choice guiding words or other multiple-choice guiding words can be provided in a drop-down list for the user to select one of the guiding words, and then enter the entry in the input box associated with the drop-down box.
[0108] Based on the keyword entry, the first category of video material is obtained from the material library.
[0109] It should be noted that, in the embodiments of the present application, the first category of video material, the second category of video material, the third category of video material, the fourth category of video material and the target category of video material all refer to a collection containing multiple video materials, where the category can mean a collection.
[0110] Based on the auxiliary terms, the second category of video materials is selected from the first category of video materials; the auxiliary terms are selectively input terms. The number of auxiliary terms that can be input is not limited.
[0111] The auxiliary terms may be descriptive terms input by the user, and the terms may include one or more descriptive terms. The auxiliary terms may be descriptions of emotional tones or plot events.
[0112] In one example, multiple auxiliary terms can be described using different connectors.
[0113] Exemplarily, using semicolons to separate them can represent the description of all candidate video materials; for example, the emotional tone is "sadness", the plot event is "the death of Luo's mother"; the auxiliary terms are "sadness; the death of Luo's mother", then each video material in the second category of video materials screened out includes content related to sadness and the death of Luo's mother.
[0114] For example, multiple terms can be enclosed in square brackets to indicate that video materials corresponding to the multiple terms are obtained respectively. For example, [birth, school, adulthood] can indicate that video materials of the birth stage, video materials of the school stage, and video materials of the adult stage are obtained respectively. In this way, the generated video can express video content of multiple different stages.
[0115] As another example, the separator in the brackets of the above auxiliary terms is ",", which can indicate that the order cannot be disrupted, that is, the video material corresponding to the first auxiliary word "birth" is used for the first duration in the duration sequence; the video material corresponding to the second auxiliary word "school" is used for the second duration in the duration sequence; the video material corresponding to the third auxiliary word "adulthood" is used for the third duration in the duration sequence; if there is a fourth duration, the content in the brackets does not need to correspond.
[0116] As another example, if you want the video material corresponding to the first auxiliary word "birth" in the above auxiliary terms to be used for the third duration in the duration sequence; the video material corresponding to the second auxiliary word "school" to be used for the fifth duration in the duration sequence; and the video material corresponding to the third auxiliary word "adulthood" to be used for the sixth and seventh durations in the duration sequence, then it can be described as [,,birth,,school,adulthood,adulthood].
[0117] As another example, brackets and semicolons can be used in one auxiliary entry at the same time, for example: sadness; [,, birth,, school, adulthood, adulthood]; Luo's mother passed away.
[0118] Based on the exclusion terms, video materials whose video tags match the exclusion terms are removed from the second category of video materials to obtain the third category of video materials; the exclusion terms are the terms selected as input.
[0119] It can be understood that if the user does not input the auxiliary terms, the second category of video material is equivalent to the first category of video material.
[0120] The exclusion term may be any category of terms. For example, the exclusion term may be Zhu XX in order to exclude video materials containing the character "Zhu XX".
[0121] The third type of video material is determined as the target type of video material, and multiple candidate video materials are obtained from the target type of video material. In the absence of an exclusion term, the third type of video material is equivalent to the second type of video material, and the second type of video material can be determined as the target type of video material.
[0122] In the embodiment of the present application, candidate video materials are obtained from the material library by combining key words, auxiliary words and exclusion words, so that the obtained video materials are accurate and meet the user's expectations, and further the generated video meets the user's expectations.
[0123] In the embodiments of the present application, when using key words, auxiliary words and exclusion words to match videos in the material library, semantic fuzzy processing can be used to obtain accurate video materials from a larger range.
[0124] In the embodiment of the present application, the video material in the material library may be uploaded by other users, and when uploading the video material, the video material may be described, etc. When the server receives the video material, it may parse the video material to obtain information such as the role, plot, rhythm, emotion or duration of the video material, and mark the relevant information in the video material.
[0125] The combined element information of the key words, auxiliary words and exclusion words in the embodiment of the present application can also be used to obtain the target music according to the element information. By obtaining multiple candidate video materials and the time sequence based on the element information, the user only needs to input the element information to obtain the generated video and complete the video creation, further improving the efficiency of video creation.
[0126] In one implementation, step S220 includes:
[0127] Get the maximum and minimum duration of multiple durations;
[0128] Determining a maximum preset duration based on the maximum duration, and determining a minimum preset duration based on the minimum duration;
[0129] From the third category of video materials, video materials with a duration greater than a maximum preset duration are eliminated, and / or video materials with a duration less than a minimum preset duration are eliminated, to obtain fourth category of video materials;
[0130] The fourth category of video material is determined to be the target category of video material, and a plurality of candidate video materials are obtained from the target category of video material.
[0131] In an embodiment of the present application, by eliminating video materials with a duration greater than a maximum preset duration and / or eliminating video materials with a duration less than a minimum preset duration at the stage of candidate video materials, video materials with large differences in duration can be excluded, thereby reducing the number of candidate video materials and improving the efficiency of obtaining candidate video materials.
[0132] The maximum preset duration is determined based on the maximum duration, and the minimum preset duration is determined based on the minimum duration. The preset durations may be obtained by calculating based on the duration tolerance.
[0133] By reducing the number of candidate video materials, the matching efficiency can also be improved when multiple candidate video materials are subsequently matched with each duration.
[0134] In one implementation, obtaining a plurality of candidate video materials from a target video material includes:
[0135] Get the number of segments of multiple durations;
[0136] Based on the number of segments, determining the calibration quantity of the candidate video materials to be obtained;
[0137] A first random factor is used to obtain a calibrated number of multiple candidate video materials from the target video material.
[0138] In the embodiment of the present application, by obtaining candidate video materials according to the calibrated quantity at the stage of candidate video materials, the number of candidate video materials to be obtained can be reduced and the efficiency of obtaining candidate video materials can be improved.
[0139] In one example, based on the number of segments, the calibrated number of candidate video materials to be obtained is determined, and the calibrated number can be determined according to a preset multiple of the number of segments.
[0140] For example, the duration sequence includes 7 durations, the preset multiple is 10, and the target video material includes 100 candidate video materials. Then 30 candidate video materials are eliminated to retain 70 candidate video materials for matching with each duration when subsequently generating videos.
[0141] In an example, the duration of each video material in the target video material may also be obtained, so as to determine the calibrated number of candidate video materials of a specific duration for each duration.
[0142] For example, if the number of candidate video materials with a duration of 3-5s is calibrated to 15, then 15 candidate video materials are obtained from the 3-5s video materials in the target video materials; if the number of candidate video materials with a duration of 6-12s is calibrated to 20, then 20 candidate video materials are obtained from the 6-12s video materials in the target video materials.
[0143] A calibrated number of video materials are obtained from the target video materials as candidate video materials. The video materials can be arranged according to the correlation between the multiple video materials and the element information, and the calibrated number of video materials at the front are obtained based on the arrangement order.
[0144] In the embodiment of the present application, by acquiring a calibrated number of video materials as candidate video materials, the number of candidate video materials can be reduced, thereby improving the matching efficiency when multiple candidate video materials are subsequently matched with each duration.
[0145] In one implementation, step S230 includes:
[0146] Get the length of a period of time;
[0147] Acquire multiple video materials matching the time length from multiple candidate video materials;
[0148] A second random factor is used to obtain a video material from multiple video materials as the target video material for the duration.
[0149] After obtaining multiple video materials that match the time length, the multiple video materials can be labeled. Based on the second random factor, randomly obtain video materials with any labels as target video materials.
[0150] In a time sequence, when the time lengths of multiple time segments are the same, for the first time segment with the same time length, based on the second random factor, video materials with any labels can be randomly obtained as target video materials; for the second time segment with the same time length, the second random factor can be used to randomly obtain video materials from the remaining labels as target video materials.
[0151] In one implementation, obtaining a plurality of video materials matching the time length from a plurality of candidate video materials includes:
[0152] Get duration tolerance;
[0153] Determine the duration range based on the duration and duration tolerance;
[0154] Based on the duration range, multiple video materials matching the duration range are obtained from multiple candidate video materials.
[0155] The duration tolerance can be user-configured or system-preset.
[0156] The duration tolerance may be, for example, ±20%. If the time length is 10 seconds, the duration range is 8-12 seconds.
[0157] By using the duration tolerance, multiple candidate video materials that match the duration range are obtained, so as to expand the range of candidate video materials and avoid being limited to a fixed time length, which makes it difficult to find video materials with matching content.
[0158] In one implementation, step S240 includes:
[0159] Adjust the playback speed of the target video material so that the duration of the target video material is adapted to the time length. To adjust the playback speed of the target video material, you can obtain the time length value and then adjust the playback speed adaptively according to the time length value. You can play it according to the corresponding multiple of the original playback speed based on the ratio of the time length to the duration of the video material. For example, if the duration of the target video material is 5s and the time length is 4s, it will be played at 0.8 times the speed of the target video material.
[0160] In one example, when setting the duration tolerance, the duration tolerance may be determined based on the fact that the effect of adjusting the playback speed will not affect the overall video generation effect.
[0161] Based on the multiple target video materials after speed adjustment and the sequence of the multiple target video materials, a video is generated, so that the generated video can change scenes according to the card point positions in the time sequence.
[0162] In one embodiment, step S250 includes:
[0163] Create video projects;
[0164] Import multiple target video materials into the video project in order to generate a video.
[0165] A video project can be created before obtaining candidate video materials and obtaining a time sequence.
[0166] In one example, when the user opens a designated application on the user end, a video project is created, and then the user enters element information, configures parameters, or selects target music from the option bar of the video project.
[0167] In the embodiment of the present application, by creating a video project to generate a video, the duration sequence and the target video material corresponding to each duration can be conveniently and intuitively imported into the video project.
[0168] In one example, for a generated video, if the user is not satisfied with a specific segment of the video content, the user can also enter the video content that needs to be modified. The user can select a specific segment of the video content by clicking in the video project, or can select the video content that needs to be modified by entering the duration sequence number.
[0169] By selecting a specific segment of video content that needs to be modified, candidate materials can be further obtained based on the length of the segment to regenerate the video; so that the ultimately generated video content can meet user expectations and improve user satisfaction.
[0170] In one implementation, step S240 includes:
[0171] Acquire multiple candidate special effect materials;
[0172] Using a third random factor from a plurality of candidate special effect materials, adjust the special effect material for each target video material;
[0173] A video is generated based on the multiple target video materials after adding special effects and the sequence of the multiple target video materials.
[0174] In the embodiment of the present application, by adding special effects to the target video, the generated video can have special effects. The special effects include filter effects, floating text effects, etc.
[0175] Add special effects to the target video. You can add different special effects to each target video, or you can add the same special effect to the generated video.
[0176] Special effect materials can be obtained before the video is generated so that the generated video has special effects. Special effect materials can also be obtained after the video is generated to add special effects according to the video playback effect.
[0177] The special effect material may be a target special effect material selected from a special effect material library, or may be a special effect material edited by a user.
[0178] In one example, the server may obtain multiple candidate special effect materials from the special effect material library based on the special effect term input by the user, and then add them to each target video segment by matching.
[0179] In one embodiment, the video generation method further includes sending the generated video to the client. If the user is not satisfied with the generated video content, the element information can be changed or re-entered to update the obtained candidate video material, thereby adjusting the video content so that the finally generated video content meets the user's expectations and improves user satisfaction.
[0180] In the above example, the cover duration may also be inserted into the duration sequence, that is, at each card point in the duration sequence, the cover duration may be inserted to play the cover content at that time node.
[0181] In the embodiment of the present application, the first random factor, the second random factor and the third random factor may be random values obtained according to a random function, thereby determining the candidate video material, video material or special effect material corresponding to the random value according to the random value.
[0182] In the embodiment of the present application, by obtaining a random factor to determine the corresponding candidate video material, video material or special effect material, the generated video can be made unique.
[0183] The cover content can be a single picture, multiple pictures, or a video.
[0184] The cover contents of multiple cover durations can be different, or all the same, or can be 2 to 3 different cover contents in a loop.
[0185] The cover duration can be configured by the user or automatically configured according to the user's choice. For example, if the user selects that the cover duration is required, the cover duration is inserted at the card point position.
[0186] The exemplary video generation process of the embodiment of the present application is as follows: Figure 3 shown.
[0187] The user inputs the element information to match the element information and obtain multiple candidate video materials; obtain the target music, mark the card point position of the target music, and obtain the duration sequence. According to the time tolerance, calculate the time range of each duration in the duration sequence. Use the second random factor to match multiple candidate video materials with each duration so that each duration obtains the corresponding target video material. Obtain special effects from the special effects material library and match them to the target video material. Generate a video based on the duration sequence and the target video material corresponding to each duration, and output it to the user for preview. If modification is required, regenerate the video by modifying the entry or re-entering the entry.
[0188] Embodiment 2
[0189] Figure 4 FIG. 1 is a flow chart showing a video generation method according to an embodiment of the present application. Figure 4 As shown, the video generation method may include:
[0190] S410, sending element information, where the element information is used to indicate characteristic elements that need to be included in the generated video, so that the server generates the video based on the element information;
[0191] S420, receiving the video returned by the server.
[0192] In the embodiment of the present application, by sending the element information to the server, the server can generate a video based on the element information. For example, the server can obtain a duration sequence including multiple durations according to the element information, and can obtain multiple candidate video materials, so that the server can generate a video according to the duration sequence and the multiple candidate video materials.
[0193] In one embodiment, the target music information may be sent so that the server determines the duration sequence according to the received target music information. The target music information may be music specified from an associated music library or a music link.
[0194] In one implementation, configuration information may be sent so that the server determines the duration sequence according to the configuration information.
[0195] In one implementation, a video project creation request may be sent so that the server creates a video project based on the video project creation request, thereby being used to generate a video.
[0196] In one implementation, a material library link may be sent so that the server can obtain candidate video materials from the material library link.
[0197] In one implementation, a duration tolerance may be sent so that when the server acquires multiple candidate video materials, it may acquire video materials within the duration tolerance range as candidate video materials based on the duration tolerance.
[0198] Embodiment 3
[0199] Figure 5 FIG. 5 shows a structural block diagram of a video generating device 500 according to an embodiment of the present application. Figure 5 As shown, the video generating device 500 may include:
[0200] A duration sequence acquisition module 510 is used to acquire a duration sequence, where the duration sequence includes a plurality of durations in a sequential order;
[0201] A material acquisition module 520 is used to acquire a plurality of candidate video materials;
[0202] The material matching module 530 is used to match the target video material for each time segment from the multiple candidate video materials, so as to obtain multiple target video materials corresponding to the multiple time segments;
[0203] The sequence determination module 540 is used to determine the sequence of the multiple target video materials according to the sequence of the multiple durations;
[0204] The video generation module 550 is used to generate a video based on multiple target video materials and the sequence of the multiple target video materials.
[0205] In one implementation, the duration sequence acquisition module 510 is used to:
[0206] Get the target music;
[0207] Identify multiple card points of the target music; the multiple card points include rhythm mutation points of the target music;
[0208] A duration sequence including multiple durations is generated based on multiple card points.
[0209] In one implementation, the duration sequence acquisition module 510 is used to:
[0210] Get configuration parameters;
[0211] Based on the configuration parameters, a duration sequence including multiple durations is generated.
[0212] In one implementation, the video generating device 500 further includes:
[0213] An element information receiving module is used to receive element information; the element information is used to indicate the characteristic elements that the generated video needs to include, and the multiple characteristics that need to be included;
[0214] The material acquisition module 520 is used to acquire a plurality of candidate video materials from the material library based on the element information.
[0215] In one embodiment, the element information includes key terms, auxiliary terms, and exclusion terms;
[0216] The material acquisition module 520 is used to acquire the first type of video material whose tag information matches the keyword from the material library based on the keyword;
[0217] Based on the auxiliary terms, the second category of video materials is selected from the first category of video materials; the auxiliary terms are selectively input terms;
[0218] Based on the exclusion terms, video materials whose video tags match the exclusion terms are removed from the second category of video materials to obtain the third category of video materials; the exclusion terms are the terms selected as input;
[0219] The third category video material is determined to be the target category video material, and a plurality of candidate video materials are obtained from the target category video material.
[0220] In one implementation, the material acquisition module 520 is used to:
[0221] Get the maximum and minimum duration of multiple durations;
[0222] Determining a maximum preset duration based on the maximum duration, and determining a minimum preset duration based on the minimum duration;
[0223] From the third category of video materials, video materials with a duration greater than a maximum preset duration are eliminated, and / or video materials with a duration less than a minimum preset duration are eliminated, to obtain fourth category of video materials;
[0224] The fourth category of video material is determined to be the target category of video material, and a plurality of candidate video materials are obtained from the target category of video material.
[0225] In one implementation, the material acquisition module 520 is further configured to:
[0226] Get the number of segments of multiple durations;
[0227] Based on the number of segments, determining the calibration quantity of the candidate video materials to be obtained;
[0228] A first random factor is used to obtain a calibrated number of multiple candidate video materials from the target video material.
[0229] In one implementation, the material matching module 530 is used to:
[0230] Get the length of a period of time;
[0231] Acquire multiple video materials matching the time length from multiple candidate video materials;
[0232] A second random factor is used to obtain a video material from multiple video materials as the target video material for the duration.
[0233] In one implementation, the material matching module 530 is further configured to:
[0234] Get duration tolerance;
[0235] Determine the duration range based on the duration and duration tolerance;
[0236] Based on the duration range, multiple video materials matching the duration range are obtained from multiple candidate video materials.
[0237] In one embodiment, the video generation module 550 is used to:
[0238] Adjust the playback speed of the target video material so that the duration of the target video material is consistent with the time length;
[0239] A video is generated based on the multiple target video materials after speed adjustment and the sequence of the multiple target video materials.
[0240] In one embodiment, the video generation module 550 is used to:
[0241] Create video projects;
[0242] Import multiple target video materials into the video project in order to generate a video.
[0243] In one embodiment, the video generation module 550 is used to:
[0244] Acquire multiple candidate special effect materials;
[0245] Using a third random factor from a plurality of candidate special effect materials, adjust the special effect material for each target video material;
[0246] A video is generated based on the multiple target video materials after adding special effects and the sequence of the multiple target video materials.
[0247] The functions of each module in each device in the embodiments of the present application can be found in the corresponding description of the video generation method in the above-mentioned embodiment 1, and will not be repeated here.
[0248] Embodiment 4
[0249] Figure 6 FIG. 6 is a block diagram showing a structure of a video generating device 600 according to an embodiment of the present application. Figure 6 As shown, the video generating device 600 may include:
[0250] An element configuration module 610 is used to send element information, where the element information is used to indicate characteristic elements that need to be included in the generated video, so that the server generates the video based on the element information;
[0251] The video receiving module 620 is used to receive the video returned by the server.
[0252] The functions of each module in each device in the embodiments of the present application can be found in the corresponding description of the video generation method in the above-mentioned embodiment 2, and will not be repeated here.
[0253] Embodiment 5
[0254] Figure 7 The hardware architecture diagram of a computer device 700 suitable for implementing the video generation method according to the first embodiment of the present application is schematically shown. In this embodiment, the computer device 700 is a device that can automatically perform numerical calculations and / or information processing according to pre-set or stored instructions. For example, it can be a smart phone, a tablet computer, a laptop computer, a desktop computer, a rack server, a blade server, a tower server or a cabinet server (including an independent server, or a server cluster composed of multiple servers), etc. Figure 7 As shown, the computer device 700 includes at least but is not limited to: a memory 710, a processor 720, and a network interface 730 which can communicate with each other through a system bus. Among them:
[0255] The memory 710 includes at least one type of computer-readable storage medium, and the readable storage medium includes flash memory, hard disk, multimedia card, card-type memory (for example, SD or DX memory, etc.), random access memory (RAM), static random access memory (SRAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), programmable read-only memory (PROM), magnetic memory, magnetic disk, optical disk, etc. In some embodiments, the memory 710 can be an internal storage module of the computer device 700, such as a hard disk or memory of the computer device 700. In other embodiments, the memory 710 can also be an external storage device of the computer device 700, such as a plug-in hard disk equipped on the computer device 700, a smart memory card (Smart Media Card, referred to as SMC), a secure digital (Secure Digital, referred to as SD) card, a flash card, etc. Of course, the memory 710 can also include both the internal storage module of the computer device 700 and its external storage device. In this embodiment, the memory 710 is generally used to store the operating system and various application software installed on the computer device 700, such as the program code of the video generation method, etc. In addition, the memory 710 can also be used to temporarily store various types of data that have been output or are to be output.
[0256] In some embodiments, the processor 720 may be a central processing unit (CPU), a controller, a microcontroller, a microprocessor, or other data processing chip. The processor 720 is generally used to control the overall operation of the computer device 700, such as performing control and processing related to data interaction or communication with the computer device 700. In this embodiment, the processor 720 is used to run the program code stored in the memory 710 or process data.
[0257] The network interface 730 may include a wireless network interface or a wired network interface, and the network interface 730 is generally used to establish a communication link between the computer device 700 and other computer devices. For example, the network interface 730 is used to connect the computer device 700 to an external terminal through a network, and to establish a data transmission channel and a communication link between the computer device 700 and the external terminal. The network may be a wireless or wired network such as an intranet, the Internet, the Global System of Mobile communication (GSM), Wideband Code Division Multiple Access (WCDMA), 4G network, 5G network, Bluetooth, Wi-Fi, etc.
[0258] It should be pointed out that Figure 7 Only a computer device having components 710 - 730 is shown, but it should be understood that implementing all of the components shown is not a requirement, and more or fewer components may alternatively be implemented.
[0259] In this embodiment, the video generation method stored in the memory 710 can also be divided into one or more program modules and executed by one or more processors (processor 720 in this embodiment) to complete the embodiment of the present application.
[0260] Embodiment 6
[0261] The embodiment of the present application further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps of the video generation method in the embodiment are implemented.
[0262] In this embodiment, the computer-readable storage medium includes flash memory, hard disk, multimedia card, card-type memory (for example, SD or DX memory, etc.), random access memory (RAM), static random access memory (SRAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), programmable read-only memory (PROM), magnetic memory, disk, optical disk, etc. In some embodiments, the computer-readable storage medium can be an internal storage unit of a computer device, such as a hard disk or memory of the computer device. In other embodiments, the computer-readable storage medium can also be an external storage device of a computer device, such as a plug-in hard disk equipped on the computer device, a smart memory card (Smart Media Card, referred to as SMC), a secure digital (Secure Digital, referred to as SD) card, a flash card, etc. Of course, the computer-readable storage medium can also include both the internal storage unit of the computer device and its external storage device. In this embodiment, the computer-readable storage medium is generally used to store an operating system and various application software installed on the computer device, such as the program code of the video generation method in the embodiment, etc. In addition, the computer-readable storage medium can also be used to temporarily store various types of data that have been output or are to be output.
[0263] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present application. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine different embodiments or examples described in this specification and the features of different embodiments or examples, unless they are contradictory.
[0264] Any process or method description in the flow chart or otherwise described herein can be understood to represent a module, fragment or portion of a code including one or more (two or more) executable instructions for implementing the steps of a specific logical function or process. And the scope of the preferred embodiment of the present application includes other implementations, in which the functions may not be performed in the order shown or discussed, including in a substantially simultaneous manner or in a reverse order according to the functions involved.
[0265] The logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as an ordered list of executable instructions for implementing logical functions, which can be embodied in any computer-readable medium for use by an instruction execution system, apparatus or device (such as a computer-based system, a system including a processor or other system that can fetch instructions from an instruction execution system, apparatus or device and execute instructions), or used in combination with these instruction execution systems, apparatuses or devices.
[0266] It should be understood that the various parts of the present application can be implemented with hardware, software, firmware or a combination thereof. In the above embodiments, multiple steps or methods can be implemented with software or firmware stored in a memory and executed by a suitable instruction execution system. All or part of the steps of the above embodiment method can be completed by instructing the relevant hardware through a program, which can be stored in a computer-readable storage medium, and when the program is executed, it includes one of the steps of the method embodiment or a combination thereof.
[0267] In addition, each functional unit in each embodiment of the present application can be integrated into a processing module, or each unit can exist physically separately, or two or more units can be integrated into one module. The above-mentioned integrated module can be implemented in the form of hardware or in the form of a software functional module. If the above-mentioned integrated module is implemented in the form of a software functional module and sold or used as an independent product, it can also be stored in a computer-readable storage medium. The storage medium can be a read-only memory, a disk or an optical disk, etc.
[0268] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of various changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
Claims
1. A video generation method, characterized in that: include: Acquire a duration sequence, wherein the duration sequence includes a plurality of durations in a sequential order; Acquire multiple candidate video materials; Matching target video materials for each duration from the multiple candidate video materials, thereby obtaining multiple target video materials corresponding to the multiple durations; Determining the sequence of the multiple target video materials according to the sequence of the multiple durations; Based on the multiple target video materials and the sequence of the multiple target video materials, a video is generated; wherein: The step of matching the target video material for each duration from the plurality of candidate video materials to obtain a plurality of target video materials corresponding to the plurality of durations further comprises: When the corresponding target video material is not obtained for two consecutive time periods, the two time periods are merged; Acquire video material that matches the merge duration as candidate video material, and then acquire target video material corresponding to the merge duration; When a segment or a plurality of intervals of the duration have no corresponding target video material, the duration without the target video material is deleted.
2. The method according to claim 1, characterized in that The acquiring time sequence includes: Get the target music; Identifying a plurality of card points of the target music, wherein the plurality of card points include rhythm mutation points of the target music; A duration sequence including multiple durations is generated based on the multiple card points.
3. The method according to claim 1, characterized in that: The acquiring time sequence includes: Get configuration parameters; Based on the configuration parameters, a duration sequence including a plurality of durations is generated.
4. The method according to claim 1, characterized in that: The method further includes: receiving element information, the element information being used to indicate characteristic elements that the generated video needs to include; The obtaining of a plurality of candidate video materials includes: obtaining a plurality of candidate video materials from a material library based on the element information.
5. The method according to claim 4, characterized in that The element information includes key words, auxiliary words and excluded words; The acquiring a plurality of candidate video materials from a material library based on the element information includes: Based on the keyword, obtaining a first type of video material whose tag information matches the keyword from a material library; Based on the auxiliary terms, selecting the second category of video materials from the first category of video materials; the auxiliary terms are selectively input terms; Based on the exclusion terms, video materials whose video tags match the exclusion terms are removed from the second category of video materials to obtain third category of video materials; the exclusion terms are selected input terms; The third category video material is determined to be a target category video material, and a plurality of candidate video materials are obtained from the target category video material.
6. The method according to claim 5, characterized in that The obtaining of multiple candidate video materials includes: Get the maximum and minimum duration of multiple durations; Determining a maximum preset duration based on the maximum duration, and determining a minimum preset duration based on the minimum duration; From the third category of video materials, video materials with a duration greater than the maximum preset duration are eliminated, and / or video materials with a duration less than the minimum preset duration are eliminated, to obtain fourth category of video materials; The fourth category video material is determined to be a target category video material, and a plurality of candidate video materials are obtained from the target category video material.
7. The method according to claim 5 or 6, characterized in that: The obtaining a plurality of candidate video materials from the target video material comprises: Get the number of segments of multiple durations; Based on the number of segments, determining a calibrated number of candidate video materials to obtain; A first random factor is used to obtain a calibrated number of multiple candidate video materials from the target video material.
8. The method according to claim 1, characterized in that The step of matching the target video material for each duration from the plurality of candidate video materials comprises: Get the length of a period of time; Acquire a plurality of video materials matching the time length from the plurality of candidate video materials; A second random factor is used to obtain a video material from the multiple video materials as the target video material for the duration.
9. The method according to claim 8, characterized in that The step of acquiring a plurality of video materials matching the time length from the plurality of candidate video materials comprises: Get duration tolerance; Determining a duration range based on the time length and the duration tolerance; Based on the duration range, a plurality of video materials matching the duration range are obtained from the plurality of candidate video materials.
10. The method according to claim 9, characterized in that The step of generating a video based on the plurality of target video materials and the sequence of the plurality of target video materials comprises: Adjusting the playback speed of the target video material so that the duration of the target video material is adapted to the time length; A video is generated based on the multiple target video materials after speed adjustment and the sequence of the multiple target video materials.
11. The method according to claim 1, characterized in that: The step of generating a video based on the plurality of target video materials and the sequence of the plurality of target video materials comprises: Create video projects; According to the sequence of the multiple target video materials, the multiple target video materials are respectively imported into the video project to generate a video.
12. The method according to claim 1, characterized in that The step of generating a video based on the plurality of target video materials and the sequence of the plurality of target video materials comprises: Acquire multiple candidate special effect materials; Using a third random factor from the plurality of candidate special effect materials, to adjust the special effect material for each target video material; A video is generated based on a plurality of target video materials after adding special effects and the sequence of the plurality of target video materials.
13. A video generation method, characterized in that: include: Sending element information, where the element information is used to indicate characteristic elements that need to be included in the generated video, so that the server obtains multiple candidate video materials from the material library based on the element information and generates a video according to the multiple candidate video materials and the time sequence; Receive the video returned by the server; wherein: The duration sequence includes multiple durations in a sequential order; Generating a video according to the plurality of candidate video materials and the duration sequence comprises: Matching target video materials for each duration from the multiple candidate video materials, thereby obtaining multiple target video materials corresponding to the multiple durations; When a segment or a plurality of intervals of the duration have no corresponding target video material, the duration without the target video material is deleted.
14. A video generating device, characterized in that: include: A duration sequence acquisition module, used to acquire a duration sequence, wherein the duration sequence includes a plurality of durations in a sequential order; A material acquisition module, used to acquire multiple candidate video materials; A material matching module, used to match the target video material for each duration from the multiple candidate video materials, so as to obtain multiple target video materials corresponding to the multiple durations; A sequence determination module, used to determine the sequence of the plurality of target video materials according to the sequence of the plurality of durations; A video generation module is used to generate a video based on the multiple target video materials and the sequence of the multiple target video materials; wherein: The material matching module is further configured to merge the two consecutive durations when no corresponding target video material is obtained for the two consecutive durations; Acquire video material that matches the merge duration as candidate video material, and then acquire target video material corresponding to the merge duration; When a segment or a plurality of intervals of the duration have no corresponding target video material, the duration without the target video material is deleted.
15. A video generating device, characterized in that: include: An element configuration module, used to send element information, wherein the element information is used to indicate characteristic elements that need to be included in the generated video, so that the server obtains multiple candidate video materials from the material library based on the element information and generates a video according to the multiple candidate video materials and the time sequence; The video receiving module is used to receive the video returned by the server; wherein: The duration sequence includes multiple durations in a sequential order; Generating a video according to the plurality of candidate video materials and the duration sequence comprises: Matching target video materials for each duration from the multiple candidate video materials, thereby obtaining multiple target video materials corresponding to the multiple durations; When a segment or a plurality of intervals of the duration have no corresponding target video material, the duration without the target video material is deleted.
16. An electronic device, characterized in that: include: at least one processor; as well as a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method according to any one of claims 1 to 13.
17. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and when the computer instructions are executed by a processor, the method according to any one of claims 1 to 13 is implemented.
18. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the computer program implements any one of claims 1 to 13.
Citation Information
Patent Citations
Multimedia resource searching method and device
CN110019852A
Video generation method and device, computer equipment and storage medium
CN111625682A
Mixed shear video generation method and device, electronic equipment and computer readable storage medium
CN111683209A
Video music matching method and device, storage medium and electronic equipment
CN111741233A
Method and device for generating video
CN111798879A
