Video stitching method, electronic device and program product
By identifying the missing time periods in the baseline video and using other videos to fill in the gaps, the problem of restoring multi-source videos in online contract signing was solved, generating a complete video with a continuous timeline and clear information.
Patent Information
- Application Number
- CN202511717935.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-21
- Publication Date
- 2026-02-24
AI Technical Summary
During the online signing process, due to the differences between different video capture terminals, how to reproduce a complete and coherent meeting video under multi-source video capture conditions has become an urgent technical problem to be solved.
By identifying the time gaps in the baseline video and using other videos to fill the gaps, a baseline video is determined using a preset baseline video determination rule. Combined with homology analysis and priority strategy, other video segments are cut to fill the gaps, generating a complete and coherent video.
It enables accurate differentiation between videos from the same source and different sources at low cost and high efficiency, ensuring that the generated videos are continuous and uninterrupted on the timeline, thus improving the credibility and integrity of the videos.
Smart Images

Figure CN121567916A_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to a video stitching method, electronic device, storage medium, and program product. Background Technology
[0002] With the rapid development of real estate transactions and contract signing services, the service model of contract signing centers has undergone a significant transformation from traditional offline signing to online signing. Specifically, the traditional offline signing model typically requires both parties to be present in person to complete negotiations and sign the contract face-to-face. Due to the increasing complexity of contract signing and the diversification of customer needs, the proportion of situations where both parties cannot be present simultaneously is gradually rising. This is particularly prominent in cross-regional transactions, scheduling conflicts, or other special scenarios. To address this issue, contract signing centers have introduced online signing functionality. Through audio and video communication technology, both parties can communicate, negotiate, and sign simultaneously from different locations, significantly improving the flexibility and efficiency of the signing process.
[0003] In traditional offline signing models, the signing process is typically recorded from a single source using a large-screen device at the signing center for archiving or subsequent review. However, with the introduction of online signing functionality, the sources of video capture for the signing process have become more complex. In addition to the videos recorded by the large-screen device at the signing center, videos recorded in online audio and video live streaming rooms have also been added.
[0004] However, since videos captured by different acquisition devices may differ, how to reconstruct a complete and coherent meeting video under multi-source video acquisition conditions has become an urgent technical problem to be solved. Summary of the Invention
[0005] This disclosure provides a video stitching method, electronic device, storage medium, and program product.
[0006] According to one aspect of this disclosure, a video stitching method is provided, which, in response to receiving a fusion instruction for multi-source videos, acquires the event time period of the acquisition object of the multi-source videos, the recording start time and recording end time of each video segment in the multi-source videos; determines a reference video from the multi-source videos using a preset reference video determination rule; the reference video determination rule includes a rule for evaluating the reference video based on at least one parameter of video duration, resolution, and frame rate; performs time gap detection based on the event time period, the recording start time and recording end time of each video segment of the reference video to obtain a gap time period; matches the gap time period with the recording start time and recording end time of each video segment of other videos in the multi-source videos besides the reference video to determine the cutting time range of other videos corresponding to the gap time period; and stitches the other videos with the reference video after video cutting based on the cutting time range of the other videos.
[0007] According to one technical solution, the missing time period of the reference video is identified by missing detection, and other videos are used to fill in the gap, thereby restoring the multi-source video into a complete and coherent video, which can solve the problem of multi-source video restoration caused by differences in different acquisition ends.
[0008] According to at least one embodiment of the video stitching method of this disclosure, the step of matching the gap time period with the recording start time and recording end time of each video segment of the other videos in the multi-source videos (excluding the reference video) to determine the cutting time range of the other videos corresponding to the gap time period includes: performing homology analysis on the other videos to obtain analysis results; in response to the analysis results being homology, matching the gap time period with the recording start time and recording end time of each video segment of the other videos in the multi-source videos (excluding the reference video) to determine the cutting time range of the other videos corresponding to the gap time period.
[0009] According to the technical solution of this embodiment, repeated completion can be avoided and invalid data processing can be reduced, thereby improving the efficiency of the gap completion process.
[0010] According to at least one embodiment of the video stitching method of this disclosure, the step of performing homology analysis on the other videos to obtain analysis results includes: performing homology analysis based on the path prefix of each video in the other videos to obtain analysis results; or performing homology analysis based on the filename of each video in the other videos to obtain analysis results; or performing homology analysis based on the metadata of each video in the other videos to obtain analysis results; or performing homology analysis based on the storage location of each video in the other videos to obtain analysis results.
[0011] According to the technical solution of this embodiment, it is possible to accurately distinguish between videos from the same source and videos from different sources under the premise of low cost and high efficiency, and to accurately and stably identify the source of video acquisition.
[0012] According to at least one embodiment of the video stitching method of this disclosure, in response to the analysis result being of different sources, the step of matching the gap time period with the recording start time and recording end time of each video segment of the other videos in the multi-source videos (excluding the reference video) to determine the cutting time range of the other videos corresponding to the gap time period further includes: obtaining the priority of the videos of different sources in the other videos; matching the gap time period with the recording start time and recording end time of each video segment of the highest priority video in the other videos to determine a first sub-cutting time range of the highest priority video corresponding to the gap time period; determining whether the first sub-cutting time range can cover the gap time period; and in response to the first sub-cutting time range being able to cover the gap time period, using the first sub-cutting time range as the cutting time range of the other videos.
[0013] According to the technical solution of this embodiment, high-quality, low-cost and efficient acquisition of gap video can be achieved.
[0014] According to at least one embodiment of the video stitching method of this disclosure, in response to the first sub-cutting time range not covering the gap time period, the step of matching the gap time period with the recording start time and recording end time of each video segment of other videos in the multi-source videos (excluding the reference video) to determine the cutting time range of other videos corresponding to the gap time period further includes: performing gap analysis based on the first sub-cutting time range and the gap time period to obtain the time period to be filled; matching the time period to be filled with the recording start time and recording end time of each video segment of the next priority video of the currently matched video in the other videos to determine the second sub-cutting time range of the next priority video corresponding to the time period to be filled; updating the first sub-cutting time range to the current first sub-cutting time range and the current second sub-cutting time range, and performing the step of determining whether the first sub-cutting time range can cover the gap time period until a cutoff condition is reached; and using the first sub-cutting time range and the second sub-cutting time range when the cutoff condition is reached as the cutting time range of the other videos.
[0015] According to the technical solution of this embodiment, high-quality, complete and efficient acquisition of gapped video can be achieved, which not only ensures coverage, but also ensures the continuity and consistency of the overall video.
[0016] According to at least one embodiment of the video stitching method of this disclosure, the step of stitching other videos with a reference video after cutting them based on the cutting time range of the other videos includes: determining whether the cutting time range of the other videos can cover the gap time period; in response that the cutting time range of the other videos can cover the gap time period, stitching the other videos with the reference video after cutting them based on the cutting time range of the other videos; in response that the cutting time range of the other videos cannot cover the gap time period, determining an uncovered time period based on the cutting time range of the other videos and the gap time period; generating an empty source video for the uncovered time period; and stitching the other videos with the reference video and the empty source video after cutting them based on the cutting time range of the other videos.
[0017] According to the technical solution of this embodiment, it is possible to ensure that even when the real video cannot completely cover the gap time period, a final video with complete time, smooth playback, and clear information is still generated, thereby ensuring that the final video is continuous and uninterrupted on the timeline and improving the credibility of the final video.
[0018] According to at least one embodiment of the video stitching method of this disclosure, generating the empty source video of the uncovered time period includes: generating the empty source video of the uncovered time period based on a static image; or, generating the empty source video of the uncovered time period based on a prompt text; or, generating the empty source video of the uncovered time period based on a video template.
[0019] According to the technical solution of this embodiment, it is possible to flexibly fill the gap time periods in different scenarios.
[0020] According to at least one embodiment of the video stitching method of this disclosure, the step of cutting the other videos based on the cutting time range of the other videos and then stitching them with the reference video includes: using a time fusion method to cut the other videos based on the cutting time range of the other videos and then stitching them with the reference video; or, providing the cutting time range of the other videos to a video processing tool, the video processing tool being used to cut the other videos according to the cutting time range of the other videos and then stitch them with the reference video.
[0021] According to the technical solution of this embodiment, the continuity of the video timeline and the integrity of the picture content can be guaranteed, thereby obtaining a complete and coherent video.
[0022] According to at least one embodiment of the video splicing method of this disclosure, before providing the cut time range of the other videos to the video processing tool, the step of cutting the other videos based on the cut time range of the other videos and then splicing them with the reference video further includes: generating a video list arranged in chronological order based on the cut time range of the other videos; the step of providing the cut time range of the other videos to the video processing tool includes: providing the video list to the video processing tool.
[0023] According to the technical solution of this embodiment, it is possible to generate videos with continuous timelines and complete visuals efficiently and accurately.
[0024] According to another aspect of this disclosure, an electronic device is provided, comprising: a memory storing execution instructions; and a processor executing the execution instructions stored in the memory, causing the processor to perform a video stitching method according to any embodiment of this disclosure.
[0025] According to another aspect of this disclosure, a readable storage medium is provided, wherein executable instructions are stored therein, which, when executed by a processor, are used to implement the video stitching method of any embodiment of this disclosure.
[0026] According to another aspect of this disclosure, a computer program product is provided, including a computer program that, when executed by a processor, implements a video stitching method according to any embodiment of this disclosure. Attached Figure Description
[0027] The accompanying drawings illustrate exemplary embodiments of the present disclosure and, together with the description thereof, serve to explain the principles of the present disclosure. These drawings are included to provide a further understanding of the present disclosure and are incorporated in and constitute a part of this specification.
[0028] Figure 1 This is a schematic diagram illustrating an application scenario of a video splicing method according to one embodiment of the present disclosure.
[0029] Figure 2 This is an illustrative interactive flowchart of a video stitching method according to one embodiment of the present disclosure.
[0030] Figure 3 yes Figure 2 The illustrated interactive flow of the gap-filling method in the video stitching method shown. Figure 1 .
[0031] Figure 4 yes Figure 3 The diagram shows an illustrative interactive flowchart of the homology analysis method in the gap-filling method.
[0032] Figure 5 yes Figure 2 The illustrated interactive flow of the gap-filling method in the video stitching method shown. Figure 2 .
[0033] Figure 6 yes Figure 2 The illustrated interactive flow of the gap-filling method in the video stitching method shown. Figure 3 .
[0034] Figure 7 yes Figure 2 The illustrated interactive flow of the cutting and splicing method in the video splicing method shown. Figure 1 .
[0035] Figure 8 yes Figure 2 The illustrated interactive flow of the cutting and splicing method in the video splicing method shown. Figure 2 .
[0036] Figure 9 yes Figure 2 The illustrated interactive flow of the cutting and splicing method in the video splicing method shown. Figure 3 .
[0037] Figure 10 yes Figure 2 The illustrated interactive flow of the cutting and splicing method in the video splicing method shown. Figure 4 .
[0038] Figure 11 yes Figure 2 The illustrated interactive flow of the cutting and splicing method in the video splicing method shown. Figure 5 .
[0039] Figure 12 This is an illustrative interactive flowchart of a video stitching method according to one embodiment of the present disclosure.
[0040] Figure 13 This is a schematic structural block diagram of a video splicing device according to one embodiment of the present disclosure.
[0041] Figure 14 This is a schematic structural block diagram of an electronic device according to one embodiment of the present disclosure. Detailed Implementation
[0042] The present disclosure will now be described in further detail with reference to the accompanying drawings and examples. It should be understood that the specific examples described herein are for illustrative purposes only and are not intended to limit the scope of the disclosure. Furthermore, it should be noted that, for ease of description, only the parts relevant to the present disclosure are shown in the accompanying drawings.
[0043] It should be noted that, where there is no conflict, the embodiments and features described in this disclosure can be combined with each other. The technical solutions of this disclosure will now be described in detail with reference to the accompanying drawings and embodiments.
[0044] Taking online real estate transactions as an example, both the buyer and seller can communicate in real time online to complete the signing. In this case, the video is recorded not only by the large screen equipment in the signing center but also by videos recorded in the online audio-visual live stream. The challenge now is to reconstruct the complete video from these recordings.
[0045] To this end, the present disclosure proposes the following technical solution, which enables the reconstruction of complete and coherent conference video under multi-source video acquisition conditions.
[0046] To facilitate description and make the technical solutions of this disclosure easier to understand, the terminology of this disclosure will be explained before describing the technical solutions of this disclosure.
[0047] Multi-source video refers to a collection of video data generated by two or more video acquisition devices or systems from different sources.
[0048] Homology analysis refers to the use of technologies such as computer vision, pattern recognition, and deep learning to compare video data in order to identify whether the videos have the same source.
[0049] A benchmark video refers to a video stream that serves as a reference standard for time synchronization and content alignment in a multi-source video collection.
[0050] Figure 1 A schematic diagram illustrating an application scenario of this disclosure is shown. In this application scenario, a user terminal 100 and a server 200 may be included. The user terminal 100 is connected to the server 200 via a network.
[0051] Figure 2 A schematic diagram illustrating the overall flow of a video stitching method according to one embodiment of this disclosure is shown. Figure 2 The video stitching method M200 shown includes steps S210 to S240. This method can be executed by an electronic device such as a server.
[0052] In step S210, in response to receiving the fusion instruction of the multi-source video, the event time period of the acquisition object of the multi-source video, the recording start time and recording end time of each video segment in the multi-source video are obtained.
[0053] In some embodiments of this disclosure, the multi-source videos in step S210 are typically videos of the same event, scene, or task, captured from different shooting devices, different network nodes, or different angles, such as asynchronous capture from multiple locations or capture from different media platforms. The fusion instruction in step S210 can be triggered by an event, task assignment, timed triggering, or manual operation.
[0054] The event time period of the multi-source video obtained in step S210 is the duration of the target event (i.e., the event, scene, or task that triggers the multi-source video capture) on the timeline, that is, the time interval in which the target event itself occurs. The recording start time of a video segment obtained in step S210 is the timestamp of the first video frame that the camera device begins to capture. The recording end time of a video segment obtained in step S210 is the timestamp of the last video frame that the camera device captures.
[0055] In step S210, the multi-source video can include videos recorded by the local terminal and remote interactive videos. Videos from different sources can be stored in different S3 buckets to improve video fusion efficiency. The IDs of the S3 buckets can be stored in a list, and their storage order can be set according to an agreement. For example, the base video is at the top, and other videos are in subsequent positions. Specifically, the remote interactive video can consist of multiple video streams, with different channels carrying different interactive elements. For example, one channel can carry the video feed of the contracting party, another channel can carry the video feed of a third party (such as an agent or administrator), and yet another channel can carry the video feed displayed on a large screen.
[0056] In step S220, a reference video is determined from the multi-source videos using a preset reference video determination rule.
[0057] In some embodiments of this disclosure, the reference video determination rule in step S220 is a criterion or algorithm used to determine which video among multiple sources serves as a reference. This reference video determination rule includes rules for evaluating the reference video based on at least one parameter among the video's duration, resolution, and frame rate.
[0058] Step S220 can apply the benchmark video judgment rules for evaluation, determine the score of each video in the multi-source videos, and select the video with the highest score as the benchmark video. In particular, to avoid rule misjudgment, after determining the benchmark video through step S220, the result can be submitted to human verification for further confirmation. If it is confirmed to be correct, step S230 is then executed; otherwise, the benchmark video is manually corrected or the benchmark video is re-determined through step S220.
[0059] In step S230, time gap detection is performed based on the event time period, the recording start time and recording end time of each video segment of the reference video, to obtain the gap time period.
[0060] In some embodiments of this disclosure, step S230 may compare the event time period with the time intervals of all video segments of the reference video and treat the uncovered time period as the gap time period.
[0061] In step S240, the gap time period is matched with the recording start time and recording end time of each video segment of the other videos in the multi-source videos, excluding the reference video, to determine the cutting time range of the other videos corresponding to the gap time period.
[0062] In some embodiments of this disclosure, step S240 may identify segments from other video clips that overlap with the gap time period and use the time range of the overlapping segments as the cutting time range. When multiple video clips are found to overlap with a certain time segment in the gap time period through step S240, step S240 may determine the cutting time range based on any one of them or by selecting a higher priority one according to priority.
[0063] Step S240 can first perform a segment search operation based on the gap time period, and then determine the cutting time range based on the found video segments. The segment search operation can include: finding all video segments in other videos whose start time is earlier than the start time of the first video segment of the reference video; finding all video segments in other videos whose end time is later than the end time of the last video segment of the reference video; finding all video segments in other videos that can cover the gap between two adjacent video segments of the reference video; finding video segments in other videos whose start time is earlier than the end time of the preceding video segment in two adjacent video segments and whose end time is later than the end time of the preceding video segment in two adjacent video segments; finding video segments in other videos whose start time is later than the end time of the preceding video segment in two adjacent video segments and whose end time is earlier than the start time of the following video segment in two adjacent video segments; and finding video segments in other videos whose start time is earlier than the start time of the following video segment in two adjacent video segments and whose end time is later than the start time of the following video segment in two adjacent video segments.
[0064] In step S250, other videos are cut based on their cutting time range and then spliced with the reference video.
[0065] In some embodiments of this disclosure, step S250 may splice the reference video and the cut video according to time.
[0066] The video stitching method disclosed herein identifies gap time periods in a reference video through gap detection and then uses other videos to fill in the gaps, thereby restoring multi-source videos into a complete and coherent video. This video stitching method solves the problem of multi-source video restoration caused by differences in different acquisition ends in existing technologies.
[0067] Regarding step S240, in some embodiments of this disclosure, it may include, for example... Figure 3 Steps S241 to S242 are shown.
[0068] In step S241, a homology analysis is performed on other videos to obtain the analysis results.
[0069] In some embodiments of this disclosure, step S241 can be used to determine whether the videos in other videos originate from the same acquisition end, thereby obtaining analysis results. The analysis results obtained through step S241 can be from the same source or different sources.
[0070] In step S242, in response to the analysis result being from the same source, the gap time period is matched with the recording start time and recording end time of each video segment of the other videos in the multi-source videos, excluding the reference video, to determine the cutting time range of the other videos corresponding to the gap time period.
[0071] In some embodiments of this disclosure, step S242 can identify segments from other video clips that overlap with the gap time period and use the time range of the overlapping segments as the cutting time range. When multiple video clips are found to overlap with a certain time segment in the gap time period through step S242, step S242 can determine the cutting time range based on any one of them or by selecting a higher priority one according to priority.
[0072] Steps S241 to S242 perform homology analysis during the gap filling process, which can avoid repeated filling and reduce invalid data processing, thereby improving the efficiency of the gap filling process.
[0073] Regarding step S241, in some embodiments of this disclosure, it may include, for example... Figure 4 The steps S2411, S2412, S2413, or S2414 shown.
[0074] In step S2411, a homology analysis is performed based on the path prefix of each video in the other videos to obtain the analysis results.
[0075] In some embodiments of this disclosure, step S2411 may obtain the complete path of each video in other videos, and after parsing and extracting the path prefix of the complete path of each video, perform homology analysis based on the path prefix. The path prefix may typically include the acquisition device number, acquisition location identifier, or storage node representation.
[0076] In particular, to make the homology analysis more accurate, stable and efficient, before parsing the complete path of each video, the complete path of each video can be normalized first to unify the path format, remove irrelevant information and retain the core identifiers, and then the normalized complete path of each video can be parsed separately.
[0077] In step S2412, a homology analysis is performed based on the filename of each video in the other videos to obtain the analysis results.
[0078] In some embodiments of this disclosure, step S2412 may obtain the complete path of each video in other videos, extract the filename from the complete path of each video, then parse the acquisition terminal information in the filename, and finally perform a homology analysis based on the acquisition terminal information. For example, videos with the same acquisition terminal identifier in the acquisition terminal information are considered to be of the same origin, and videos with different acquisition terminal identifiers in the acquisition terminal information are considered to be of different origins.
[0079] In step S2413, a homology analysis is performed based on the metadata of each video in the other videos to obtain the analysis results.
[0080] In some embodiments of this disclosure, the video metadata in step S2413 may include relevant information about the acquisition device (such as unique device ID, device model, manufacturer, firmware version, etc.), recording information (such as recording start time, recording end time, frame rate, resolution, bit rate, etc.), and encoding and encapsulation information (such as encoding format, encapsulation format, etc.). Step S2413 can use a video processing library or metadata extraction tool to extract metadata from each video in other videos, and then perform homology analysis based on the metadata.
[0081] In particular, before performing homology analysis based on metadata, the metadata can be normalized first to eliminate format differences, improve matching accuracy, enhance compatibility, and reduce false positives and false negatives.
[0082] In step S2414, a homology analysis is performed based on the storage location of each video in the other videos to obtain the analysis results.
[0083] In some embodiments of this disclosure, step S2414 may use the file system interface of the operating system or programming language, in conjunction with the management system, to locate the storage location of each video in other videos, and then perform a homology analysis based on the storage location. This storage location may include server IP, network shared path, disk volume label, directory structure, etc.
[0084] In particular, before performing homology analysis based on storage location, the storage location can be normalized to remove dynamic parts unrelated to the acquisition end (such as date, temporary folders, etc.) and retain the core storage node or device identifier.
[0085] Step S2411, S2412, S2413, or S2414 can accurately distinguish between videos from the same source and videos from different sources under the premise of low cost and high efficiency, and accurately and stably identify the source of video acquisition.
[0086] Regarding step S240, in some embodiments of this disclosure, in response to the analysis results being from different sources, it may further include, as follows: Figure 5 Steps S243 to S246 are shown.
[0087] In step S243, the priority of videos from different sources in other videos is obtained.
[0088] In some embodiments of this disclosure, step S243 may determine priority based on evaluation metrics (such as time coverage, device credibility, etc.) of videos from different sources in other videos.
[0089] In step S244, the start and end times of recording for each video segment of the highest priority video in the other videos are matched to determine the first sub-cut time range of the highest priority video corresponding to the gap time period.
[0090] In some embodiments of this disclosure, step S244 may identify segments that overlap with the gap time period from video segments of the highest priority video among other videos, and use the time range of the overlapping segments as the first sub-cut time range.
[0091] In step S245, it is determined whether the first sub-shearing time range can cover the gap time period.
[0092] In some embodiments of this disclosure, step S245 can determine whether the first sub-shearing time range can cover the gap time period by comparing the start and end times of the first sub-shearing time range and the gap time period.
[0093] In step S246, in response to the fact that the first sub-cut time range can cover the gap time period, the first sub-cut time range is used as the cut time range for other videos.
[0094] Steps S243 to S246 enable the acquisition of the shearing time range in a high-quality, low-cost, and efficient manner.
[0095] Regarding step S240, in some embodiments of this disclosure, in response to the first sub-shearing time range not covering the gap time period, it may further include, as follows: Figure 6 Steps S247 to S251 are shown.
[0096] In step S247, gap analysis is performed based on the first sub-shear time range and the gap time period to obtain the time period to be filled.
[0097] In some embodiments of this disclosure, step S247 can determine the time period to be filled by comparing the first sub-shear time range with the start and end times of the gap time period.
[0098] In step S248, the recording start time and recording end time of each video segment of the next priority video of the video currently being matched with other videos are matched to determine the second sub-cut time range corresponding to the next priority video of the time period to be filled.
[0099] In some embodiments of this disclosure, step S247 can determine the second sub-cut time range by comparing the time period to be filled with the start and end times of the next priority video.
[0100] In step S249, the first sub-shear time range is updated to the current first sub-shear time range and the current second sub-shear time range.
[0101] In some embodiments of this disclosure, after updating the first sub-cutting time range in step S249, step S245 is executed until a cutoff condition is met. This cutoff condition can be, for example, no available video for completion, or the maximum number of iterations.
[0102] In step S251, the first sub-cutting time range and the second sub-cutting time range when the cutoff condition is met are used as the cutting time ranges for other videos.
[0103] Steps S247 to S251 employ a priority-based iterative completion strategy to obtain the cut time range, which enables high-quality, complete, and efficient acquisition of the cut time range, ensuring both coverage and the overall video's coherence and consistency.
[0104] Regarding step S250, in some embodiments of this disclosure, it may include, for example... Figure 7 Steps S252 to S256 are shown.
[0105] In step S252, it is determined whether the cut time range of other videos can cover the gap time period.
[0106] In some embodiments of this disclosure, step S252 can determine whether the cut time range of other videos can cover the gap time period by comparing the start and end times of the gap time period with the cut time range of other videos.
[0107] If step S252 determines that the cutting time range of other videos can cover the gap time period, proceed to step S253. If step S252 determines that the cutting time range of other videos cannot cover the gap time period, proceed to step S254.
[0108] In step S253, other videos are cut based on their cutting time range and then spliced with the reference video.
[0109] In step S254, the uncovered time period is determined based on the cut time range and gap time period of other videos.
[0110] In some embodiments of this disclosure, step S254 can determine the uncovered time period by comparing the start and end times of the gap time period with the cut time ranges of other videos. That is, the uncovered time period is the time interval within the gap time period that is not covered by the cut time ranges of other videos.
[0111] In step S255, an empty source video for the uncovered time period is generated.
[0112] In some embodiments of this disclosure, the material used for the empty source video obtained through step S255 can be from static images (such as meeting background images, company logos, meeting agenda images, etc.), looping videos (such as panoramic views of the meeting room, fixed-angle monitoring videos, etc.), and prompt images (such as "Video missing during this time period" or "Signal interrupted, please wait" and other letter backgrounds).
[0113] In step S256, other videos are cut based on their cutting time range and then spliced with the reference video and the empty source video.
[0114] Steps S252 to S256 ensure that even when the real video cannot fully cover the gap in time, a final video with complete time, smooth playback, and clear information is still generated, thereby ensuring that the final video is continuous and uninterrupted on the timeline and improving the credibility of the final video.
[0115] Regarding step S255, in some embodiments of this disclosure, it may include, for example... Figure 8 Any of the following steps shown.
[0116] Generate empty source video for uncovered time periods based on static images; or, Generate an empty source video for the uncovered time period based on the prompt text; or, Generate empty source videos for periods not covered by video templates.
[0117] In some embodiments of this disclosure, static images, i.e., single-frame image files, are used as placeholder images, suitable for short gaps, providing stable visuals and small file sizes. Prompt text, i.e., a piece of text displayed in the video, is typically overlaid on a uniform background, suitable for clearly conveying information and reducing misunderstandings. Video templates are usually pre-made, reusable video clips, suitable for longer gaps or situations requiring integration with the overall video style.
[0118] The above steps are used to obtain empty source video. The technology is simple to implement and has low resource consumption, and it can flexibly fill the gap time periods in different scenarios.
[0119] Regarding step S250, in some embodiments of this disclosure, it may include, for example... Figure 9 Step S257 is shown.
[0120] In step S257, a time fusion method is used to cut other videos based on the cutting time range of other videos and then splice them with the reference video.
[0121] In some embodiments of this disclosure, step S257 may involve sequentially splicing the reference video and the cut video in chronological order.
[0122] By performing video fusion in step S257, the continuity of the video timeline and the integrity of the video content can be guaranteed, thus obtaining a complete and coherent video.
[0123] Regarding step S250, in some embodiments of this disclosure, it may also include, as follows: Figure 10 Step S258 is shown.
[0124] In step S258, the cutting time range of other videos is provided to the video processing tool, which then cuts the other videos according to the cutting time range and splices them with the reference video.
[0125] Step S258 uses video processing tools to splice videos, which can efficiently and accurately generate videos with continuous timelines and complete visuals.
[0126] At this point, before step S258, the following may also be included: Figure 11 Step S259 is shown.
[0127] In step S259, a video list arranged in chronological order is generated based on the cut time range of other videos.
[0128] At this point, step S258 specifically involves providing the video list to the video processing tool.
[0129] Step S258 utilizes a video list in video stitching, which helps to achieve accurate stitching of multi-source videos, improving the quality of the final video and processing efficiency.
[0130] The video stitching method disclosed herein can reconstruct a complete video according to the timeline of events by intelligently, efficiently, and completely selecting and marking multiple source videos, regardless of whether there is time overlap between the multiple source videos, thus ensuring the continuity and accuracy of the video.
[0131] Figure 12 An exemplary flowchart based on the video stitching method of this disclosure is shown.
[0132] Figure 12 In the flowchart shown, taking a real estate contract signing scenario as an example, the video fusion process may include steps S310 to S350.
[0133] In step S310, in response to receiving the fusion instruction of the multi-source video, the event time period of the acquisition object of the multi-source video, the recording start time and recording end time of each video segment in the multi-source video are obtained.
[0134] In some embodiments of this disclosure, the multi-source video in step S310 may include video recorded on the large screen of the signing center (hereinafter referred to as large screen video) and video recorded in the online audio and video live broadcast room (hereinafter referred to as live video). The event time period of the multi-source video is the time from the start to the end of a real estate event. Both the large screen video and the live video may include one or more video segments, and the start time and end time of recording of a video segment are the timestamps of when the relevant device starts capturing video and stops capturing video.
[0135] In step S320, a reference video is determined from the multi-source videos using a source-based reference video determination rule.
[0136] In some embodiments of this disclosure, since large-screen videos are usually stored locally on the large screen and then uploaded to the video fusion terminal, there may be issues such as packet loss. Therefore, the benchmark video judgment rule based on the source can determine that live video is more reliable, and large-screen video is considered a supplement to live video.
[0137] In step S330, time gap detection is performed based on the event time period, the start time of recording of each video segment of the live video, and the end time of recording to obtain the gap time period.
[0138] In some embodiments of this disclosure, step S330 can subtract the start and end times of recording for each video segment of the live video from the event time period to obtain the gap time period.
[0139] In step S340, the gap time period is matched with the recording start time and recording end time of each video segment of the other videos in the multi-source videos, excluding the reference video, to determine the cutting time range of the other videos corresponding to the gap time period.
[0140] In some embodiments of this disclosure, step S340 can classify the gap time periods into a first time period before the start time of recording the first video segment of the live video, a second time period consisting of the gaps between every two adjacent video segments in the live video, and a third time period after the end time of recording the last video segment of the live video. For the first time period, the corresponding cut time range can be determined based on all video segments in the large-screen video whose start time is earlier than the end time of the first time period. For the second time period, the corresponding cut time range can be determined based on video segments in the large-screen video that can completely cover the time period, or based on video segments in the large-screen video that can cover a portion of the time period. For the third time period, the corresponding cut time range can be determined based on video segments in the large-screen video whose end time is later than the end time of recording of the time period. The above cut time ranges together constitute the cut time ranges for other videos corresponding to the gap time periods.
[0141] In step S350, other videos are cut based on their cutting time range and then spliced with the reference video.
[0142] In some embodiments of this disclosure, step S350 can directly stitch the reference video and the cut video together according to the time sequence. In particular, when the cut video and the reference video cannot completely cover the missing time period, the missing part can be supplemented by an empty source video.
[0143] When supplementary videos come from multiple sources, the system can intelligently analyze which video should be used for which time period. When multiple videos are available for supplementation within a certain time period, the system can determine the cutting time range of the video with higher priority. When no video is available for supplementation within a certain time period, an empty source video can be used as a supplement.
[0144] Taking a multi-source video as an example, the first source video includes two video segments: 18:10:00-18:12:59 and 18:13:00-18:14:59, and the second source video includes two video segments: 18:03:00-18:06:59 and 18:07:00-18:09:59. When the first source video is the base video, assuming the meeting time is 18:01:00-18:16:59, using the video splicing method provided in this disclosure, the gap time periods are 18:01:00-18:09:59 and 18:15:00-18:16:59. The segment times of the second source video can all be used as the cutting time range.
[0145] Taking a multi-source video as an example, the first source video includes two video segments: 18:10:00-18:12:59 and 18:13:00-18:14:59; the second source video includes one video segment: 18:03:00-18:05:59; the third source video includes two video segments: 18:04:00-18:10:59 and 18:11:00-18:15:59; and the fourth source video includes one video segment: 18:13:00-18:16:59. The first source video is the base video, and the videos from the second, third, and fourth sources are prioritized. When the time interval decreases, assuming the meeting time is 18:01:00-18:18:59, using the video splicing method provided in this disclosure, the gap time intervals are 18:01:00-18:09:59 and 18:15:00-18:18:59. The video segments from the second source can all be used as the cutting time range. In the video from the third source, 18:06:00-18:09:59 and 18:15:00-18:15:59 can all be used as the cutting time range. In the video from the fourth source, 18:16:00-18:16:59 can be used as the cutting time range.
[0146] Taking a multi-source video as an example, where the first source video includes two video segments 18:10:00-18:12:59 and 18:13:00-18:14:59, and the second source video includes two video segments 18:15:00-18:16:59 and 18:17:00-18:19:59, and the first source video is the base video, assuming the meeting time is 18:08:00-18:21:59, using the video splicing method provided in this disclosure, the gap time periods are 18:08:00-18:09:59 and 18:15:00-18:21:59, and the segment times of the second source video can all be used as the cutting time range.
[0147] Taking a multi-source video as an example, where the first source video includes two video segments, 18:10:00-18:12:59 and 18:13:00-18:14:59, and the second source video includes one video segment, 18:03:00-18:20:59, and the first source video is the base video, assuming the meeting time is 18:01:00-18:22:59, using the video splicing method provided in this disclosure, the gap time periods are 18:01:00-18:09:59 and 18:15:00-18:22:59. In the second source video, 18:03:00-18:09:59 and 18:15:00-18:20:59 can be used as the cutting time range.
[0148] Taking a multi-source video as an example, where the first source video includes two video segments (18:10:00-18:12:59 and 18:13:00-18:14:59), the second source video includes two video segments (18:01:00-18:02:59 and 18:03:00-18:08:59), and the third source video includes one video segment (18:05:00-18:11:59), with the first source video serving as the base video and the second and third source videos having decreasing priority, assuming the meeting time is 17:59:00-18:16:59, using the video splicing method provided in this disclosure, the gap time periods are 17:59:00-18:09:59 and 18:15:00-18:16:59. The entire time segment of the second source video can be used as the cutting time range, and 18:09:00-18:09:59 in the third source video can be used as the cutting time range.
[0149] Taking a multi-source video as an example, where the first source video includes two video segments, 18:10:00-18:12:59 and 18:13:00-18:15:59, and the second source video includes one video segment, 18:11:00-18:14:59, and the first source video is used as the base video, assuming the meeting time is 18:08:00-18:18:59, using the video splicing method provided in this disclosure, the gap time periods are 18:08:00-18:09:59 and 18:16:00-18:18:59. The second source video cannot be used as the gap video and can be directly used to fill in the gap video.
[0150] Taking a video from the first source in a multi-source video as an example, which includes a video segment from 17:30:00 to 18:00:59, and a video from the second source as an example, where the video from the first source is the base video, assuming the meeting time is 18:00:00 to 18:18:59, using the video splicing method provided in this disclosure, the gap time period is 18:01:00 to 18:18:59, and the segment time of the video from the second source can all be used as the cutting time range.
[0151] Taking a multi-source video as an example, where the first source video includes a video segment from 18:05:00 to 18:35:00 and the second source video includes a video segment from 18:02:00 to 18:07:00, and the first source video is the base video, assuming the meeting time is 18:00:00 to 18:30:00, using the video splicing method provided in this disclosure, the gap time period is 18:00:00 to 18:04:59. The segment time of the second source video, 18:02:00 to 18:04:59, can be used as the cutting time range.
[0152] The video clip ends at XX:XX:59, and the video clip contains the complete footage at the 59th second.
[0153] This disclosure also provides a video splicing apparatus (corresponding to a video splicing method). Figure 13 A schematic diagram of the hardware implementation using the processing system is shown.
[0154] like Figure 14 As shown, the hardware architecture of electronic devices / devices can be implemented using a bus architecture. The bus architecture can include any number of interconnect buses and bridges, depending on the specific application and overall design constraints of the hardware. Bus 1100 connects various circuits including one or more processors 1200, memory 1300, and / or hardware modules. Bus 1100 can also connect various other circuits 1400 such as peripherals, voltage regulators, power management circuits, external antennas, etc. Bus 1100 can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Component (EISA) bus, etc. Buses can be categorized as address buses, data buses, control buses, etc. For ease of illustration, only one connection line is used in this figure, but this does not indicate that there is only one bus or one type of bus.
[0155] For ease of explanation, certain steps of the above method are described in relation to modules. It should be understood that the corresponding module performing one or more steps of the above method may be one or more hardware modules specifically configured to perform the corresponding step, or implemented by a processor configured to perform the corresponding step, or stored in a computer-readable medium for implementation by a processor, or implemented by some combination thereof.
[0156] like Figure 13 As shown, the video splicing device includes a time acquisition module 1010, a video judgment module 1020, a gap detection module 1030, a range determination module 1040, and a video splicing module 1050.
[0157] The time acquisition module 1010 is used to acquire the event time period of the acquisition object of the multi-source video, the recording start time and recording end time of each video segment in the multi-source video in response to receiving the fusion instruction of the multi-source video.
[0158] The video determination module 1020 is used to determine a reference video from multiple source videos using preset reference video determination rules; the reference video determination rules include rules for evaluating the reference video based on at least one of the parameters of video duration, resolution and frame rate.
[0159] The gap detection module 1030 is used to detect time gaps based on the event time period, the start time of recording and the end time of recording each video segment of the reference video, and obtain the gap time period.
[0160] The range determination module 1040 is used to match the gap time period with the recording start time and recording end time of each video segment of the other videos in the multi-source videos, excluding the reference video, to determine the cutting time range of the other videos corresponding to the gap time period.
[0161] The video stitching module 1050 is used to cut other videos based on their cutting time range and then stitch them with a reference video.
[0162] The specific implementation of each module in the above-mentioned device can be referred to the implementation process of the corresponding steps in the above-mentioned method implementation method of this disclosure, and will not be repeated here.
[0163] This disclosure also provides a readable storage medium storing a computer program that, when executed by a processor, is used to implement the methods described above. A "readable storage medium" can be any means capable of containing, storing, communicating, propagating, or transmitting a program for use by or in conjunction with an instruction execution system, apparatus, or device. More specific examples of a readable storage medium include: an electrical connection with one or more wires (electronic device), a portable computer disk drive (magnetic device), random access memory (RAM), read-only memory (ROM), erasable and programmable read-only memory (EPROM or flash memory), fiber optic devices, and portable read-only memory (CDROM), etc.
[0164] This disclosure also provides a computer program product, the methods of which can be implemented wholly or partially through software, hardware, firmware, or any combination thereof. When implemented in software, it can be implemented wholly or partially as a computer program product. The computer program product includes one or more computer programs or instructions. When the computer program or instructions are loaded and executed, all or part of the processes or functions of this disclosure are performed.
[0165] Computer programs or instructions can be stored in a readable storage medium or transferred from one readable storage medium to another. For example, the computer program or instructions can be transferred from one website, computer, server, or data center to another website, computer, server, or data center via wired or wireless means. The readable storage medium can be any available medium capable of access, or a data storage device such as a server or data center that integrates one or more available media. The available medium can be a magnetic medium, such as a floppy disk, hard disk, or magnetic tape; an optical medium, such as a digital video optical disc; or a semiconductor medium, such as a solid-state drive. The computer-readable storage medium can be a volatile or non-volatile storage medium, or it can include both volatile and non-volatile types of storage media.
[0166] Those skilled in the art will understand that embodiments of this disclosure can be provided as methods, systems, or computer program products. Therefore, this disclosure can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this disclosure can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0167] This disclosure is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to this disclosure. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0168] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0169] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0170] In the description of this specification, the references to terms such as "one embodiment / mode," "some embodiments / modes," "example," "specific example," or "some examples," etc., refer to specific features, structures, or characteristics described in connection with that embodiment / mode or example, which are included in at least one embodiment / mode or example of this disclosure. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment / mode or example. Moreover, the specific features, structures, or characteristics described may be combined in any suitable manner in one or more embodiments / modes or examples. Furthermore, without contradiction, those skilled in the art can combine and integrate the different embodiments / modes or examples described in this specification, as well as the features of different embodiments / modes or examples.
[0171] Those skilled in the art should understand that the above embodiments are merely for illustrating the present disclosure and are not intended to limit the scope of the disclosure. Those skilled in the art can make other changes or modifications based on the above disclosure, and these changes or modifications still fall within the scope of the present disclosure.
Claims
1. A video stitching method, characterized in that, include: In response to receiving a multi-source video fusion instruction, the event time period of the acquisition object of the multi-source video, the recording start time and recording end time of each video segment in the multi-source video are obtained; A reference video is determined from the multi-source videos using a preset reference video determination rule; The benchmark video determination rules include rules for evaluating benchmark videos based on at least one of the following parameters: video duration, resolution, and frame rate. Based on the event time period, the start and end times of recording for each video segment of the reference video, time gap detection is performed to obtain the gap time period; The gap time period is matched with the recording start and end times of each video segment in the multi-source videos (excluding the reference video) to determine the cutting time range of the other videos corresponding to the gap time period; and The other videos are cut based on their cut time range and then spliced with the reference video.
2. The video stitching method as described in claim 1, characterized in that, The step of matching the gap time period with the recording start and end times of each video segment in the multi-source videos (excluding the reference video) to determine the cutting time range of the other videos corresponding to the gap time period includes: The other videos were subjected to homology analysis, and the analysis results were obtained; and In response to the analysis result indicating a common source, the gap time period is matched with the recording start time and recording end time of each video segment in the multi-source videos other than the reference video to determine the cutting time range of the other videos corresponding to the gap time period.
3. The video stitching method as described in claim 2, characterized in that, The process of performing homology analysis on the other videos to obtain analysis results includes: Based on the path prefixes of each of the other videos, a homology analysis is performed to obtain the analysis results; or, A homology analysis is performed on the filenames of each of the other videos to obtain the analysis results; or, A homology analysis is performed on the metadata of each of the other videos to obtain the analysis results; or, Based on the storage location of each of the other videos, a homology analysis was performed to obtain the analysis results.
4. The video stitching method as described in claim 2, characterized in that, In response to the analysis result indicating different sources, the step of matching the gap time period with the recording start and end times of each video segment in the multi-source videos (excluding the reference video) to determine the cut time range of the other videos corresponding to the gap time period further includes: Obtain the priority of videos from different sources among the other videos; The gap time period is matched with the recording start time and recording end time of each video segment of the highest priority video among the other videos to determine the first sub-cut time range corresponding to the highest priority video of the gap time period; Determine whether the first sub-shearing time range can cover the gap time period; and In response to the fact that the first sub-cut time range can cover the gap time period, the first sub-cut time range is used as the cut time range for the other videos.
5. The video stitching method as described in claim 4, characterized in that, In response to the first sub-cutting time range not covering the gap time period, the step of matching the gap time period with the recording start time and recording end time of each video segment of the other videos in the multi-source videos (excluding the reference video) to determine the cutting time range of the other videos corresponding to the gap time period further includes: Based on the first sub-shearing time range and the gap time period, gap analysis is performed to obtain the time period to be filled; The recording start time and recording end time of each video segment of the next priority video of the currently matched video in the other videos are matched to determine the second sub-cut time range corresponding to the next priority video of the time period to be filled. Update the first sub-shear time range to the current first sub-shear time range and the current second sub-shear time range, and perform the determination that the first sub-shear time range can cover the gap time period until the cutoff condition is met; and The first and second sub-cutting time ranges when the cutoff condition is met are used as the cutting time ranges for the other videos.
6. The video stitching method as described in claim 1, characterized in that, The step of cropping the other videos based on their cutting time ranges and then stitching them together with the reference video includes: Determine whether the cut time range of the other videos can cover the gap time period; In response to the fact that the cutting time range of the other videos can cover the gap time period, the other videos are cut based on the cutting time range of the other videos and then spliced with the reference video; In response to the fact that the cut time range of the other videos cannot cover the gap time period, the uncovered time period is determined based on the cut time range of the other videos and the gap time period; Generate empty source video for the uncovered time period; and After cropping the other videos based on their cutting time range, the videos are then spliced together with the reference video and the empty source video.
7. The video stitching method according to any one of claims 1 to 6, characterized in that, The step of cropping the other videos based on their cutting time ranges and then stitching them together with the reference video includes: A temporal fusion method is used to cut the other videos based on their cut time ranges, and then splices them with the reference video; or... The video processing tool provides the cutting time range of the other videos to the video processing tool, which then cuts the other videos according to the cutting time range and splices them with the reference video.
8. The video stitching method as described in claim 7, characterized in that, Before providing the cutting time range of the other videos to the video processing tool, the step of cutting the other videos based on the cutting time range of the other videos and then splicing them with the reference video further includes: generating a video list arranged in chronological order according to the cutting time range of the other videos; Providing the cut time range of the other videos to the video processing tool includes: providing the video list to the video processing tool.
9. An electronic device, characterized in that, include: The memory stores execution instructions; as well as A processor that executes execution instructions stored in the memory, causing the processor to perform the video stitching method according to any one of claims 1 to 8.
10. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by the processor, it implements the video stitching method according to any one of claims 1 to 8.