Video generation method, video generation device and electronic equipment
By automatically detecting and shooting cover images during the video recording process and generating target videos, the problem of users needing to use additional software to set video cover images is solved, and convenient video cover image settings and high degree of freedom are achieved.
Patent Information
- Application Number
- CN202210766367.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-07-01
- Publication Date
- 2024-11-12
- Estimated Expiration
- 2042-07-01
AI Technical Summary
In the prior art, users need to use additional video editing software when setting video cover images, which is cumbersome and inconvenient.
By detecting the motion state of the target object during the recording of the video, automatically taking the cover image, and generating the target video based on the recorded video and cover image, the cover image required by the user can be set without additional software.
It simplifies user operations, improves the freedom to set video cover images, and improves the convenience of users taking photos during video recording.
Smart Images

Figure CN115174812B_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the field of shooting technology, and specifically relates to a video generation method, a video generation device and an electronic device. Background Art
[0002] In the related art, the cover image of the recorded video is usually automatically generated by the system according to the video frames in the video, or the user edits the video cover image through video editing software. Although this method can obtain a cover image that satisfies the user, the user operation is relatively cumbersome. Summary of the invention
[0003] The purpose of the embodiments of the present application is to provide a video generating method, a video generating device and an electronic device, which can set the cover image required by the user for the target video without using additional video editing software, thereby simplifying the user's operation and increasing the freedom of setting the video cover image.
[0004] In a first aspect, an embodiment of the present application provides a video generation method, comprising: during video recording, when the motion state of the target object meets a preset condition, capturing at least one first image, the first image including the target object; after recording is completed, obtaining a first video; based on the first video and the first target image in the at least one first image, generating a target video, the target video including at least two cover images, and the at least two cover images including the first target image.
[0005] In a second aspect, an embodiment of the present application provides a video generating device, comprising: a shooting module, for capturing at least one first image including the target object when the motion state of the target object meets a preset condition during video recording; a recording module, for obtaining a first video after recording is completed; and a generating module, for generating a target video based on the first video and a first target image in at least one first image, the target video including at least two cover images, and at least the two cover images including the first target image.
[0006] In a third aspect, an embodiment of the present application provides an electronic device, including a processor and a memory, wherein the memory stores programs or instructions that can be executed on the processor, and when the programs or instructions are executed by the processor, the steps of the method of the first aspect are implemented.
[0007] In a fourth aspect, an embodiment of the present application provides a readable storage medium, on which a program or instruction is stored, and when the program or instruction is executed by a processor, the steps of the method of the first aspect are implemented.
[0008] In a fifth aspect, an embodiment of the present application provides a chip, which includes a processor and a communication interface, the communication interface is coupled to the processor, and the processor is used to run programs or instructions to implement the steps of the first aspect and the method of the first aspect.
[0009] In a sixth aspect, an embodiment of the present application provides a computer program product, which is stored in a storage medium and is executed by at least one processor to implement the method of the first aspect.
[0010] In the embodiment of the present application, during the process of video recording by the electronic device, the motion state of the target object can be detected, and when the motion state of the target object meets the preset conditions, the target object is automatically photographed, so that photographing can be performed during the process of video recording without user operation, which improves the convenience of users taking photos during video recording. After the first image is captured, the target video can be automatically generated according to the first target image in the first image and the first video obtained by recording, so that the cover image of the target video includes the first target image, so that the target video can be set with the cover image required by the user without using additional video editing software, which simplifies the user's operation and improves the degree of freedom in setting the video cover image. BRIEF DESCRIPTION OF THE DRAWINGS
[0011] Figure 1 A schematic diagram of a process flow of a video generation method provided in an embodiment of the present application is shown;
[0012] Figure 2 One of the schematic diagrams of the preview interface of the target video provided in the embodiment of the present application is shown;
[0013] Figure 3 A second schematic diagram of a preview interface of a target video provided in an embodiment of the present application is shown;
[0014] Figure 4 A third schematic diagram showing a preview interface of a target video provided in an embodiment of the present application is shown;
[0015] Figure 5 A fourth schematic diagram of a preview interface of a target video provided in an embodiment of the present application is shown;
[0016] Figure 6 A schematic diagram of a shooting parameter setting interface provided in an embodiment of the present application is shown;
[0017] Figure 7 A structural block diagram of a video generation device provided in an embodiment of the present application is shown;
[0018] Figure 8 A structural block diagram of an electronic device provided in an embodiment of the present application is shown;
[0019] Fig. 9 A schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present application is shown. DETAILED DESCRIPTION
[0020] The following will be combined with the drawings in the embodiments of the present application to clearly describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, rather than all the embodiments. All other embodiments obtained by ordinary technicians in this field based on the embodiments in the present application belong to the scope of protection of this application.
[0021] The terms "first", "second", etc. in the specification and claims of the present application are used to distinguish similar objects, and are not used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable under appropriate circumstances, so that the embodiments of the present application can be implemented in an order other than those illustrated or described here, and the objects distinguished by "first", "second", etc. are generally of one type, and the number of objects is not limited. For example, the first object can be one or more. In addition, "and / or" in the specification and claims represents at least one of the connected objects, and the character " / " generally indicates that the objects associated with each other are in an "or" relationship.
[0022] The following is combined with Figures 1 to 9 , the video generation method, video generation device, electronic device and storage medium provided in the embodiments of the present application are described in detail through specific embodiments and their application scenarios.
[0023] In an embodiment of the present application, a video generation method is provided. Figure 1 A schematic diagram of the process of the video generation method provided in the embodiment of the present application is shown. Figure 1 As shown, the video generation method includes:
[0024] Step 102, during the video recording process, when the motion state of the target object meets a preset condition, at least one first image is captured, and the first image includes the target object;
[0025] It should be noted that, during the process of video recording by the electronic device, the motion state of the target object in the recorded video can be continuously identified by image recognition.
[0026] Specifically, the posture of the target object in each video frame including the target object in the recorded video is identified, so as to obtain the posture change state of the target object in the video frame, that is, the motion state of the target object.
[0027] Exemplarily, the target object may be a portrait. When a portrait is detected in the recorded video, the posture of the portrait in each video frame is continuously detected, and the motion state of the target object is determined by the changes in the posture of the portrait in the video frame.
[0028] Step 104, after recording is completed, a first video is obtained;
[0029] Step 106: Generate a target video based on the first video and the first target image in at least one first image, wherein the target video includes at least two cover images, and the at least two cover images include the first target image.
[0030] In an embodiment of the present application, when a user is recording a first video including a target object through an electronic device, the electronic device can automatically detect the motion state of the target object during the video recording process, and when it is detected that the motion state of the target object meets a preset condition, a photo-taking operation is performed on the target object, thereby obtaining a first image including the target object.
[0031] After the video recording is completed, a first video and a first image captured during the recording process are obtained. According to the first video and the first target image in at least one of the first images, a target video can be generated. The target video includes at least two cover images, and at least two cover images include the first target image.
[0032] The first target image is an image selected by a user from at least one first image.
[0033] For example, during the video recording process, four first images are captured, and the user selects three first target images from the four first images as the cover images of the target video. Then, the electronic device can generate the target video based on the three first target images and the recorded first video. When the target video is displayed in thumbnail form, the three first target images can be viewed on the cover of the target video. The three first target images can be scrolled and displayed on the cover of the target video, and can also be arranged and displayed on the cover of the target video.
[0034] Figure 2 One of the schematic diagrams of the preview interface of the target video provided in the embodiment of the present application is shown, such as Figure 2 As shown, a thumbnail image of the target video 200 is displayed in the display interface of the electronic device, and three cover images 202 are displayed in the thumbnail image. The three cover images 202 are taken during the recording process of the target video 200.
[0035] For example, when a user needs to record a selfie video with a mobile phone, and after the mobile phone is placed in a fixed position, the user enters the shooting angle of the mobile phone. The mobile phone starts recording the selfie video and continuously detects the motion state of the user (target object). When it is detected that the motion state of the user meets the preset conditions, the mobile phone automatically shoots the user to obtain a first image including the user image.
[0036] In the embodiment of the present application, during the process of video recording by the electronic device, the motion state of the target object can be detected, and when the motion state of the target object meets the preset conditions, the target object is automatically photographed, so that photographing can be performed during the process of video recording without user operation, which improves the convenience of users taking photos during video recording. After the first image is captured, the target video can be automatically generated according to the first target image in the first image and the first video obtained by recording, so that the cover image of the target video includes the first target image, so that the target video can be set with the cover image required by the user without using additional video editing software, which simplifies the user's operation and improves the degree of freedom in setting the video cover image.
[0037] In some embodiments of the present application, a target video is generated based on a first video and a first target image in at least one first image, including: displaying at least one first image; receiving a first input from a user for the first target image in the first image; in response to the first input, replacing a first video segment in the first video with the first target image according to the shooting moment of the first target image, wherein a degree of match between image content of each frame of the video image in the first video segment and image content of the first target image is greater than a preset threshold.
[0038] In the embodiment of the present application, the recorded first video includes a video clip of the process of shooting the first image. After completing the recording of the first video, the electronic device can identify the video clip in the first video according to the first image shot. After the user selects the first target image in at least one first image, the system can identify the first video clip corresponding to the first target image and replace the first video clip in the first video with the first target image.
[0039] The electronic device identifies the correspondence between the first video segment and the first target image based on the image content of each frame of the video image in the first video and the image content of the first target image. Specifically, the electronic device identifies the image content such as the posture and image of the target object in the first target image through image recognition technology, and finds the first video segment in the first video.
[0040] In some possible implementations, to improve the accuracy of identifying the first video segment, the electronic device can also obtain the shooting time of the first target image and the recording time of each frame of the video image in the first video. According to the shooting time, the recording time range is determined. The recording time range is used as the time range for searching the first video segment.
[0041] Specifically, after completing recording the first video, the electronic device displays all captured first images. The user performs a first input on the first target image in the first image to select the first target image. After the electronic device determines the first target image in the first image, it replaces the first video segment corresponding to the first target image with the first target image to obtain the target video, so that the first video segment corresponding to the shooting process of the first target image does not exist in the target video.
[0042] Exemplarily, a user records a selfie video through a mobile phone, and the mobile phone automatically captures multiple first images during the recording process. After the first video is recorded, the electronic device displays the multiple first images, and the user selects a first target image from the multiple first images by clicking. Based on the first target image, the electronic device automatically identifies the first video segment corresponding to the shooting process of the first target image in the first video, and replaces the first video segment with the first target image to generate a target video. When the target video is played to the progress of the shooting process of the first target image, the first target image is displayed.
[0043] It should be noted that the first video clip includes multiple frames of video images. In the process of replacing the first video clip with the first target image, the multiple frames of video images are replaced with one frame of the first target image, which ensures that during the playback of the target video, only the target image is displayed, and the shooting process of the target image is not displayed, thereby improving the smoothness of the playback of the target video and reducing the space occupied by the target video.
[0044] In the embodiment of the present application, the electronic device can find the first video clip during the shooting process of the first target image according to the image content of the first target image selected by the user in the first image and the image content of multiple frames of video images in the first video, and replace the first video clip with the first target image. The first video clip of the shooting process of the first target image in the first video is accurately deleted, ensuring that only the target image is displayed during the playback of the target video, and not the shooting process of the target image, thereby improving the smoothness of the playback of the target video and reducing the space occupied by the target video.
[0045] In some embodiments of the present application, after generating the target video, the video generation method further includes: receiving a second input from a user for a first target cover image among at least two cover images; in response to the second input, playing the target video from a target time point, and the target time point is associated with the shooting moment of the first target cover image.
[0046] In the embodiment of the present application, at least two cover images in the target video correspond to the play time point in the target video. In the preview interface of the target video, the target video is not played, and the target video displays at least two cover images. The user selects the first target cover image from the at least two cover images by clicking, and the target video starts playing at the target time point corresponding to the first target cover image.
[0047] It should be noted that the cover image may include the first image captured in the recorded video, and may also include a target video image selected by the user from multiple frames of video images in the first video.
[0048] In the case where the first target image is the first image, after the user selects the first target image by executing the second input, the shooting time of the first image is obtained, and the target time point in the target video is searched according to the shooting time of the first image. The shooting time of the video image corresponding to the target time point is the same as the shooting time of the first image.
[0049] In the case where the first target image is the target video image selected by the user from multiple frames of video images in the first video, after the user selects the first target image by executing the second input, the target time point is determined according to the shooting moment of the target video image, and the target video starts playing at the target time point.
[0050] Figure 3 A second schematic diagram of a preview interface of a target video provided in an embodiment of the present application is shown, Figure 3 As shown, when multiple cover images are displayed in the preview interface 300, the user clicks on the first target cover image 302 among the multiple cover images to start playing the target video at the time point corresponding to the playing moment of the cover image in the target video.
[0051] In an embodiment of the present application, the electronic device establishes a mapping relationship between at least two cover images and the playback time point in the target video. After the user selects the first target cover image among the at least two cover images, the target video can be played at the target time point corresponding to the first target cover image, so that the user can easily adjust the time point when the target video starts playing, avoiding the need for the user to repeatedly adjust the playback progress during the playback of the target video when the user needs to watch the video at the target time point, thereby simplifying the operation steps for the user to find the video content corresponding to the cover image.
[0052] In some embodiments of the present application, generating a target video based on the first video and a first target image in the at least one first image includes:
[0053] displaying at least one first image;
[0054] receiving a sixth input from a user regarding a third target image in the first image;
[0055] In response to the sixth input, a first control is displayed in the target video according to the shooting time of the third target image; wherein, the playback progress of the target video can be adjusted to the shooting time of the third target image through the first control, and a thumbnail of the third target image is displayed on the first control.
[0056] In the embodiment of the present application, after obtaining the target video, a first control for adjusting the playback progress is displayed. During the playback of the target video, the first control is displayed, and the user performs an operation input on the first control to jump to the playback progress corresponding to the shooting moment of the third target image in the target video.
[0057] Figure 4 A third schematic diagram of a preview interface of a target video provided in an embodiment of the present application is shown, Figure 4 As shown, during the playback of the target video, a first control 404 is displayed on a progress bar 402 in the target video, and a thumbnail of a third target image is displayed at a corresponding position of the first control 404. By clicking on the thumbnail, the user can jump to the playback time point of the corresponding shooting moment of the third target image.
[0058] In the embodiment of the present application, the user can select the shooting moment of the third target image during the recording of the first video, and set a first control for jumping the video playback progress in the target video. During the playback of the target video, the user can jump to the video playback progress corresponding to the shooting moment of the third target image by performing an operation input on the first control, so that the user can quickly find the shooting moment of the third target image during the viewing of the target video.
[0059] In some embodiments of the present application, a target video is generated based on a first video and a first target image in at least one first image, including: displaying at least one first image; receiving a third input from a user for a second target image in at least one first image; and in response to the third input, using the second target image as a cover image of the target video.
[0060] In an embodiment of the present application, after recording the first video, the electronic device displays the first image obtained during the video recording process. After the user selects a second target image from at least one of the first images, the second target image is used as the cover image of the target video.
[0061] Specifically, after completing recording the first video, the electronic device displays all captured first images. The user performs a third input on the second target image in the first image to select the second target image. After the electronic device determines the second target image in the first image, it uses the second target image as the cover image of the target video and displays the cover image in the preview interface of the target video.
[0062] It should be noted that there are multiple cover images, and at least some of the multiple cover images are second target images. The multiple cover images are all set as the second target image in the first image, or some of the multiple cover images are set as the second target image in the first image.
[0063] In an embodiment of the present application, after the first video is recorded, the electronic device displays all the first images captured during the recording process, and the user can select the second target image in the first image as the cover image of the target video, thereby enabling the user to choose to set the cover image of the target video according to actual needs, further simplifying the operation steps for the user to set the cover of the target video.
[0064] In some embodiments of the present application, after generating the target video, the video generation method also includes: simultaneously displaying at least two second target cover images in the video cover area of the target video, the at least two cover images including at least two second target cover images; receiving a fourth input from the user; and updating the cover image displayed in the video cover area in response to the fourth input.
[0065] In an embodiment of the present application, the target video is in a preview state, and at least two second target cover images of the target video are displayed in the video cover area of the target video, wherein the at least two cover images include at least two second target cover images, wherein, if the video cover area cannot display the complete cover image, the user can update the cover image displayed in the video cover area by executing a fourth input.
[0066] Specifically, when the target video includes multiple cover images, there is a situation where they cannot be displayed completely. The user executes the fourth input to change the cover image displayed in the video cover area, that is, to scroll and display multiple cover images, so that the user can select each of the multiple cover images.
[0067] Figure 5 A fourth schematic diagram of a preview interface of a target video provided in an embodiment of the present application is shown, Figure 5As shown, multiple cover images 502 are displayed in the cover display area 500 of the preview display interface, and the multiple cover images 502 include two second target cover images, wherein cover image 504 is the second target cover image that can be fully displayed, and cover image 506 is the second target cover image that cannot be fully displayed. The user drags cover image 506 to update the display content in the cover display area 500, so that cover image 506 and cover image 504 are swapped in display position, and cover image 506 that could not be fully displayed originally is fully displayed in the cover display area 500.
[0068] In an embodiment of the present application, when there is an incomplete cover image in the cover display area of the target video, the user can execute the fourth input to adjust and update the cover image displayed in the cover display area, thereby enabling the user to conveniently view all cover images and facilitating the user to select multiple cover images.
[0069] In some embodiments of the present application, the preset condition includes any one of the following: the posture of the target object is in a preset posture, and the duration of the target object being in a stationary state reaches a preset duration.
[0070] In the embodiment of the present application, the user can choose to use different modes to control the electronic device to automatically capture a first image including a target object during video recording.
[0071] When the target object remains stationary for a preset time period, the electronic device is controlled to automatically shoot the target object to obtain a first image.
[0072] Specifically, during the video recording process, when the electronic device detects that the change amplitude of the posture of the target object in multiple consecutive video frames is less than a preset amplitude, it can determine that the target object is in a stopped state for a preset time. It is worth noting that the number of video frames detected corresponds to the preset time, that is, all video frames within the preset time.
[0073] For example, when a user needs to record a selfie video with a mobile phone, the user places the mobile phone in a fixed position and enters the shooting angle of the mobile phone. The mobile phone starts recording the selfie video and continuously detects the motion state of the user (target object). At this time, the user can make the action he wants to shoot and maintain the action for a preset time. After the mobile phone detects that the target object has stopped moving for a preset time, it automatically starts shooting.
[0074] Before recording the video, the user sets the preset posture according to actual needs. During the video recording process, when the electronic device detects that the target object in the video is in the preset posture, the electronic device captures the first image.
[0075] Specifically, during the video recording process, the electronic device detects the image content of the video image, and automatically captures the first image of the target object when the posture of the target object in the image content matches the preset posture set in advance. It should be noted that the preset posture includes posture information and error information, so that even if there is a certain error between the actual posture of the target object and the preset posture, it can still be recognized and automatically captured, thereby improving the recognition rate and shooting success rate.
[0076] In an embodiment of the present application, during the process of video recording by an electronic device, the motion state of the target object can be detected. When the posture of the target object is in a preset posture or the target object is in a static state for a preset time, the target object is automatically photographed, thereby realizing that photographing can be performed during video recording without user operation, thereby improving the convenience of users taking photos during video recording.
[0077] In some embodiments of the present application, before recording a video, the video generation method also includes: receiving a fifth input from the user to the parameter setting window while displaying the parameter setting window; determining shooting parameters in response to the fifth input; wherein the shooting parameters include at least one of the following: shooting parameters of the image, shooting parameters of the video.
[0078] In the embodiment of the present application, before the electronic device starts recording a video, the electronic device displays a parameter setting window. The user can set the shooting parameters of the subsequent video recording of the electronic device by performing the fifth input on the parameter setting window, and can also set the image shooting parameters of the images captured during the video recording process.
[0079] After the shooting parameters are set, the electronic device records the first video according to the video shooting parameters and captures the first image according to the image shooting parameters during the video recording process.
[0080] The video shooting parameters include at least one of the following: video recording effects, video recording angle of view, and video recording frame rate.
[0081] The image shooting parameters include at least one of the following: image shooting effects, shooting angle of view, and image shooting size.
[0082] Figure 6 FIG. 4 shows a schematic diagram of a shooting parameter setting interface provided in an embodiment of the present application. Figure 6 As shown, a parameter setting window 602 in the shooting parameter setting interface 600 of the electronic device displays a plurality of controls 604 corresponding to image shooting special effects that can be added, and the user sequentially clicks the controls 604 according to actual needs. The parameter setting window 602 in the shooting parameter setting interface 600 of the electronic device sequentially displays special effect identifiers 606 corresponding to the added image shooting special effects.
[0083] It should be noted that, in the case where the image special effects are set before the shooting begins, when the electronic device records the first video, the image special effects are set for the multiple first images captured in the order in which the special effects are added. For example, if the user adds sticker special effects, blur special effects, no special effects, and auto zoom special effects in sequence, the electronic device will sequentially configure sticker special effects, blur special effects, no special effects, and auto zoom special effects to the first, second, third, and fourth images captured during the recording of the first video, and no special effects will be configured for the images captured thereafter.
[0084] In an embodiment of the present application, a user can set the video shooting parameters and image shooting parameters in advance before the electronic device starts recording the video, without having to set them during the video recording process, thereby simplifying the user's video recording operation steps and improving operational convenience.
[0085] The video generation method provided in the embodiment of the present application can be executed by a video generation device. In the embodiment of the present application, the method of executing video generation by a video generation device is taken as an example to illustrate the video generation device provided in the embodiment of the present application.
[0086] In some embodiments of the present application, a video generating device is provided. Figure 7 The structure block diagram of the video generation device provided in the embodiment of the present application is shown as follows: Figure 7 As shown, the video generating device 700 includes:
[0087] The shooting module 702 is used to shoot and obtain at least one first image including the target object when the motion state of the target object meets a preset condition during the video recording process;
[0088] A recording module 704, used to obtain a first video after recording is completed;
[0089] The generating module 706 is used to generate a target video based on the first video and the first target image in at least one first image, wherein the target video includes at least two cover images, and the at least two cover images include the first target image.
[0090] In the embodiment of the present application, during the process of video recording by the electronic device, the motion state of the target object can be detected, and when the motion state of the target object meets the preset conditions, the target object is automatically photographed, so that photographing can be performed during the process of video recording without user operation, which improves the convenience of users taking photos during video recording. After the first image is captured, the target video can be automatically generated according to the first target image in the first image and the first video obtained by recording, so that the cover image of the target video includes the first target image, so that the target video can be set with the cover image required by the user without using additional video editing software, which simplifies the user's operation and improves the degree of freedom in setting the video cover image.
[0091] In some embodiments of the present application, the video generating device 700 further includes:
[0092] A first display module, configured to display at least one first image;
[0093] A first receiving module, used for receiving a first input of a user on a first target image in a first image;
[0094] The first processing module is used to replace the first video segment in the first video with the first target image in response to the first input according to the shooting time of the first target image, wherein the matching degree between the image content of each frame of the video image in the first video segment and the image content of the first target image is greater than a preset threshold.
[0095] In the embodiment of the present application, the electronic device can find the first video clip during the shooting process of the first target image according to the image content of the first target image selected by the user in the first image and the image content of multiple frames of video images in the first video, and replace the first video clip with the first target image. The first video clip of the shooting process of the first target image in the first video is accurately deleted, ensuring that only the target image is displayed during the playback of the target video, and not the shooting process of the target image, thereby improving the smoothness of the playback of the target video and reducing the space occupied by the target video.
[0096] In some embodiments of the present application, the video generating device 700 further includes:
[0097] A second receiving module, configured to receive a second input from a user regarding a first target cover image among the at least two cover images;
[0098] The second display module is used to play the target video from a target time point in response to the second input, and the target time point is associated with the shooting moment of the first target cover image.
[0099] In an embodiment of the present application, the electronic device establishes a mapping relationship between at least two cover images and the playback time point in the target video. After the user selects the first target cover image among the at least two cover images, the target video can be played at the target time point corresponding to the first target cover image, so that the user can easily adjust the time point when the target video starts playing, avoiding the need for the user to repeatedly adjust the playback progress during the playback of the target video when the user needs to watch the video at the target time point, thereby simplifying the operation steps for the user to find the video content corresponding to the cover image.
[0100] In some embodiments of the present application, the video generating device 700 further includes:
[0101] a fifth display module, configured to display at least one first image;
[0102] a fifth receiving module, configured to receive a sixth input from a user on a third target image in the first image;
[0103] The fifth display module is also used to respond to the sixth input and display a first control in the target video according to the shooting time of the third target image; wherein, the playback progress of the target video can be adjusted to the shooting time of the third target image through the first control, and a thumbnail of the third target image is displayed on the first control.
[0104] In the embodiment of the present application, the user can select the shooting moment of the third target image during the recording of the first video, and set a first control for jumping the video playback progress in the target video. During the playback of the target video, the user can jump to the video playback progress corresponding to the shooting moment of the third target image by performing an operation input on the first control, so that the user can quickly find the shooting moment of the third target image during the viewing of the target video.
[0105] In some embodiments of the present application, the video generating device 700 further includes:
[0106] A third display module, configured to display at least one first image;
[0107] A third receiving module, used for receiving a third input from a user on a second target image in at least one first image;
[0108] The second processing module is used to respond to the third input and use the second target image as the cover image of the target video.
[0109] In an embodiment of the present application, after the first video is recorded, the electronic device displays all the first images captured during the recording process, and the user can select the second target image in the first image as the cover image of the target video, thereby enabling the user to choose to set the cover image of the target video according to actual needs, further simplifying the operation steps for the user to set the cover of the target video.
[0110] In some embodiments of the present application, the video generating device 700 further includes:
[0111] A fourth display module, configured to simultaneously display at least two second target cover images in the video cover area of the target video, wherein the at least two cover images include at least two second target cover images;
[0112] A fourth receiving module, used to receive a fourth input from a user;
[0113] An updating module is used to update the cover image displayed in the video cover area in response to a fourth input.
[0114] In an embodiment of the present application, when there is an incomplete cover image in the cover display area of the target video, the user can execute the fourth input to adjust and update the cover image displayed in the cover display area, thereby enabling the user to conveniently view all cover images and facilitating the user to select multiple cover images.
[0115] In some embodiments of the present application, the preset condition includes any of the following:
[0116] The posture of the target object is in a preset posture, and the duration for which the target object is in a static state reaches a preset duration.
[0117] In an embodiment of the present application, during the process of video recording by an electronic device, the motion state of the target object can be detected. When the posture of the target object is in a preset posture or the target object is in a static state for a preset time, the target object is automatically photographed, thereby realizing that photographing can be performed during video recording without user operation, thereby improving the convenience of users taking photos during video recording.
[0118] In some embodiments of the present application, the video generating device 700 further includes:
[0119] a fifth receiving module, configured to receive a fifth input of the user to the parameter setting window when the parameter setting window is displayed;
[0120] a determination module, configured to determine a shooting parameter in response to a fifth input;
[0121] The shooting parameters include at least one of the following: image shooting parameters and video shooting parameters.
[0122] In an embodiment of the present application, a user can set the video shooting parameters and image shooting parameters in advance before the electronic device starts recording the video, without having to set them during the video recording process, thereby simplifying the user's video recording operation steps and improving operational convenience.
[0123] The video generating device of the electronic device in the embodiment of the present application can be an electronic device, or a component in the electronic device, such as an integrated circuit or a chip. The electronic device can be a terminal, or other devices other than a terminal. Exemplarily, the electronic device can be a mobile phone, a tablet computer, a laptop computer, a PDA, a vehicle-mounted electronic device, a mobile Internet device (Mobile Internet Device, MID), an augmented reality (augmented reality, AR) / virtual reality (virtual reality, VR) device, a robot, a wearable device, an ultra-mobile personal computer (ultra-mobile personal computer, UMPC), a netbook or a personal digital assistant (personal digital assistant, PDA), etc., and can also be a server, a network attached storage (Network Attached Storage, NAS), a personal computer (personal computer, PC), a television (television, TV), a teller machine or a self-service machine, etc., which is not specifically limited in the embodiment of the present application.
[0124] The video generation device of the electronic device in the embodiment of the present application may be a device having an operating system. The operating system may be an Android operating system, an iOS operating system, or other possible operating systems, which are not specifically limited in the embodiment of the present application.
[0125] The video generating device of the electronic device provided in the embodiment of the present application can implement each process implemented in the above method embodiment and achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0126] Optionally, an embodiment of the present application further provides an electronic device, which includes a video generating device as in any of the above embodiments, and thus has all the beneficial effects of the video generating device in any of the embodiments, which will not be elaborated herein.
[0127] Optionally, an embodiment of the present application further provides an electronic device, Figure 8 A structural block diagram of an electronic device according to an embodiment of the present application is shown. Figure 8As shown, the electronic device 800 includes a processor 802 and a memory 804. The memory 804 stores programs or instructions that can be executed on the processor 802. When the programs or instructions are executed by the processor 802, the various processes of the above-mentioned video generation method embodiment are implemented and the same technical effect can be achieved. To avoid repetition, they are not described here.
[0128] It should be noted that the electronic devices in the embodiments of the present application include the above-mentioned mobile electronic devices and non-mobile electronic devices.
[0129] Fig. 9 A schematic diagram of the hardware structure of an electronic device to implement an embodiment of the present application.
[0130] The electronic device 900 includes but is not limited to: a radio frequency unit 901, a network module 902, an audio output unit 903, an input unit 904, a sensor 905, a display unit 906, a user input unit 907, an interface unit 908, a memory 909, a processor 910 and other components.
[0131] Those skilled in the art will appreciate that the electronic device 900 may also include a power source (such as a battery) for supplying power to each component, and the power source may be logically connected to the processor 910 through a power management system, thereby implementing functions such as managing charging, discharging, and power consumption management through the power management system. Fig. 9 The electronic device structure shown in the figure does not constitute a limitation on the electronic device. The electronic device may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently, which will not be described in detail here.
[0132] The processor 910 is configured to capture at least one first image including the target object when the motion state of the target object meets a preset condition during the video recording process;
[0133] Processor 910, for obtaining a first video after recording is completed;
[0134] Processor 910 is used to generate a target video based on the first video and a first target image in at least one first image, where the target video includes at least two cover images, and the at least two cover images include the first target image.
[0135] In the embodiment of the present application, during the process of video recording by the electronic device, the motion state of the target object can be detected, and when the motion state of the target object meets the preset conditions, the target object is automatically photographed, so that photographing can be performed during the process of video recording without user operation, which improves the convenience of users taking photos during video recording. After the first image is captured, the target video can be automatically generated according to the first target image in the first image and the first video obtained by recording, so that the cover image of the target video includes the first target image, so that the target video can be set with the cover image required by the user without using additional video editing software, which simplifies the user's operation and improves the degree of freedom in setting the video cover image.
[0136] Further, the display unit 906 is used to display at least one first image;
[0137] A user input unit 907, configured to receive a first input from a user on a first target image in the first image;
[0138] Processor 910 is used to replace a first video segment in a first video with a first target image in response to a first input according to a shooting time of the first target image, wherein a degree of matching between image content of each frame of the video image in the first video segment and image content of the first target image is greater than a preset threshold.
[0139] In the embodiment of the present application, the electronic device can find the first video clip during the shooting process of the first target image according to the image content of the first target image selected by the user in the first image and the image content of multiple frames of video images in the first video, and replace the first video clip with the first target image. The first video clip of the shooting process of the first target image in the first video is accurately deleted, ensuring that only the target image is displayed during the playback of the target video, and not the shooting process of the target image, thereby improving the smoothness of the playback of the target video and reducing the space occupied by the target video.
[0140] Further, the user input unit 907 is used to receive a second input from a user on a first target cover image among the at least two cover images;
[0141] Processor 910 is used to respond to the second input and start playing the target video from a target time point, where the target time point is associated with the shooting moment of the first target cover image.
[0142] In an embodiment of the present application, the electronic device establishes a mapping relationship between at least two cover images and the playback time point in the target video. After the user selects the first target cover image among the at least two cover images, the target video can be played at the target time point corresponding to the first target cover image, so that the user can easily adjust the time point when the target video starts playing, avoiding the need for the user to repeatedly adjust the playback progress during the playback of the target video when the user needs to watch the video at the target time point, thereby simplifying the operation steps for the user to find the video content corresponding to the cover image.
[0143] Further, the display unit 906 is used to display at least one first image;
[0144] A user input unit 907, configured to receive a sixth input from a user on a third target image in the first image;
[0145] The display unit 906 is used to respond to the sixth input and display a first control in the target video according to the shooting time of the third target image; wherein, the playback progress of the target video can be adjusted to the shooting time of the third target image through the first control, and a thumbnail of the third target image is displayed on the first control.
[0146] In the embodiment of the present application, the user can select the shooting moment of the third target image during the recording of the first video, and set a first control for jumping the video playback progress in the target video. During the playback of the target video, the user can jump to the video playback progress corresponding to the shooting moment of the third target image by performing an operation input on the first control, so that the user can quickly find the shooting moment of the third target image during the viewing of the target video.
[0147] Further, the display unit 906 is used to display at least one first image;
[0148] A user input unit 907, configured to receive a third input from a user on a second target image in at least one first image;
[0149] The processor 910 is configured to use the second target image as a cover image of the target video in response to a third input.
[0150] In an embodiment of the present application, after the first video is recorded, the electronic device displays all the first images captured during the recording process, and the user can select the second target image in the first image as the cover image of the target video, thereby enabling the user to choose to set the cover image of the target video according to actual needs, further simplifying the operation steps for the user to set the cover of the target video.
[0151] Further, the display unit 906 is used to simultaneously display at least two second target cover images in the video cover area of the target video, wherein the at least two cover images include at least two second target cover images;
[0152] A user input unit 907, configured to receive a fourth input from a user;
[0153] Processor 910 is used to update the cover image displayed in the video cover area in response to a fourth input.
[0154] In an embodiment of the present application, when there is an incomplete cover image in the cover display area of the target video, the user can execute the fourth input to adjust and update the cover image displayed in the cover display area, thereby enabling the user to conveniently view all cover images and facilitating the user to select multiple cover images.
[0155] Furthermore, the preset condition includes any one of the following: the posture of the target object is in a preset posture, and the duration of the target object being in a stationary state reaches a preset duration.
[0156] In an embodiment of the present application, during the process of video recording by an electronic device, the motion state of the target object can be detected. When the posture of the target object is in a preset posture or the target object is in a static state for a preset time, the target object is automatically photographed, thereby realizing that photographing can be performed during video recording without user operation, thereby improving the convenience of users taking photos during video recording.
[0157] Further, the user input unit 907 is used to receive a fifth input of the user to the parameter setting window when the parameter setting window is displayed;
[0158] Processor 910, configured to determine shooting parameters in response to a fifth input;
[0159] The shooting parameters include at least one of the following: image shooting parameters and video shooting parameters.
[0160] In an embodiment of the present application, a user can set the video shooting parameters and image shooting parameters in advance before the electronic device starts recording the video, without having to set them during the video recording process, thereby simplifying the user's video recording operation steps and improving operational convenience.
[0161] It should be understood that in the embodiment of the present application, the input unit 904 may include a graphics processor (Graphics Processing Unit, GPU) 9041 and a microphone 9042, and the graphics processor 9041 processes the image data of the static picture or video obtained by the image capture device (such as a camera) in the video capture mode or the image capture mode. The display unit 906 may include a display panel 9061, and the display panel 9061 may be configured in the form of a liquid crystal display, an organic light emitting diode, etc. The user input unit 907 includes a touch panel 9071 and at least one of other input devices 9072. The touch panel 9071 is also called a touch screen. The touch panel 9071 may include at least two parts of a touch detection device and a touch controller. Other input devices 9072 may include, but are not limited to, a physical keyboard, function keys (such as volume control keys, switch keys, etc.), a trackball, a mouse, and a joystick, which will not be repeated here.
[0162] The memory 909 can be used to store software programs and various data. The memory 909 may mainly include a first storage area for storing programs or instructions and a second storage area for storing data, wherein the first storage area may store an operating system, an application program or instructions required for at least one function (such as a sound playback function, an image playback function, etc.), etc. In addition, the memory 909 may include a volatile memory or a non-volatile memory, or the memory 909 may include both volatile and non-volatile memories. Among them, the non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), a static random access memory (SRAM), a dynamic random access memory (DRAM), a synchronous dynamic random access memory (SDRAM), a double data rate synchronous dynamic random access memory (DDRSDRAM), an enhanced synchronous dynamic random access memory (ESDRAM), a synchronous link dynamic random access memory (SLDRAM) and a direct memory bus random access memory (DRRAM). The memory 909 in the embodiment of the present application includes but is not limited to these and any other suitable types of memory.
[0163] The processor 910 may include one or more processing units; optionally, the processor 910 integrates an application processor and a modem processor, wherein the application processor mainly processes operations related to an operating system, a user interface, and application programs, and the modem processor mainly processes wireless communication signals, such as a baseband processor. It is understandable that the modem processor may not be integrated into the processor 910.
[0164] An embodiment of the present application also provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, the various processes of the above-mentioned method embodiment are implemented and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.
[0165] The processor is the processor in the electronic device in the above embodiment. The readable storage medium includes a computer readable storage medium, such as a computer read-only memory ROM, a random access memory RAM, a magnetic disk or an optical disk.
[0166] An embodiment of the present application further provides a chip, which includes a processor and a communication interface, wherein the communication interface and the processor are coupled, and the processor is used to run programs or instructions to implement the various processes of the above-mentioned video generation method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0167] It should be understood that the chip mentioned in the embodiments of the present application can also be called a system-level chip, a system chip, a chip system or a system-on-chip chip, etc.
[0168] An embodiment of the present application provides a computer program product, which is stored in a storage medium. The program product is executed by at least one processor to implement the various processes of the above-mentioned video generation method embodiment and can achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0169] It should be noted that, in this article, the terms "comprise", "include" or any other variant thereof are intended to cover non-exclusive inclusion, so that the process, method, article or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise one..." do not exclude the presence of other identical elements in the process, method, article or device including the element. In addition, it should be pointed out that the scope of the methods and devices in the embodiments of the present application is not limited to performing functions in the order shown or discussed, and may also include performing functions in a substantially simultaneous manner or in reverse order according to the functions involved, for example, the described method may be performed in an order different from that described, and various steps may also be added, omitted, or combined. In addition, the features described with reference to certain examples may be combined in other examples.
[0170] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a computer software product, which is stored in a storage medium (such as ROM / RAM, a disk, or an optical disk), and includes a number of instructions for a terminal (which can be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods of each embodiment of the present application.
[0171] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present application, ordinary technicians in this field can also make many forms without departing from the purpose of the present application and the scope of protection of the claims, all of which are within the protection of the present application.
Claims
1. A video generation method, It is characterized in that include: During the video recording process, when the motion state of the target object meets a preset condition, at least one first image is captured, wherein the first image includes the target object; After recording is completed, the first video is obtained; displaying the at least one first image; receiving a first input from a user regarding a first target image in the at least one first image; In response to the first input, according to the shooting time of the first target image, the first video segment in the first video is replaced with the first target image to generate a target video, wherein the degree of match between the image content of each frame of the video image in the first video segment and the image content of the first target image is greater than a preset threshold, and the target video includes at least two cover images, and the at least two cover images include the first target image.
2. The video generation method according to claim 1, It is characterized in that After generating the target video, the video generation method further includes: receiving a second input from a user regarding a first target cover image among the at least two cover images; In response to the second input, the target video is played starting from a target time point, and the target time point is associated with the shooting moment of the first target cover image.
3. The video generation method according to claim 1, It is characterized in that The method further comprises: receiving a third input from a user regarding a second target image in at least one of the first images; In response to the third input, the second target image is used as a cover image of the target video.
4. The video generation method according to any one of claims 1 to 3, It is characterized in that After generating the target video, the video generation method further includes: Simultaneously displaying at least two second target cover images in the video cover area of the target video, the at least two cover images including the at least two second target cover images; receiving a fourth input from the user; In response to the fourth input, the cover image displayed in the video cover area is updated.
5. The video generation method according to any one of claims 1 to 3, It is characterized in that The preset condition includes any of the following: The posture of the target object is in a preset posture, and the duration for which the target object is in a static state reaches a preset duration.
6. The video generation method according to any one of claims 1 to 3, It is characterized in that Before recording the video, the method further includes: In the case where the parameter setting window is displayed, receiving a fifth input from the user on the parameter setting window; In response to the fifth input, determining a shooting parameter; The shooting parameters include at least one of the following: image shooting parameters and video shooting parameters.
7. A video generating device, It is characterized in that include: A shooting module, used for shooting and obtaining at least one first image including the target object when the motion state of the target object meets a preset condition during the video recording process; A recording module, used to obtain a first video after recording is completed; A generating module, configured to generate a target video based on the first video and a first target image in the at least one first image, wherein the target video includes at least two cover images, and the at least two cover images include the first target image; A first display module, configured to display at least one of the first images; A first receiving module, configured to receive a first input from a user regarding a first target image in the first image; A first processing module is used to respond to the first input and replace the first video segment in the first video with the first target image according to the shooting time of the first target image to generate a target video, wherein the degree of matching between the image content of each frame of the video image in the first video segment and the image content of the first target image is greater than a preset threshold.
8. An electronic device, It is characterized in that include: A processor and a memory, wherein the memory stores a program or instruction that can be run on the processor, and when the program or instruction is executed by the processor, the steps of the video generation method according to any one of claims 1 to 6 are implemented.
