Video processing method and device, electronic equipment and storage medium
By supporting the addition of transitions to sub-tracks in the video editing interface, the limitation of the main track in existing tools is resolved, enabling a more flexible and diverse video editing experience.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- BEIJING ZITIAO NETWORK TECH CO LTD
- Filing Date
- 2023-09-28
- Publication Date
- 2026-06-02
AI Technical Summary
Existing video editing tools only support adding transitions to the main track, which limits the diversity of video editing scenarios and affects the video editing experience.
By showcasing the video editing interface, it supports adding transitions to sub-tracks, allowing the main video to be set on a sub-track and the background video to be set on the main track or other sub-tracks, increasing the diversity of video editing scenarios.
It improves the flexibility and experience of video editing, supports adding transitions to multiple tracks, and enhances the diversity and efficiency of video editing.
Smart Images

Figure CN119729120B_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of video processing technology, and in particular to a video processing method, apparatus, electronic device and storage medium. Background Technology
[0002] With the increasing abundance of information on the internet, watching videos has become a popular form of entertainment in people's daily lives. To enhance the user viewing experience, video editing is an important step before publishing any type of video.
[0003] During the video editing process, creators can use the functions provided by video editing tools to add special effects, filters, text, stickers, transitions, etc. to package the video and make the edited video look better before it is published.
[0004] Transitions can make the transitions between video clips more natural. Currently, video editing tools only support adding transitions between adjacent clips on the main track. Therefore, the main video can only be set on the main track, which limits the video editing scenarios and seriously affects the video editing experience. Summary of the Invention
[0005] In order to solve the above-mentioned technical problems, or at least partially solve the above-mentioned technical problems, this disclosure provides a video processing method, apparatus, electronic device and storage medium.
[0006] A first aspect of this disclosure provides a video processing method, the method comprising: displaying a video editing interface, the video editing interface including a material area and a timeline area, wherein the material area displays a plurality of transition markers, each transition marker indicating a transition effect scheme, and the timeline area including at least one video track; in response to a target trigger operation of a target transition marker among the plurality of transition markers, determining 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 among 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 marker.
[0007] A second aspect of this disclosure provides a video processing apparatus, comprising: a display module for displaying a video editing interface, the video editing interface including a material area and a timeline area, wherein a plurality of transition markers are displayed in the material area, each transition marker indicating a transition effect scheme, and the timeline area including at least one video track; and a processing module for responding to a target trigger operation of a target transition marker among the plurality of transition markers, determining that the target video segments in the target video track corresponding to the target trigger operation are at the same level, the target video track being a sub-track among 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 marker.
[0008] A third aspect of this disclosure provides an electronic device including 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.
[0009] A fourth aspect of this disclosure provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the video processing method as described in the first aspect.
[0010] A fifth aspect of this disclosure provides a computer program product, wherein the computer program product includes a computer program that, when the computer program product is run on a processor, causes the processor to execute the computer program to implement the video processing method as described in the first aspect.
[0011] A sixth aspect of this disclosure provides a chip including a processor and a communication interface coupled to the processor, the processor being configured to execute program instructions to implement the video processing method as described in the first aspect.
[0012] The technical solution provided in this disclosure has the following advantages compared with the prior art: A video editing interface is displayed, including a material area and a timeline area. Multiple transition markers are displayed in the material area, each indicating a transition effect scheme. The timeline area includes at least one video track. In response to a target trigger operation on a target transition marker among the multiple transition markers, it is determined that the target video segment 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 among the at least one video track. Based on the transition effect scheme indicated by the target transition marker, a transition is added between adjacent video segments of the target. This solution supports adding transitions to sub-tracks, allowing the main video to be set in a sub-track, and background videos to be set in the main track or other sub-tracks, increasing the diversity of video editing scenarios and improving the video editing experience. Attached Figure Description
[0013] The accompanying drawings, which are incorporated in and form a part of this specification, illustrate embodiments consistent with this disclosure and, together with the description, serve to explain the principles of this disclosure.
[0014] To more clearly illustrate the technical solutions in the embodiments of this disclosure or the prior art, the accompanying drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, for those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0015] Figure 1 A flowchart illustrating a video processing method provided in an embodiment of this disclosure;
[0016] Figure 2 A schematic diagram of an interface for a video processing method provided in an embodiment of this disclosure;
[0017] Figure 3 A schematic diagram of a video processing method provided in this embodiment of the present disclosure;
[0018] Figure 4 This is one of the hierarchical diagrams of the video processing method provided in the embodiments of this disclosure;
[0019] Figure 5 A second hierarchical diagram illustrating the video processing method provided in this embodiment of the disclosure;
[0020] Figure 6 This is the third hierarchical diagram of the video processing method provided in the embodiments of this disclosure;
[0021] Figure 7 The fourth hierarchical diagram of the video processing method provided in the embodiments of this disclosure;
[0022] Figure 8 Fifth of the hierarchical diagrams illustrating the video processing method provided in this embodiment of the disclosure;
[0023] Figure 9 A sixth hierarchical diagram of the video processing method provided in this embodiment of the disclosure;
[0024] Figure 10 The seventh hierarchical diagram of the video processing method provided in the embodiments of this disclosure;
[0025] Figure 11 Eighth of the hierarchical diagrams illustrating the video processing method provided in this embodiment of the disclosure;
[0026] Figure 12 A ninth hierarchical diagram illustrating the video processing method provided in this embodiment of the disclosure;
[0027] Figure 13 A structural block diagram of a video processing apparatus provided in an embodiment of this disclosure;
[0028] Figure 14 This is a structural block diagram of an electronic device provided in an embodiment of the present disclosure. Detailed Implementation
[0029] To better understand the above-mentioned objectives, features, and advantages of this disclosure, the solutions disclosed herein will be further described below. It should be noted that, unless otherwise specified, the embodiments and features described herein can be combined with each other.
[0030] Numerous specific details are set forth in the following description in order to provide a full understanding of this disclosure, but this disclosure may also be implemented in other ways different from those described herein; obviously, the embodiments in the specification are only some, and not all, of the embodiments of this disclosure.
[0031] The terms "first," "second," etc., used in this disclosure and in the claims are used to distinguish similar objects and not to describe a specific order or sequence. It should be understood that such use of data can be interchanged where appropriate so that embodiments of this disclosure can be implemented in orders other than those illustrated or described herein, and the objects distinguished by "first," "second," etc., are generally of the same class and the number of objects is not limited; for example, a first object can be one or more. Furthermore, in the specification and claims, "and / or" indicates at least one of the connected objects, and the character " / " generally indicates that the preceding and following objects are in an "or" relationship.
[0032] Currently, the transition functions provided by video editing tools only support adding transitions between adjacent segments in the main track. However, most videos are edited on multiple tracks. If transitions are limited to the main track, many effects cannot be achieved. For example, in a scenario where the background video is on the main track and the main video is on a secondary track, transitions cannot be added. To add transitions, the main video must be set on the main track and the background video on the secondary track. This limits the video editing scenarios and seriously affects the video editing effect.
[0033] To address the aforementioned technical issues, this embodiment of the application presents a video editing interface. This interface includes a material area and a timeline area. The material area displays multiple transition markers, each indicating a transition effect. The timeline area includes at least one video track. In response to a target trigger operation on a target transition marker among the multiple transition markers, it is determined that the target video segment in the target video track corresponding to the target trigger operation is at the same level, and this target video track is a sub-track among the at least one video track. Based on the transition effect indicated by the target transition marker, a transition is added between adjacent video segments of the target. This solution supports adding transitions to sub-tracks, allowing the main video to be set in a sub-track, and background videos to be set in the main track or other sub-tracks, increasing the diversity of video editing scenarios and improving the video editing experience.
[0034] The electronic devices in this disclosure can be mobile electronic devices or non-mobile electronic devices. Mobile electronic devices can be mobile phones, tablets, laptops, PDAs, in-vehicle electronic devices, wearable devices, ultra-mobile personal computers (UMPCs), netbooks, or personal digital assistants (PDAs), etc.; non-mobile electronic devices can be personal computers (PCs), televisions (TVs), ATMs, or self-service machines, etc.; this disclosure does not impose specific limitations.
[0035] The execution subject of the video processing method provided in this disclosure can be the aforementioned electronic device (including mobile electronic devices and non-mobile electronic devices), or it can be a functional module and / or functional entity in the electronic device that can implement the video processing method. The specific implementation subject can be determined according to actual usage requirements, and this disclosure does not limit it.
[0036] The video processing method provided by the present disclosure will be described in detail below with reference to the accompanying drawings, through specific embodiments and application scenarios.
[0037] like Figure 1As shown in the figure, this disclosure provides a video processing method, which may include the following steps 100 to 102.
[0038] 100. Display the video editing interface, which includes a media area and a timeline area.
[0039] This material area displays multiple transition icons, each indicating a transition effect scheme. The timeline area includes at least one video track.
[0040] The material area displays multiple material type options, including transition options, as well as special effects options, filter options, text options, sticker options, material library options, etc. The specific options can be determined according to the actual situation, and there are no restrictions here.
[0041] Specifically, when different material options are selected, the material area displays multiple material icons corresponding to the selected material options. When a transition option is selected, this material area displays multiple transition icons.
[0042] 101. In response to a target trigger operation of 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.
[0043] The target video track is a sub-track among the at least one video track.
[0044] 102. Based on the transition effect scheme indicated by the target transition identifier, add a transition between adjacent video segments of the target.
[0045] The target video track is a sub-track among the at least one video track.
[0046] The target trigger operation can be a click operation on the target transition icon, a drag operation on the target transition icon, or other feasible operations on the target transition icon. The specific operation can be determined according to the actual situation and is not limited here.
[0047] Among them, the transition effects indicated by multiple transition indicators may include, but are not limited to: spatial rotation transition, page turning transition, before and after contrast transition, shaking magnification transition, vibration transition, heart-shaped dissolve transition, stretching transition, inhalation transition, atomization transition, water droplet transition, etc.
[0048] In this embodiment of the application, at least one video track may include at least one sub-track, and at least one video track may also include a main track. The specific details can be determined according to the actual situation and are not limited here.
[0049] Specifically, adding a transition between adjacent video segments refers to adding a transition where two adjacent video segments meet.
[0050] In this embodiment, it is supported to add transitions on the main track and also to add transitions on the sub-track. In specific use cases, transitions can be added on the main track or the sub-track according to actual needs.
[0051] In this embodiment, by enabling the addition of transitions to a sub-track, the main video can be placed on the sub-track, while background videos and other videos can be placed on the main track or other sub-tracks. This increases the diversity of video editing scenarios and improves the video editing experience.
[0052] In some embodiments of this application, step 101 can be specifically implemented by the following steps 201 and 202.
[0053] 201. In response to a target trigger operation on the target transition identifier among the plurality of transition identifiers, if the target trigger operation is a click operation, traverse the at least one video track, and during the traversal of 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.
[0054] 202. Determine that the target video segment in the target video track corresponding to the target trigger operation is at the same level.
[0055] Specifically, steps 201, 202, and 102 can be performed in response to a click on the target transition marker. This involves obtaining all video tracks containing video segments in the timeline region, resulting in at least one video track. These tracks are then sorted according to a specific rule (e.g., sorting by timeline region from top to bottom, or by bottom to top) to obtain track numbers. The process then iterates through these tracks by number. When a track is reached, it is determined whether a video segment for which a transition can be added exists. If a target adjacent video segment for which a transition can be added exists, the transition is added, the process ends, and other video tracks are not iterated. If no such transition exists, the process moves to the next video track. During the iteration of at least one video track, a transition is added to the first identified target adjacent video segment for which a transition can be added, and then the iteration stops. Alternatively, if no adjacent video segment for which a transition can be added exists after iterating through each video segment, the transition addition fails, and the process ends.
[0056] In this embodiment of the application, the above steps 201, 202 and 102 enable intelligent addition of transitions. The system can automatically identify adjacent video segments in the video track of the timeline area that can have transitions added, and then add the transitions, thereby improving operational efficiency.
[0057] In some embodiments of this application, step 101 can be specifically implemented by steps 203 and 204.
[0058] 203. In response to a target trigger operation on the target transition identifier among the multiple transition identifiers, if the target trigger operation is a drag operation, the adjacent video segment corresponding to the end position of the drag operation trajectory is determined as the target adjacent video segment.
[0059] In some embodiments of this application, when the trajectory of the drag operation passes over any adjacent video segment, the connecting area of the any adjacent video segment is displayed in a first display mode. The first display mode can be a highlight display, which can prompt the user that an adjacent video segment exists at that location.
[0060] 204. Determine that the target video segment in the target video track corresponding to the target trigger operation is at the same level.
[0061] In this embodiment, users can drag and drop transition markers to the position where the target adjacent video segment to which a transition needs to be added, and then add a transition to the target adjacent video segment, which can improve the user experience.
[0062] In some embodiments of this application, if there is no adjacent video segment at the end position of the drag operation trajectory, the transition will fail to be added.
[0063] In some embodiments of this application, in response to a target trigger operation on a target transition identifier among a plurality of transition identifiers, if 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 of the following: there is no adjacent video segment at the current addition position; the length of the video segment at the current addition position is less than or equal to a length threshold; the video track at the current addition position is locked; the adjacent video segments at the current addition position are not at the same level.
[0064] For example, such as Figure 2The diagram shows a video editing interface. The area marked "21" is the media area, "22" is the timeline area, "23" is the player area, and "24" is the function panel. The transition pack option in the media area is selected. The timeline area includes four video tracks, all sub-tracks. Selected media 1, 2, and 3 are three media clips from the media pack combination. Clicking the transition icon adds a transition between video clip 1 and composite clip 1.
[0065] Currently, video editing tools only support adding transitions to 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. Since the rendering levels of video clips in the main track are always the same, the main track supports adding transitions between adjacent video clips. However, without the free level function enabled, the rendering levels of video clips in the sub-track are always different, so the sub-track does not support adding transitions between adjacent video clips.
[0066] In related technologies, in non-free-level drafts (drafts without free-level functionality), all sub-track video clips are rendered at different levels. Since transitions cannot be added to sub-tracks when each clip is at a different level, it's necessary to use new level setting rules that allow different clips to be at the same level while maintaining the current level relationship. The level setting rule in related technologies is to directly set the level of newly added video clips to the current maximum level plus 1. Adding a new video clip to a sub-track within the timeline area... Figure 3 Taking the video clips shown as an example, add clips 1 through 4 in sequence. The corresponding hierarchical relationship is as follows: Figure 4 As shown in (a) in the figure.
[0067] In some embodiments of this application, the video processing method provided in this application may further include the following steps 103 to 105.
[0068] 103. In response to a trigger operation that adds a new video clip to the timeline region, determine that the initial level of the new video clip is the sum of the current maximum level in the timeline region and 1.
[0069] 104. If, in at least one consecutive level below the initial level, the area corresponding to the newly added video segment can accommodate the newly added video segment, then the final level of the newly added video segment is determined to be the smallest level among the at least one consecutive levels.
[0070] 105. If 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.
[0071] In this embodiment, 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. Then, it is determined whether the next level can accommodate the newly added video clip. If it can, the level is "sinked" until it can no longer be "sinked" (i.e., the level below the current level cannot accommodate the newly added video clip). Figure 4 Based on (a) in the middle, such as Figure 4 As shown in (b), adding segment 2 allows it to sink to level 1, while adding segments 3 and 4 allows them to sink to level 2. Therefore, in this embodiment, the rendering levels of the video segments in the sub-track may be the same or different.
[0072] In this embodiment of the application, by using the "sinking method" to determine the level of the newly added video segment, the addition of transitions to the subtrack can be well achieved.
[0073] In some embodiments of this application, step 101 can be implemented by step 301, step 302, or step 303.
[0074] 301. If the free level function is enabled on the target video track, determine that the target video segment is at the same level.
[0075] The free-level function is used to indicate that the level of the video clip in each sub-track is the track number of the corresponding sub-track. That is, when the free-level function is enabled, the video clips in each sub-track have the same level, and the level of each video clip in a sub-track is its own track number.
[0076] Specifically, when the free-level feature is enabled on a sub-track, the video clips within that sub-track will have the same level. When the free-level feature is disabled on a sub-track, the video clips within that sub-track may have the same or different levels, but generally they will have different levels. Therefore, if the free-level feature is enabled, it ensures that adjacent video clips are at the same level.
[0077] 302. If the free level function is not enabled on the target video track, and the level identifiers of the adjacent video segments are the same, then the target video segments are determined to be at the same level.
[0078] The layer identifier can be a layer index. If the layer indices of adjacent video segments are the same, then the adjacent video segments are determined to be at the same layer.
[0079] In some embodiments of this application, the level size can be determined based on the level index of different levels.
[0080] 303. If the free level function is not enabled on the target video track and the level identifiers of the adjacent video segments are different, adjust the adjacent video segments to the same level so that the adjacent video segments are at the same level.
[0081] In this embodiment of the application, the layer of one or two video segments in the target adjacent video segments is adjusted so that the adjusted target adjacent video segments are in the same layer.
[0082] Specifically, steps 301 to 303 can be as follows: First, determine if the target video track has the free level function enabled. If the target video track has the free level function enabled, it can be determined that adjacent video segments are at the same level. Second, if the target video track does not have the free level function enabled, determine if the level identifiers of the adjacent video segments are the same. If the level identifiers of the adjacent video segments are the same, it can be determined that the adjacent video segments are at the same level. Third, if the level identifiers of the adjacent video segments are different, adjust the adjacent video segments to the same level to determine that they are at the same level. In summary, after determining that adjacent video segments are at the same level through any of steps 301 to 303, a transition can be added between adjacent video segments based on the transition effect scheme indicated by the target transition identifier.
[0083] In this embodiment of the application, by adding a determination of whether the free layer function is enabled and whether the layer identifiers of adjacent video segments are the same, transitions can be added to the sub-track.
[0084] In some embodiments of this application, step 303 can be specifically implemented by steps 303a to 303d below.
[0085] 303a. If it is determined that the free level function is not enabled on the target video track and the level identifiers of the adjacent video segments of the target are different, determine whether the video images within the target duration range are the same before and after the adjacent video segments of the target are adjusted to the same level.
[0086] The target duration range refers to the time range of video segments whose layers have been adjusted within the adjacent video segments of the target in the timeline region.
[0087] It can be understood that when the layer of one video segment adjacent to the target is adjusted, the target duration range is the duration interval corresponding to that one video segment. When the layer of both video segments adjacent to the target is adjusted, the target duration range is the duration interval corresponding to those two video segments.
[0088] Because two video clips with overlapping timelines are located at different levels, during display, the video clip on the upper level will obscure the video clip on the lower level. Therefore, when the levels of these two video clips are swapped, the obscuring between the video clips changes, thus altering the displayed video image. For example... Figure 5 As shown, segment 1 is located in layer 1 and segment 2 is located in layer 2. Currently, segment 2 will obscure segment 1. However, when the layers of segment 1 and segment 2 are swapped, segment 1 will obscure segment 2, thus causing the video image to change during display.
[0089] If it is determined that the video footage within the target's duration is the same before and after the adjacent video segments of the target are adjusted to the same level, then step 303b is executed. If it is determined that the video footage within the target's duration is different before and after the adjacent video segments of the target are adjusted to the same level, then steps 303c and 303d are executed.
[0090] 303b. Adjust the adjacent video clips of the target to the same level.
[0091] 303c. Display a prompt message, which includes a first option and a second option. The first option is used to indicate that the adjacent video segments of the target should be adjusted to the same level, and the second option is used to indicate that the adjacent video segments of the target should not be adjusted to the same level.
[0092] 303d, In response to the trigger operation of the first option, adjust the adjacent video segments of the target to the same level.
[0093] In this embodiment, if the video footage within the target's duration is the same before and after adjusting adjacent video segments to the same level, adjusting the adjacent video segments to the same level directly improves operational efficiency since it does not affect the displayed video footage. If the video footage within the target's duration is different before and after adjusting adjacent video segments to the same level, a prompt message can be used to indicate that level switching will affect the video footage. Therefore, based on the user's choice of the prompt message, it is determined whether to perform level adjustment or add a transition, allowing the user to understand that level adjustment will affect the video footage. Compared to directly adjusting adjacent video segments to the same level, this improves the user experience.
[0094] In some embodiments of this application, when it is determined that the target adjacent video segments are at different levels, a prompt message may be displayed asking whether to adjust the level, and then the user's choice may be made to determine whether to adjust the level and then add a transition.
[0095] In some embodiments of this application, the target adjacent video segments include a first video segment and a second video segment, wherein 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 implemented by any one of the following steps 303e to 303g.
[0096] 303e. If the area corresponding to the first video segment in the first level can accommodate the first video segment, adjust the level of the first video segment to the first level.
[0097] The area corresponding to the first video segment can be the area corresponding to the position of the first video segment within the timeline.
[0098] 303f If the area corresponding to the first video segment in the first level cannot accommodate the first video segment, and the area corresponding to the adjacent video segment in the second level can accommodate the adjacent video segment, the level of the adjacent video segment is adjusted to the second level.
[0099] The second level is the level above the first level.
[0100] 303g. If the area corresponding to the first video segment in the first level cannot accommodate the first video segment, and the area corresponding to the adjacent video segment in the second level cannot accommodate the adjacent video segment of the target, a third level is created above the first level, and the level of the adjacent video segment of the target is adjusted to the third level.
[0101] In some embodiments of this application, a third level can be created between the first level and the second level. The level index of the third level is the level index of the second level, and the level indices of the second level and other levels higher than the second level are incremented by 1.
[0102] For example, such as Figure 5 As shown, clip 1 and clip 3 are adjacent video clips on the same video track. Clip 1 is located at level 1, and clip 3 is located at level 3. If a transition is added between clip 1 and clip 3, since level 3 can accommodate clip 1, therefore... Figure 6 As shown in (a), you can adjust segment 1 to level 3 and then add a transition.
[0103] For example, such as Figure 5As shown, clip 1 and clip 4 are adjacent video clips on the same video track. Clip 1 is located at level 1, and clip 4 is located at level 2. If a transition is added between clip 1 and clip 4, it will be impossible to accommodate clip 1 at level 2, and clips 1 and 4 at level 3. Therefore, as shown... Figure 6 As shown in (b), a new layer 3 can be created above layer 2, then the layer index of the previous layer 3 is incremented by 1, then fragment 1 and fragment 4 are adjusted to the newly created layer 3, and then a transition is added.
[0104] In this embodiment, the hierarchical adjustment is performed according to steps 303e to 303g, which is logically simple and minimizes the change in the relative hierarchical relationship between segments, thus having the least impact on the video picture.
[0105] In some embodiments of this application, a third level may be created above the second or highest level, and the third level may be the highest level.
[0106] In some embodiments of this application, if the layer where the first video segment is located can accommodate the second video segment, the layer of the second video segment can also be adjusted to the layer of the first video segment. The specific adjustment can be determined according to the actual situation and is not limited here.
[0107] In some embodiments of this application, step 303 can be specifically implemented by step 303h and / or step 303i.
[0108] 303h, when the first video segment is connected to other video segments via a transition, adjust the target's adjacent video segments and other video segments connected to the first video segment via a transition to the same level.
[0109] 303i, when the second video segment is connected to other video segments via a transition, adjust the target's adjacent video segments and other video segments connected to the second video segment via a transition to the same level.
[0110] Simultaneously executing steps 303h and / or 303i means adjusting the target's adjacent video segments, other video segments connected to the first video segment via transitions, and other video segments connected to the second video segment via transitions to the same level.
[0111] In this embodiment, when adjusting adjacent video segments to the same level, it's not sufficient to only consider adjusting them to the same level. This is because one or two video segments within the adjacent segments may be "connected" to other video segments via transitions (hereinafter, two video segments "connected" via transitions are referred to as a segment chain). If only the adjacent video segments are adjusted to the same level, the transitions already added to that video segment (or two video segments) may become invalid. Therefore, it's necessary to adjust the level of the entire segment chain corresponding to that video segment (or two video segments) together. Specifically, if the level of a higher-level segment chain can accommodate a lower-level segment chain, the lower-level segment chain is promoted to the higher level; otherwise, a new layer is created above the higher-level segment chain to hold the two segment chains.
[0112] For example, such as Figure 7 As shown in (a), fragments 1 and 2 form a fragment chain located at level 1, and fragments 3 and 4 form a fragment chain located at level 2. Level 1 also includes fragment 5. When a transition needs to be added between adjacent fragments 2 and 3, since level 2 can accommodate the fragment chain formed by fragments 1 and 2, therefore, as shown in (a), Figure 7 As shown in (b), the level of the fragment chain formed by fragment 1 and fragment 2 can be raised to level 2, and then a transition can be added between fragment 2 and fragment 3.
[0113] For example, such as Figure 8 As shown in (a), fragments 1 and 2 form a fragment chain located at level 1, and fragments 3 and 4 form a fragment chain located at level 2. Level 1 also includes fragment 5, and level 2 includes fragment 6. When a transition needs to be added between adjacent fragments 2 and 3, since level 2 cannot accommodate fragments 1 and 2 forming a fragment chain, therefore, as shown in (a),... Figure 8 As shown in (b), a new level 3 can be created on level 2. The levels of fragment 1 and fragment 2 forming a fragment chain, and fragment 3 and fragment 4 forming a fragment chain, can be simultaneously promoted to level 3. Then, a transition can be added between fragment 2 and fragment 3.
[0114] In some embodiments of this application, after step 102 described above, the video processing method provided in this application may further include step 106 as described below.
[0115] 106. In response to an editing operation on a target video segment in an adjacent video segment, process the target video segment accordingly and delete transitions that are invalidated in response to the editing operation.
[0116] The editing operation includes any of the following: deletion, pasting, moving, adjusting levels, or shortening duration.
[0117] The delete operation deletes the target video segment, the paste operation pastes the target video segment to the target location (the paste operation includes copying or cutting the target video segment before the paste operation), the move operation moves the target video segment to the target location, the level adjustment operation manually adjusts the level of the target video segment in the function panel area, and the duration reduction operation shortens the duration of the transition added to the target video segment.
[0118] In this embodiment of the application, since transitions are added between adjacent video segments to form a segment chain, when the target video segment in the adjacent video segment is edited, the transition between the adjacent video segments may fail. After the transition fails, the efficiency of video editing can be improved by automatically deleting the failed transition.
[0119] In this embodiment, the deletion response to an invalidated editing operation can be either direct deletion or deletion via a deletion function. In this embodiment, invalid transitions caused by editing operations such as deletion, pasting, moving, level adjustment, and duration shortening can all be deleted using a single deletion function, thus simplifying the deletion logic and improving operational efficiency.
[0120] In some embodiments of this application, when the editing operation includes a paste operation, a move operation, or a layer adjustment operation, the corresponding processing includes: if the area corresponding to the first layer to be determined and the target video segment can accommodate the target video segment, determining the layer of the target video segment as the first layer to be determined; if the editing operation includes a paste operation or a move operation, the first layer to be determined is the layer where the target video segment was located before the editing operation; if the editing operation includes a layer adjustment operation, the first layer to be determined is the layer corresponding to the layer adjustment operation; and if the first layer to be determined and the target video segment can accommodate the target video segment, determining the layer of the target video segment as the first layer to be determined. If the area corresponding to the video segment cannot contain the target video segment, but the area corresponding to the second undetermined level can contain the target video segment, then the level of the target video segment is determined as the second undetermined level, which is the level above the first undetermined level. If the area corresponding to the first undetermined level and the target video segment cannot contain the target video segment, and the area corresponding to the second undetermined level and the target video segment cannot contain the target video segment, then a third undetermined level is created above the first undetermined level, and the level of the target video segment is determined as the third undetermined level.
[0121] Understandably, for move and paste operations, the moved or pasted video clips are adjusted one by one from bottom to top according to their original layer. Specifically, if the original layer can accommodate the moved or pasted video clip, the layer of the moved or pasted video clip remains unchanged; if the original layer cannot accommodate the moved or pasted video clip, it attempts to adjust it to the next higher layer. If the next higher layer can accommodate the moved or pasted video clip, it is directly promoted to the next higher layer; otherwise, a new layer is created above the original layer to place the moved or pasted video clip.
[0122] For example, fragment 1 and fragment 2 are located in level 1, fragment 3 and fragment 4 are located in level 2, and fragment 5 and fragment 6 are located in level 3, as shown below. Figure 9 As shown in (a), when fragment 3 is moved, level 2 cannot accommodate fragment 3, but level 3 can accommodate fragment 3, as follows. Figure 9 As shown in (b), adjust fragment 3 to level 3.
[0123] For example, fragment 1 and fragment 2 are located in level 1, fragment 3 and fragment 4 are located in level 2, and fragment 5 and fragment 6 are located in level 3, as shown below. Figure 10 As shown in (a), when fragment 3 is moved, level 2 cannot accommodate fragment 3, and level 3 also cannot accommodate fragment 3, as shown in (a). Figure 10 As shown in (b), the original level 3 is adjusted to level 4, a new level 3 is created between level 2 and level 4, and fragment 3 is adjusted to level 3.
[0124] In this embodiment, the hierarchical adjustment is performed according to the above-mentioned processing. The logic is simple, and the change in the relative hierarchical relationship between segments is minimal, thus having the least impact on the video picture.
[0125] In some embodiments of this application, the level adjustment operation is a level rotation operation of multiple video segments selected on the playback progress line. For example... Figure 11 As shown in (a), segments 1 and 6 are at level 1, segment 2 is at level 2, and segments 3, 4, and 5 are at level 3. The current playback progress bar selects segments 1, 2, and 3. When the relative level of segment 3 is set to 1, the levels of the three segments rotate. At this point, as shown in (a),... Figure 11 As shown in (b), segment 2 overlaps with other segments after moving to level 3, therefore... Figure 12 As shown in (a), fragment 2 needs to be moved up one layer.
[0126] In this embodiment, the hierarchy displayed on the functional panel is the relative hierarchy between segments at the current moment. Changing the calculation method for the hierarchy does not affect the calculation of this relative hierarchy. Based on the change in relative hierarchy, the hierarchy of related segments is rotated, and then the internal conflicts of the hierarchy are handled according to the logic of the paste operation (or move operation). The logic is simple, and the change in the relative hierarchy relationship between segments is minimal, resulting in minimal impact on the video picture.
[0127] In some embodiments of this application, when the editing operation includes a deletion operation, the corresponding processing includes: deleting the target video segment; and when there are no video segments at the target level, demoting video segments at levels higher than the target level by one level, wherein the target level is the level where the target video segment was located before the editing operation.
[0128] This is understandable. Considering that transitions may be added between clips, deleting a clip should not cause it to sink to the next level individually. Instead, the entire deleted level should sink to the next level when an empty level occurs. This ensures that empty levels are avoided, improves level management efficiency, and prevents added transitions from becoming invalid, thus guaranteeing a better user experience.
[0129] For example, such as Figure 11 As shown in (a), when the fragment located at level 2 is deleted, level 2 becomes an empty level, therefore... Figure 12 As shown in (b), fragments 3, 4, and 5 can be sunk to level 2.
[0130] Figure 13 This is a structural block diagram of a video processing apparatus shown in an embodiment of the present disclosure, such as... Figure 3 As shown, it includes: a display module 1301 for displaying a video editing interface, which includes a material area and a timeline area. The material area displays multiple transition markers, each of which indicates a transition effect scheme. The timeline area includes at least one video track. A processing module 1302 is used to respond to a target trigger operation of a target transition marker among the multiple transition markers, determine that the target video segment in the target video track corresponding to the target trigger operation is at the same level, and that the target video track is a sub-track among the at least one video track; and add a transition between adjacent target video segments based on the transition effect scheme indicated by the target transition marker.
[0131] In some embodiments of this application, the apparatus further includes a determining module, configured to, before adding a transition between target adjacent video segments based on a transition effect scheme indicated by a target transition identifier, traverse the at least one video track when the target triggering operation is a click operation, and during the traversal of 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; and when the target triggering operation is a drag operation, determine the adjacent video segment corresponding to the end position of the drag operation trajectory as the target adjacent video segment.
[0132] In some embodiments of this application, the processing module 1302 is specifically configured to: determine that the target video segment is at the same level when the free level function is enabled on the target video track, wherein the free level function is used to indicate that the level of the video segment in each sub-track is the track number of the corresponding sub-track; determine that the target video segment is at the same level when the free level function is not enabled on the target video track and the level identifiers of the adjacent video segments are the same; and adjust the adjacent video segments to the same level when the free level function is not enabled on the target video track and the level identifiers of the adjacent video segments are different, so that the adjacent video segments are at the same level.
[0133] In some embodiments of this application, the processing module 1302 is specifically configured to adjust the adjacent video segments of the target to the same level when it is determined that the video frames within the target duration range are the same before and after adjusting the adjacent video segments of the target to the same level, wherein the target duration range is the time range corresponding to the video segments of the adjacent video segments of the target to the adjusted level within the timeline area; and to display a prompt message when it is determined that the video frames within the target duration range are different before and after adjusting the adjacent video segments of the target to the same level, wherein the prompt message includes a first option and a second option, wherein the first option is used to indicate that the adjacent video segments of the target are adjusted to the same level, and the second option is used to indicate that the adjacent video segments of the target are not adjusted to the same level; and to adjust the adjacent video segments of the target to the same level in response to the triggering operation of the first option.
[0134] In some embodiments of this application, the target adjacent video segment includes a first video segment and a second video segment, wherein 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 processing module 1302 is specifically used to adjust the level of the first video segment to the first level when the area corresponding to the first video segment at the first level can accommodate the first video segment; when the area corresponding to the first video segment at the first level cannot accommodate the first video segment, but 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, where the second level is the level above the first level; when 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 cannot accommodate the target adjacent video segment, create a third level above the first level, and adjust the level of the target adjacent video segment to the third level.
[0135] In some embodiments of this 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 via transitions to the same level when the first video segment is connected to other video segments via transitions; and to adjust the target adjacent video segment and other video segments connected to the second video segment via transitions to the same level when the second video segment is connected to other video segments via transitions.
[0136] In some embodiments of this application, the apparatus further includes an editing module, configured to, after adding a transition between adjacent video segments based on a transition effect scheme indicated by a target transition identifier, process the target video segment accordingly in response to an editing operation on the target video segment in the adjacent video segments, and delete the transition that is invalidated in response to the editing operation; the editing operation includes any one of the following: deletion operation, paste operation, move operation, level adjustment operation, and duration shortening operation.
[0137] In some embodiments of this application, when the editing operation includes a paste operation, a move operation, or a level adjustment operation, the corresponding processing includes: if the area corresponding to the first level to be determined and the target video segment can accommodate the target video segment, determining the level of the target video segment as the first level to be determined; if the editing operation includes a paste operation or a move operation, the first level to be determined is the level where the target video segment was located before the editing operation; if the editing operation includes a level adjustment operation, the first level to be determined is the level corresponding to the level adjustment operation; if the area corresponding to the first level to be determined and the target video segment cannot accommodate the target video segment, and the area corresponding to the second level to be determined and the target video segment can accommodate the target video segment... In the following cases, the target video segment is determined to be at a second undetermined level, which is the level above the first undetermined level. If the area corresponding to the target video segment in the first undetermined level cannot contain the target video segment, and the area corresponding to the target video segment in the second undetermined level also cannot contain the target video segment, a third undetermined level is created above the first undetermined level, and the target video segment is determined to be at a third undetermined level. If the editing operation includes a deletion operation, the corresponding processing includes: deleting the target video segment; if no video segment exists at the target level, video segments with levels higher than the target level are each demoted by one level, and the target level is the level where the target video segment was located before the editing operation.
[0138] In some embodiments of this application, the apparatus further includes: a determining module, configured to, in response to a triggering operation of adding a new video segment to the timeline region, determine that the initial level of the new video segment is the sum of the current maximum level in the timeline region and 1; if, in at least one consecutive level below the initial level, the area corresponding to the new video segment can accommodate the new video segment, determine that the final level of the new video segment is the minimum level among the at least one consecutive levels; if, in the current maximum level, the area corresponding to the new video segment cannot accommodate the new video segment, determine that the final level of the new video segment is the initial level.
[0139] In this embodiment, each module can implement the video processing method provided in the above method embodiments and achieve the same technical effect. To avoid repetition, it will not be described again here.
[0140] Figure 14 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present disclosure. It is used to illustrate the electronic device that implements any video processing method in the embodiments of the present disclosure and should not be construed as a specific limitation on the embodiments of the present disclosure.
[0141] like Figure 14 As shown, electronic device 1400 may include a processor (e.g., central processing unit, graphics processor, etc.) 1401, which can perform various appropriate actions and processes according to a program stored in read-only memory (ROM) 1402 or a program loaded from storage device 1408 into random access memory (RAM) 1403. The RAM 1403 also stores various programs and data required for the operation of electronic device 1400. The processor 1401, ROM 1402, and RAM 1403 are interconnected via bus 1404. Input / output (I / O) interface 1405 is also connected to bus 1404.
[0142] Typically, the following devices can be connected to I / O interface 1405: input devices 1406 including, for example, touchscreens, touchpads, keyboards, mice, cameras, microphones, accelerometers, gyroscopes, etc.; output devices 1407 including, for example, liquid crystal displays (LCDs), speakers, vibrators, etc.; storage devices 1408 including, for example, magnetic tapes, hard disks, etc.; and communication devices 1409. Communication device 1409 allows electronic device 1400 to communicate wirelessly or wiredly with other devices to exchange data. Although electronic device 1400 with various devices is shown, it should be understood that it is not required to implement or possess all of the devices shown. More or fewer devices may be implemented or possessed alternatively.
[0143] In particular, according to embodiments of this disclosure, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments of this disclosure include a computer program product comprising a computer program carried on a non-transitory computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via communication device 1409, or installed from storage device 1408, or installed from ROM 1402. When the computer program is executed by processor 1401, it can perform the functions defined in any video processing method provided in embodiments of this disclosure.
[0144] It should be noted that the computer-readable medium described in this disclosure can be a computer-readable signal medium or a computer-readable storage medium, or any combination thereof. A computer-readable storage medium can be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of a computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof. In this disclosure, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, apparatus, or device. In this disclosure, a computer-readable signal medium can include a data signal propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such propagated data signals can take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. A computer-readable signal medium can be any computer-readable medium other than a computer-readable storage medium, which can send, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium can be transmitted using any suitable medium, including but not limited to: wires, optical fibers, RF (radio frequency), etc., or any suitable combination thereof.
[0145] In some implementations, the client and server can communicate using any currently known or future-developed network protocol such as HTTP (Hypertext Transfer Protocol), and can interconnect with digital data communication (e.g., communication networks) of any form or medium. Examples of communication networks include local area networks (“LANs”), wide area networks (“WANs”), the Internet (e.g., the Internet of Things), and peer-to-peer networks (e.g., ad hoc peer-to-peer networks), as well as any currently known or future-developed networks.
[0146] The aforementioned computer-readable medium may be included in the aforementioned electronic device; or it may exist independently and not assembled into the electronic device.
[0147] The aforementioned computer-readable medium carries one or more programs that, when executed by the electronic device, cause the electronic device to: display a video editing interface, the video editing interface including a media area and a timeline area, the media area displaying multiple transition markers, each transition marker indicating a transition effect scheme, the timeline area including at least one video track; in response to a target trigger operation of a target transition marker among the multiple transition markers, determine that the target video segment in the target video track corresponding to the target trigger operation is at the same level, the target video track being a sub-track among the at least one video track; and add a transition between adjacent target video segments based on the transition effect scheme indicated by the target transition marker.
[0148] In embodiments of this disclosure, computer program code for performing the operations of this disclosure can be written in one or more programming languages or a combination thereof. These programming languages include, but are not limited to, object-oriented programming languages such as Java, Smalltalk, and C++, as well as conventional procedural programming languages such as the "C" language or similar programming languages. The program code can be executed entirely on a computer, partially on a computer, as a standalone software package, partially on a computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or it can be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0149] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this disclosure. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.
[0150] The units described in the embodiments of this disclosure can be implemented in software or hardware. The names of the units are not, in some cases, intended to limit the specific unit.
[0151] The functions described above in this document can be performed, at least in part, by one or more hardware logic components. For example, exemplary types of hardware logic components that can be used, without limitation, include: Field Programmable Gate Arrays (FPGAs), Application-Specific Integrated Circuits (ASICs), Application Standard Products (ASSPs), System-on-Chip (SoCs), Complex Programmable Logic Devices (CPLDs), and so on.
[0152] In the context of this disclosure, a computer-readable medium can be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. A computer-readable medium can be a computer-readable signal medium or a computer-readable storage medium. A computer-readable medium can be, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of computer-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.
[0153] The above description is merely a preferred embodiment of this disclosure and an explanation of the technical principles employed. Those skilled in the art should understand that the scope of this disclosure is not limited to technical solutions formed by specific combinations of the above-described technical features, but should also cover other technical solutions formed by arbitrary combinations of the above-described technical features or their equivalents without departing from the above-described concept. For example, technical solutions formed by substituting the above features with (but not limited to) technical features disclosed in this disclosure that have similar functions.
[0154] Furthermore, while the operations are described in a specific order, this should not be construed as requiring these operations to be performed in the specific order shown or in a sequential order. In certain environments, multitasking and parallel processing may be advantageous. Similarly, while several specific implementation details are included in the above discussion, these should not be construed as limiting the scope of this disclosure. Certain features described in the context of individual embodiments may also be implemented in combination in a single embodiment. Conversely, various features described in the context of a single embodiment may also be implemented individually or in any suitable sub-combination in multiple embodiments.
[0155] Although the subject matter has been described using language specific to structural features and / or methodological logic, it should be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or actions described above. Rather, the specific features and actions described above are merely illustrative examples of implementing the claims.
Claims
1. A method of video processing, the method comprising: The method comprises: displaying a video clip interface, the video clip interface comprising a material area and a timeline area, the material area displaying a plurality of transition identifiers, 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 triggering operation on a target transition identifier in the plurality of transition identifiers, determining that target adjacent video clips in a target video track are in the same level if the target video track has a free level function enabled, the free level function being used to indicate that a level of a video clip in each sub-track is the track number of the corresponding sub-track; in the case where the target video track does not have the free level function enabled and the levels of the adjacent video clips have the same level identifier, determining that the target adjacent video clips are in the same level; in the case where the target video track does not have the free level function enabled and the levels of the target adjacent video clips have different level identifiers, adjusting the target adjacent video clips to the same level so that the target adjacent video clips are in the same level, the target video track being a sub-track in the at least one video track; adding a transition between the target adjacent video clips based on the transition effect scheme indicated by the target transition identifier.
2. The method of claim 1, wherein, Before adding the transition between the target adjacent video clips based on the transition effect scheme indicated by the target transition identifier, the method comprises: in the case where the target triggering operation is a click operation, traversing the at least one video track, and determining a first adjacent video clip that can have a transition added as the target adjacent video clip during the traversal of the at least one video track; in the case where the target triggering operation is a drag operation, determining an adjacent video clip corresponding to an end position of a track of the drag operation as the target adjacent video clip.
3. The method of claim 1, wherein, The adjusting of the target adjacent video clips to the same level comprises: in the case where video pictures in a target time range are the same before and after the determination of the adjustment of the target adjacent video clips to the same level, adjusting the target adjacent video clips to the same level, the target time range being a time range corresponding to a video clip that is adjusted in level in the target adjacent video clips in the timeline area; in the case where the video pictures in the target time range are different before and after the determination of the adjustment of the target adjacent video clips to the same level, displaying prompt information, the prompt information comprising a first option and a second option, the first option being used to indicate the adjustment of the target adjacent video clips to the same level, and the second option being used to indicate the non-adjustment of the target adjacent video clips to the same level; in response to a triggering operation on the first option, adjusting the target adjacent video clips to the same level.
4. The method of claim 1, wherein, The target adjacent video clips comprise a first video clip and a second video clip, the level of the first video clip being lower than the level of the second video clip, and the level of the second video clip being a first level; The adjusting the target adjacent video clip to the same level comprises: in a case that the first video clip is accommodated in the region corresponding to the first level, adjusting the level of the first video clip to the first level; in a case that the first video clip is not accommodated in the region corresponding to the first level and the target adjacent video clip is accommodated in the region corresponding to the second level, adjusting the level of the target adjacent video clip to the second level, the second level being a previous level of the first level; in a case that the first video clip is not accommodated in the region corresponding to the first level and the target adjacent video clip is not accommodated in the region corresponding to the second level, newly creating a third level above the first level, and adjusting the level of the target adjacent video clip to the third level.
5. The method of claim 4, wherein, The adjusting the target adjacent video clip to the same level comprises: in a case that the first video clip is connected to other video clips through transitions, adjusting the target adjacent video clip and other video clips connected to the first video clip through transitions to the same level; in a case that the second video clip is connected to other video clips through transitions, adjusting the target adjacent video clip and other video clips connected to the second video clip through transitions to the same level.
6. The method of claim 1, wherein, The method further comprises: in response to an editing operation on a target video clip in the target adjacent video clips, performing corresponding processing on the target video clip and deleting a transition that is invalidated in response to the editing operation; the editing operation comprises any one of the following: a deletion operation, a paste operation, a move operation, a level adjustment operation, and a time length shortening operation.
7. The method of claim 6, wherein, in a case that the editing operation comprises a paste operation, a move operation, or a level adjustment operation, the corresponding processing comprises: in a case that a first to-be-determined level is accommodated in the region corresponding to the target video clip, determining the level of the target video clip to be the first to-be-determined level, in a case that the editing operation comprises a paste operation or a move operation, the first to-be-determined level being a level in which the target video clip is located before the editing operation, and in a case that the editing operation comprises a level adjustment operation, the first to-be-determined level being a level corresponding to the level adjustment operation; in a case that the first to-be-determined level is not accommodated in the region corresponding to the target video clip and a second to-be-determined level is accommodated in the region corresponding to the target video clip, determining the level of the target video clip to be the second to-be-determined level, the second to-be-determined level being a previous level of the first to-be-determined level; In a case where the first to-be-determined level and the second to-be-determined level cannot accommodate the target video clip, a third to-be-determined level is newly built above the first to-be-determined level, and the level of the target video clip is determined as the third to-be-determined level; In a case where the editing operation comprises a deletion operation, the corresponding processing comprises: deleting the target video clip; In a case where no video clip exists in the target level, video clips at levels greater than the target level are each lowered by one level, the target level being the level of the target video clip before the editing operation.
8. The method according to any one of claims 1 to 7, characterized in that, The method further comprises: In response to a trigger operation of adding a new video clip in the timeline area, determining that an initial level of the new video clip is a sum of a current maximum level in the timeline area and 1; In a case where regions corresponding to the new video clip in at least one continuous level below the initial level can accommodate the new video clip, determining that a final level of the new video clip is a minimum level in the at least one continuous level; In a case where a region corresponding to the new video clip in the current maximum level cannot accommodate the new video clip, determining that the final level of the new video clip is the initial level.
9. A video processing apparatus, comprising: comprise: a display module configured to display a video clip interface, the video clip interface comprising a material area and a timeline area, the material area displaying a plurality of transition identifiers, each transition identifier being used to indicate a transition effect scheme, and the timeline area comprising at least one video track; a processing module configured to, in response to a target trigger operation on a target transition identifier in the plurality of transition identifiers, determine that target adjacent video clips in a target video track corresponding to the target trigger operation are at a same level in a case where the target video track has a free level function enabled, the free level function being used to indicate that video clips in each sub-track are at a track number of a corresponding sub-track; determine that the target adjacent video clips are at the same level in a case where the target video track does not have the free level function enabled and levels of the target adjacent video clips have same level identifiers; adjust the target adjacent video clips to be at a same level in a case where the target video track does not have the free level function enabled and the levels of the target adjacent video clips have different level identifiers, the target video track being a sub-track in the at least one video track; add a transition between the target adjacent video clips based on a transition effect scheme indicated by the target transition identifier.
10. An electronic device, comprising: comprise: a memory and a processor, the memory being used to store a computer program, and the processor being used to execute the video processing method in any one of claims 1 to 8 when the computer program is invoked.
11. A computer readable storage medium, characterized in that, a computer program stored thereon, the computer program being executed by a processor to implement the video processing method in any one of claims 1 to 8.