Video processing method and apparatus, electronic device, and storage medium

By supporting the addition of transitions in the secondary track in the video editing interface, the problem of restricted video editing scenes in the prior art is solved, and the diversity and experience of video editing is improved.

WO2025067367A1PCT designated stage expired Publication Date: 2025-04-03BEIJING ZITIAO NETWORK TECH CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2024/121562
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2023-09-28
Filing Date
2024-09-26
Publication Date
2025-04-03

AI Technical Summary

Technical Problem

Existing video editing tools only support adding transitions between adjacent clips in the main track, resulting in limited video editing scenes and seriously affecting the video editing experience.

Method used

By displaying the video editing interface, including the material area and the timeline area, multiple transition signs are displayed in the material area, and in response to the triggering operation of the target transition sign, it is determined that the video clips in the target video track are the same level, and the transitions are added between adjacent video clips, supporting the addition of transitions in the secondary track.

Benefits of technology

Increases the diversity of video editing scenes, allowing the main video and background video to be set in different tracks, improving the video editing experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2024121562_03042025_PF_FP_ABST
    Figure CN2024121562_03042025_PF_FP_ABST
Patent Text Reader

Abstract

The present disclosure relates to a video processing method and apparatus, an electronic device, and a storage medium. The method comprises: displaying a video clipping interface, wherein the video clipping interface comprises a material region and a timeline region, multiple transition identifiers are displayed in the material region, each transition identifier is used for indicating a transition effect scheme, and the timeline region comprises at least one video track; in response to a target trigger operation for a target transition identifier among the multiple transition identifiers, determining that target video clips in a target video track corresponding to the target trigger operation are at the same level, wherein the target video track is a sub-track among the at least one video track; and on the basis of the transition effect scheme indicated by the target transition identifier, adding a transition between adjacent target video clips.
Need to check novelty before this filing date? Find Prior Art

Description

Video processing method, device, electronic device and storage medium

[0001] CROSS-REFERENCE TO RELATED APPLICATIONS

[0002] This application claims priority to the Chinese invention patent application with application number 202311278214.0, entitled “Video processing method, device, electronic device and storage medium” and filing date September 28, 2023, and incorporates the entirety of that application into this document by reference. Technical Field

[0003] The present disclosure relates to the field of video processing technology, and in particular to a video processing method, device, electronic device, and storage medium. Background Art

[0004] With the increasing abundance of information on the Internet, watching videos has become an entertainment activity in people's daily lives. In order to improve users' viewing experience, video editing is an important step before publishing various videos.

[0005] When editing videos, creators can add special effects, filters, text, stickers, transitions, etc. to the videos based on the functions provided by the video editing tools to package the videos, making the edited videos to be published more effective.

[0006] Transitions can make the transitions between video clips more natural. Currently, the video editing tool only supports adding transitions between adjacent clips in the main track. Therefore, the main video can only be set in the main track, which limits the video editing scenes and seriously affects the video editing experience.

[0007] Summary of the Invention

[0008] In order to solve the above technical problems or at least partially solve the above technical problems, the present disclosure provides a video processing method, device, electronic device and storage medium.

[0009] A first aspect of an embodiment of the present disclosure provides a video processing method, the method comprising: displaying a video editing interface, the video editing interface comprising a material area and a timeline area, a plurality of transition identifiers being displayed in the material area, each transition identifier being used to indicate a transition effect scheme, and the timeline area comprising at least one video track; in response to a target trigger operation of a target transition identifier among the plurality of transition identifiers, determining that a target video segment in a target video track corresponding to the target trigger operation is at the same level, the target video track being a sub-track in the at least one video track; and adding a transition between adjacent target video segments based on the transition effect scheme indicated by the target transition identifier.

[0010] According to a second aspect of an embodiment of the present disclosure, a video processing device is provided, which includes: a display module for displaying a video editing interface, the video editing interface including a material area and a timeline area, a plurality of transition identifiers are displayed in the material area, each transition identifier is used to indicate a transition effect scheme, and the timeline area includes at least one video track; a processing module for responding to a target trigger operation of a target transition identifier among the plurality of transition identifiers, determining that the target video clips in the target video track corresponding to the target trigger operation are at the same level, and the target video track is a sub-track in the at least one video track; and adding a transition between adjacent target video clips based on the transition effect scheme indicated by the target transition identifier.

[0011] According to a third aspect of an embodiment of the present disclosure, an electronic device is provided, comprising a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the computer program, when executed by the processor, implements the video processing method as described in the first aspect.

[0012] According to a fourth aspect of the embodiments of the present disclosure, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the video processing method as described in the first aspect is implemented.

[0013] According to a fifth aspect of the embodiments of the present disclosure, a computer program product is provided, wherein the computer program product includes a computer program. When the computer program product runs on a processor, the processor executes the computer program to implement the video processing method as described in the first aspect.

[0014] According to a sixth aspect of the embodiments of the present disclosure, a chip is provided, which includes a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run program instructions to implement the video processing method as described in the first aspect.

[0015] The technical solution provided by the embodiment of the present disclosure includes: by displaying a video editing interface, the video editing interface includes a material area and a timeline area, multiple transition identifiers are displayed in the material area, each transition identifier is used to indicate a transition effect scheme, and the timeline area includes at least one video track; in response to a target trigger operation of a target transition identifier among the multiple transition identifiers, it is determined that the target video clips in the target video track corresponding to the target trigger operation are at the same level, and the target video track is a sub-track in the at least one video track; based on the transition effect scheme indicated by the target transition identifier, a transition is added between adjacent target video clips. BRIEF DESCRIPTION OF THE DRAWINGS

[0016] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the present disclosure.

[0017] In order to more clearly illustrate the embodiments of the present disclosure or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.

[0018] FIG1 is a flow chart of a video processing method provided by an embodiment of the present disclosure;

[0019] FIG2 is a schematic diagram of an interface of a video processing method provided by an embodiment of the present disclosure;

[0020] FIG3 is a track diagram of a video processing method provided by an embodiment of the present disclosure;

[0021] FIG4 is a schematic diagram of a hierarchy of a video processing method according to an embodiment of the present disclosure;

[0022] FIG5 is a second hierarchical diagram of the video processing method provided by an embodiment of the present disclosure;

[0023] FIG6 is a third hierarchical diagram of a video processing method provided by an embodiment of the present disclosure;

[0024] FIG7 is a fourth hierarchical diagram of a video processing method provided by an embodiment of the present disclosure;

[0025] FIG8 is a fifth hierarchical diagram of a video processing method provided by an embodiment of the present disclosure;

[0026] FIG9 is a sixth hierarchical diagram of a video processing method provided by an embodiment of the present disclosure;

[0027] FIG10 is a seventh hierarchical diagram of a video processing method provided by an embodiment of the present disclosure;

[0028] FIG11 is an eighth hierarchical diagram of a video processing method provided by an embodiment of the present disclosure;

[0029] FIG12 is a ninth hierarchical diagram of a video processing method provided by an embodiment of the present disclosure;

[0030] FIG13 is a structural block diagram of a video processing device provided by an embodiment of the present disclosure;

[0031] FIG14 is a structural block diagram of an electronic device provided by an embodiment of the present disclosure. DETAILED DESCRIPTION

[0032] In order to more clearly understand the above-mentioned objectives, features and advantages of the present disclosure, the scheme of the present disclosure will be further described below. It should be noted that the embodiments of the present disclosure and the features therein can be combined with each other in the absence of conflict.

[0033] In the following description, many specific details are set forth to facilitate a full understanding of the present disclosure, but the present disclosure may also be implemented in other ways different from those described herein; it is obvious that the embodiments in the specification are only part of the embodiments of the present disclosure, rather than all of the embodiments.

[0034] The terms "first", "second", etc. in the specification and claims of the present disclosure are used to distinguish similar objects, and are not used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable under appropriate circumstances, so that the embodiments of the present disclosure can be implemented in an order other than those illustrated or described herein, and the objects distinguished by "first", "second", etc. are generally of the same type, and the number of objects is not limited. For example, the first 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 related to each other are in an "or" relationship.

[0035] The transition function currently provided by video editing tools only supports adding transitions between adjacent clips in the main track. However, most videos are edited on multiple tracks. If transitions are limited to adding to the main track, many effects cannot be achieved. For example, if the background video is on the main track and the main video is on the sub-track, the video cannot add transitions. To add a transition, the main video must be set on the main track and the background video on the sub-track. This limits the video editing scenarios and seriously affects the video editing effects.

[0036] In order to solve the above technical problems, in an embodiment of the present application, a video editing interface is displayed, which includes a material area and a timeline area, wherein a plurality of transition identifiers are displayed in the material area, each transition identifier is used to indicate a transition effect scheme, and the timeline area includes at least one video track; in response to a target trigger operation on a target transition identifier among the plurality of transition identifiers, it is determined that the target video clip in the target video track corresponding to the target trigger operation is at the same level, and the target video track is a sub-track in the at least one video track; based on the transition effect scheme indicated by the target transition identifier, a transition is added between adjacent video clips of the target. This solution supports adding transitions to sub-tracks, so that the main video can be set in the sub-track, and background and other videos can be set in the main track or other sub-tracks, which increases the diversity of video editing scenes and improves the video editing experience.

[0037] The electronic devices in the embodiments of the present disclosure may be mobile electronic devices or non-mobile electronic devices. Mobile electronic devices may include mobile phones, tablet computers, laptop computers, PDAs, in-vehicle electronic devices, wearable devices, ultra-mobile personal computers (UMPCs), netbooks, or personal digital assistants (PDAs); non-mobile electronic devices may include personal computers (PCs), televisions (TVs), ATMs, or self-service kiosks; and the embodiments of the present disclosure do not specifically limit these.

[0038] The execution subject of the video processing method provided in the embodiments of the present disclosure may be the above-mentioned electronic device (including mobile electronic devices and non-mobile electronic devices), or may be a functional module and / or functional entity in the electronic device that can implement the video processing method. The specific execution subject may be determined based on actual usage requirements and is not limited by the embodiments of the present disclosure.

[0039] The video processing method provided by the embodiment of the present disclosure is described in detail below through specific embodiments and application scenarios in conjunction with the accompanying drawings.

[0040] As shown in FIG1 , an embodiment of the present disclosure provides a video processing method, which may include the following steps 100 to 102 .

[0041] 100. Display a video editing interface, which includes a material area and a timeline area.

[0042] Among them, a plurality of transition identifiers are displayed in the material area, each transition identifier is used to indicate a transition effect scheme, and the timeline area includes at least one video track.

[0043] Among them, the material area displays multiple material type options, including transition options, special effects options, filter options, text options, sticker options, material library options, etc. The specific options can be determined according to actual conditions and are not limited here.

[0044] When different material options are selected, the material area displays multiple material identifiers corresponding to the selected material options. When a transition option is selected, the material area displays multiple transition identifiers.

[0045] 101. In response to a target triggering operation on a target transition identifier among the multiple transition identifiers, determine that target video segments in target video tracks corresponding to the target triggering operation are at the same level.

[0046] The target video track is a sub-track in the at least one video track.

[0047] 102. Add a transition between the target adjacent video segments based on the transition effect solution indicated by the target transition identifier.

[0048] The target video track is a sub-track in the at least one video track.

[0049] Among them, the target trigger operation can be a click operation on the target transition logo, a drag operation on the target transition logo, or other feasible operations on the target transition logo. The specific operation can be determined according to actual conditions and is not limited here.

[0050] Among them, the transition effect schemes indicated by multiple transition identifiers may include but are not limited to: spatial rotation transition, page turning transition, front and back comparison transition, shaking and amplifying transition, vibration transition, heart-shaped overlay transition, stretching transition, inhalation transition, atomization transition, water drop transition, etc.

[0051] In the embodiment of the present application, at least one video track may include at least one sub-track, and at least one video track may further include a main track. The specific details may be determined based on actual conditions and are not limited here.

[0052] Adding a transition between target adjacent video segments specifically refers to adding a transition at a location where two adjacent video segments are connected.

[0053] In the embodiment of the present application, it supports adding transitions to the main track and also supports adding transitions to the sub-track. In specific usage scenarios, transitions can be added to the main track or the sub-track according to actual needs.

[0054] In an embodiment of the present application, by setting support for adding transitions to the sub-track, the main video can be set on the sub-track, and background and other videos can be set on the main track or other sub-tracks, which increases the diversity of video editing scenes and improves the video editing experience.

[0055] In some embodiments of the present application, the above step 101 can be specifically implemented through the following steps 201 and 202.

[0056] 201. In response to a target trigger operation on a target transition identifier among the multiple transition identifiers, when the target trigger operation is a click operation, traverse the at least one video track, and in the process of traversing the at least one video track, determine the first adjacent video segment to which a transition can be added as the target adjacent video segment.

[0057] 202. Determine that target video clips in target video tracks corresponding to the target trigger operation are at the same level.

[0058] Above-mentioned steps 201, step 202 and step 102 specifically can be in response to the click operation to target transition mark, obtain all video tracks of video fragment in timeline area, obtain at least one video track, according to certain rule (as sequentially video track is sorted from top to bottom according to timeline area, or according to sequentially video track is sorted from bottom to top), at least one video track is sorted, obtain the numbering of at least one video track, then according to numbering traversal at least one video track, when traversing to a video track, determine whether this video track exists the video fragment that can add transition, if this video track exists the target adjacent video fragment that can add transition, then add transition for target adjacent video fragment, flow process ends, no longer traverse other video tracks, if this video fragment does not exist the video fragment that can add transition, then traverse next video track.In at least one video track traversal process, first target adjacent video fragment that can add transition is added to determine, stop traversal then, or after traversing each video fragment, under the situation of the adjacent video fragment that all does not exist can add transition, add transition failure, flow process ends.

[0059] In an embodiment of the present application, the above-mentioned steps 201, 202 and 102 are used to support intelligent addition of transitions. Adjacent video clips to which transitions can be added can be automatically identified in the video track in the timeline area, and then transitions can be added, thereby improving operational efficiency.

[0060] In some embodiments of the present application, the above step 101 can be specifically implemented through the following steps 203 and 204.

[0061] 203. In response to a target triggering operation on a target transition identifier among the multiple transition identifiers, when the target triggering operation is a dragging operation, determine an adjacent video segment corresponding to an end position of a trajectory of the dragging operation as the target adjacent video segment.

[0062] In some embodiments of the present application, when the dragging operation track passes through any adjacent video segments, the connecting area of ​​the adjacent video segments is displayed in a first display mode. The first display mode may be a highlighted display, so as to prompt the user that there is an adjacent video segment at that location.

[0063] 204. Determine that the target video clips in the target video track corresponding to the target trigger operation are at the same level.

[0064] In an embodiment of the present application, the user can drag the transition identifier to the position where the target adjacent video clips where the transition needs to be added are connected, and then add the transition to the target adjacent video clips, which can improve the user experience.

[0065] In some embodiments of the present application, if there is no adjacent video clip at the end position of the drag operation trajectory, adding the transition fails.

[0066] In some embodiments of the present application, in response to a target trigger operation on a target transition identifier among the multiple transition identifiers, when adding a transition fails, the reason for the failure to add a transition is displayed; wherein, the reason for the failure to add a transition includes any one of the following: there is no adjacent video clip at the current adding position; the length of the video clip at the current adding position is less than or equal to the length threshold; the video track where the current adding position is located is locked; the adjacent video clips where the current adding position is located are not at the same level.

[0067] For example, as shown in Figure 2, a schematic diagram of a video editing interface is shown. The area marked "21" is the material area, the area marked "22" is the timeline area, the area marked "23" is the player area, and the area marked "24" is the function panel. The transition package option in the material area is selected. The timeline area includes four video tracks, all of which are sub-tracks. The selected materials 1, 2, and 3 are the three materials in the material package combination. Click the transition icon to add a transition between video clip 1 and compound clip 1.

[0068] Currently, the video editing tool only supports adding transitions on the main track because: transitions can only be added between adjacent video clips with the same rendering level (hereinafter referred to as level), and cannot be added between adjacent video clips with different rendering levels. The rendering levels of the video clips in the main track must be the same, so the main track supports adding transitions between adjacent video clips. If the free level function is not enabled, the rendering levels of the video clips in the sub-track must be different, so the sub-track does not support adding transitions between adjacent video clips.

[0069] In the related art, in a non-free level draft (a draft without the free level function enabled), all sub-track video clips are at different rendering levels. In this case, each clip is at a different level and it is impossible to add transitions to the sub-track. Therefore, it is necessary to use a new level setting rule to allow different clips to be at the same level while satisfying the current level relationship. The level setting rule in the related art is to directly set the level of the newly added video clip to the current maximum level plus 1. Taking the addition of the video clip shown in Figure 3 in the sub-track in the timeline area as an example, add clips 1 to 4 in sequence, and the corresponding level relationship is shown in (a) in Figure 4.

[0070] In some embodiments of the present application, the video processing method provided in the embodiments of the present application may further include the following steps 103 to 105.

[0071] 103. In response to a triggering operation of adding a new video clip in the timeline region, determine an initial level of the new video clip as the sum of a current maximum level in the timeline region and 1.

[0072] 104. If, in at least one continuous level below the initial level, all areas corresponding to the newly added video clip can accommodate the newly added video clip, determine the final level of the newly added video clip to be the minimum level in the at least one continuous level.

[0073] 105. When the area corresponding to the newly added video clip in the current maximum level cannot accommodate the newly added video clip, determine the final level of the newly added video clip as the initial level.

[0074] In the embodiment of the present application, a "sinking method" is used to determine the level of the newly added video clip. Specifically, the level of the newly added video clip is first set to the current maximum level plus 1, and then it is determined whether the next level can accommodate the newly added video clip. If it can, the level is "sunk" until it cannot "sink" (that is, the level below the current level cannot accommodate the newly added video clip). Based on Figure 4 (a), as shown in Figure 4 (b), when adding segment 2, it can sink to level 1, and when adding segments 3 and 4, it can sink to level 2. Therefore, in the embodiment of the present application, the rendering levels of the video clips in the secondary track may be the same or different.

[0075] In the embodiment of the present application, by adopting the "sinking method" to determine the level of the newly added video clip, the addition of transitions to the sub-track can be well achieved.

[0076] In some embodiments of the present application, the above step 101 can be specifically implemented through the following step 301, or can be implemented through the following step 302, or can be implemented through the following step 303.

[0077] 301. When the free level function is enabled on the target video track, determine that the target video clips are at the same level.

[0078] The free level function is used to indicate that the level of the video clips in each sub-track is the track number of the corresponding sub-track. This means that when the free level function is enabled, the level of the video clips in each sub-track is the same, and the level of the video clips in a sub-track is the track number of the video clip.

[0079] Among them, when the free level function is enabled on a sub-track, the levels of the video clips in the sub-track are the same. When the free level function is not enabled on a sub-track, the levels of the video clips in the sub-track may be the same or different, but generally they are not the same. Therefore, if the free level function is enabled, it is determined that the target adjacent video clips are at the same level.

[0080] 302. When the free layer function is not enabled on the target video track and the layer identifiers of the layers of the adjacent video clips are the same, determine that the layers of the target video clips are the same.

[0081] The level identifier may be a level index. If the level indexes of the levels at which the target adjacent video segments are located are the same, it is determined that the target adjacent video segments are located at the same level.

[0082] In some embodiments of the present application, the level size can be determined according to the level indexes of different levels.

[0083] 303. If the target video track does not have a free layer function enabled and the target adjacent video segments are located at layers with different layer identifiers, adjust the target adjacent video segments to the same layer so that the target adjacent video segments are located at the same layer.

[0084] In the embodiment of the present application, the levels of one or two target adjacent video segments are adjusted so that the adjusted target adjacent video segments are at the same level.

[0085] The above steps 301 to 303 can specifically be used to determine whether the target video track has the free level function turned on; when it is determined that the target video track has the free level function turned on, it can be determined that the target adjacent video clips are at the same level; when it is determined that the target video track does not have the free level function turned on, it is determined whether the level identifiers of the levels where the target adjacent video clips are located are the same; when the level identifiers of the levels where the target adjacent video clips are located are the same, it can be determined that the target adjacent video clips are at the same level; when the level identifiers of the levels where the target adjacent video clips are located are different, the target adjacent video clips are adjusted to the same level, thereby determining that the target adjacent video clips are at the same level. In summary, after determining that the target adjacent video clips are at the same level through any one of steps 301 to 303, transitions can be added between the target adjacent video clips based on the transition effect scheme indicated by the target transition identifier.

[0086] In the embodiment of the present application, by adding whether the free level function is turned on and whether the level identifiers of the levels where the target adjacent video clips are located are the same, transitions can be added to the sub-track.

[0087] In some embodiments of the present application, the above step 303 can be specifically implemented through the following steps 303a to 303d.

[0088] 303a. When it is determined that the target video track does not have the free level function enabled and the level identifiers of the levels of the target adjacent video segments are different, determine whether the video images within the target duration range are the same before and after adjusting the target adjacent video segments to the same level.

[0089] The target duration range is a time range corresponding to the video segment of the adjusted level in the target adjacent video segment in the timeline area.

[0090] It is understood that, when one of the target adjacent video segments is adjusted in level, the target duration range is the duration interval corresponding to the one video segment. When both of the target adjacent video segments are adjusted in level, the target duration range is the duration interval corresponding to the two video segments.

[0091] Because two temporally overlapping video clips are located at different levels, the upper-level clip obscures the lower-level clip during display. Therefore, swapping the levels of the two clips changes the occlusion between the clips, resulting in a change in the displayed video image. As shown in Figure 5, Clip 1 is located at Level 1 and Clip 2 is located at Level 2. Currently, Clip 2 obscures Clip 1. However, swapping the levels of Clips 1 and 2 causes Clip 1 to obscure Clip 2, resulting in a change in the displayed video image.

[0092] When it is determined that the video images within the target duration are the same before and after the target adjacent video segments are adjusted to the same level, execute the following step 303b; when it is determined that the video images within the target duration are different before and after the target adjacent video segments are adjusted to the same level, execute the following steps 303c and 303d.

[0093] 303b: Adjust the target adjacent video segments to the same level.

[0094] 303c. Display prompt information, which includes a first option and a second option. The first option is used to instruct to adjust the target adjacent video segments to the same level, and the second option is used to instruct not to adjust the target adjacent video segments to the same level.

[0095] 303d: In response to the triggering operation on the first option, adjust the target adjacent video segments to the same level.

[0096] In an embodiment of the present application, when it is determined that the target adjacent video clips are adjusted to the same level and the video images within the target duration are the same before and after, the target adjacent video clips are directly adjusted to the same level, which can improve operational efficiency because it does not affect the displayed video images; when it is determined that the target adjacent video clips are adjusted to the same level and the video images within the target duration are different before and after, a prompt message is used to indicate that the level switching will affect the video images. Therefore, based on the user's selection of the prompt information, it is determined whether to perform the level adjustment and whether to add the transition, so that the user understands that the level adjustment will affect the video images. Compared with directly adjusting the target adjacent video clips to the same level, the user experience can be improved.

[0097] In some embodiments of the present application, when it is determined that the target adjacent video clips are at different levels, a prompt message indicating whether to perform level adjustment can be displayed, and then whether to perform level adjustment can be determined based on the user's selection, and then a transition can be added.

[0098] In some embodiments of the present application, the target adjacent video segments include a first video segment and a second video segment, the level of the first video segment is lower than the level of the second video segment, and the level of the second video segment is the first level; the above step 303 can be specifically implemented by any step from the following steps 303e to 303g.

[0099] 303e: If the area corresponding to the first video clip at the first level can accommodate the first video clip, adjust the level of the first video clip to the first level.

[0100] The area corresponding to the first video clip may be an area corresponding to the position of the first video clip in the timeline.

[0101] 303f. If the area corresponding to the first video segment at the first level cannot accommodate the first video segment, and the area corresponding to the target adjacent video segment at the second level can accommodate the target adjacent video segment, adjust the level of the target adjacent video segment to the second level.

[0102] Among them, the second level is the upper level of the first level.

[0103] 303g. When the area corresponding to the first video clip at the first level cannot accommodate the first video clip, and the area corresponding to the target adjacent video clip at the second level cannot accommodate the target adjacent video clip, a third level is created above the first level, and the level of the target adjacent video clip is adjusted to the third level.

[0104] In some embodiments of the present application, a third level may be newly created between the first level and the second level, and the level index of the third level is then the level index of the second level, and the level indexes of the second level and other levels higher than the second level are increased by 1 respectively.

[0105] For example, as shown in Figure 5, fragment 1 and fragment 3 are adjacent video fragments in the same video track, where fragment 1 is located at level 1 and fragment 3 is located at level 3. If a transition is added between fragment 1 and fragment 3, since level 3 can accommodate fragment 1, as shown in (a) in Figure 6, fragment 1 can be adjusted to level 3 and then the transition can be added.

[0106] For example, as shown in Figure 5, fragment 1 and fragment 4 are adjacent video fragments in the same video track, where fragment 1 is located at level 1 and fragment 4 is located at level 2. If a transition is added between fragment 1 and fragment 4, since level 2 cannot accommodate fragment 1 and level 3 cannot accommodate fragment 1 and fragment 4, as shown in (b) in Figure 6, a new level 3 can be created above level 2, and then the level index of the previous level 3 is increased by 1, and then fragment 1 and fragment 4 are adjusted to the newly created level 3, and then the transition is added.

[0107] In the embodiment of the present application, the hierarchical adjustment is performed according to the above steps 303e to 303g. The logic is simple, and the relative hierarchical relationship between the segments is changed minimally, which has the least impact on the video image.

[0108] In some embodiments of the present application, a third level may be newly created above the second level or the highest level, and the third level is then the highest level.

[0109] In some embodiments of the present application, when the level of the first video clip can accommodate the second video clip, the level of the second video clip can also be adjusted to the level of the first video clip. The specific level can be determined based on actual conditions and is not limited here.

[0110] In some embodiments of the present application, the above step 303 can be specifically implemented through the following step 303h and / or step 303i.

[0111] 303h. When the first video segment is connected to other video segments through transition, the target adjacent video segment and the other video segments connected to the first video segment through transition are adjusted to the same level.

[0112] 303i. When the second video segment is connected to other video segments through transition, adjust the target adjacent video segment and the other video segments connected to the second video segment through transition to the same level.

[0113] Executing the above steps 303h and / or 303i simultaneously is to adjust the target adjacent video segment, other video segments connected to the first video segment through transition, and other video segments connected to the second video segment through transition to the same level.

[0114] In an embodiment of the present application, in the process of adjusting the target adjacent video clips to the same level, it is not possible to only consider adjusting the target adjacent video clips to the same level, because one video clip (or two video clips) in the target adjacent clips may also be "connected" with other video clips through transitions (hereinafter, two video clips "connected" together through transitions are referred to as fragment chains). If only the target adjacent video clips are adjusted to the same level, the transitions that have been added to the one video clip (or two video clips) may be invalid. Therefore, it is necessary to adjust the levels of the entire fragment chain corresponding to the one video clip (or two video clips) together. Specifically, if the level of the fragment chain at the high level can accommodate the fragment chain at the low level, the fragment chain at the low level is promoted to the high level. Otherwise, a new layer is created on the upper level fragment chain to place the two fragment chains.

[0115] For example, as shown in (a) in Figure 7, fragment 1 and fragment 2 constitute a fragment chain, which is located at level 1, fragment 3 and fragment 4 constitute a fragment chain, which is located at level 2, and level 1 also includes fragment 5. When it is necessary to add a transition between adjacent fragments 2 and 3, since level 2 can accommodate fragment 1 and fragment 2 to constitute a fragment chain, as shown in (b) in Figure 7, the level of the fragment chain consisting of fragment 1 and fragment 2 can be upgraded to level 2, and then a transition can be added between fragment 2 and fragment 3.

[0116] For example, as shown in (a) in Figure 8, fragment 1 and fragment 2 constitute a fragment chain, which is located at level 1, and fragment 3 and fragment 4 constitute a fragment chain, which is located at level 2. At the same time, level 1 also includes fragment 5, and level 2 also includes fragment 6. When it is necessary to add a transition between adjacent fragments 2 and 3, since level 2 cannot accommodate fragment 1 and fragment 2 to constitute a fragment chain, as shown in (b) in Figure 8, a new level 3 can be created on level 2, and the levels of the fragment chain consisting of fragment 1 and fragment 2, and the fragment chain consisting of fragment 3 and fragment 4 can be simultaneously upgraded to level 3, and then a transition can be added between fragment 2 and fragment 3.

[0117] In some embodiments of the present application, after the above step 102, the video processing method provided by the embodiment of the present application may further include the following step 106.

[0118] 106. In response to an editing operation on a target video segment in the target adjacent video segments, perform corresponding processing on the target video segment, and delete transitions that are invalidated in response to the editing operation.

[0119] The editing operation includes any of the following: a deletion operation, a paste operation, a move operation, a level adjustment operation, and a duration reduction operation.

[0120] Among them, the delete operation is the operation of deleting the target video clip, the paste operation is the operation of pasting the target video clip to the target position (the paste operation includes the copy operation or cut operation of the target video clip before), the move operation is the operation of moving the target video clip to the target position, the level adjustment operation is the operation of manually adjusting the level of the target video clip in the function panel area, and the duration shortening operation is the operation of shortening the duration of the target video clip at one end of the added transition.

[0121] In an embodiment of the present application, since transitions are added between target adjacent video clips to form a clip chain, when the target video clip in the target adjacent video clip is edited, the transitions between the target adjacent video clips may become invalid. After the transition becomes invalid, the invalid transition can be automatically deleted to improve the video editing efficiency.

[0122] In the embodiment of the present application, the above-mentioned deletion of the transition that is invalidated in response to the editing operation can be directly deleted or deleted by calling a deletion function. In the embodiment of the present application, invalid transitions caused by editing operations such as deletion, pasting, moving, level adjustment, and duration reduction can all be deleted by calling a deletion function, which can simplify the deletion logic of the code and improve operational efficiency.

[0123] In some embodiments of the present application, when the editing operation includes a paste operation, a move operation, or a level adjustment operation, the corresponding processing includes: when the area corresponding to the first to-be-determined level and the target video clip can accommodate the target video clip, determining the level of the target video clip to be the first to-be-determined level; when the editing operation includes a paste operation or a move operation, the first to-be-determined level is the level at which the target video clip was located before the editing operation; when the editing operation includes a level adjustment operation, the first to-be-determined level is the level corresponding to the level adjustment operation; when the first to-be-determined level corresponds to the target video clip, If the area corresponding to the video clip cannot accommodate the target video clip, and the area corresponding to the target video clip at the second to-be-determined level can accommodate the target video clip, the level of the target video clip is determined to be the second to-be-determined level, and the second to-be-determined level is the upper level of the first to-be-determined level; if the area corresponding to the target video clip at the first to-be-determined level cannot accommodate the target video clip, and the area corresponding to the target video clip at the second to-be-determined level cannot accommodate the target video clip, a third to-be-determined level is created above the first to-be-determined level, and the level of the target video clip is determined to be the third to-be-determined level.

[0124] It can be understood that for move and paste operations, the moved or pasted video clips will be adjusted one by one from bottom to top according to the original level. Specifically, if the original level can accommodate the moved or pasted video clip, the level of the moved or pasted video clip will remain unchanged; if the original level cannot accommodate the moved or pasted video clip, an attempt will be made to adjust it to the previous level. If the previous level can accommodate the moved or pasted video clip, the moved or pasted video clip will be directly promoted to the previous level. Otherwise, a new level will be created above the original level to place the moved or pasted video clip.

[0125] For example, fragments 1 and 2 are located at level 1, fragments 3 and 4 are located at level 2, and fragments 5 and 6 are located at level 3. As shown in (a) in Figure 9 , fragment 3 is moved, level 2 cannot accommodate fragment 3, but level 3 can accommodate fragment 3. As shown in (b) in Figure 9 , fragment 3 is adjusted to level 3.

[0126] For example, fragments 1 and 2 are located at level 1, fragments 3 and 4 are located at level 2, and fragments 5 and 6 are located at level 3. As shown in (a) in Figure 10, fragment 3 is moved, level 2 cannot accommodate fragment 3, and level 3 cannot accommodate fragment 3 either. As shown in (b) in Figure 10, the original level 3 is adjusted to level 4, a new level 3 is created between levels 2 and 4, and fragment 3 is adjusted to level 3.

[0127] In the embodiment of the present application, the hierarchical adjustment is performed according to the above corresponding processing, the logic is simple, and the relative hierarchical relationship between the segments changes minimally, which has the least impact on the video picture.

[0128] In some embodiments of the present application, the level adjustment operation involves rotating the levels of multiple video segments selected by the playback progress line. As shown in Figure 11 (a), segments 1 and 6 are located at level 1, segment 2 is located at level 2, and segments 3, 4, and 5 are located at level 3. The playback progress line currently selects segments 1, 2, and 3. When the relative level of segment 3 is set to 1 and the levels of the three segments are rotated, segment 2 overlaps with other segments after being moved to level 3, as shown in Figure 11 (b). Therefore, segment 2 needs to be moved up one level, as shown in Figure 12 (a).

[0129] In this embodiment of the application, the hierarchy displayed on the functional interface is the relative hierarchy between the clips at the current moment. Changing the hierarchy calculation method does not affect this relative hierarchy calculation. Based on the relative hierarchy changes, the hierarchy of the related clips is rotated, and then internal hierarchy conflicts are handled according to the logic of the paste operation (or move operation). This simple logic minimizes the change in the relative hierarchy between the clips and minimizes the impact on the video image.

[0130] In some embodiments of the present application, when the editing operation includes a deletion operation, the corresponding processing includes: deleting the target video clip; when there is no video clip at the target level, lowering the video clips at a level greater than the target level by one level, and the target level is the level at which the target video clip was located before the editing operation.

[0131] Understandably, considering that transitions may be added between clips, when deleting a clip, you cannot drop each clip to the next level individually. Instead, you must drop the entire level to the next level when an empty level appears. This prevents empty levels, improves level management efficiency, and ensures that added transitions are not invalidated, maintaining a good user experience.

[0132] For example, as shown in (a) in FIG11 , after the segments at level 2 are deleted, level 2 becomes an empty level, so as shown in (b) in FIG12 , segments 3 , 4 and 5 can be moved down to level 2.

[0133] Figure 13 is a structural block diagram of a video processing device shown in an embodiment of the present disclosure, as shown in Figure 3, including: a display module 1301, used to display a video editing interface, the video editing interface includes a material area and a timeline area, multiple transition identifiers are displayed in the material area, each transition identifier is used to indicate a transition effect scheme, and the timeline area includes at least one video track; a processing module 1302, used to respond to a target trigger operation on a target transition identifier among the multiple transition identifiers, determine that the target video clips in the target video track corresponding to the target trigger operation are at the same level, and the target video track is a sub-track in the at least one video track; based on the transition effect scheme indicated by the target transition identifier, add a transition between adjacent video clips of the target.

[0134] In some embodiments of the present application, the device also includes a determination module for traversing the at least one video track before adding a transition between target adjacent video clips based on a transition effect scheme indicated by a target transition identifier, when the target trigger operation is a click operation, and in the process of traversing the at least one video track, determining the first detected adjacent video clip to which a transition can be added as the target adjacent video clip; and when the target trigger operation is a drag operation, determining the adjacent video clip corresponding to the end position of the trajectory of the drag operation as the target adjacent video clip.

[0135] In some embodiments of the present application, the processing module 1302 is specifically used to determine that the target video clips are at the same level when the free level function is enabled on the target video track, and the free level function is used to indicate that the level at which the video clips in each sub-track are located is the track number of the corresponding sub-track; when the free level function is not enabled on the target video track and the level identifiers of the levels at which the adjacent video clips are located are the same, determine that the target video clips are at the same level; when the free level function is not enabled on the target video track and the level identifiers of the levels at which the target adjacent video clips are located are different, adjust the target adjacent video clips to the same level so that the target adjacent video clips are at the same level.

[0136] In some embodiments of the present application, the processing module 1302 is specifically used to adjust the target adjacent video clips to the same level when it is determined that the video images within the target time range are the same before and after the target adjacent video clips are adjusted to the same level, and the target time range is the time range corresponding to the video clips of the adjusted level in the target adjacent video clips in the timeline area; when it is determined that the video images within the target time range are different before and after the target adjacent video clips are adjusted to the same level, display prompt information, and the prompt information includes a first option and a second option, the first option is used to indicate that the target adjacent video clips are adjusted to the same level, and the second option is used to indicate that the target adjacent video clips are not adjusted to the same level; in response to the triggering operation of the first option, the target adjacent video clips are adjusted to the same level.

[0137] In some embodiments of the present application, the target adjacent video clip includes a first video clip and a second video clip, the level of the first video clip is smaller than the level of the second video clip, and the level of the second video clip is the first level; the processing module 1302 is specifically used to adjust the level of the first video clip to the first level when the area corresponding to the first video clip at the first level can accommodate the first video clip; adjust the level of the target adjacent video clip to the second level when the area corresponding to the first video clip at the first level cannot accommodate the first video clip, and the area corresponding to the target adjacent video clip at the second level can accommodate the target adjacent video clip, and the second level is the upper level of the first level; when the area corresponding to the first video clip at the first level cannot accommodate the first video clip, and the area corresponding to the target adjacent video clip at the second level cannot accommodate the target adjacent video clip, create a new third level above the first level, and adjust the level of the target adjacent video clip to the third level.

[0138] In some embodiments of the present application, the processing module 1302 is specifically used to adjust the target adjacent video segment and other video segments connected to the first video segment through transition to the same level when the first video segment is connected to other video segments through transition; and to adjust the target adjacent video segment and other video segments connected to the second video segment through transition to the same level when the second video segment is connected to other video segments through transition.

[0139] In some embodiments of the present application, the device also includes an editing module for adding a transition between target adjacent video segments based on a transition effect scheme indicated by a target transition identifier, and then, in response to an editing operation on a target video segment in the target adjacent video segment, performing corresponding processing on the target video segment and deleting the transition that is invalidated in response to the editing operation; the editing operation includes any one of the following: a deletion operation, a paste operation, a move operation, a level adjustment operation, and a duration shortening operation.

[0140] In some embodiments of the present application, when the editing operation includes a paste operation, a move operation or a level adjustment operation, the corresponding processing includes: when the area corresponding to the target video clip at the first to-be-determined level can accommodate the target video clip, determining the level of the target video clip to be the first to-be-determined level; when the editing operation includes a paste operation or a move operation, the first to-be-determined level is the level at which the target video clip was located before the editing operation; when the editing operation includes a level adjustment operation, the first to-be-determined level is the level corresponding to the level adjustment operation; the area corresponding to the target video clip at the first to-be-determined level cannot accommodate the target video clip, and the area corresponding to the target video clip at the second to-be-determined level can accommodate the target video clip. In this case, the level of the target video clip is determined to be the second level to be determined, and the second level to be determined is the upper level of the first level to be determined; when the area corresponding to the target video clip at the first level to be determined cannot accommodate the target video clip, and the area corresponding to the target video clip at the second level to be determined cannot accommodate the target video clip, a third level to be determined is newly created above the first level to be determined, and the level of the target video clip is determined to be the third level to be determined; when the editing operation includes a deletion operation, the corresponding processing includes: deleting the target video clip; when there is no video clip at the target level, lowering the video clips with a level greater than the target level by one level respectively, and the target level is the level where the target video clip was located before the editing operation.

[0141] In some embodiments of the present application, the device also includes: a determination module for determining, in response to a triggering operation of adding a new video clip in the timeline area, that the initial level of the new video clip is the sum of the current maximum level in the timeline area and 1; if, in at least one continuous level below the initial level, the area corresponding to the new video clip can accommodate the new video clip, the final level of the new video clip is determined to be the minimum level in the at least one continuous level; if, in the current maximum level, the area corresponding to the new video clip cannot accommodate the new video clip, the final level of the new video clip is determined to be the initial level.

[0142] In the embodiments of the present disclosure, each module can implement the video processing method provided by the above method embodiments and can achieve the same technical effect. To avoid repetition, it will not be described here.

[0143] FIG14 is a schematic structural diagram of an electronic device provided in an embodiment of the present disclosure, which is used to exemplify an electronic device that implements any video processing method in an embodiment of the present disclosure and should not be understood as a specific limitation on the embodiment of the present disclosure.

[0144] As shown in FIG14 , the electronic device 1400 may include a processor (e.g., a central processing unit, a graphics processing unit, etc.) 1401, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 1402 or a program loaded from a storage device 1408 into a random access memory (RAM) 1403. Various programs and data required for the operation of the electronic device 1400 are also stored in the RAM 1403. The processor 1401, the ROM 1402, and the RAM 1403 are connected to each other via a bus 1404. An input / output (I / O) interface 1405 is also connected to the bus 1404.

[0145] Typically, the following devices may be connected to the I / O interface 1405: an input device 1406 including, for example, a touch screen, a touchpad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; an output device 1407 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; a storage device 1408 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 1409. The communication device 1409 may allow the electronic device 1400 to communicate with other devices wirelessly or by wire to exchange data. Although the electronic device 1400 is shown as having various devices, it should be understood that it is not required to implement or have all of the devices shown. More or fewer devices may alternatively be implemented or have.

[0146] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program carried on a non-transitory computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through the communication device 1409, or installed from the storage device 1408, or installed from the ROM 1402. When the computer program is executed by the processor 1401, the functions defined in any video processing method provided by the embodiment of the present disclosure can be performed.

[0147] It should be noted that the computer-readable medium mentioned above in the present disclosure may be a computer-readable signal medium or a computer-readable storage medium, or any combination of the two. Computer-readable storage media may be, for example, but not limited to, electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or components, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present disclosure, a computer-readable storage medium may be any tangible medium that contains or stores a program that can be used by or in conjunction with an instruction execution system, device, or component. In the present disclosure, a computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, which carries computer-readable program code. Such a propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. A computer-readable signal medium may also be any computer-readable medium other than a computer-readable storage medium that can transmit, propagate, or transport a program for use by or in conjunction with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium may be transmitted using any suitable medium, including but not limited to wires, optical cables, RF (radio frequency), etc., or any suitable combination thereof.

[0148] In some embodiments, the client and server can communicate using any currently known or future developed network protocol, such as HTTP (HyperText Transfer Protocol), and can be interconnected with any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network ("LAN"), a wide area network ("WAN"), an internet (e.g., the Internet), and a peer-to-peer network (e.g., an ad hoc peer-to-peer network), as well as any currently known or future developed network.

[0149] The computer-readable medium may be included in the electronic device, or may exist independently without being incorporated into the electronic device.

[0150] The above-mentioned computer-readable medium carries one or more programs. When the above-mentioned one or more programs are executed by the electronic device, the electronic device: displays a video editing interface, which includes a material area and a timeline area, and multiple transition identifiers are displayed in the material area, each transition identifier is used to indicate a transition effect scheme, and the timeline area includes at least one video track; in response to a target trigger operation on a target transition identifier among the multiple transition identifiers, it is determined that the target video clips in the target video track corresponding to the target trigger operation are at the same level, and the target video track is a sub-track in the at least one video track; based on the transition effect scheme indicated by the target transition identifier, a transition is added between adjacent target video clips.

[0151] In embodiments of the present disclosure, computer program code for performing the operations of the present disclosure may be written in one or more programming languages ​​or a combination thereof, including but not limited to object-oriented programming languages ​​such as Java, Smalltalk, C++, and conventional procedural programming languages ​​such as "C" or similar programming languages. The program code may be executed entirely on the computer, partially on the computer, as a separate software package, partially on the computer and partially on a remote computer, or entirely on the remote computer or server. In cases involving a remote computer, the remote computer may be connected to the computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0152] The flowcharts and block diagrams in the accompanying drawings illustrate the possible implementation architecture, functions and operations of the systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each box in the flowchart or block diagram can represent a module, program segment, or a part of code, and the module, program segment, or a part of code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order than that marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flowchart, and the combination of the boxes in the block diagram and / or flowchart, can be implemented with a dedicated hardware-based system that performs the specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0153] The units involved in the embodiments described in this disclosure may be implemented in software or hardware, wherein the name of a unit does not necessarily limit the unit itself.

[0154] The functions described above herein may be performed, at least in part, by one or more hardware logic components. For example, and without limitation, exemplary types of hardware logic components that may be used include: field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chip (SOCs), complex programmable logic devices (CPLDs), and the like.

[0155] In the context of the present disclosure, a computer-readable medium can be a tangible medium that can contain or store a program for use by an instruction execution system, device or equipment or used in combination with an instruction execution system, device or equipment. A computer-readable medium can be a computer-readable signal medium or a computer-readable storage medium. A computer-readable medium can include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or equipment, or any suitable combination of the foregoing. A more specific example of a computer-readable storage medium can include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0156] The above description is merely a preferred embodiment of the present disclosure and an illustration of the technical principles employed. Those skilled in the art should understand that the scope of disclosure involved in the present disclosure is not limited to the technical solutions formed by the specific combination of the above-mentioned technical features, but also includes other technical solutions formed by any combination of the above-mentioned technical features or their equivalents without departing from the above-mentioned disclosed concepts. For example, a technical solution formed by replacing the above-mentioned features with (but not limited to) technical features with similar functions disclosed in this disclosure.

[0157] In addition, although each operation is described in a specific order, this should not be understood as requiring these operations to be performed in the specific order shown or in a sequential order. Under certain circumstances, multitasking and parallel processing may be advantageous. Similarly, although some specific implementation details have been included in the above discussion, these should not be interpreted as limiting the scope of the present disclosure. Some features described in the context of a separate embodiment can also be implemented in a single embodiment in combination. On the contrary, the various features described in the context of a single embodiment can also be implemented in multiple embodiments individually or in any suitable sub-combination mode.

[0158] Although the subject matter has been described in language specific to structural features and / or methodological logical acts, it should be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or acts described above. Rather, the specific features and acts described above are merely example forms of implementing the claims.

Claims

1. A video processing method, the method comprising: Displaying a video editing interface, the video editing interface includes a material area and a timeline area, a plurality of transition marks are displayed in the material area, each transition mark is used to indicate a transition effect scheme, and the timeline area includes at least one video track; In response to a target trigger operation on a target transition identifier among the multiple transition identifiers, determining that target video segments in a target video track corresponding to the target trigger operation are at the same level, and the target video track is a sub-track in the at least one video track; Based on the transition effect scheme indicated by the target transition identifier, a transition is added between the target adjacent video segments.

2. The method according to claim 1, wherein the transition effect scheme based on the target transition identifier indicates, before adding a transition between the target adjacent video segments, the method comprises: In a case where the target trigger operation is a click operation, traversing the at least one video track, and in the process of traversing the at least one video track, determining the first detected adjacent video segment to which a transition can be added as the target adjacent video segment; In the case where the target triggering operation is a dragging operation, the adjacent video segment corresponding to the end position of the track of the dragging operation is determined as the target adjacent video segment.

3. The method according to claim 1, wherein determining that the target video segments in the target video tracks corresponding to the target triggering operation are at the same level comprises: In the case where the target video track has a free level function enabled, determining that the target video clips are at the same level, the free level function being used to indicate that the level at which the video clips in each sub-track are located is the track number of the corresponding sub-track; When the free level function is not enabled on the target video track and the level identifiers of the levels at which the adjacent video clips are located are the same, determining that the levels at which the target video clips are located are the same; When the free level function is not enabled for the target video track and the level identifiers of the levels where the target adjacent video clips are located are different, the target adjacent video clips are adjusted to the same level so that the target adjacent video clips are at the same level.

4. The method according to claim 3, wherein adjusting the target adjacent video segments to the same level comprises: When it is determined that the video images within the target duration range are the same before and after the target adjacent video segments are adjusted to the same level, the target adjacent video segments are adjusted to the same level, and the target duration range is a time range corresponding to the video segments of the adjusted level in the target adjacent video segments in the timeline area; When it is determined that the video images within the target duration are different before and after the target adjacent video segments are adjusted to the same level, prompt information is displayed, wherein the prompt information includes a first option and a second option, wherein the first option is used to indicate that the target adjacent video segments are adjusted to the same level, and the second option is used to indicate that the target adjacent video segments are not adjusted to the same level. Adjacent video clips are adjusted to the same level; In response to a triggering operation on the first option, the target adjacent video segments are adjusted to the same level.

5. The method according to claim 3, wherein the target adjacent video segment comprises a first video segment and a second video segment, the level of the first video segment is lower than the level of the second video segment, and the level of the second video segment is the first level; The step of adjusting the target adjacent video segments to the same level includes: If the area at the first level corresponding to the first video clip can accommodate the first video clip, adjusting the level of the first video clip to the first level; If the area at the first level corresponding to the first video segment cannot accommodate the first video segment, and the area at the second level corresponding to the target adjacent video segment can accommodate the target adjacent video segment, adjusting the level of the target adjacent video segment to the second level, where the second level is a level above the first level; When the area corresponding to the first level and the first video clip cannot accommodate the first video clip, and the area corresponding to the second level and the target adjacent video clip cannot accommodate the target adjacent video clip, a third level is newly created on the first level, and the level of the target adjacent video clip is adjusted to the third level.

6. The method according to claim 5, wherein adjusting the target adjacent video segments to the same level comprises: In the case where the first video segment is connected to other video segments through transition, adjusting the target adjacent video segment and other video segments connected to the first video segment through transition to the same level; In the case where the second video segment is connected to other video segments through transition, the target adjacent video segment and other video segments connected to the second video segment through transition are adjusted to the same level.

7. The method according to claim 1, wherein the transition effect scheme based on the target transition identifier indicates, after adding a transition between the target adjacent video segments, the method further comprises: In response to an editing operation on a target video segment in the target adjacent video segments, performing corresponding processing on the target video segment, and deleting transitions that are invalidated in response to the editing operation; The editing operation includes any one of the following: a deletion operation, a pasting operation, a moving operation, a level adjustment operation, and a duration shortening operation.

8. The method according to claim 7, wherein when the editing operation includes a pasting operation, a moving operation or a level adjustment operation, the corresponding processing includes: In a case where the area at the first to-be-determined level corresponding to the target video clip can accommodate the target video clip, determining the level of the target video clip to be the first to-be-determined level, in a case where the editing operation includes a pasting operation or a moving operation, the first to-be-determined level is the level at which the target video clip is located before the editing operation, and in a case where the editing operation includes a level adjustment operation, the first to-be-determined level is the level corresponding to the level adjustment operation; In the case where the area corresponding to the target video segment at the first to-be-determined level cannot accommodate the target video segment, and the area corresponding to the target video segment at the second to-be-determined level can accommodate the target video segment, determining Determine the level of the target video segment as the second level to be determined, where the second level to be determined is a level above the first level to be determined; If the area of ​​the first to-be-determined level corresponding to the target video clip cannot accommodate the target video clip, and the area of ​​the second to-be-determined level corresponding to the target video clip cannot accommodate the target video clip, a third to-be-determined level is newly created on the first to-be-determined level, and the level of the target video clip is determined to be the third to-be-determined level; In the case where the editing operation includes a deletion operation, the corresponding processing includes: Deleting the target video clip; In the case that no video clip exists at the target level, video clips at a level greater than the target level are respectively downgraded by one level, and the target level is the level at which the target video clip is located before the editing operation.

9. The method according to any one of claims 1 to 8, further comprising: In response to a triggering operation of adding a new video segment in the timeline region, determining an initial level of the new video segment as a sum of a current maximum level in the timeline region and 1; In the case where all areas corresponding to the newly added video clip in at least one continuous level below the initial level can accommodate the newly added video clip, determining the final level of the newly added video clip to be the minimum level in the at least one continuous level; In a case where the area corresponding to the newly added video segment in the current maximum level cannot accommodate the newly added video segment, the final level of the newly added video segment is determined to be the initial level.

10. A video processing device, comprising: A display module, used for displaying a video editing interface, the video editing interface includes a material area and a timeline area, a plurality of transition marks are displayed in the material area, each transition mark is used to indicate a transition effect scheme, and the timeline area includes at least one video track; A processing module, configured to, in response to a target trigger operation on a target transition identifier among the multiple transition identifiers, determine that the target video segments in the target video track corresponding to the target trigger operation are at the same level, and the target video track is a sub-track in the at least one video track; Based on the transition effect scheme indicated by the target transition identifier, a transition is added between the target adjacent video segments.

11. An electronic device, comprising: A memory and a processor, the memory is used to store computer programs; The processor is used to execute the video processing method according to any one of claims 1 to 9 when calling the computer program.

12. A computer-readable storage medium having a computer program stored thereon, wherein when the computer program is executed by a processor, the video processing method according to any one of claims 1 to 9 is implemented.

13. A computer program product, comprising a computer program, wherein when the computer program is executed by a processor, the computer program implements the video processing method according to any one of claims 1 to 9.

Citation Information

Patent Citations

  • Video rendering method and device, equipment, storage medium and computer program product

    CN112860944A

  • Video preview method and device, equipment and storage medium

    CN114827722A

  • Video content creation tool and method

    US20230230618A1