Video processing method and device
By identifying the feature information of the video clip and the duration threshold of the video playback platform, and outputting matching target video clips, the problem of cumbersome operations of users when publishing videos on different platforms is solved, and efficient video editing and content display is achieved.
Patent Information
- Application Number
- CN202411424821.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-12
- Publication Date
- 2024-12-31
AI Technical Summary
When users publish videos on different video playback platforms, they need to crop the videos multiple times to meet the duration requirements of each platform, resulting in cumbersome and inconvenient operations.
By identifying the characteristic information of the video clip, the highlight clip is identified, and the matching target video clip is output according to the duration threshold of each video playback platform, so as to meet the video duration requirements of multiple platforms at one time.
It simplifies user operations, improves video editing efficiency, ensures the integrity and excitement of video content, and avoids multiple cropping and splicing operations.
Smart Images

Figure CN119233016A_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the field of image processing technology, and specifically relates to a video processing method and device. Background Art
[0002] At present, there are more and more video playback platforms. When users publish videos on different video playback platforms, different video playback platforms have different restrictions on the length of videos that can be published. For example, some video playback platforms limit the video length to 10 seconds, while some video playback platforms limit the video length to 1 minute.
[0003] Suppose a user shoots a travel video and needs to publish it on different video playback platforms. The user needs to repeatedly crop the video to make the video length meet the requirements of different video playback platforms. In order to ensure that the content of each cropped video is complete and wonderful, the user needs to screen and check the video content every time he crops, instead of simply cropping the first few frames or the last few frames.
[0004] It can be seen that in the prior art, when users publish videos on different video playback platforms, they need to crop a video multiple times, which makes the user operation cumbersome. Summary of the invention
[0005] The purpose of the embodiments of the present application is to provide a video processing method that can solve the problem in the prior art that when a user publishes a video on different video playback platforms, the user needs to crop a video multiple times, resulting in cumbersome user operations.
[0006] In a first aspect, an embodiment of the present application provides a video processing method, the method comprising:
[0007] According to feature information of a video segment in the video to be processed, a highlight segment in the video to be processed is identified; wherein a score of the feature information of the highlight segment is greater than a preset score threshold;
[0008] According to the duration threshold of each video playback platform and the identified highlight segment, target video segments matching the duration threshold of each video playback platform are output respectively.
[0009] In a second aspect, an embodiment of the present application provides a video processing device, the device comprising:
[0010] An identification module, configured to identify a highlight segment in the video to be processed according to feature information of the video segment in the video to be processed; wherein the score of the feature information of the highlight segment is greater than a preset score threshold;
[0011] The output module is used to output target video segments that match the duration threshold of each video playback platform according to the duration threshold of each video playback platform and the identified highlight segments.
[0012] In a third aspect, an embodiment of the present application provides an electronic device, comprising a processor and a memory, wherein the memory stores programs or instructions that can be run on the processor, and when the programs or instructions are executed by the processor, the steps described in the first aspect are implemented.
[0013] In a fourth aspect, an embodiment of the present application provides a readable storage medium, on which a program or instruction is stored, and when the program or instruction is executed by a processor, the steps of the method described in the first aspect are implemented.
[0014] In a fifth aspect, an embodiment of the present application provides a chip, comprising a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run a program or instruction to implement the method described in the first aspect.
[0015] In a sixth aspect, an embodiment of the present application provides a computer program product, which is stored in a storage medium and is executed by at least one processor to implement the method described in the first aspect.
[0016] In an embodiment of the present application, by identifying the highlight segments whose feature information scores in the video to be processed are greater than a preset score threshold according to the feature information of each video segment in the video to be processed, the target video segments that match the duration threshold of each video playback platform are outputted respectively according to the duration threshold limited by the video playback platform and the identified highlight frequency band for different video playback platforms. In this technical scheme, video segments with different durations can be outputted at one time for the video to be processed to meet the video release duration requirements of each video playback platform, and since the highlight segments of the video to be processed are obtained by screening based on the feature information of the segment content. Therefore, the highlight segments can more fully display the wonderful content of the video to be processed, and then the target video segments outputted according to the highlight segments can also more richly reflect the wonderful content of the video. In this way, when it is necessary to obtain multiple video segments of different durations based on the same video, there is no need for the user to perform video editing operations such as cropping and splicing multiple times to match different durations, and multiple high-quality video segments of different durations that can fully display the video content can be obtained, which simplifies user operations and effectively improves video editing efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] Figure 1 It is one of the flow charts of the video processing method provided in the embodiment of the present application;
[0018] Figure 2This is one of the interface diagrams of the platform selection interface provided in the embodiment of the present application;
[0019] Figure 3 This is the second interface diagram of the platform selection interface provided in the embodiment of the present application;
[0020] Figure 4 This is one of the interface schematic diagrams of the video editing interface provided in the embodiment of the present application;
[0021] Figure 5 This is the second flowchart of the video processing method provided in the embodiment of the present application;
[0022] Figure 6 This is the second interface schematic diagram of the video editing interface provided in the embodiment of the present application;
[0023] Figure 7 This is the third interface diagram of the video editing interface provided in the embodiment of the present application;
[0024] Figure 8 This is the fourth interface diagram of the video editing interface provided in the embodiment of the present application;
[0025] Fig. 9 This is the fifth interface diagram of the video editing interface provided in the embodiment of the present application;
[0026] Fig.10 This is the sixth interface diagram of the video editing interface provided in the embodiment of the present application;
[0027] Fig.11 This is the seventh interface schematic diagram of the video editing interface provided in the embodiment of the present application;
[0028] Fig.12 is one of the block diagrams of the video processing device provided in the embodiment of the present application;
[0029] Fig.13 One of the block diagrams of the electronic device provided in the embodiment of the present application;
[0030] Fig.14 This is one of the hardware structure diagrams of the electronic device provided in the embodiment of the present application. DETAILED DESCRIPTION
[0031] The following will be combined with the drawings of the embodiments of the present application to clearly describe the technical solutions of the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, rather than all of the embodiments. All other embodiments obtained by ordinary technicians in this field based on the embodiments of the present application belong to the scope of protection of this application.
[0032] The terms "first", "second", etc. in the specification and claims of the present application are used to distinguish similar objects, and are not used to describe a specific order or sequence. It should be understood that the terms used in this way can be interchangeable under appropriate circumstances, so that the embodiments of the present application can be implemented in an order other than those illustrated or described here, and the objects distinguished by "first", "second", etc. are generally a class, and the number of objects is not limited. For example, the target object can be one or more. In addition, "and / or" in the specification and claims represents at least one of the connected objects, and the character " / " generally indicates that the objects associated before and after are in an "or" relationship.
[0033] The video processing method and device provided in the embodiments of the present application are described in detail below through specific embodiments and their application scenarios in conjunction with the accompanying drawings.
[0034] like Figure 1 FIG. 2 is a flowchart of a video processing method provided by an embodiment of the present application. The video processing method can be applied to an electronic device. Optionally, the electronic device can be a mobile phone, a tablet, a computer, or a wearable device. The embodiment of the present application uses the video processing method applied to an electronic device as an example. The video processing method includes:
[0035] Step 110: identifying a highlight segment in the video to be processed according to feature information of the video segment in the video to be processed, wherein the score of the feature information of the highlight segment is greater than a preset score threshold.
[0036] Among them, the score of the feature information of the video clip is used to indicate the importance of the content of the video clip in the entire video. For example, the stronger the driving force of the plot of the video clip on the events in the video, the higher the score of the video clip; the higher the emotion expressed by the video clip, the higher the score of the video clip; the better the visual effect of the video clip, the higher the score of the video clip, etc. The higher the proportion of shots of human objects in the video clip, the higher the score of the video clip. Based on this, the highlight clip can also become a key clip, which can be a clip with a plot turning point, a clip with an emotional climax, or a visually eye-catching picture clip in the video. For example, when the human object in the video clip is standing in the front, the score is higher. On the contrary, when the human object in the video clip is standing in the side, the score is relatively lower.
[0037] Optionally, the electronic device may use a highlight segment recognition algorithm to divide the video to be processed into multiple video segments and analyze the feature information of each video segment. Based on the feature information of each video segment, the score of each video segment is identified. The highlight segment recognition algorithm is used to output the score of each video segment by analyzing the feature information of each video segment in the input video. Furthermore, the electronic device determines the video segments with scores greater than a preset threshold in the video segments of the video to be processed as highlight segments, and outputs the highlight segments. By way of example, the highlight segment recognition algorithm may be a master editing algorithm, a highlight segment technology algorithm based on prototype learning, and the like.
[0038] For example, this embodiment can be applied to a video editing application. The application can be used to output scores for video segments using a highlight segment recognition algorithm. The electronic device uses the application to extract highlight segments from the video to be processed based on the scores of feature information of each video segment in the video to be processed.
[0039] In some embodiments of the present application, the video to be processed may be composed of at least one video segment. Alternatively, the video to be processed may be composed of multiple pictures. Alternatively, the video to be processed may be composed of a video and a picture.
[0040] In some embodiments, when the video to be processed is at least one video, the electronic device can divide the video to be processed into multiple video segments according to the video duration or video plot. For example, the electronic device can divide the video into multiple video segments of the same duration. Or, the electronic device can divide the content of each plot in the video into a video segment to obtain multiple video segments. For example, the video duration of each video segment obtained by the electronic device can be 2 seconds. Or, the video to be processed records the content of the protagonist A from driving out, eating to driving home again. The three video segments that the electronic device can obtain by dividing specifically include: a video segment recording driving out, a video segment recording eating, and a video segment recording driving home again.
[0041] In the case where the video to be processed includes multiple pictures, the electronic device can group the multiple images into multiple video clips according to the number of pictures or the relevance of the picture contents. For example, the electronic device can divide the multiple pictures into multiple video clips including an equal number of pictures. Alternatively, the electronic device can divide multiple pictures whose relevance parameters of the picture contents are greater than a preset relevance threshold into one video clip to obtain multiple video clips. For example, each video clip obtained by the electronic device may include 3 pictures. Alternatively, the electronic device divides the video clips according to the categories of the photographed objects in the multiple pictures. Alternatively, the electronic device divides the video clips according to the order of the shooting moments of the multiple pictures.
[0042] When the video to be processed includes a video and a picture, the electronic device can splice the picture and the video to obtain a spliced video. The spliced video is divided into a plurality of video segments according to the duration of the spliced video.
[0043] In an optional implementation, the size of the preset score threshold can be determined according to the score range of the feature information of the video clip. Of course, the size of the preset score threshold can also be customized. For example, it is assumed that the score range of the feature information of the video clip is 1 to 5. For reference, the preset score threshold can be 3. Accordingly, if the score of the video clip is greater than 3, the video clip is considered to be a high-scoring clip.
[0044] Step 120: According to the duration threshold of each video playback platform and the identified highlight segments, target video segments matching the duration threshold of each video playback platform are output respectively.
[0045] Optionally, the electronic device may store the duration threshold of each video playback platform. Alternatively, the electronic device may read the duration threshold of each video playback platform from a third-party device. The electronic device matches the video segment with the duration threshold of each video playback platform according to the duration threshold of each video playback platform and the identified highlight segment, and outputs the target video segment that matches the duration threshold of each video playback platform.
[0046] The target video segment that matches the duration threshold may refer to a video segment whose video duration is equal to the duration threshold. Taking a video playback platform as an example, the electronic device may output a video segment that meets the duration threshold based on the duration threshold of the video playback platform and the identified highlight segment to obtain a target video segment that matches the video playback platform.
[0047] In an optional implementation, the electronic device may support the user to preview the target video clips matched for each video playback platform, so that the user can check the video clips generated for each video playback platform. Specifically, the electronic device may display the video clips of one video playback platform first after obtaining the video clips of each video playback platform. The user's switching display input is received, and in response to the switching display input, the video clips of another video playback platform are switched to display.
[0048] Among them, the switching display input is used to control the electronic device to display video clips of different video playback platforms. For example, the switching display input can be an input in the form of a click, long press, slide or voice for the switching control. Or, the switching display input can be a left and right slide input or an up and down slide input, etc. For example, the user can preview the target video clips that match different video playback platforms by sliding left and right in the video preview page. In addition, the user can click the export video control to enable the electronic device to output video clips suitable for each video platform. Of course, the electronic device can also preview the video clips of each video playback platform in other ways. For example, the electronic device can simultaneously display preview images of video clips of multiple video playback platforms in a list. By receiving a trigger input for the preview image, the video clip corresponding to the preview image is displayed in response to the trigger input.
[0049] In some embodiments of the present application, the video processing method can output a target video clip that matches multiple fixed video playback platforms. Alternatively, the method also supports the user to customize the video playback platform to match the video clip to the video playback platform selected by the user, thereby improving the flexibility of video editing. Based on this, optionally, the video processing method also includes:
[0050] Display a list of video playback platforms, which includes platform identifiers of multiple video playback platforms and the recommended video duration of each video playback platform (i.e., the duration threshold of the video playback platform). Receive input of multiple target platform identifiers in the displayed platform identifiers. In response to the input of multiple target platform identifiers, determine the selected multiple target platform identifiers, and obtain the duration threshold of the video playback platform indicated by each target platform identifier, so that the electronic device can output the target video clips that match the duration threshold of each video playback platform according to the duration thresholds of the multiple video playback platforms and the identified highlight clips. Among them, the input of the target platform identifier can be an input in the form of clicking, long pressing, sliding or voice on the target platform identifier.
[0051] For example, this embodiment can be applied to a video editing application. After a user starts a video editing application through an electronic device, he can enter Figure 2The platform selection interface shown. The video playback platform list displayed on the platform selection interface includes the platform identification application (Application, APP) 1 of the first video playback platform, the platform identification APP2 of the second video playback platform, and the platform identification APP3 of the third video playback platform. In addition, the video playback platform list also includes the recommended video durations for the first video playback platform, the second video playback platform, and the third video playback platform: 10 minutes (min), 1min, and 10min, respectively. The user can click APP1 201 and APP3 202 in sequence to enable the electronic device to determine that the selected target platform identifications are APP1 and APP3, and obtain the duration thresholds of 10min and 10min for the first video playback platform and the third video playback platform, respectively.
[0052] Optionally, the video processing method may also support customizing the duration of the target video segment to be output, so as to increase the flexibility of video duration processing and improve the user's video cropping experience. The video processing method may also include:
[0053] A list of video playback platforms is displayed, which also includes a custom duration setting identifier. An input for the custom duration setting identifier is received, and in response to the input, a duration input page is displayed. The video duration entered on the duration input page is obtained, and a new duration threshold is determined as the video duration. The electronic device can also output a target video segment that matches the duration threshold based on the new duration threshold and the identified highlight segments. The input for the custom duration setting identifier can be an input in the form of a click, long press, slide, or voice on the target platform identifier.
[0054] For an example, please refer to Figure 3 , the video playback platform list displayed on the platform selection interface includes: a custom duration setting mark. The custom duration setting mark displays the words "Please click to enter the duration". The user can click the custom duration setting mark 203 to cause the electronic device to display the duration input page, and the display format of the video duration on the duration input page is hours-minutes-seconds. After the user writes the video duration of 100 seconds on the duration input page, the electronic device displays 00 hours, 1 minute and 40 seconds, and determines that the new duration threshold is 1 minute and 40 seconds.
[0055] In another example, after the user selects the video playback platform on the platform selection interface, the user can click the next control on the platform selection interface to cause the electronic device to jump to the object selection page, which can display the videos and pictures that the user has authorized to access. The user selects the videos and pictures to be uploaded on the object selection page as the videos to be processed. After the user completes the selection, the user can click the next control on the object selection page to cause the electronic device to jump to the video editing interface. The electronic device can identify the highlight clips of the video to be processed in the video editing interface and display them in the following manner: Figure 4 The video editing interface shown shows the various video clips in the video to be processed, and the highlight clips are marked. Figure 4 In FIG. 4 , the highlight segment of the video to be processed is indicated by arrow 401. The electronic device can output a target video segment that matches the duration threshold of each video playback platform according to the highlight segment.
[0056] In the embodiment of the present application, according to the characteristic information of each video clip in the video to be processed, the highlight clip whose score of the characteristic information in the video to be processed is greater than the preset score threshold is identified, so as to output the target video clips matching the duration threshold of each video playback platform according to the duration threshold limited by the video playback platform and the identified highlight frequency band for different video playback platforms. In this technical scheme, video clips with different durations can be output at one time for the video to be processed to meet the video release duration requirements of each video playback platform, and because the highlight clips of the video to be processed are obtained by screening based on the characteristic information of the clip content. Therefore, the highlight clips can more fully display the wonderful content of the video to be processed, and then the target video clips output according to the highlight clips can also more richly reflect the wonderful content of the video. In this way, when it is necessary to obtain multiple video clips of different durations based on the same video, there is no need for the user to perform video editing operations such as cropping and splicing multiple times to match different durations, and multiple high-quality video clips of different durations that can fully display the video content can be obtained, which simplifies the user operation and effectively improves the video editing efficiency.
[0057] In the embodiment of the present application, when the electronic device outputs video clips according to the duration threshold and highlight clips of each video playback platform, the following three situations may occur for each duration threshold: the total duration of the highlight clips is equal to the duration threshold, the total duration of the highlight clips is less than the duration threshold, and the total duration of the highlight clips is greater than the duration threshold. For different situations, the electronic device can process in different ways the process of executing step 120 to output target video clips that match the duration threshold of each video playback platform according to the duration threshold of each video playback platform and the identified highlight clips, respectively.
[0058] In an optional implementation, Figure 5As shown, the process in which the electronic device performs step 102 to output target video segments matching the duration thresholds of the respective video playback platforms according to the duration thresholds of the respective video playback platforms and the identified highlight segments may include:
[0059] Step 501: for each video playback platform's duration threshold, determine the relationship between the total duration of the highlight segment of the video to be processed and the duration threshold.
[0060] Among them, the total duration of the highlight segments refers to the sum of the durations of all the highlight segments identified for the video to be processed. The electronic device can obtain the total duration of the highlight segments of the video to be processed by calculating the sum of the durations of each highlight segment. By comparing the total duration of the highlight segments with the duration threshold, the size relationship between the total duration of the highlight segments and the duration threshold is determined. The size relationship can be that the total duration of the highlight segments is less than the duration threshold, or the total duration of the highlight segments is equal to the duration threshold, or the total duration of the highlight segments is greater than the duration threshold.
[0061] Step 502: When the total duration of the highlight segments is equal to the duration threshold, output a target video segment that matches the duration threshold according to the highlight segments.
[0062] Optionally, the electronic device can directly splice all the identified highlight segments according to the target splicing order to obtain and output the target video segment that matches the duration threshold. The target splicing order can be the playback order of the highlight segments in the video to be processed. Alternatively, the target splicing order can be a user-defined order, etc.
[0063] In some embodiments of the present application, when the total duration of the highlight segments is greater than the duration threshold, the electronic device may further filter the highlight segments from the highlight segments of the video to be processed to output a target video segment that matches the duration threshold. Optionally, the electronic device executing step 102 further includes:
[0064] Step 503: When the total duration of the highlight segment is greater than the duration threshold, output a video judgment that matches the duration threshold according to the selection priority of the highlight segment from high to low. The selection priority is positively correlated with the score of the feature information of the highlight segment.
[0065] Optionally, when the total duration of the highlight segments is greater than the duration threshold, it indicates that the sum of the durations of all the screened highlight segments is greater than the duration threshold of the video playback platform. The electronic device may prioritize the highlight segments with higher scores according to the order of the selection priorities of the highlight segments from high to low. The screened highlight segments are spliced in the target splicing order to obtain and output a target video segment that matches the duration threshold. Among them, the screened highlight segments meet the following conditions: the total duration is greater than or equal to the duration threshold, the number is the smallest, and the score is the highest. It is not difficult to understand that the total duration of the screened highlight segments is not less than the duration threshold, and is closest to the duration threshold.
[0066] It should be noted that there is a case where the total duration of the highlight segments selected according to the selection priority cannot be equal to the duration threshold. For example, suppose the selection priority is arranged as follows: highlight segment A, highlight segment B, and highlight segment C. The video duration of highlight segment A is less than the duration threshold, but the total duration of highlight segment A and highlight segment B is greater than the duration threshold.
[0067] In this case, the electronic device may optionally crop a highlight segment obtained by cropping to obtain a new highlight segment, so that the sum of the durations of the highlight segments after cropping matches the duration threshold. The duration of the new highlight segment may be the difference between the sum of the durations of all highlight segments selected before cropping and the duration threshold.
[0068] In addition, since there may be at least two highlight segments with the same score, in some embodiments, when the total duration of the highlight segments is greater than the duration threshold, the electronic device can filter the at least two highlight segments with the same score according to the target filtering rule.
[0069] Among them, the target screening rule can be a random screening rule. Alternatively, the target screening rule can follow the method of video duration better matching the duration threshold. For example, if the sum of the durations of the highlight clips currently screened out is 5 seconds, and the duration threshold is 6 seconds. If the video durations of two highlight clips with the same score are 1 second and 3 seconds respectively, the electronic device can select the highlight clip with a video duration of 1 second to better fit the duration threshold.
[0070] For example, assume that the total duration of all highlight segments is 32 seconds, and the duration threshold is 15 seconds. Also assume that the score range of the feature information of the highlight segments is 5 to 1. There are 3 highlight segments with a score of 5 and 4 highlight segments with a score of 4 in the video to be processed.
[0071] The electronic device can select a highlight segment with a score of 5 from all highlight segments, and determine whether the video duration of the selected highlight segment is greater than a duration threshold.
[0072] If yes, and the video duration of the highlight segment is equal to the duration threshold, the electronic device can determine the selected highlight segment as the target video segment that matches the duration threshold, and output the video segment. If no, the electronic device can select another highlight segment with a score of 5, and determine whether the sum of the video durations of all selected highlight segments (i.e., 2 highlight segments with a score of 5) is greater than the duration threshold.
[0073] If yes, and the sum of the video durations of all the selected highlight clips is equal to the duration threshold, the electronic device can splice the selected highlight clips according to the target splicing order to obtain and output the target video clip that matches the duration threshold. If no, the electronic device can determine whether the sum of the video durations of the three highlight clips with a score of 5 (i.e., all highlight clips with a score of 5) is greater than the duration threshold.
[0074] If yes, and the sum of the video durations of all the selected highlight clips is equal to the duration threshold, the electronic device can splice the selected highlight clips according to the target splicing order to obtain and output the target video clip that matches the duration threshold. If no, the electronic device can select a highlight clip with a score of 4 again, and determine whether the sum of the video durations of all the selected highlight clips (3 highlight clips with a score of 5 and 1 highlight clip with a score of 4) is greater than the duration threshold.
[0075] If so, but the sum of the video durations of all the selected highlight segments is 17 seconds, which is greater than the duration threshold, the electronic device can crop one of all the selected highlight segments to obtain a highlight segment with a video duration of 17-15 seconds. The electronic device can splice the selected highlight segments in the target splicing order to obtain and output a target video segment that matches the duration threshold.
[0076] For example, it is assumed that the electronic device identifies highlight segments A, B, and C from the video to be processed. However, the total duration of highlight segments A, B, and C is greater than the duration threshold. The electronic device selects highlight segments A and C according to the selection priority of the highlight segments. And based on highlight segments A and C, the electronic device outputs a target video segment 601 that matches the duration threshold. Figure 6 The video editing interface is displayed. Figure 6 The interface shown also displays the video clips to be processed, and Figure 6 In the figure, the highlight segments are marked with arrows, and the highlight segments A and C constituting the output target video segments are marked with black as the background color.
[0077] In an embodiment of the present application, when the total duration of the screened highlight segments is greater than the duration threshold, the electronic device can prioritize highlight segments with higher scores to generate target video segments that match the duration threshold, thereby ensuring that the output target video segments can more fully display the wonderful content shot by the user and improve the video editing effect.
[0078] In some embodiments of the present application, when the total duration of the highlight segments is less than the duration threshold, the electronic device may further select non-highlight segments in part of the video to be processed, so as to jointly generate a target video segment that matches the duration threshold based on the highlight segments and the selected non-highlight segments. Optionally, the electronic device executing step 102 further includes:
[0079] Step 504: When the total duration of the highlight segments is less than the duration threshold, output a target video segment that matches the duration threshold based on all the highlight segments and at least some of the non-highlight segments.
[0080] Optionally, when the total duration of the highlight segments is less than the duration threshold, it indicates that the identified highlight segments are insufficient to generate a target video segment that matches the duration threshold. The electronic device may filter at least some of the non-highlight segments from the non-highlight segments of the video to be processed according to the segment screening rule to ensure that the sum of the video durations of the screened non-highlight segments and all the highlight segments is not less than the duration threshold, and is as close to the duration threshold as possible. The electronic device splices the screened non-highlight segments and all the highlight segments in a target splicing order to obtain and output a target video segment that matches the duration threshold. The segment screening rule may be a random screening rule. Alternatively, the segment screening rule may be a screening rule based on scores from high to low.
[0081] As an example, assume that the total duration of all highlight segments is 10 seconds and the duration threshold is 15 seconds. The electronic device can select a non-highlight segment with the highest score from all non-highlight segments of the video to be processed. If the video duration of the non-highlight segment is 15-10 seconds, the electronic device can directly splice the non-highlight segment and all highlight segments to generate a target video segment that matches the duration threshold.
[0082] If the video duration of the non-highlight segment is greater than 15-10 seconds, the electronic device may crop the non-highlight segment to retain a 5-second video segment. Afterwards, the electronic device may splice the non-highlight segment and all highlight segments to generate a target video segment that matches the duration threshold.
[0083] If the video length of the non-highlight segment is less than 15-10 seconds, the electronic device can select a non-highlight segment with the highest score again, and determine whether the total length of all selected non-highlight segments is less than 5 seconds. If not, select a non-highlight segment with the highest score again... until the total length of all selected non-highlight segments is greater than or equal to 5 seconds.
[0084] When the total duration of all selected non-highlight segments is equal to 5 seconds, the electronic device can directly splice all selected non-highlight segments and all highlight segments to generate a target video segment that matches the duration threshold. When the total duration of all selected non-highlight segments is greater than 5 seconds, the electronic device can crop the selected non-highlight segments to retain 5 seconds of video segments. Thereafter, the electronic device can splice all selected non-highlight segments and all highlight segments to generate a target video segment that matches the duration threshold. The target splicing order can be the playback order of the highlight segments in the video to be processed. Alternatively, the target splicing order can be a user-defined order, etc.
[0085] As another example, assume that the electronic device identifies highlight segments A, B, and C from the video to be processed. However, for the first video playback platform indicated by APP1, the total duration of highlight segments A, B, and C is less than the duration threshold. The electronic device randomly selects non-highlight segments D and non-highlight segments E, and outputs a target video segment 701 that matches the duration threshold based on highlight segments A, B, C, non-highlight segments D, and non-highlight segments E. Figure 7 The video editing interface is displayed. Figure 7 The interface shown also displays the various video clips of the video to be processed, and, Figure 7 In the figure, the highlight segments are marked with arrows, and the highlight segments A, B, C, and non-highlight segments D and E constituting the target video segment 701 are marked with black as the background color. It should be noted that Figure 7 The video segments marked by arrows and with black as the background color are: highlight segments constituting the target video segment 701. The video segments not marked by arrows but with black as the background color are: non-highlight segments constituting the target video segment 701.
[0086] In an embodiment of the present application, when the total duration of the screened highlight segments is less than the duration threshold, the electronic device can randomly select non-highlight segments to combine with the highlight segments to generate a target video segment that matches the duration threshold, thereby ensuring that the video duration of the output target video segment matches the duration threshold while ensuring that the output target video segment can fully display the wonderful content shot by the user.
[0087] In some embodiments of the present application, the electronic device may also identify highlight segments for manual editing by the user, so as to output a target video segment that matches a single duration threshold according to the manual editing result of the user. Optionally, step 120 outputs target video segments that match the duration threshold of each video playback platform according to the duration threshold of each video playback platform and the identified highlight segments, including:
[0088] Sub-step D1: According to the duration of the highlight segment of the video to be processed and the duration threshold, the video segments in the list whose duration matches the duration threshold are marked.
[0089] In the embodiment of the present application, the electronic device can display a list of video clips in the video to be processed. For each duration threshold, according to the duration of the highlight clip of the video to be processed and the duration threshold, the video clips in the list whose duration matches the duration threshold are marked, so that the target video clips matching the duration threshold are subsequently generated according to the marked video clips, and the target video clips matching the duration threshold of each video playback platform are obtained.
[0090] It should be noted that the video segment whose duration matches the duration threshold may include: at least one video segment of the video to be processed. Accordingly, when the video segment whose duration matches the duration threshold includes: a video segment of the video to be processed, that is, when there is a highlight segment whose video duration meets the duration threshold, the electronic device may mark the highlight segment whose video duration meets the duration threshold. When the video segment whose duration matches the duration threshold includes: at least two video segments of the video to be processed, that is, when the video duration after combining at least two video segments meets the duration threshold, the electronic device may mark both of the at least two video segments whose video duration meets the duration threshold.
[0091] Optionally, the electronic device may mark the video clips in the list whose duration matches the duration threshold value by referring to the above-mentioned Figure 5 The method embodiment shown. The video clip marked by the electronic device can be the aforementioned Figure 5 In each case of the method shown, a video segment forms a target video segment.
[0092] Specifically and optionally, the electronic device may identify all highlight segments when the total duration of the highlight segments is equal to the duration threshold. When the total duration of the highlight segments is greater than the duration threshold, the electronic device may select highlight segments whose duration matches the duration threshold for identification according to the selection priority of the highlight segments. When the total duration of the highlight segments is less than the duration threshold, the electronic device may identify highlight segments whose duration matches the duration threshold and non-highlight segments.
[0093] In one example, after the electronic device identifies n (n is a positive integer) highlight segments of the video to be processed, the electronic device displays the following Figure 8 The video editing interface shown in the figure displays a list 402 of various video clips of the video to be processed. For the duration threshold of the second video playback platform indicated by APP2, if the total duration of n highlight clips is equal to the duration threshold, or the total duration of n highlight clips is greater than the duration threshold, but the total duration of n-1 highlight clips is less than the duration threshold, then the electronic device uses arrows and black as the background color to jointly identify all highlight clips A, highlight clips B and highlight clips C whose durations match the duration threshold in the list 402. Among them, the arrow mark indicates the highlight clip of the video to be processed. The black background color mark indicates that the video clip is selected to match the duration threshold.
[0094] In another example, if the total duration of n highlight segments is less than the duration threshold, the electronic device determines that the video segments whose durations match the duration threshold include: highlight segment A, highlight segment B, and highlight segment C, and non-highlight segment D and non-highlight segment E. Fig. 9 As shown, the electronic device identifies all highlight segments A, highlight segments B and highlight segments C in list 402 with arrows and black as the background color, and identifies non-highlight segments D and non-highlight segments E with black as the background color.
[0095] Sub-step D2: Receive a first input.
[0096] Among them, the first input can be used to confirm the marked video clip. Exemplarily, the first input includes but is not limited to: the user's touch input to the on-screen controls or screen areas through a touch device such as a finger or a stylus, or a voice command input by the user, or a specific gesture input by the user, or other feasible inputs, which can be determined according to actual usage needs and are not limited by the embodiments of the present invention. The specific gesture in the embodiments of the present application can be any one of a single-click gesture, a sliding gesture, a dragging gesture, a pressure recognition gesture, a long press gesture, an area change gesture, a double-press gesture, and a double-click gesture; the click input in the embodiments of the present application can be a single-click input, a double-click input, or any number of click inputs, etc., and can also be a long press input or a short press input. For example, if Figure 8 and Fig. 9 As shown, the video editing interface displays an “export video” control 404. The first input is a click input to the “export video” control 404.
[0097] Sub-step D3: In response to the first input, output a target video segment according to the marked video segment.
[0098] Optionally, the first input can be used to confirm the marked video segments corresponding to each duration threshold. Based on this, the electronic device can output the target video segments matching each duration threshold synchronously according to the marked video segments corresponding to each duration threshold in response to the first input. In this way, the user can control the electronic device to output the target video segments matching each duration threshold with one click, thereby improving the convenience of operation.
[0099] Alternatively, the first input may be used to confirm the marked video segment corresponding to a single duration threshold. Based on this, the electronic device may output a target video segment matching the duration threshold according to the determined marked video segment corresponding to the single duration threshold in response to the first input. In this way, the user may confirm the marked video segment corresponding to each duration threshold separately, so as to control the electronic device to selectively output a satisfactory target video segment and directly discard an unsatisfactory target video segment.
[0100] The following is a schematic illustration of the process of an electronic device outputting a target video segment matching a duration threshold according to a marked video segment corresponding to a single duration threshold. The process of an electronic device outputting target video segments matching each duration threshold according to the marked video segments can refer to the process of outputting the target video segment matching a single duration threshold.
[0101] Optionally, in response to the first input, the electronic device may splice the marked video segments according to the target splicing order to obtain a preliminary target video segment. Furthermore, the electronic device may determine whether the video duration of the preliminary target video segment is equal to the duration threshold. If so, the preliminary target video segment is directly determined to be the target video segment. If not, the electronic device crops the preliminary target video segment to obtain a target video segment whose video duration is equal to the duration threshold.
[0102] Alternatively, the electronic device may also determine, in response to the first input, whether the total duration of the marked video segments is equal to the duration threshold. If so, the marked video segments are spliced together according to the target splicing order to obtain the target video segments. If not, one of the marked video segments is cropped, and the processed marked video segments are spliced together according to the target splicing order to obtain the target video segment whose duration matches the duration threshold.
[0103] For example, Fig. 9 Taking the example shown as an example, Fig. 9The video editing interface shown also includes an "export video" control 404. When the user confirms that the target video segment is generated using the marked video segment selected by the electronic device, the user can click the "export video" control 404 to enable the electronic device to splice the highlight segment A, the highlight segment B, the highlight segment C, and the non-highlight segment D and the non-highlight segment E according to the playback order of the video segments in the video to be processed, and obtain and output the target video segment that matches the duration threshold.
[0104] Optionally, after marking the video segments in the list whose duration matches the duration threshold, the electronic device can also directly generate a target video segment based on the marked video segments, and display the target video segment for the user to preview the effect of the target video segment. If the user is satisfied with the target video segment, the user can perform a first input, so that the electronic device outputs the target video segment in response to the first input.
[0105] In an embodiment of the present application, before outputting a target video segment, all video segments used to constitute the target video segment can be output for user confirmation, thereby not only realizing the automation of video editing, but also satisfying the user's personalized video editing needs.
[0106] In some embodiments of the present application, the user can also set the playback effects of each video segment constituting the target video segment to adjust the overall playback effect of the target video segment, thereby further improving the video editing effect. Optionally, after step 110 and sub-step D1, the method further includes:
[0107] Sub-step E1: receiving a second input of a video segment in the video to be processed.
[0108] In an embodiment of the present application, the second input is used for the user to adjust the playback effect of the video clip. Among them, the video clip can be a highlight frequency band and a non-highlight clip. The playback effect includes the transition effect of the video clip, the filter display effect, the text display effect, etc. Exemplarily, the second input includes but is not limited to: the user's touch input to the controls on the screen or the screen area through a touch device such as a finger or a stylus, or a voice command input by the user, or a specific gesture input by the user, or other feasible input, which can be determined according to actual use requirements, and the embodiment of the present invention is not limited. The specific gesture in the embodiment of the present application can be any one of a single-click gesture, a sliding gesture, a drag gesture, a pressure recognition gesture, a long press gesture, an area change gesture, a double-press gesture, and a double-click gesture; the click input in the embodiment of the present application can be a single-click input, a double-click input, or any number of click inputs, etc., and can also be a long press input or a short press input.
[0109] Sub-step E2: In response to the second input, adjust the special effect information of the video clip.
[0110] The special effect information of the video clip is used for the electronic device to add the special effect indicated by the special effect information to the video clip included in the target video clip. In this step, the special effect information of the video clip includes but is not limited to: image color tone, text display effects in the video clip, filter display effects, and transition effects of a video clip to the next video clip.
[0111] Optionally, after the electronic device performs step 110 and identifies the highlight segments in the video to be processed according to the feature information of the video segments in the video to be processed, it can display a list including the video segments in the video to be processed. Based on this, the second input can be a second input to the displayed video segments. After receiving the second input to the video segments, the electronic device can adjust the special effect information of the video segments so that in the subsequent execution of step 120, the target video segments that match the duration threshold of each video playback platform and have the special effect information indicating the special effect of the video segments are output respectively.
[0112] Further optionally, after executing sub-step D1 and marking the video segments in the list whose duration matches the duration threshold according to the duration of the highlight segment of the video to be processed and the duration threshold, the electronic device may also receive a second input of the marked video segments to adjust the special effects information of the video segments, so as to output the target video segment having the special effects information indicating the special effects during the subsequent execution of step D3.
[0113] In one example, the second input includes a first sub-input and a second sub-input. The first sub-input is used to trigger the display of multiple playback special effect controls. The multiple playback special effect controls include: a color adjustment control, a text adjustment control, a transition effect adjustment control, etc. Each playback special effect control is used to trigger a different special effect. The second sub-input is used to trigger the special effect information of adjusting the video clip.
[0114] If the user wants to adjust the playback effect of a certain video clip, the user can click on the video clip in the list of video clips in the video to be processed displayed by the electronic device. After receiving the click input (i.e., the first sub-input) for the video clip, the electronic device can display multiple playback special effect controls. The user operates the target playback special effect control according to the desired special effect. After receiving the operation input (i.e., the second sub-input) of the target playback special effect control, the electronic device can adjust the feature information of the video clip according to the operation result of the target playback feature control. For example, the user adds filter A to the video clip by operating the target playback feature control. After receiving the operation input of the target playback special effect control, the electronic device writes the information of adding filter A to the feature information of the video clip.
[0115] As another example, in Figure 8In the example, since video clip 801 and video clip 802 are not continuously played video clips in the video to be processed, but video clip 801 and video clip 802 are selected highlight clips. Therefore, video clip 801 and video clip 802 may become adjacently played video clips in the output target video clip. The user can perform a second input on video clip 801 and video clip 802 respectively, so as to improve the visual playback smoothness between video clip 801 and video clip 802 in the target video clip by adjusting the overall image tones of video clip 801 and video clip 802 so that the overall image tones of the two video clips are the same or close.
[0116] In addition, the user may also perform a second input on video clip 801 and video clip 802 respectively to unify the text titles in video clip 801 and video clip 802, or adjust the text titles in video clip 801 and video clip 802 to have a certain chronological correlation to improve the visual playback smoothness between video clip 801 and video clip 802 in the target video clip.
[0117] In addition, the user can also perform a second input on video clip 801 and video clip 802 respectively, so as to edit the subtitles in video clip 801 and video clip 802 so that the subtitles in video clip 801 and video clip 802 are naturally connected, thereby improving the smoothness of video playback.
[0118] In the embodiment of the present application, by adding a playback special effect adjustment path for video clips, it is convenient for users to coordinate the playback effects of various video clips. While enriching the expression of video clips, the playback flow and integrity of the target video clips are improved, rather than rigidly splicing all video clips together, thereby effectively ensuring the quality of video editing and improving the video editing effect.
[0119] In some embodiments of the present application, the user may also perform trimming processing on each video segment of the video to be processed, especially on the identified highlight segment, to improve the flexibility of video editing. Optionally, after step 110 and sub-step D1, the method further includes:
[0120] Step F1: Receive a third input for the first highlight segment.
[0121] In some embodiments of the present application, the third input is used for the user to crop the first highlight segment. The first highlight segment is any highlight segment in the highlight segments of the video to be processed. Exemplarily, the third input includes but is not limited to: the user's touch input to the controls on the screen or the screen area through a touch device such as a finger or a stylus, or a voice command input by the user, or a specific gesture input by the user, or other feasible input, which can be determined according to actual usage requirements and is not limited in the embodiments of the present invention. The specific gesture in the embodiments of the present application can be any one of a single-click gesture, a sliding gesture, a drag gesture, a pressure recognition gesture, a long press gesture, an area change gesture, a double-press gesture, and a double-click gesture; the click input in the embodiments of the present application can be a single-click input, a double-click input, or any number of click inputs, etc., and can also be a long press input or a short press input.
[0122] Step F2: In response to the third input, the first highlight segment is cropped to obtain a second highlight segment.
[0123] Optionally, the third input can be used to trigger a cropping control to capture the first highlight segment through the cropping control. In an optional implementation, after the electronic device performs step 110 to identify the highlight segment in the video to be processed based on the feature information of the video segment in the video to be processed, it can display a list including each video segment in the video to be processed, in which the identified highlight segment is identified. Based on this, the third input can be a third input to the displayed highlight segment. After receiving the third input to the highlight segment, the electronic device can crop the first highlight segment so that the target video segment can be subsequently generated by splicing the cropped highlight segment.
[0124] And optionally, after executing sub-step D1 and marking the video segments in the list whose duration matches the duration threshold according to the duration and duration threshold of the highlight segments of the video to be processed, the electronic device may also receive a third input of the marked first highlight segment to crop the first highlight segment to obtain a second highlight segment, so that in the subsequent execution of step D3, the target video segment can be output according to the second highlight segment.
[0125] For example, after identifying the highlight segment of the video to be processed, the electronic device may display the following Figure 4 The video editing interface shown in FIG. 4 includes a list 402, which displays various video clips of the video to be processed, and arrows are used to indicate the highlight clips of the video to be processed. The third input may be a user's click input on the first highlight clip in the list 402. After the user clicks on the first highlight clip, the electronic device jumps to the Fig.10 The video editing interface is shown. Fig.10In the example, the electronic device displays a thumbnail 1001 of the first highlight segment and a cropping control 1002. The first highlight segment 1001 enters the cropping state, and the user can manually drag two sliders of the cropping control 1002 located on the first highlight segment 1001, the two sliders being slider 10021 and slider 10022, so that the electronic device determines the video segment in the middle area indicated by the sliders 10021 and 10022 as the cropped second highlight segment. Fig.10 In the video editing interface shown, shadow effects are added to the video clips on both sides of sliders 10021 and 10022 on the first highlight clip 1001 to contrast the video clips in the middle area pointed by sliders 10021 and 10022, thereby more effectively prompting the user to obtain the video clips after cropping.
[0126] Among them, the first highlight segment can be a longer highlight segment composed of highlight segments based on multiple unit durations, so as to facilitate cropping. For example, if the unit duration is 2 seconds, the electronic device can combine 10 2-second highlight segments together to obtain a 20-second highlight segment, so that the user can crop the 20-second highlight segment. It should be noted that the technical solution of the present application also supports users to crop non-highlight segments using the above method.
[0127] In some embodiments of the present application, the user can also convert the attributes of the highlight segment and the non-highlight segment of the video segment to be processed, so that the electronic device can perform video synthesis based on the highlight segment that the user is more satisfied with, thereby improving the flexibility of video editing. Optionally, after step 110, the method further includes:
[0128] Step F3: Receive a fourth input for the third highlight segment.
[0129] In the embodiment of the present application, the fourth input is used for the user to modify the third highlight segment to a non-highlight segment, which is defined here as the first non-highlight segment. The third highlight segment is any highlight segment among the highlight segments of the video to be processed. Exemplarily, the fourth input includes but is not limited to: the user's touch input to the controls on the screen or the screen area through a touch device such as a finger or a stylus, or a voice command input by the user, or a specific gesture input by the user, or other feasible input, which can be determined according to actual usage requirements and is not limited in the embodiment of the present invention. The specific gesture in the embodiment of the present application can be any one of a single-click gesture, a sliding gesture, a drag gesture, a pressure recognition gesture, a long press gesture, an area change gesture, a double-press gesture, and a double-click gesture; the click input in the embodiment of the present application can be a single-click input, a double-click input, or any number of click inputs, etc., and can also be a long press input or a short press input.
[0130] Step F4: In response to the fourth input, determine the third highlight fragment as the first non-highlight fragment.
[0131] For example, after executing step 110, the electronic device may display a list including various video segments in the video to be processed, in which the identified highlight segments are identified. Based on this, the fourth input may be a user long pressing any highlight segment in the list (i.e., the third highlight segment). After receiving the fourth input, the electronic device may display a cancel highlight option. After the user clicks the cancel highlight option, the third highlight segment is adjusted to a non-highlight segment. The electronic device may add a gray mask to the non-highlight segment to mark the non-highlight segment.
[0132] Similarly, optionally, after step 110, the method further includes:
[0133] Step F5: Receive a fifth input for the second non-highlight segment.
[0134] In the embodiment of the present application, the fifth input is used for the user to modify the second non-highlight segment into a highlight segment, which is defined as the fourth highlight segment here. The second non-highlight segment is any non-highlight segment among the non-highlight segments of the video to be processed. Exemplarily, the fifth input includes but is not limited to: the user's touch input to the controls on the screen or the screen area through a touch device such as a finger or a stylus, or a voice command input by the user, or a specific gesture input by the user, or other feasible input, which can be determined according to actual usage requirements and is not limited in the embodiment of the present invention. The specific gesture in the embodiment of the present application can be any one of a single-click gesture, a sliding gesture, a drag gesture, a pressure recognition gesture, a long press gesture, an area change gesture, a double-press gesture, and a double-click gesture; the click input in the embodiment of the present application can be a single-click input, a double-click input, or any number of click inputs, etc., and can also be a long press input or a short press input.
[0135] Step F6: In response to the fifth input, determine the second non-highlight fragment as the fourth highlight fragment.
[0136] For example, after executing step 110, the electronic device may display a list including each video segment in the video to be processed. The fifth input may be a user long pressing any highlight segment in the list (i.e., the third highlight segment). After receiving the fourth input, the electronic device may display a cancel highlight option. After the user clicks the cancel highlight option, the third highlight segment is adjusted to a non-highlight segment.
[0137] Based on this, the fifth input can be a user long pressing any non-highlight segment in the list (i.e., the second non-highlight segment). After receiving the fifth input, the electronic device can display a mark highlight option. After the user clicks the mark highlight option, the second non-highlight segment is adjusted to a highlight segment. The electronic device can cancel the gray mask used to mark the non-highlight segment on the second non-highlight segment to indicate that the second non-highlight segment is converted into a highlight segment.
[0138] In some embodiments of the present application, in the above input implementation, the user input can also be performed when the electronic device automatically selects the video segment for synthesizing the target video segment. Accordingly, the electronic device can adjust the video segment to be synthesized into the target video segment at any time based on the user's changes to the highlight segment and the non-highlight segment in combination with the intelligent creation algorithm.
[0139] In an embodiment of the present application, on the basis of automatically identifying highlight clips, the user can also manually fine-tune the video clip properties to achieve the attribute switching of highlight clips and non-highlight clips, so that the adjusted highlight clips are more in line with user requirements, ensuring that the edited target video clips are more in line with user expectations and improving the video editing effect.
[0140] In some embodiments of the present application, after identifying the highlight segments in the video to be processed, the scores of the respective video segments in the video to be processed may also be displayed, so that the user can further perform video editing such as the aforementioned video segment attribute switching and highlight segment editing according to the scores, thereby improving the user editing experience. Optionally, after step 110 and sub-step D1, the method further includes:
[0141] Step C1: Display a list of each video segment in the video to be processed.
[0142] Optionally, the electronic device can be Figure 4 In the video editing interface shown, a prompt is displayed during the process of identifying highlight segments: highlight identification in progress, and after the identification is completed, all segments are displayed in the form of a list 301.
[0143] Step C2: When displaying a list of video segments in the video to be processed, mark scores for highlight segments in the list.
[0144] For example, Figure 4 , Figure 6 , Figure 7 , Figure 8 , Fig. 9 As shown, the electronic device can mark the highlight segment with an arrow and display the score of the highlight segment in the arrow. Figure 6 In the example, highlight clip A has a score of 5, highlight clip B has a score of 3, and highlight clip C has a score of 5.
[0145] In addition, in some embodiments of the present application, the user can also slide left and right on the list of each video editing interface to view the recognition status of each video segment in the entire video to be processed. When the user slides, the picture of the video to be processed played on the screen can change synchronously with the sliding progress. Figure 4 , Figure 6 , Figure 7 , Figure 8 , Fig. 9 As shown, a timeline 403 is displayed corresponding to the list 402 , and each video clip in the list 402 corresponds to a moment on the timeline 403 , which is used to indicate the start moment and the end moment of the video clip.
[0146] Furthermore, in the video to be processed, if the scores of multiple adjacent video clips are the same, the electronic device can also merge multiple video clips with the same scores, and the merged video clips can be displayed in the list as one video clip. For example, the unit length of the identified video clip is 2 seconds, and if the scores of three consecutive video clips are all 5, the three video clips can be merged into a video clip with a length of 6 seconds.
[0147] In an embodiment of the present application, during the video editing process, all video clips in the video to be processed are output and the scores of the highlight clips are marked so that the user can have some understanding of the screened highlight clips, which facilitates the user to proceed to the next step of confirmation and deletion.
[0148] In some embodiments of the present application, it also supports editing metadata information of the target video clip to enrich the user editing function.
[0149] Optionally, after step 120, the method further includes:
[0150] Step G1: Receive a sixth input of metadata information of a target video segment.
[0151] In some embodiments of the present application, the sixth input is used for the user to input metadata information for the target video segment. The metadata information may include but is not limited to the title, video description, and tags. Optionally, the electronic device may also output the metadata information of the recommended target video segment for the user to select based on the content of the target video segment and in combination with the recommendation algorithms of various video playback platforms.
[0152] Exemplarily, the sixth input includes, but is not limited to: the user's touch input to the on-screen controls or screen areas through a touch device such as a finger or a stylus, or a voice command input by the user, or a specific gesture input by the user, or other feasible inputs, which can be determined according to actual usage requirements and are not limited in the embodiments of the present invention. The specific gesture in the embodiments of the present application can be any one of a single-click gesture, a sliding gesture, a dragging gesture, a pressure recognition gesture, a long-press gesture, an area change gesture, a double-press gesture, and a double-click gesture; the click input in the embodiments of the present application can be a single-click input, a double-click input, or any number of click inputs, etc., and can also be a long-press input or a short-press input.
[0153] For example, after outputting the target video segment, the electronic device may prompt the user to input metadata information. The user clicks the prompt to cause the electronic device to display a metadata input box. The user edits metadata content in the metadata input box to serve as metadata information of the target video segment.
[0154] Optionally, the electronic device may also output the metadata information of the recommended target video clip for user selection based on the content of the target video clip and the recommendation algorithms of various video playback platforms. For example, the electronic device may display intelligent suggestions for metadata information, such as recommended tags, descriptions, and title options, based on the content of the target video clip and the recommendation algorithms in the corresponding video playback platforms. The user may perform a sixth input to click on the corresponding option to complete the input of metadata information. For example, after outputting the target video clip, the electronic device may also display multiple sets of metadata recommended for the target video clip. The user clicks on a set of metadata so that the electronic device uses the metadata clicked by the user as the metadata information of the target video clip.
[0155] Step G2: In response to the sixth input, the target video clip carrying metadata information is published to each video playback platform according to user information of each video playback platform.
[0156] Optionally, the user can add different metadata information to the target video clips released by each video playback platform. Alternatively, the user can add the same metadata information to the target video clips released by each video playback platform.
[0157] For example, the user may input metadata information of a target video segment of a video playback platform each time, triggering the release of the target video segment once. Alternatively, after the user inputs metadata information of the target video segment of each video playback platform, triggering the release of the target video segment once.
[0158] Further optionally, the user can also set a timed release for the target video clip. Of course, the user can also choose to release it immediately. For example, a video editing application that supports the video processing method provided in the embodiment of the present application can be connected to the application programming interface (API) of each video playback platform to automatically release the synthesized output target video clip based on the user information provided by the user on each video playback platform. Among them, in the automatic release scheme, the user can also set permissions in advance on the video playback platform to allow the video editing application to automatically release, thereby protecting user privacy.
[0159] In more embodiments, the electronic device may support saving the output target video clip to a folder such as an album, a preset folder, etc., so as to achieve local storage of the target video clip.
[0160] In the embodiment of the present application, on the basis of performing multi-version editing of the video to be processed according to multiple video playback platforms, an automatic publishing function for multiple video playback platforms is also provided to further simplify user operations.
[0161] In another embodiment of the video processing method of the present application, the electronic device may first display the video clip of one video playback platform after obtaining the video clips of each video playback platform. Then, in response to the display switching input, the electronic device may switch to display the video clip of another video playback platform. For example, Fig.11 As shown, when a video editing interface of a video playback platform (APP1) is displayed, the user can slide the screen left and right to switch to display the video editing interface of another video playback platform (APP2). The user can click Fig.11 The play option 1101 in the video editing interface shown on the right is used to preview and play the target video clip that matches the duration threshold of APP2. Of course, the user can also click Fig.11 The play option 1101 in the video editing interface shown on the left is used to preview and play the target video segment that matches the duration threshold of APP1.
[0162] In addition, the user can also fine-tune the video clips of the synthesized target video clips on the video editing interface based on the preview results using the editing method provided by the technical solution of the present application to adjust the output target video clips. Finally, the user can export (and / or publish) the target video clips that match the corresponding video playback platform in each video editing interface. Of course, the user can also export (and / or publish) the target video clips that match all video playback platforms with one click.
[0163] In a video processing method of another embodiment of the present application, the electronic device can also determine the matching result of the duration of the target video segment to be output and the duration threshold based on the fine-tuning of the user and the fine-tuned video segment, and prompt the user whether the video segment needs to be optimized to ensure the output of the target video segment that matches the duration threshold. For example, after the user crops a certain highlight segment, the total duration of all video segments of the synthesizable target video segment may exceed or fall short of the duration threshold. For example, the electronic device can present a green mask on the list of the video editing interface based on the user's fine-tuning if the duration of the target video segment to be output matches the duration threshold, to prompt the user that the target video segment meets the duration requirement; otherwise, a red mask is presented to prompt the user that the duration of the target video segment to be output does not match the duration threshold, which will affect the export of the target video segment, such as export failure.
[0164] Optionally, when the electronic device determines that the duration of the target video segment to be output does not match the duration threshold, it outputs a prompt message and an adjustment plan. The adjustment plan guides the user to adjust the video segment of the video to be processed to output the target video segment that matches the duration threshold. For example, when a red mask appears in the list, the electronic device can output a pop-up reminder above the list to remind the user that a duration adjustment is required. Among them, the pop-up reminder also includes an adjustment plan, such as a video segment can be discarded to shorten the duration; another example is that a video segment can be set as a highlight segment to extend the duration of the target video segment.
[0165] In summary, the purpose of this application is to provide a video editing method, so as to edit the video according to the restrictions on the video length of different video playback platforms, so as to meet the requirements of the video length restrictions of different video playback platforms. Among them, on the one hand, based on the video playback platform selected by the user, combined with the duration threshold of the video playback platform, the duration of the edited video is automatically set. On the other hand, by identifying the highlight clips of the video, high-quality content is automatically edited. Combining the above two points, it can ensure that the edited video has high quality (such as the complete narrative of the edited video) on the basis of meeting the requirements of the video length of each video playback platform. In addition, a path is also provided to facilitate users to preview and fine-tune the results of intelligent editing to ensure that the final published video achieves the user's expected effect. It can be seen that this application simplifies the user's video editing process, improves the production efficiency of video content, and at the same time ensures the integrity and narrative quality of the content in the editing results.
[0166] The video processing method provided in the embodiment of the present application can be executed by a video processing device. In the embodiment of the present application, the video processing device provided in the embodiment of the present application is described by taking the video processing method executed by the video processing device as an example.
[0167] Please refer to Fig.12, which shows a block diagram of a video processing device provided by an embodiment of the present application. Fig.12 As shown, the video processing device 1200 includes: an identification module 1201 and an output module 1202 .
[0168] The identification module 1201 is used to identify the highlight segment in the video to be processed according to the feature information of the video segment in the video to be processed; wherein the score of the feature information of the highlight segment is greater than a preset score threshold;
[0169] The output module 1202 is used to output target video segments that match the duration threshold of each video playback platform according to the duration threshold of each video playback platform and the identified highlight segments.
[0170] Optionally, the output module 1202 is also used to: when the total duration of the highlight segment is greater than the duration threshold, output the target video segment that matches the duration threshold according to the selection priority of the highlight segment from high to low, and the selection priority is positively correlated with the score.
[0171] Optionally, the output module 1202 is further used to: when the total duration of the highlight segments is less than the duration threshold, output a target video segment that matches the duration threshold based on all the highlight segments and at least some of the non-highlight segments.
[0172] Optionally, the video processing device 1200 further includes: a marking module, configured to mark scores of highlight segments in the list when displaying a list of video segments in the video to be processed.
[0173] Optionally, the output module 1202 is further configured to:
[0174] According to the duration of the highlight segment and the duration threshold, the video segments in the list whose duration matches the duration threshold are marked;
[0175] Receiving a first input; wherein the first input is used to confirm the marked video clip;
[0176] In response to the first input, a target video segment is output according to the marked video segment.
[0177] In an embodiment of the present application, by identifying the highlight segments whose feature information scores in the video to be processed are greater than a preset score threshold according to the feature information of each video segment in the video to be processed, the target video segments that match the duration threshold of each video playback platform are outputted respectively according to the duration threshold limited by the video playback platform and the identified highlight frequency band for different video playback platforms. In this technical scheme, video segments with different durations can be outputted at one time for the video to be processed to meet the video release duration requirements of each video playback platform, and since the highlight segments of the video to be processed are obtained by screening based on the feature information of the segment content. Therefore, the highlight segments can more fully display the wonderful content of the video to be processed, and then the target video segments outputted according to the highlight segments can also more richly reflect the wonderful content of the video. In this way, when it is necessary to obtain multiple video segments of different durations based on the same video, there is no need for the user to perform video editing operations such as cropping and splicing multiple times to match different durations, and multiple high-quality video segments of different durations that can fully display the video content can be obtained, which simplifies user operations and effectively improves video editing efficiency.
[0178] The device in the embodiment of the present application can be an electronic device, or a component in the electronic device, such as an integrated circuit or a chip. The electronic device can be a terminal, or it can be other devices other than a terminal. Exemplarily, the electronic device can be a mobile phone, a tablet computer, a laptop computer, a PDA, a vehicle-mounted electronic device, a mobile Internet device (Mobile Internet Device, MID), an augmented reality (augmented reality, AR) / virtual reality (virtual reality, VR) device, a robot, a wearable device, an ultra-mobile personal computer (ultra-mobile personal computer, UMPC), a netbook or a personal digital assistant (personal digital assistant, PDA), etc., and can also be a server, a network attached storage (Network Attached Storage, NAS), a personal computer (personal computer, PC), a television (television, TV), a teller machine or a self-service machine, etc., which is not specifically limited in the embodiment of the present application.
[0179] The device of the embodiment of the present application may be a device having an action system. The action system may be an Android action system, an iOS action system, or other possible action systems, which are not specifically limited in the embodiment of the present application.
[0180] The device provided in the embodiment of the present application can implement each process implemented in the above method embodiment and achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0181] Alternatively, if Fig.13 As shown, an embodiment of the present application also provides an electronic device 1300, including a processor 1301, a memory 1302, and a program or instruction stored in the memory 1302 and executable on the processor 1301. When the program or instruction is executed by the processor 1301, each step of any of the above-mentioned video processing method embodiments is implemented, and the same technical effect can be achieved. To avoid repetition, it will not be described here.
[0182] It should be noted that the electronic devices in the embodiments of the present application include the above-mentioned mobile electronic devices and non-mobile electronic devices.
[0183] Fig.14 The hardware structure diagram of an electronic device for implementing the embodiment of the present application is shown in FIG. The electronic device 1400 includes, but is not limited to, a radio frequency unit 1401, a network module 1402, an audio output unit 1403, an input unit 1404, a sensor 1405, a display unit 1406, a user input unit 1407, an interface unit 1408, a memory 1409, a processor 1410, a camera 1411, and other components.
[0184] Those skilled in the art will appreciate that the electronic device 1400 may also include a power source (such as a battery) for supplying power to each component, and the power source may be logically connected to the processor 1410 through a power management system, thereby implementing functions such as managing charging, discharging, and power consumption management through the power management system. Fig.14 The electronic device structure shown in the figure does not constitute a limitation on the electronic device. The electronic device may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently, which will not be described in detail here.
[0185] The processor 1410 is configured to identify a highlight segment in the video to be processed according to feature information of the video segment in the video to be processed; wherein the score of the feature information of the highlight segment is greater than a preset score threshold;
[0186] The processor 1410 is further configured to output target video segments that match the duration threshold of each video playback platform according to the duration threshold of each video playback platform and the identified highlight segments.
[0187] In an embodiment of the present application, by identifying the highlight segments whose feature information scores in the video to be processed are greater than a preset score threshold according to the feature information of each video segment in the video to be processed, the target video segments that match the duration threshold of each video playback platform are outputted respectively according to the duration threshold limited by the video playback platform and the identified highlight frequency band for different video playback platforms. In this technical scheme, video segments with different durations can be outputted at one time for the video to be processed to meet the video release duration requirements of each video playback platform, and since the highlight segments of the video to be processed are obtained by screening based on the feature information of the segment content. Therefore, the highlight segments can more fully display the wonderful content of the video to be processed, and then the target video segments outputted according to the highlight segments can also more richly reflect the wonderful content of the video. In this way, when it is necessary to obtain multiple video segments of different durations based on the same video, there is no need for the user to perform video editing operations such as cropping and splicing multiple times to match different durations, and multiple high-quality video segments of different durations that can fully display the video content can be obtained, which simplifies user operations and effectively improves video editing efficiency.
[0188] Optionally, processor 1410 is also used to output a target video segment that matches the duration threshold when the total duration of the highlight segment is greater than the duration threshold, according to the order of selection priority of the highlight segment from high to low, and the selection priority is positively correlated with the score.
[0189] Optionally, the processor 1410 is further configured to output a target video segment that matches the duration threshold based on all the highlight segments and at least some of the non-highlight segments when the total duration of the highlight segments is less than the duration threshold.
[0190] Optionally, the processor 1410 is further configured to, when displaying a list of video segments in the video to be processed, mark the score of the highlight segment in the list.
[0191] Optionally, the processor 1410 is further configured to mark, according to the duration of the highlight segment and the duration threshold, the video segment in the list whose duration matches the duration threshold;
[0192] The user input unit 1407 is used to receive a first input; wherein the first input is used to confirm the marked video segment;
[0193] The processor 1410 is further configured to output the target video segment according to the marked video segment in response to the first input.
[0194] In an embodiment of the present application, by identifying the highlight segments whose feature information scores in the video to be processed are greater than a preset score threshold according to the feature information of each video segment in the video to be processed, the target video segments that match the duration threshold of each video playback platform are outputted respectively according to the duration threshold limited by the video playback platform and the identified highlight frequency band for different video playback platforms. In this technical scheme, video segments with different durations can be outputted at one time for the video to be processed to meet the video release duration requirements of each video playback platform, and since the highlight segments of the video to be processed are obtained by screening based on the feature information of the segment content. Therefore, the highlight segments can more fully display the wonderful content of the video to be processed, and then the target video segments outputted according to the highlight segments can also more richly reflect the wonderful content of the video. In this way, when it is necessary to obtain multiple video segments of different durations based on the same video, there is no need for the user to perform video editing operations such as cropping and splicing multiple times to match different durations, and multiple high-quality video segments of different durations that can fully display the video content can be obtained, which simplifies user operations and effectively improves video editing efficiency.
[0195] It should be understood that in the embodiment of the present application, the input unit 1404 may include a graphics processor (Graphics Processing Unit, GPU) 14041 and a microphone 14042, and the graphics processor 14041 processes the image data of the static picture or video image obtained by the image capture device (such as a camera) in the video image capture mode or the image capture mode. The display unit 1406 may include a display panel 14061, and the display panel 14061 may be configured in the form of a liquid crystal display, an organic light emitting diode, etc. The user input unit 1407 includes a touch panel 14071 and at least one of other input devices 14072. The touch panel 14071 is also called a touch screen. The touch panel 14071 may include two parts, a touch detection device and a touch controller. Other input devices 14072 may include, but are not limited to, a physical keyboard, a function key (such as a volume control button, a switch button, etc.), a trackball, a mouse, and an action rod, which will not be repeated here. The memory 1409 can be used to store software programs and various data, including but not limited to applications and action systems. The processor 1410 may integrate an application processor and a modem processor, wherein the application processor mainly processes the action system, user pages and application programs, etc., and the modem processor mainly processes wireless communications. It is understandable that the modem processor may not be integrated into the processor 1410.
[0196] The memory 1409 can be used to store software programs and various data. The memory 1409 may mainly include a first storage area for storing programs or instructions and a second storage area for storing data, wherein the first storage area may store an operating system, an application program or instructions required for at least one function (such as a sound playback function, an image playback function, etc.), etc. In addition, the memory 1409 may include a volatile memory or a non-volatile memory, or the memory 1409 may include both volatile and non-volatile memories. Among them, the non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), a static random access memory (SRAM), a dynamic random access memory (DRAM), a synchronous dynamic random access memory (SDRAM), a double data rate synchronous dynamic random access memory (DDRSDRAM), an enhanced synchronous dynamic random access memory (ESDRAM), a synchronous link dynamic random access memory (SLDRAM) and a direct memory bus random access memory (DRRAM). The memory 1409 in the embodiment of the present application includes but is not limited to these and any other suitable types of memory.
[0197] The processor 1410 may include one or more processing units; optionally, the processor 1410 integrates an application processor and a modem processor, wherein the application processor mainly processes operations related to an operating system, a user interface, and application programs, and the modem processor mainly processes wireless communication signals, such as a baseband processor. It is understandable that the modem processor may not be integrated into the processor 1410.
[0198] An embodiment of the present application also provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, each process of the above-mentioned video processing method embodiment is implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.
[0199] The processor is the processor in the electronic device in the above embodiment. The readable storage medium includes a computer readable storage medium, such as a computer read-only memory ROM, a random access memory RAM, a magnetic disk or an optical disk.
[0200] An embodiment of the present application further provides a chip, which includes a processor and a communication interface, wherein the communication interface and the processor are coupled, and the processor is used to run programs or instructions to implement the various processes of the above-mentioned video processing method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0201] It should be understood that the chip mentioned in the embodiments of the present application can also be called a system-level chip, a system chip, a chip system or a system-on-chip chip, etc.
[0202] An embodiment of the present application provides a computer program product, which is stored in a storage medium. The program product is executed by at least one processor to implement the various processes of the above-mentioned video processing method embodiment and can achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0203] It should be noted that, in this article, the terms "comprise", "include" or any other variant thereof are intended to cover non-exclusive inclusion, so that the process, method, article or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise one..." do not exclude the presence of other identical elements in the process, method, article or device including the element. In addition, it should be pointed out that the scope of the methods and devices in the embodiments of the present application is not limited to performing functions in the order shown or discussed, and may also include performing functions in a substantially simultaneous manner or in reverse order according to the functions involved, for example, the described method may be performed in an order different from that described, and various steps may also be added, omitted, or combined. In addition, the features described with reference to certain examples may be combined in other examples.
[0204] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a computer software product, which is stored in a storage medium (such as ROM / RAM, a disk, or an optical disk), and includes a number of instructions for a terminal (which can be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods of each embodiment of the present application.
[0205] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present application, ordinary technicians in this field can also make many forms without departing from the purpose of the present application and the scope of protection of the claims, all of which are within the protection of the present application.
Claims
1. A video processing method, characterized in that: The method comprises: According to feature information of a video segment in the video to be processed, a highlight segment in the video to be processed is identified; wherein a score of the feature information of the highlight segment is greater than a preset score threshold; According to the duration threshold of each video playback platform and the identified highlight segment, target video segments matching the duration threshold of each video playback platform are output respectively.
2. The method according to claim 1, characterized in that The step of outputting target video segments matching the duration thresholds of the respective video playback platforms according to the duration thresholds of the respective video playback platforms and the identified highlight segments comprises: When the total duration of the highlight segment is greater than the duration threshold, the target video segment matching the duration threshold is output according to the selection priority of the highlight segment from high to low, and the selection priority is positively correlated with the score.
3. The method according to claim 1, characterized in that: The step of outputting target video segments matching the duration thresholds of the respective video playback platforms according to the duration thresholds of the respective video playback platforms and the identified highlight segments comprises: When the total duration of the highlight segments is less than the duration threshold, a target video segment matching the duration threshold is output based on all the highlight segments and at least part of the non-highlight segments.
4. The method according to claim 1, characterized in that After identifying the highlight segment in the video to be processed, the method further includes: When a list including each video segment in the to-be-processed video is displayed, the score is marked on the highlight segment in the list.
5. The method according to claim 4, characterized in that The step of outputting target video segments matching the duration thresholds of the respective video playback platforms according to the duration thresholds of the respective video playback platforms and the identified highlight segments comprises: According to the duration of the highlight segment and the duration threshold, marking the video segment in the list whose duration matches the duration threshold; Receiving a first input; wherein the first input is used to confirm the marked video segment; In response to the first input, the target video segment is output according to the marked video segment.
6. A video processing device, characterized in that: The device comprises: An identification module, configured to identify a highlight segment in the video to be processed according to feature information of the video segment in the video to be processed; wherein the score of the feature information of the highlight segment is greater than a preset score threshold; The output module is used to output target video segments that match the duration threshold of each video playback platform according to the duration threshold of each video playback platform and the identified highlight segments.
7. The device according to claim 6, characterized in that The output module is further used for: When the total duration of the highlight segment is greater than the duration threshold, the target video segment matching the duration threshold is output according to the selection priority of the highlight segment from high to low, and the selection priority is positively correlated with the score.
8. The device according to claim 6, characterized in that The output module is further used for: When the total duration of the highlight segments is less than the duration threshold, a target video segment matching the duration threshold is output based on all the highlight segments and at least part of the non-highlight segments.
9. The device according to claim 6, characterized in that The device also includes: The marking module is used to mark the score of the highlight segment in the list when displaying a list of each video segment in the video to be processed.
10. The device according to claim 9, characterized in that The output module is further used for: According to the duration of the highlight segment and the duration threshold, marking the video segment in the list whose duration matches the duration threshold; Receiving a first input; wherein the first input is used to confirm the marked video segment; In response to the first input, the target video segment is output according to the marked video segment.
