Video processing method, device, electronic device and storage medium

By extracting target objects during video processing and generating dynamic background plates and fusion processing, the problem that special effects videos in the existing technology cannot meet personalized needs is solved, and the richness of video content and user experience are improved.

CN115002359BActive Publication Date: 2024-10-11BEIJING ZITIAO NETWORK TECH CO LTD
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202210567327.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-05-23
Publication Date
2024-10-11
Estimated Expiration
2042-05-23

AI Technical Summary

Technical Problem

The existing special effects video production function cannot meet the personalized needs of users, resulting in poor video content and poor user experience.

Method used

By extracting the target object in the video frame to be processed and generating a dynamically changing image background plate, the target object and the background plate are merged and processed to generate a special effects video frame until an operation to stop shooting the special effects video is received.

Benefits of technology

It realizes personalized display of background images, improves the richness of video content and user experience, and enhances the attractiveness of application software.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115002359B_ABST
    Figure CN115002359B_ABST
Patent Text Reader

Abstract

The disclosed embodiments provide a video processing method, device, electronic device and storage medium. The method includes: extracting a target object in a video frame to be processed in response to a special effect trigger operation; fusing the target object with an image background plate including at least one image to be displayed to obtain a special effect video frame and display it, wherein the display content and / or display angle of the image background plate relative to the target object changes dynamically. The technical solution provided by the disclosed embodiments solves the problem in the prior art that the special effect video content cannot meet the personalized needs of users, resulting in poor video content and poor user experience, and realizes that the image background plate is generated based on the image to be displayed selected by the user, which satisfies the effect of personalized display of the background image. Furthermore, it can improve the attractiveness of the application software to users, thereby improving the effect of user stickiness.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

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

[0002] With the development of network technology, more and more applications have entered the lives of users, especially a series of software that can shoot short videos, which are deeply loved by users.

[0003] In order to increase the fun of video shooting, relevant application software can provide users with a variety of special effects video production functions. However, the special effects video production functions currently provided to users are very limited, and the fun of the final special effects video needs to be further improved. At the same time, the personalized needs of users who want to change the background picture in the video are not taken into account, thereby reducing the user experience. Summary of the invention

[0004] The present disclosure provides a video processing method, device, electronic device and storage medium to achieve the effect of improving the richness of video content on the basis of satisfying personalized needs of background images.

[0005] In a first aspect, an embodiment of the present disclosure provides a video processing method, the method comprising:

[0006] In response to the special effect triggering operation, extracting the target object in the video frame to be processed;

[0007] generating an image background plate including at least one image to be displayed;

[0008] The target object is fused with the image background plate to obtain a special effect video frame and display it;

[0009] Wherein, the display content and / or display angle of the image background board relative to the target object changes dynamically.

[0010] In a second aspect, an embodiment of the present disclosure further provides a video processing device, the device comprising:

[0011] An object extraction module, used for extracting a target object in a video frame to be processed in response to a special effect trigger operation;

[0012] A background plate generating module, used to generate an image background plate including at least one image to be displayed;

[0013] A video generation module, used for fusing the target object with the image background plate to obtain and display a special effect video frame;

[0014] The display content and / or display angle of the image background board relative to the target object is dynamically changed. In a third aspect, the embodiment of the present disclosure further provides an electronic device, characterized in that the electronic device comprises:

[0015] one or more processors;

[0016] a storage device for storing one or more programs,

[0017] When the one or more programs are executed by the one or more processors, the one or more processors implement the video processing method as described in any one of the embodiments of the present disclosure.

[0018] In a fourth aspect, the embodiments of the present disclosure further provide a storage medium comprising computer executable instructions, wherein the computer executable instructions are used to execute the video processing method as described in any one of the embodiments of the present disclosure when executed by a computer processor.

[0019] The technical solution provided by the embodiment of the present disclosure can extract the target object in the video frame to be processed in response to the special effect trigger operation, and after generating an image background plate including at least one image to be displayed, the target object can be fused with the image background plate to obtain the special effect video frame and display it until the operation of stopping the special effect video shooting is received. This solves the problem in the prior art that the special effect video content cannot meet the personalized needs of users, resulting in poor video content and poor user experience. The image background plate is generated based on the image to be displayed selected by the user, which meets the effect of personalized display of the background image. Further, the attractiveness of the application software to users can be improved, thereby improving user satisfaction. BRIEF DESCRIPTION OF THE DRAWINGS

[0020] The above and other features, advantages and aspects of the embodiments of the present disclosure will become more apparent with reference to the following detailed description in conjunction with the accompanying drawings. Throughout the accompanying drawings, the same or similar reference numerals represent the same or similar elements. It should be understood that the drawings are schematic and the originals and elements are not necessarily drawn to scale.

[0021] Figure 1 A schematic diagram of a video processing method provided by an embodiment of the present disclosure;

[0022] Figure 2 A schematic diagram of the effect of a special effect video frame provided by an embodiment of the present disclosure;

[0023] Figure 3 A schematic diagram of a video processing method provided by an embodiment of the present disclosure;

[0024] Figure 4 A schematic diagram of the structure of a video processing device provided by an embodiment of the present disclosure;

[0025] Figure 5 A schematic diagram of the structure of an electronic device provided by an embodiment of the present disclosure. DETAILED DESCRIPTION

[0026] Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although certain embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure can be implemented in various forms and should not be construed as being limited to the embodiments described herein, which are instead provided for a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the present disclosure are only for exemplary purposes and are not intended to limit the scope of protection of the present disclosure.

[0027] It should be understood that the various steps described in the method embodiments of the present disclosure may be performed in different orders and / or in parallel. In addition, the method embodiments may include additional steps and / or omit the steps shown. The scope of the present disclosure is not limited in this respect.

[0028] The term "including" and its variations used herein are open inclusions, i.e., "including but not limited to". The term "based on" means "based at least in part on". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments". The relevant definitions of other terms will be given in the following description.

[0029] It should be noted that the concepts such as "first" and "second" mentioned in the present disclosure are only used to distinguish different devices, modules or units, and are not used to limit the order or interdependence of the functions performed by these devices, modules or units.

[0030] It should be noted that the modifications of "one" and "plurality" mentioned in the present disclosure are illustrative rather than restrictive, and those skilled in the art should understand that unless otherwise clearly indicated in the context, it should be understood as "one or more".

[0031] The names of the messages or information exchanged between multiple devices in the embodiments of the present disclosure are only used for illustrative purposes and are not used to limit the scope of these messages or information.

[0032] It is understandable that before using the technical solutions disclosed in the embodiments of the present disclosure, the types, scope of use, usage scenarios, etc. of the personal information involved in the present disclosure should be informed to the user and the user's authorization should be obtained in an appropriate manner in accordance with relevant laws and regulations.

[0033] For example, in response to receiving an active request from a user, a prompt message is sent to the user to clearly prompt the user that the operation requested to be performed will require obtaining and using the user's personal information. Thus, the user can autonomously choose whether to provide personal information to software or hardware such as an electronic device, application, server, or storage medium that performs the operation of the technical solution of the present disclosure according to the prompt message.

[0034] As an optional but non-limiting implementation, in response to receiving an active request from the user, the prompt information may be sent to the user in the form of a pop-up window, in which the prompt information may be presented in text form. In addition, the pop-up window may also carry a selection control for the user to choose "agree" or "disagree" to provide personal information to the electronic device.

[0035] It is understandable that the above notification and the process of obtaining user authorization are merely illustrative and do not constitute a limitation on the implementation of the present disclosure. Other methods that meet the relevant laws and regulations may also be applied to the implementation of the present disclosure.

[0036] It is understandable that the data involved in this technical solution (including but not limited to the data itself, the acquisition or use of the data) shall comply with the requirements of relevant laws, regulations and relevant provisions.

[0037] Before introducing the technical solution, the application scenario of the embodiment of the present disclosure can be illustrated first. For example, when a user shoots a video through an application software, or makes a video call with other users, he may want to make the shot video more interesting. At the same time, the user may have personalized needs for the screen of the special effects video. For example, some users want to replace the background in the video screen with specific content. At this time, according to the technical solution of this embodiment, the background image in the video shooting process can be determined, and then the background image and the target object are merged to generate a special effects video, so that the special effects video screen presents the effect of the target object and the background board being merged. The background board can be generated based on a video frame that has been uploaded or shot in advance. In other words, the background board is based on the splicing of multiple images, which can be understood as an existing photo wall.

[0038] Figure 1 The following is a flow chart of a video processing method provided by an embodiment of the present disclosure. The embodiment of the present disclosure is applicable to the case of generating special effect videos. The method can be executed by a video processing device, which can be implemented in the form of software and / or hardware. Optionally, it can be implemented by an electronic device, which can be a mobile terminal, a PC or a server. Figure 1 As shown, the method includes:

[0039] S110 . In response to a special effect triggering operation, extract a target object in a video frame to be processed.

[0040] Among them, the device for executing the special effect video determination method provided by the embodiment of the present disclosure can be integrated into the application software that supports the special effect video processing function, and the software can be installed in the electronic device. Optionally, the electronic device can be a mobile terminal or a PC, etc. The application software can be a type of software for image / video processing. The specific application software will not be described here one by one, as long as the image / video processing can be realized. It can also be a specially developed application program to realize the software for adding special effects and displaying special effects, or it can be integrated in the corresponding page, and the user can realize the processing of special effect videos through the page integrated in the PC.

[0041] It should be noted that the technical solution of this embodiment can be executed in the process of real-time video recording based on the mobile terminal, or it can be executed after the system receives the video data actively uploaded by the user. For example, when the user shoots a video in real time based on the camera device on the terminal device, the application software detects the special effect trigger operation and responds to the operation, thereby obtaining the uploaded image and processing the video currently shot by the user to obtain a special effect video. Alternatively, when the user actively uploads image data through the application software and performs a special effect trigger operation, the application will also respond to the operation, and then process the image data actively uploaded by the user after obtaining the uploaded image, thereby obtaining a special effect video.

[0042] In the embodiment of the present disclosure, responding to the special effects triggering operation includes at least one of the following methods: triggering a shooting control corresponding to the special effects video production; monitoring voice information including special effects adding instructions; detecting that the display interface includes a facial image.

[0043] Specifically, a control for triggering and running a special effects video production program can be developed in advance in the application software. The control is the special effects video production control. Based on this, when the application detects that the user triggers the control, the special effects video production program can be run to process the uploaded image obtained. It can also be that voice information is collected based on the microphone array deployed on the terminal device, and the voice information is analyzed and processed. If the processing result includes the vocabulary of special effects video processing, it means that the function of performing special effects processing on the current video is triggered. The advantage of determining whether to perform special effects video processing based on the content of the voice information is that it avoids the interaction between the user and the display page and improves the intelligence of special effects video processing. Another implementation method can be to determine whether the user's facial image is included in the field of view according to the shooting field of view of the mobile terminal. When the user's facial image is detected, the application software can use the event of detecting the facial image as a trigger operation for performing special effects processing on the video. Those skilled in the art should understand that the specific event selected as the condition for special effects video processing can be set according to actual conditions, and the embodiments of the present disclosure are not specifically limited here.

[0044] Usually, the application software is installed on the terminal device, and the terminal device is provided with a shooting function. After responding to the special effect triggering operation, the video or image can be shot based on the camera device or the application software. If the video shooting control is turned on, the video can be shot based on the camera device, and each shot frame is used as a video frame to be processed. At this time, the video frame to be processed may include a target object. The target object can be either dynamic or static. At the same time, the number of target objects can be one or more. For example, multiple specific users can be used as target objects. Based on this, when the application is based on a pre-trained image recognition model, when the facial features of one or more specific users are identified from the real-time video screen, the special effect video processing process of the embodiment of the present disclosure can be executed. All correspondences in the screen can also be used as target objects. The target object in the video frame can be obtained by using the cutout technology, or the target object in the video frame to be processed can be extracted by using the limb torso recognition method. Specifically, when the application obtains the video shot by the user in real time and identifies the target object from the screen, the video can be parsed to obtain the video frame to be processed corresponding to the current moment. Furthermore, based on a pre-written cutout program, the view corresponding to the target object is extracted from the video frame to be processed. Those skilled in the art should understand that cutout is to separate an image or image from a part of the original image or video frame to obtain a separate layer processing operation. In this embodiment, the view obtained by cutout processing is the image corresponding to the target object.

[0045] Based on the above technical solutions, after triggering the image shooting control, real-time video frames can be shot based on the camera device, and when it is detected that the preset conditions are met, the target object in the video frame to be processed is extracted, and the special effects video is determined based on the video frame to be processed and the special effects video frame subsequently fused.

[0046] Optionally, shoot the video frame to be processed corresponding to the current scene; when it is detected that the special effect display condition is met, continue to shoot the video frame to be processed to extract the target object in the video frame to be processed.

[0047] The current scene may be the scene where the target object is currently located, and the special effect display condition may be that the duration of continuously shooting the video frames to be processed reaches a preset duration threshold.

[0048] For example, when the triggering of the image shooting control is detected, the video frame to be processed corresponding to the current scene can be shot. When the countdown on the current display interface is detected to be "1", the video frame to be processed can continue to be shot, and the target object in the video frame to be processed can be extracted so as to merge the target object with the image background to obtain a special effect video frame.

[0049] It should be noted that it is detected that the shooting time reaches the preset shooting time threshold; the received voice information includes a special effect display wake-up word that triggers a preset body movement on the target object in the video frame to be processed.

[0050] Specifically, when the duration of continuous shooting of the current scene reaches a preset shooting duration threshold, or when audio data is obtained and a voice wake-up word is included in the audio data, it means that the target object in the video frame to be processed needs to be extracted. Alternatively, the target object in the video frame to be processed triggers a preset body movement, which means that the target object in the video frame to be processed needs to be extracted.

[0051] S120: Generate an image background plate including at least one image to be displayed.

[0052] Wherein, the number of images to be displayed includes multiple, and one or more photo walls can be generated based on the images to be displayed, and the one or more photo walls can be used as image background boards. The images to be displayed can be based on the video frames to be processed shot by the camera device, or can be pre-shot images, or downloaded images. For example, it can be based on images shot by the camera device and stored in an image library or image storage library, or it can be images downloaded from the Internet. For example, if a user likes a certain actor very much, he can download the image corresponding to the actor to generate an image background board, so as to merge it with the image background board to obtain a corresponding special effect video frame.

[0053] In this embodiment, before generating an image background plate including at least one image to be displayed, it also includes: jumping to an image resource library to determine at least one image to be displayed from the image resource library and upload it, so as to determine the image background plate based on the at least one image to be displayed.

[0054] Among them, the image to be displayed can be an image actively uploaded by the user. For example, when the user triggers the image upload control, it can trigger the application software to call the image library on the mobile terminal, or trigger the application software to call the cloud image library associated with it, and then determine the uploaded image according to the user's selection result. It can also trigger the application software to call the relevant interface of the mobile terminal camera device, so as to obtain the image taken by the camera device, and use the image as the image to be displayed.

[0055] For example, when a user uses a camera device of a mobile terminal to shoot a video in real time and triggers the image upload box displayed in the display interface, the application software can automatically open the "album" in the mobile terminal according to the user's triggering operation on the image upload box, and display the images in the "album" on the display interface. When the user's triggering operation on a certain image is detected, it indicates that the user wants to use the image as the background of the special effect video, that is, the spliced ​​image in the image background board. Further, the image selected by the user will be uploaded to the server or client corresponding to the application software, so that the application software will make an image background board based on the uploaded image. Alternatively, when a user uses a camera device of a mobile terminal to shoot a video in real time and triggers the image upload box displayed in the display interface, the application software can directly obtain the video frame at the current moment in the video shot by the camera device in real time, and use the video frame as the image to be displayed.

[0056] In this embodiment, the images to be displayed can be spliced ​​to obtain an image background plate including at least one image to be displayed, so as to achieve an effect of fusion of the target object and the background image. Determining the image background plate can be: based on at least one image layout, the at least one image to be displayed is layout processed to obtain at least one background plate to be displayed; wherein the at least one image layout is pre-set and / or pre-uploaded; based on the at least one background plate to be displayed, the image background plate is determined.

[0057] Among them, image layout can be understood as how to arrange the images to be displayed. It can be understood that there is a wall, and the user can use what kind of layout to post the image on the wall. The adopted layout is used as image layout. Image layout can include multiple types, and the user can select one or more layouts from any of the multiple layouts. It can also be that the client or the server automatically selects the number of image layouts according to the number of images to be displayed. It can also be that the client or the server automatically generates an image layout corresponding to the image to be displayed based on the image to be displayed, and arranges the corresponding image to be displayed based on this. The background board to be displayed is the background board obtained after the layout processing of the image to be displayed based on the image layout. The number of background boards to be displayed corresponds to the determined number of image layouts. Of course, the same image to be displayed can be arranged based on different image layouts, that is, an image to be displayed can be located in different background boards to be displayed. Each background board to be displayed can be used as an image background board, or each background board to be displayed can be spliced ​​to obtain an image background board.

[0058] It should be noted that the image layout can be pre-set or can be a layout pre-uploaded by the user, which achieves the effect of automatically determining the display position of the image to be displayed based on the layout, thereby improving the convenience of determining the background board to be displayed.

[0059] Next, how to determine the background plate to be displayed based on the image layout is described in detail. Optionally, the image layout includes multiple horizontal grids and vertical grids. The method of processing the at least one image to be displayed based on at least one image layout to obtain at least one background plate to be displayed includes:

[0060] According to the shooting method of at least one image to be displayed, the horizontal grid and the vertical grid corresponding to the at least one image to be displayed are determined; according to the cropping ratio corresponding to the image shooting method, the image to be laid out corresponding to the at least one image to be displayed is determined, and the at least one image to be displayed is laid out to obtain the at least one background board to be displayed.

[0061] Among them, the horizontal grid and the vertical grid are relative, and are mainly determined according to the horizontal and vertical ratio of the grid. For example, a horizontal and vertical ratio greater than or equal to 1 can be called a horizontal grid, and a horizontal and vertical ratio less than 1 can be called a vertical grid. That is, an image layout can include multiple horizontal grids, and can also include multiple vertical grids. The image to be displayed can be aligned with the horizontal or vertical grids and arranged. The image to be displayed can be directly filled according to the ratio corresponding to the horizontal and vertical grids to obtain the background plate to be displayed. In order to further improve the degree of integration of each image to be displayed and the corresponding grid in the background plate to be displayed, the background plate to be displayed can be determined based on the shooting method of each image to be displayed.

[0062] It should be noted that the shooting mode may include a horizontal shooting mode and a vertical shooting mode, and the display effects of the images to be displayed are different for different shooting modes. The images to be displayed for the horizontal shooting mode may be displayed in the horizontally arranged grid, and the images to be displayed for the vertical shooting mode may be displayed in the vertically arranged grid, so that the images to be displayed and the corresponding grids completely overlap, avoiding the problem of black edges at the edges of the grids, which may lead to poor display effects.

[0063] In practical applications, there is a problem that the shooting method of the image to be displayed is not completely matched with the grid type, or even if the image to be displayed is arranged in the corresponding grid, the problem of black edges may still occur. The image to be displayed can be further processed so that the image to be displayed can be fully adapted to the grid in the image layout to obtain a better background board effect.

[0064] Optionally, based on the cropping ratio corresponding to the shooting method, determine the image to be laid out corresponding to the at least one image to be displayed; place the at least one image to be laid out in the corresponding vertical arrangement grid or horizontal arrangement grid respectively to obtain the background board to be displayed corresponding to the image layout.

[0065] It can be understood that after determining the shooting method, the cropping ratio corresponding to the image to be displayed can be determined according to the corresponding shooting method and the ratio information of the horizontal and vertical grids, and then the corresponding image to be displayed can be cropped based on the cropping ratio, and the cropped image to be displayed can be used as the image to be laid out. Each image to be laid out can be placed in the corresponding vertical arrangement grid or horizontal arrangement grid to obtain a background plate to be displayed corresponding to the image layout.

[0066] On the basis of the above technical solution, based on at least one background board to be displayed, the image background board is determined, which can be specifically: determining the display interface size corresponding to each background board to be displayed, so as to determine the image background board based on the display interface size, or performing circular splicing on at least one background board to be displayed to obtain the image background board.

[0067] It can be understood that each background plate to be displayed can be used as an image background plate. According to the display size of the display interface, the display ratio of the image background plate in the display interface can be determined, and then the corresponding image background plate can be adjusted based on the display ratio. It can also be that each background plate to be displayed is annularly spliced ​​to obtain a circular or semicircular image background plate. It can also be that each background plate to be displayed is embedded in a pre-set 3D surround model to obtain a rotatable image background plate.

[0068] It should also be noted that in the process of displaying the image background board, in order to have a better display effect, each background board to be displayed can be displayed on the display interface in a cycle, or the surrounding background image board can be controlled to play the image background board at a certain rate.

[0069] S130: Fusing the target object with the image background plate to obtain a special effect video frame and display it.

[0070] For example, see Figure 2 , the image background plate can be displayed as the background image, and the target object can be displayed as the foreground image.

[0071] It should be noted that the display content of the image background board in each video frame and the relative display angle with the target object can be changed.

[0072] In this embodiment, the target object and the image background plate are fused and processed, which can be: according to the relative distance information between the target object and the display interface, the display size of the image background plate on the display interface is updated; the target object and the image background plate of the updated display size are fused and processed to obtain a special effect video frame. In practical applications, the front camera or the rear camera can be used to shoot the corresponding video frame to be processed. When the shooting method is different, the relative display distance between the target object and the display interface is different, and the display size of the background image in the display interface can be determined according to the relative display distance. Then, the target object is fused with the corresponding image background plate to obtain a special effect video frame.

[0073] In a specific application, the target object and the image background plate are merged and processed, and also the following steps can be performed: determining the scaling ratio of the target object according to the display size of the image background plate; and fusing the target object and the image background plate according to the scaling ratio to obtain the special effect video frame.

[0074] It can be understood that in order to achieve a better fusion effect between the target object and the image background, the target object can be reduced or enlarged according to the display size of the image background to achieve a natural fusion effect and obtain the corresponding special effect video frame.

[0075] On the basis of the above technical solution, it should be noted that the image background plate is played in a loop on the display interface. For example, the number of image background plates includes multiple images, and the display time of each image background can be set. When the display time of each image background plate reaches a preset display time threshold, the next image background plate is displayed. The above image background plates can be played in a loop, and the target objects in the video frame to be processed are merged together to obtain a special effect video frame.

[0076] In order to achieve the goal of avoiding a blank screen and causing a poor user experience when switching image background boards, corresponding transition effects can be set when switching background boards. For example, the transition effect can be an effect in which the image background board fades in and out, or it can be a pre-set animation effect played to fill the display interface when switching to the next image background board, thereby improving the user's viewing experience.

[0077] On the basis of the above technical solution, it should be noted that the image background plate can also be a surround background plate obtained by splicing multiple background plates to be displayed. In this case, the target object is fused with the image background plate to obtain a special effect video frame, which can be: determining the curvature information of the surround background plate, and determining the scaling ratio of the target object according to the curvature information; and fusion processing the target object with the surround background plate based on the scaling ratio to obtain the special effect video frame.

[0078] The curvature information may be the rotation rate of the tangent direction angle to the arc length at a point or region on the curved surface, which can be understood as the curvature of the annular image background. The scaling ratio may be determined based on the curvature information and the distance of the target object relative to the image background or the distance information of the target object relative to the center point of the background, so that the image is fused based on the scaling ratio, thereby achieving a good fusion of the target object and the background information, thereby improving the realism of the special effect image.

[0079] It can be understood that in order to merge the target object with the image background, the curvature information of the surrounding background can be obtained, and the optimal display position of the target object and the display interface can be determined based on the curvature information. The scaling ratio of the target object can be scaled based on the optimal display position.

[0080] When displaying the corresponding image background board, in order to create a visual impact, it is possible to determine the image to be displayed in each image background board that needs to be enlarged, or to enlarge the display video, or to enlarge the images in the image background board in sequence at the center position.

[0081] It can be understood that the target enlarged display image can be any image in the image background plate, or can be an image at the center of the image background plate. When enlarged display, the enlarged display image can be enlarged and displayed at the center of the image background plate.

[0082] In order to further increase the sense of technology, in the process of special effect video frames, the mirror plane corresponding to the image background board in the display interface is determined. The mirror plane mostly corresponds to the plane perpendicular to the lower edge of the image background board in the display interface. The advantage of determining the mirror plane is that the reflection of the image background board is displayed, thereby causing the effect of richness of the picture content. At the same time, the surrounding image background board can be rotated according to the preset rotation rate.

[0083] Based on the above, it can be known that no matter the looped image background board or the surround image background board, both can be displayed in a preset manner.

[0084] In this embodiment, when the application detects the operation of stopping the special effects video shooting, the above processing steps of the disclosed embodiment will no longer be executed. Among them, the operation of stopping the special effects video shooting includes at least one of the following: detecting a trigger to stop shooting control; detecting that the shooting time of the special effects video reaches a preset shooting time; detecting a wake-up word that triggers the stop shooting; detecting a body movement that triggers the stop shooting. The above conditions are explained below.

[0085] Specifically, for the first operation of stopping the special effects video shooting mentioned above, a control can be developed in the application software in advance, and at the same time, the program for terminating the special effects video processing is associated with the control, and the control is the stop shooting control. Based on this, when it is detected that the user triggers the control, the application software can call the relevant program to terminate the processing operation of each video frame to be processed at the current moment and after the moment. It can be understood that there are many ways for the user to trigger the control. For example, when the client is installed and deployed on the PC, the user can trigger the stop shooting control by clicking the mouse. When the client is installed and deployed on the mobile terminal, the user can trigger the stop shooting control by finger touch. Those skilled in the art should understand that the specific touch method can be selected according to the actual situation, and the embodiments of the present disclosure do not make specific limitations on this.

[0086] For the second operation of stopping the special effects video shooting mentioned above, the application can pre-set a duration as the preset shooting duration, and record the duration of the user's video shooting. Further, the recording result is compared with the preset shooting duration. When it is determined that the user's shooting duration has reached the preset shooting duration, the processing operation of the video frames to be processed at the current moment and after this moment can be terminated.

[0087] For the third operation of stopping the special effects video shooting mentioned above, specific information can be pre-set in the application software as the wake-up word for stopping shooting. For example, one or more of the words "stop", "stop shooting" and "stop processing" can be used as the wake-up words for stopping shooting. Based on this, when the application software receives the voice information sent by the user, it can use the pre-trained voice recognition model to recognize the voice information, and determine whether the recognition result contains one or more of the above-mentioned preset special effects mounting wake-up words. When the judgment result is yes, the application can terminate the processing operations on the video frames to be processed at the current moment and after that moment.

[0088] For the fourth operation of stopping the special effects video shooting mentioned above, the action information of multiple people can be recorded in the application software, and the action information can be used as the preset action information. For example, the information reflecting the action of a person raising his hands can be used as the preset action information. Based on this, when the application receives images or videos actively uploaded by the user or collected in real time by the camera device, the image or the pictures in each video frame can be identified based on the pre-trained body movement information recognition algorithm. When the recognition result shows that the body movement information of the target object in the current picture is consistent with the preset action information, the application can terminate the processing operation of the video frames to be processed at the current moment and after that moment.

[0089] It should be noted that the above-mentioned special effect mounting conditions can be effective in the application software at the same time, or only one or more of them can be selected to be effective in the application software. The embodiments of the present disclosure do not make specific limitations on this.

[0090] The technical solution provided by the disclosed embodiment can extract the target object in the video frame to be processed in response to the special effect trigger operation, and after generating an image background plate including at least one image to be displayed, the target object can be fused with the image background plate to obtain a special effect video frame and display it until an operation to stop the special effect video shooting is received, which solves the problem that the special effect video content in the prior art cannot meet the personalized needs of users, resulting in poor video picture content and poor user experience, and realizes that the image background plate is generated based on the image to be displayed selected by the user, which satisfies the effect of personalized display of the background image. Further, the attractiveness of the application software to users can be improved, thereby improving the effect of user stickiness. On the basis of the above technical solution, in order to further improve the fun and picture sense of the special effect video, when it is detected that the target object meets the freeze display conditions, the target object can be frozen and displayed in the image background plate to obtain a special effect video frame.

[0091] Among them, the freeze display condition can be that the target object triggers the target action, for example, the target action can be a hand-holding action, a heart-shaped action, a hugging action, a kissing action, etc. It can also be that the target object triggers the corresponding freeze wake-up word. It can also be that a timing device and a set task are set, and when the preset timing duration is reached, the set task is triggered, and the set task is freeze display of the target object and the special effect video frame.

[0092] Specifically, when the freeze-frame display conditions are met, the target object at the moment of the freeze-frame display can be displayed during the playback of the image background board, thereby achieving a specific viewing effect of the video screen.

[0093] It should also be noted that in the process of generating special effects video, the edge of the picture can be cropped according to the shooting mode of the special effects video, for example, the front mode or the rear mode, so that the video screen covers the entire display interface. Alternatively, the display ratio of the special effects video on the back of the display is determined according to a certain ratio.

[0094] Figure 3A flow chart of a video processing method provided by the embodiment of the present disclosure. Based on the above-mentioned embodiment, it can be understood that the image background board can be displayed based on the set display mode. In order to further achieve that the image background board changes with the shooting angle of the terminal device, that is, to further enrich the interactivity between the video screen and the user, the shooting angle of the shooting terminal can be obtained in real time or periodically during the fusion of the target object and the image background board, and then the display information of the image background board is determined based on the shooting angle to enhance the interactive effect between the screen content and the user. The specific implementation method can refer to the detailed description of this technical solution. Among them, the terms that are the same or corresponding to the above-mentioned embodiments are not repeated here.

[0095] like Figure 3 As shown, the method includes:

[0096] S210: In response to a special effect triggering operation, extract a target object in a video frame to be processed.

[0097] S220: Generate an image background plate including at least one image to be displayed.

[0098] S230, determining the shooting angle of the shooting device, and determining the display angle of the image background plate based on the shooting angle, so as to determine the display content in the image background plate based on the display angle, and fusing the target object with the display content to obtain a special effect video frame.

[0099] In order to further improve the intelligent effect, the display information of the image background plate can be determined based on the shooting angle of the camera device. The camera device, that is, the camera device of the terminal device, can obtain the rotation angle information of the camera device to determine the information in the display image background plate.

[0100] That is to say, the image background board can be displayed dynamically or statically in the display interface. If it is displayed dynamically, the display information of the image background board can be determined comprehensively by combining the shooting angle of the camera device during the playback of the image background board according to the preset playback effect. If the image background board is displayed statically in the display interface, the shooting angle of the camera device can be adjusted in real time or periodically to obtain the display information of the image background board based on the shooting angle, thereby obtaining a special effect video frame.

[0101] Optionally, if the display content of the image background board is determined based on the camera shooting angle, the current video shooting mode is obtained; according to the current shooting angle of the shooting device and the current shooting mode, the scene angle to be adjusted corresponding to the image background board is determined; based on the scene angle to be adjusted and the initial scene angle, the target scene angle is determined to determine the display angle of the image background based on the target scene angle.

[0102] Among them, the angle information of the shooting device can be determined based on the gyroscope set in the terminal device, and the gyroscope can obtain three sets of data eulerX, eulerY, and eulerZ of the terminal device, which respectively represent the angles in the directions of the coordinate axes in three directions. When shooting the special effects video for the first time, the three sets of data obtained are used as the initial scene angle. The current shooting mode can be understood as a front shooting mode or a rear shooting mode. Based on different shooting modes, corresponding functions can be used to determine the corresponding scene angles. That is, the scene angle to be adjusted is the angle corresponding to the image background plate. The scene angle to be adjusted is the angle corresponding to the image background plate obtained after the current scene shooting angle is processed based on the corresponding function. It should be noted that the current shooting mode may include a front shooting mode and a rear shooting mode, and different shooting modes determine the scene angle to be adjusted in different ways. Next, how the two shooting modes determine the scene angle to be adjusted is explained respectively.

[0103] Optionally, if the current shooting mode is the front shooting mode, the first direction angle and the second direction angle in the current shooting angle are inverted to obtain the scene angle to be adjusted corresponding to the image background plate.

[0104] Among them, the first direction angle, the second direction angle and the third direction angle are all relative, that is, according to the world coordinate system, the X-axis direction is the first direction, the Y-axis direction is the second direction, and the Z-axis direction is the third direction. Correspondingly, the angles corresponding to each direction are used as the first direction angle, the second direction angle and the third direction angle. Exemplarily, the front shooting mode is switched, and the current shooting angles are recorded as eulerX, eulerY, and eulerZ, then the scene angle to be adjusted can be:

[0105] neweulerX=-eulerX

[0106] neweulerY=-eulerY

[0107] neweulerZ=eulerZ

[0108] Among them, neweulerX is the first direction angle in the scene angle to be adjusted, neweulerY is the second direction angle in the scene angle to be adjusted, and neweulerZ is the third direction angle in the scene angle to be adjusted.

[0109] Optionally, if the current shooting mode is a post-shooting mode, the angle range of the first direction angle in the current shooting angle is determined, and based on the objective function corresponding to the angle range, the first angle to be adjusted is determined; based on the first angle to be adjusted and other direction angles in the current shooting angle, the scene angle to be adjusted is determined.

[0110] Exemplarily, the captured image when the eulerX of the rear camera is 0 is usually the same as the captured image when the eulerX of the front camera is 15, while ensuring that the captured images remain unchanged when eulerX is 90 and 270 (the imaging device is placed horizontally) to ensure that the user's perception is not incorrect. Therefore, a linear mapping can be performed on eulerX. For example, if 270 < eulerX < 360, the first direction angle in the scene angle to be adjusted can be determined based on the formula newEulerX = (eulerX - 270) / 90×105 + 270; if 0 < eulerX < 90, then newEulerX = eulerX / 90*75 + 15 to obtain the first direction angle in the scene angle to be adjusted. For the second and third direction angles in the scene angle to be adjusted, their values are the same as the collected data.

[0111] The advantage of determining the scene angle to be adjusted in the above manner is that the display content of the most suitable image background board can be determined according to the shooting mode.

[0112] After obtaining the corresponding scene angle to be adjusted based on the above method, it is also necessary to adapt to the initial shooting angle of the imaging device, that is, the terminal device. Specifically, it can be: based on the initial scene angle, the ideal scene angle, and the second angle to be adjusted in the scene angle to be adjusted, determine the target angle corresponding to the second angle to be adjusted; based on the other angles to be adjusted and the target angle, determine the target scene angle.

[0113] It can be understood that it is necessary to combine the initial angle of the terminal device and the ideal initial angles of each image to be adjusted to adjust the scene angle to be adjusted to obtain the target scene angle for displaying the image background board.

[0114] Exemplarily, given the ideal initial angle idealEulerY and recording the initial angle startEulerY when the prop is in the initial state, the target scene angle can be determined based on the following formula:

[0115] neweulerX = neweulerX

[0116] neweulerY = neweulerY - startEulerY + idealEulerY

[0117] neweulerZ = neweulerZ

[0118] Substituting the angles in each direction of the scene angle to be adjusted determined above into the above formula, the angles in each direction of the updated target scene angle can be obtained. Based on the target scene angle, the display content in the image background plate can be determined and displayed.

[0119] On the basis of the above technical solution, it also includes: playing preset audio special effects during the process of playing special effect video frames.

[0120] It can be understood that in the process of playing the special effect video frame, there can be background sound effects, for example, the background sound effects can be background music, and the background music can be determined according to the image content of each image to be displayed in the image background board. For example, if the image content of the image to be displayed is mostly children, the background music that can be played is a nursery rhyme. If the content of the image to be displayed is mostly two target objects, and the relationship between the target objects is relatively close, another type of background music can be played. Alternatively, the user can set the background music according to actual needs.

[0121] Based on the technical solution provided by the embodiment of the present disclosure, on the basis of making a photo wall, corresponding target objects can also be integrated to achieve the technical effect of enriching the video content.

[0122] The technical solution provided by the embodiment of the present disclosure, if the display content in the image background board corresponds to the shooting angle of the device on the terminal, can obtain the shooting angle and shooting mode of the terminal device in real time or periodically, determine the target scene angle corresponding to the shooting angle, and then display the corresponding image background board based on the target scene angle, thereby improving the video display content to change with the user's perspective, and further improving the matching effect of the video content with the user.

[0123] Figure 4 A schematic diagram of the structure of a video processing device provided by an embodiment of the present disclosure is shown in FIG. Figure 4 As shown, the device includes: an object extraction module 310, a background plate generation module 320 and a video generation module 330.

[0124] Among them, the object extraction module 310 is used to extract the target object in the video frame to be processed in response to the special effect trigger operation; the background plate generation module 320 is used to generate an image background plate including at least one image to be displayed; the video generation module 330 is used to fuse the target object with the image background plate to obtain a special effect video frame and display it until an operation to stop the special effect video shooting is received.

[0125] Based on the above technical solution, the background board generation module is also used to: jump to the image resource library to determine at least one image to be displayed from the image resource library and upload it, so as to determine the image background board based on the at least one image to be displayed.

[0126] On the basis of the above technical solutions, the background board generation module includes:

[0127] A background plate generation unit to be displayed, used for processing the at least one image to be displayed based on at least one image layout to obtain at least one background plate to be displayed; wherein the at least one image layout is pre-set and / or pre-uploaded;

[0128] The background plate generating unit is used to determine the image background plate based on the at least one background plate to be displayed.

[0129] On the basis of the above technical solutions, the image layout includes a horizontal grid and a vertical grid for placing the image to be displayed, and the background board generation unit to be displayed is further used to:

[0130] According to the shooting mode of at least one image to be displayed, the horizontal grid and the vertical grid corresponding to the at least one image to be displayed are determined, and the at least one image to be displayed is typeset to obtain the at least one background plate to be displayed.

[0131] On the basis of the above technical solutions, the device further includes:

[0132] A module for determining an image to be laid out, configured to determine an image to be laid out corresponding to the at least one image to be displayed according to a cropping ratio corresponding to the shooting method;

[0133] The background plate determination module is used to place the at least one image to be typeset into corresponding longitudinal grids or transverse grids to obtain a background plate to be displayed corresponding to the image typeset.

[0134] On the basis of the above technical solutions, the background board generation module is also used for:

[0135] Determine the display interface size corresponding to each background plate to be displayed, so as to determine the image background plate based on the display interface size; or,

[0136] The at least one background plate to be displayed is circularly spliced ​​to obtain the image background plate.

[0137] On the basis of the above technical solutions, the object extraction module is also used to:

[0138] Shooting the video frame to be processed corresponding to the current scene;

[0139] When it is detected that the special effect display condition is met, the video frame to be processed continues to be shot to extract the target object in the video frame to be processed.

[0140] Based on the above technical solutions, the video frame generation module includes:

[0141] A display size determination unit, configured to update the display size of the image background board on the display interface according to the relative distance information between the target object and the display interface;

[0142] The video frame determination unit is used to fuse the target object with the image background plate of the updated display size to obtain a special effect video frame.

[0143] Based on the above technical solutions, the video frame generation module includes:

[0144] A ratio determination unit, used to determine the scaling ratio of the target object according to the display size of the image background plate;

[0145] The video frame determination unit is used to fuse the target object with the image background plate according to the scaling ratio to obtain the special effect video frame.

[0146] On the basis of the above-mentioned technical solutions, the device also includes: a cyclic display module for cyclically displaying each image background board according to the cyclic display duration of the image background board; wherein the number of image background boards is consistent with the number of image layouts.

[0147] On the basis of the above-mentioned technical solutions, the device further includes: a transition special effect processing module, which is used to display the transition special effect when switching the image background board, so as to display the next image background board based on the transition special effect.

[0148] On the basis of the above-mentioned technical solutions, the device further includes: an image detection module, which is used to freeze-frame and display the target object in the image background board when it is detected that the target object meets the freeze-frame display condition, so as to obtain the special effect video frame.

[0149] On the basis of the above technical solutions, the image background plate is a surround background plate obtained by splicing multiple background plates to be displayed, and the video frame generation module includes:

[0150] A ratio determination unit, used to determine the curvature information of the surrounding background plate, and determine the scaling ratio of the target object according to the curvature information;

[0151] The video frame generating unit is used to fuse the target object with the surrounding background plate based on the scaling ratio to obtain a special effect video frame.

[0152] On the basis of the above technical solutions, the device also includes: an image magnification and display module, which is used to determine the target magnification and display image in the image background board during the display of the image background board, so as to magnify and display the target magnification and display image.

[0153] On the basis of the above technical solutions, the device further includes: a mirror processing module, which is used to determine a mirror plane to display the image background plate in a mirrored manner based on the mirror plane.

[0154] On the basis of the above technical solutions, the device further includes:

[0155] A shooting mode determination module, configured to obtain a current video shooting mode if the display content of the image background plate is determined based on a camera shooting angle;

[0156] A module for determining the scene angle to be adjusted, used to determine the scene angle to be adjusted corresponding to the image background plate according to the current shooting angle of the shooting device and the current shooting mode;

[0157] The target scene angle determination module is used to determine the target scene angle based on the scene angle to be adjusted and the initial scene angle, so as to determine the display angle of the image background based on the target scene angle.

[0158] On the basis of the above-mentioned technical solutions, the shooting mode determination module is also used to, if the current shooting mode is the front shooting mode, invert the first direction angle and the second direction angle in the current shooting angle to obtain the scene angle to be adjusted corresponding to the image background plate.

[0159] On the basis of the above-mentioned technical solutions, the shooting mode determination module is also used to determine the angle range of the first direction angle in the current shooting angle if the current shooting mode is the post-shooting mode, and determine the first angle to be adjusted based on the objective function corresponding to the angle range; and determine the scene angle to be adjusted based on the first angle to be adjusted and other direction angles in the current shooting angle.

[0160] Based on the above technical solutions, the target scene angle determination module is also used to determine the target angle corresponding to the second angle to be adjusted based on the initial scene angle, the ideal scene angle and the second angle to be adjusted in the scene angle to be adjusted; and determine the target scene angle based on other angles to be adjusted and the target angle.

[0161] On the basis of the above technical solutions, the device also includes an audio special effect processing module, which is used to play preset audio special effects during the process of playing special effect video frames.

[0162] Based on the above technical solutions, the operation of stopping the special effect video shooting includes at least one of the following:

[0163] A trigger is detected to stop the shooting control;

[0164] Detecting audio information triggers the stop shooting keyword;

[0165] A gesture is detected that triggers the stop of recording.

[0166] The technical solution provided by the embodiment of the present disclosure can extract the target object in the video frame to be processed in response to the special effect trigger operation, and after generating an image background plate including at least one image to be displayed, the target object can be fused with the image background plate to obtain a special effect video frame and display it until an operation to stop the special effect video shooting is received, which solves the problem that the special effect video content in the prior art cannot meet the personalized needs of users, resulting in poor video content and poor user experience, and realizes that the image background plate is generated based on the image to be displayed selected by the user, which satisfies the effect of personalized display of the background image. Further, it can improve the attractiveness of the application software to users, thereby improving the effect of user stickiness. The video processing device provided by the embodiment of the present disclosure can execute the video processing method provided by any embodiment of the present disclosure, and has the corresponding functional modules and beneficial effects of the execution method.

[0167] It is worth noting that the various units and modules included in the above-mentioned device are only divided according to functional logic, but are not limited to the above-mentioned division, as long as the corresponding functions can be achieved; in addition, the specific names of the functional units are only for the convenience of distinguishing each other, and are not used to limit the protection scope of the embodiments of the present disclosure.

[0168] Figure 5 This is a schematic diagram of the structure of an electronic device provided by an embodiment of the present disclosure. Figure 5 , which shows an electronic device (eg, Figure 5 The terminal device in the embodiment of the present disclosure may include but is not limited to mobile terminals such as mobile phones, notebook computers, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablet computers), PMPs (portable multimedia players), vehicle-mounted terminals (such as vehicle-mounted navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Figure 5 The electronic device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.

[0169] like Figure 5As shown, the electronic device 400 may include a processing device (e.g., a central processing unit, a graphics processing unit, etc.) 401, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 402 or a program loaded from a storage device 408 into a random access memory (RAM) 403. In the RAM 403, various programs and data required for the operation of the electronic device 400 are also stored. The processing device 401, the ROM 402, and the RAM 403 are connected to each other via a bus 404. An edit / output (I / O) interface 405 is also connected to the bus 404.

[0170] Typically, the following devices may be connected to the I / O interface 405: an input device 406 including, for example, a touch screen, a touch pad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; an output device 407 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; a storage device 408 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 409. The communication device 409 may allow the electronic device 400 to communicate with other devices wirelessly or by wire to exchange data. Although Figure 5 The electronic device 400 is shown with various devices, but it should be understood that it is not required to implement or possess all the devices shown. More or fewer devices may be implemented or possessed instead.

[0171] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program carried on a non-transitory computer-readable medium, and the computer program contains program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through the communication device 409, or installed from the storage device 408, or installed from the ROM 402. When the computer program is executed by the processing device 401, the above-mentioned functions defined in the method of the embodiment of the present disclosure are executed.

[0172] The names of the messages or information exchanged between multiple devices in the embodiments of the present disclosure are only used for illustrative purposes and are not used to limit the scope of these messages or information.

[0173] The electronic device provided by the embodiment of the present disclosure and the video processing method provided by the above embodiment belong to the same inventive concept. The technical details not fully described in this embodiment can be referred to the above embodiment, and this embodiment has the same beneficial effects as the above embodiment.

[0174] The embodiments of the present disclosure provide a computer storage medium on which a computer program is stored. When the program is executed by a processor, the video processing method provided by the above embodiments is implemented.

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

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

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

[0178] The computer-readable medium carries one or more programs. When the one or more programs are executed by the electronic device, the electronic device:

[0179] The computer-readable medium carries one or more programs. When the one or more programs are executed by the electronic device, the electronic device:

[0180] In response to the special effect triggering operation, extracting the target object in the video frame to be processed;

[0181] generating an image background plate including at least one image to be displayed;

[0182] The target object is fused with the image background plate to obtain a special effect video frame and display it;

[0183] Wherein, the display content and / or display angle of the image background board relative to the target object changes dynamically.

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

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

[0186] The units involved in the embodiments described in the present disclosure may be implemented by software or hardware. The name of a unit does not limit the unit itself in some cases. For example, the first acquisition unit may also be described as a "unit for acquiring at least two Internet Protocol addresses".

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

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

[0189] According to one or more embodiments of the present disclosure, [Example 1] provides a video processing method, the method comprising:

[0190] In response to the special effect triggering operation, extracting the target object in the video frame to be processed;

[0191] generating an image background plate including at least one image to be displayed;

[0192] The target object is fused with the image background plate to obtain a special effect video frame and display it until an operation to stop shooting the special effect video is received.

[0193] According to one or more embodiments of the present disclosure, [Example 2] provides a video processing method, the method comprising:

[0194] Optionally, before generating the image background plate including at least one image to be displayed, the method further includes:

[0195] Jump to the image resource library to determine at least one image to be displayed from the image resource library and upload it, so as to determine the image background plate based on the at least one image to be displayed.

[0196] According to one or more embodiments of the present disclosure, [Example 3] provides a video processing method, the method comprising:

[0197] Optionally, generating an image background plate including at least one image to be displayed includes:

[0198] Based on at least one image layout, the at least one image to be displayed is layout-processed to obtain at least one background plate to be displayed; wherein the at least one image layout is pre-set and / or pre-uploaded;

[0199] Based on the at least one background plate to be displayed, the image background plate is determined.

[0200] According to one or more embodiments of the present disclosure, [Example 4] provides a video processing method, the method comprising:

[0201] Optionally, the image layout includes a plurality of horizontal image grids and a plurality of vertical image grids, and the at least one image to be displayed is layout-processed based on at least one image layout to obtain at least one background plate to be displayed, including:

[0202] According to the shooting mode of at least one image to be displayed, the horizontal grid and the vertical grid corresponding to the at least one image to be displayed are determined, and the at least one image to be displayed is typeset to obtain the at least one background plate to be displayed.

[0203] According to one or more embodiments of the present disclosure, [Example 5] provides a video processing method, the method comprising:

[0204] Optionally, determining an image to be typeset corresponding to the at least one image to be displayed according to a cropping ratio corresponding to the shooting method;

[0205] The at least one image to be typeset is placed in the corresponding longitudinal grid or transverse grid respectively to obtain a background plate to be displayed corresponding to the image typesetting.

[0206] According to one or more embodiments of the present disclosure, [Example 6] provides a video processing method, the method comprising:

[0207] Optionally, the determining the image background plate based on the at least one background plate to be displayed includes:

[0208] Determine the display interface size corresponding to each background plate to be displayed, so as to determine the image background plate based on the display interface size; or,

[0209] The at least one background plate to be displayed is circularly spliced ​​to obtain the image background plate.

[0210] According to one or more embodiments of the present disclosure, [Example 7] provides a video processing method, the method comprising:

[0211] Optionally, before extracting the target object in the video frame to be processed, the method further includes:

[0212] Shooting the video frame to be processed corresponding to the current scene;

[0213] When it is detected that the special effect display condition is met, the video frame to be processed continues to be shot to extract the target object in the video frame to be processed.

[0214] According to one or more embodiments of the present disclosure, [Example 8] provides a video processing method, the method comprising:

[0215] Optionally, the step of fusing the target object with the image background plate to obtain a special effect video frame includes:

[0216] According to the relative distance information between the target object and the display interface, updating the display size of the image background board on the display interface;

[0217] The target object is fused with the image background plate of the updated display size to obtain a special effect video frame.

[0218] According to one or more embodiments of the present disclosure, [Example 9] provides a video processing method, the method comprising:

[0219] Optionally, the step of fusing the target object with the image background plate to obtain a special effect video frame includes:

[0220] Determining the scaling ratio of the target object according to the display size of the image background plate;

[0221] The target object is fused with the image background plate according to the scaling ratio to obtain the special effect video frame.

[0222] According to one or more embodiments of the present disclosure, [Example 10] provides a video processing method, the method comprising:

[0223] Optionally, in the process of fusing the target object with the background plate, the process further includes:

[0224] The image background panels are displayed in a loop according to the loop display duration of the image background panels;

[0225] The number of image background plates is consistent with the number of image layouts.

[0226] According to one or more embodiments of the present disclosure, [Example 11] provides a video processing method, the method comprising:

[0227] Optionally, in the process of sequentially displaying each image background plate, the process further includes:

[0228] When switching the image background plate, a transition effect is displayed to display the next image background plate based on the transition effect.

[0229] According to one or more embodiments of the present disclosure, [Example 12] provides a video processing method, the method comprising:

[0230] Optionally, when it is detected that the target object meets the freeze-frame display condition, the target object is freeze-framed and displayed in the image background board to obtain the special effect video frame.

[0231] According to one or more embodiments of the present disclosure, [Example 13] provides a video processing method, the method comprising:

[0232] Optionally, the image background plate is a surround background plate obtained by splicing multiple background plates to be displayed, and the target object is fused with the image background plate including at least one image to be displayed to obtain a special effect video frame, including:

[0233] Determining curvature information of the surrounding background plate, and determining a scaling ratio of the target object according to the curvature information;

[0234] The target object is fused with the surrounding background panel based on the scaling ratio to obtain a special effect video frame.

[0235] According to one or more embodiments of the present disclosure, [Example 14] provides a video processing method, the method comprising:

[0236] Optionally, during the display of the image background plate, a target enlarged display image in the image background plate is determined to enlarge the target enlarged display image for display.

[0237] According to one or more embodiments of the present disclosure, [Example 15] provides a video processing method, the method comprising:

[0238] Optionally, a mirror plane is determined to display the image background plate by mirroring based on the mirror plane.

[0239] According to one or more embodiments of the present disclosure, [Example 16] provides a video processing method, the method comprising:

[0240] Optionally, if the display content of the image background board is determined based on the camera shooting angle, the current video shooting mode is obtained;

[0241] Determining the scene angle to be adjusted corresponding to the image background plate according to the current shooting angle of the shooting device and the current shooting mode;

[0242] Based on the scene angle to be adjusted and the initial scene angle, a target scene angle is determined, so as to determine a display angle of the image background based on the target scene angle.

[0243] According to one or more embodiments of the present disclosure, [Example 17] provides a video processing method, the method comprising:

[0244] Optionally, determining the scene angle to be adjusted corresponding to the image background plate according to the current shooting angle of the shooting device and the current shooting mode includes:

[0245] If the current shooting mode is the front shooting mode, the first direction angle and the second direction angle in the current shooting angle are inverted to obtain the scene angle to be adjusted corresponding to the image background plate.

[0246] According to one or more embodiments of the present disclosure, [Example 18] provides a video processing method, the method comprising:

[0247] Optionally, determining the scene angle to be adjusted corresponding to the image background plate according to the current shooting angle of the shooting device and the current shooting mode includes:

[0248] If the current shooting mode is the post-shooting mode, determine the angle range of the first direction angle in the current shooting angle, and determine the first angle to be adjusted based on the objective function corresponding to the angle range; determine the scene angle to be adjusted based on the first angle to be adjusted and other direction angles in the current shooting angle.

[0249] According to one or more embodiments of the present disclosure, [Example 19] provides a video processing method, the method comprising:

[0250] Optionally, determining the target scene angle based on the scene angle to be adjusted and the initial scene angle includes:

[0251] Based on the initial scene angle, the ideal scene angle, and a second angle to be adjusted among the scene angles to be adjusted, determining a target angle corresponding to the second angle to be adjusted;

[0252] The target scene angle is determined based on other angles to be adjusted and the target angle.

[0253] According to one or more embodiments of the present disclosure, [Example 20] provides a video processing method, the method comprising:

[0254] Optionally, a preset audio effect is played during the playing of the special effect video frame.

[0255] According to one or more embodiments of the present disclosure, [Example 21] provides a video processing method, the method comprising:

[0256] Optionally, the operation of stopping the special effects video shooting includes at least one of the following:

[0257] A trigger is detected to stop the shooting control;

[0258] Detecting audio information triggers the stop shooting keyword;

[0259] A gesture is detected that triggers the stop of recording.

[0260] According to one or more embodiments of the present disclosure, [Example 22] provides a video processing device, the device comprising:

[0261] Optionally, an object extraction module is used to extract a target object in the video frame to be processed in response to a special effect triggering operation;

[0262] A background plate generating module, used to generate an image background plate including at least one image to be displayed;

[0263] The video generation module is used to fuse the target object with the image background plate to obtain a special effect video frame and display it until an operation to stop shooting the special effect video is received.

[0264] The above description is only a preferred embodiment of the present disclosure and an explanation of the technical principles used. Those skilled in the art should understand that the scope of disclosure involved in the present disclosure is not limited to the technical solutions formed by a specific combination of the above technical features, but should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the above disclosed concept. For example, the above features are replaced with the technical features with similar functions disclosed in the present disclosure (but not limited to) by each other to form a technical solution.

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

[0266] Although the subject matter has been described in language specific to structural features and / or methodological logical actions, 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. On the contrary, the specific features and actions described above are merely example forms of implementing the claims.

Claims

1. A video processing method, characterized in that: include: In response to the special effect triggering operation, extracting the target object in the video frame to be processed; Generate an image background plate including at least one image to be displayed; wherein the image background plate is a circular background plate obtained by circularly splicing multiple background plates to be displayed, or the image background plate is a background plate obtained by embedding the background plate to be displayed into a pre-set 3D surround model; The target object is fused with the image background plate to obtain a special effect video frame and display it; Wherein, the display content and / or display angle of the image background board relative to the target object changes dynamically.

2. The method according to claim 1, characterized in that The generating of an image background plate including at least one image to be displayed comprises: Based on at least one image layout, the at least one image to be displayed is layout-processed to obtain at least one background plate to be displayed; wherein the at least one image layout is preset and / or pre-uploaded; and the image to be displayed is determined from an image resource library; Based on the at least one background plate to be displayed, the image background plate is determined.

3. The method according to claim 2, characterized in that The image layout includes a horizontal grid and a vertical grid for placing the image to be displayed. The at least one image to be displayed is layout-processed based on at least one image layout to obtain at least one background plate to be displayed, including: Determining, according to a cropping ratio corresponding to the shooting method, an image to be typeset corresponding to the at least one image to be displayed; The at least one image to be typeset is placed in the corresponding longitudinal grid or transverse grid respectively to obtain a background plate to be displayed corresponding to the image typesetting.

4. The method according to claim 2, characterized in that: The determining the image background plate based on the at least one background plate to be displayed includes: Determine the display interface size corresponding to each background plate to be displayed, so as to determine the image background plate based on the display interface size; or, The at least one background plate to be displayed is circularly spliced ​​to obtain the image background plate.

5. The method according to claim 1, characterized in that Before extracting the target object in the video frame to be processed, it also includes: Shooting the video frame to be processed corresponding to the current scene; When it is detected that the special effect display condition is met, the video frame to be processed continues to be shot to extract the target object in the video frame to be processed.

6. The method according to claim 1, characterized in that The step of fusing the target object with the image background plate to obtain a special effect video frame includes: According to the relative distance information between the target object and the display interface, updating the display size of the image background board on the display interface; The target object is fused with the image background plate of the updated display size to obtain a special effect video frame.

7. The method according to claim 1, characterized in that The step of fusing the target object with the image background plate to obtain a special effect video frame includes: Determining the scaling ratio of the target object according to the display size of the image background plate; The target object is fused with the image background plate according to the scaling ratio to obtain the special effect video frame.

8. The method according to claim 1, characterized in that In the process of fusing the target object with the background plate, the following steps are also included: Each image background plate is displayed in a loop according to the loop display duration of the image background plate.

9. The method according to claim 8, characterized in that In the process of displaying each image background plate in sequence, it also includes: When switching the image background plate, a transition effect is displayed to display the next image background plate based on the transition effect.

10. The method according to claim 1, characterized in that Also includes: When it is detected that the target object meets the freeze display condition, the target object is freeze-framed and displayed in the image background board to obtain the special effect video frame.

11. The method according to claim 1, characterized in that: The image background plate is a surround background plate obtained by splicing a plurality of background plates to be displayed, and the target object is fused with the image background plate including at least one image to be displayed to obtain a special effect video frame, including: Determining curvature information of the surrounding background plate, and determining a scaling ratio of the target object according to the curvature information; The target object is fused with the surrounding background panel based on the scaling ratio to obtain a special effect video frame.

12. The method according to claim 1, characterized in that Also includes: During the display of the image background plate, a target enlarged display image in the image background plate is determined to enlarge the target enlarged display image for display.

13. The method according to claim 1, characterized in that Also includes: A mirror plane is determined to display the image background plate in a mirrored manner based on the mirror plane.

14. The method according to claim 1, characterized in that Also includes: If the display content of the image background board is determined based on the camera shooting angle, then obtaining the current video shooting mode; Determining a scene angle to be adjusted corresponding to the image background plate according to a current shooting angle of the shooting device and the current video shooting mode; Based on the scene angle to be adjusted and the initial scene angle, a target scene angle is determined, so as to determine a display angle of the image background based on the target scene angle.

15. The method according to claim 14, characterized in that The step of determining the scene angle to be adjusted corresponding to the image background plate according to the current shooting angle of the shooting device and the current shooting mode includes: If the current shooting mode is the front shooting mode, the first direction angle and the second direction angle in the current shooting angle are inverted to obtain the scene angle to be adjusted corresponding to the image background plate.

16. The method according to claim 14, characterized in that The step of determining the scene angle to be adjusted corresponding to the image background plate according to the current shooting angle of the shooting device and the current shooting mode includes: If the current shooting mode is the post-shooting mode, determine the angle range of the first direction angle in the current shooting angle, and determine the first angle to be adjusted based on the objective function corresponding to the angle range; determine the scene angle to be adjusted based on the first angle to be adjusted and other direction angles in the current shooting angle.

17. The method according to claim 14, characterized in that The step of determining a target scene angle based on the scene angle to be adjusted and the initial scene angle includes: Based on the initial scene angle, the ideal scene angle, and a second angle to be adjusted among the scene angles to be adjusted, determining a target angle corresponding to the second angle to be adjusted; The target scene angle is determined based on the other angles to be adjusted among the scene angles to be adjusted except the second angle to be adjusted and the target angle.

18. A video processing device, characterized in that: include: An object extraction module, used for extracting a target object in a video frame to be processed in response to a special effect trigger operation; A background plate generation module is used to generate an image background plate including at least one image to be displayed; wherein the image background plate is a circular background plate obtained by circularly splicing multiple background plates to be displayed, or the image background plate is a background plate obtained by embedding the background plate to be displayed into a pre-set 3D surround model; A video generation module, used for fusing the target object with the image background plate to obtain and display a special effect video frame; Wherein, the display content and / or display angle of the image background board relative to the target object changes dynamically.

19. An electronic device, characterized in that: The electronic device comprises: one or more processors; a storage device for storing one or more programs, When the one or more programs are executed by the one or more processors, the one or more processors implement the video processing method as described in any one of claims 1-17.

20. A storage medium comprising computer executable instructions, wherein the computer executable instructions are used to perform the video processing method according to any one of claims 1 to 17 when executed by a computer processor.

Citation Information

Cited By

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

    EP4531391A1

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

    WO2023226814A1