Video generation based on automatically applying target effect resources to target objects
View Patent ↗The present disclosure provides a method and apparatus, and a device and a storage medium for generating videos. The method comprises acquiring a target image to be identified based on a photographed picture in response to receiving an identification operation triggered for the photographed picture on a photographing page; sending the target image to a server, wherein the server is configured to identify a target object from the target image and determine a target effect resource for the target object; receiving the target effect resource from the server, and applying the target effect resource to the target object in the photographed picture, and generating a target video based on the photographed picture corresponding to the target object to which the target effect resource is applied.
1 . A method of generating videos, wherein the method is applied to a client computing device and comprises:
obtaining, by the client computing device, a target image based on a photographed picture on a photographing page in response to determining that an image definition of the target image conforms with a preset definition condition;
transmitting the target image to a server computing device for the server computing device identifying a target object in the target image that was obtained by and transmitted from the client computing device;
receiving a target effect resource from the server computing device, wherein the target effect resource is determined based on identifying the target object in the target image;
applying the target effect resource to the target object during a video shooting process by the client computing device; and
generating a video based on the target object to which the target effect resource is applied during the video shooting process.
2 . The method of claim 1 , wherein the obtaining, by the client computing device, a target image based on a photographed picture further comprises:
obtaining a current image corresponding to the photographed picture as an image with a definition to be determined; and
detecting whether the definition of the image conforms with the preset definition condition; and
identifying the image as the target image in response to detecting that the definition of the image conforms with the preset definition condition.
3 . The method of claim 2 , further comprising:
in response to detecting that the definition of the image fails to conform with the preset definition condition, obtaining another image from photographed pictures on the photographing page based on a preset rule of extracting frame and replacing the image with the other image; and
continuing to execute an operation of detecting whether a definition of the other image conforms with the preset definition condition until it is detected that a preset termination condition is met.
4 . The method of claim 2 , wherein the detecting whether the definition of the image conforms with a preset definition condition further comprises:
processing the image by a model preconfigured to filter fuzzy images and obtaining an image definition value of the image;
identifying that the definition of the image conforms with the preset definition condition in response to detecting that the image definition value of the image is greater than or equal to a value threshold corresponding to the preset definition condition; and
identifying that the definition of the image fails to conform with the preset definition condition in response to detecting that the image definition value of the image is less than the value threshold corresponding to the preset definition condition.
5 . The method of claim 3 , wherein the obtaining another image from photographed pictures on the photographing page based on a preset rule of extracting frame further comprises:
extracting one frame of image from images corresponding to the photographed pictures at intervals of every predetermined time period; or
extracting one frame of image from images corresponding to the photographed pictures at intervals of every predetermined number of frames.
6 . The method of claim 3 , wherein detecting that a preset termination condition is met further comprises:
in response to detecting that a number of frames extracted from the images corresponding to the photographed pictures reaches a preset image extraction number, terminating a process of obtaining another image and determining image definition; or
in response to detecting that an image definition value of the image is less than a preset minimum value, terminating the process of obtaining another image and determining image definition.
7 . The method of claim 1 , further comprising:
receiving position information indicating a location of the target object in the photographed picture from the server computing device; and
applying the target effect resource to the target object in the photographed picture based on the position information during the video shooting process.
8 . A method of generating videos, wherein the method is applied to a server computing device and comprises:
receiving a target image from a client computing device, wherein an image definition of the target image conforms with a preset definition condition;
detecting whether the target image contains any one preset object;
identifying the any one preset object as a target object in response to detecting that the target image contains the any one preset object;
identifying a target effect resource corresponding to the target object; and
transmitting the target effect resource to the client computing device for generating a video by applying the target effect resource to the target object during a video shooting process of the client computing device.
9 . The method of claim 8 , further comprising:
extracting image features of the target image;
comparing the image features with feature information corresponding to preset objects; and
in response to detecting that the image features of the target image match feature information corresponding to the any one preset object, identifying the any one preset object as the target object.
10 . The method of claim 8 , further comprising:
transmitting position information indicating a location of the target object in the photographed picture to the client computing device such that the client computing device applies the target effect resource to the target object in the photographed picture based on the position information during the video shooting process.
11 . A client computing device comprising: a memory, a processor, computer programs stored on the memory and executable by the processor, wherein the computer programs, upon execution by the processor, cause the processor to perform operations comprising:
obtaining, by the client computing device, a target image based on a photographed picture from a photographing page in response to determining that an image definition of the target image conforms with a preset definition condition;
transmitting the target image to a server computing device for the server computing device identifying a target object in the target image that was acquired by and transmitted from the client computing device;
receiving the target effect resource from the server computing device, wherein the target effect resource is determined based on identifying the target object in the target image;
applying the target effect resource to the target object during a video shooting process by the client computing device; and
generating a video based on the target object to which the target effect resource is applied during the video shooting process.
12 . The client computing device of claim 11 , wherein the acquiring, by the client computing device, a target image based on a photographed picture from a photographing page further comprises:
obtaining a current image corresponding to the photographed picture as an image with a definition to be determined; and
detecting whether the definition of the image conforms with the preset definition condition; and
identifying the image as the target image in response to detecting that the definition of the image conforms with the preset definition condition.
13 . The client computing device of claim 12 , the operations further comprising:
in response to detecting that the definition of the image fails to conform with the preset definition condition, acquiring another image from photographed pictures on the photographing page based on a preset rule of extracting frame and replacing the image with the other image; and
continuing to execute an operation of detecting whether a definition of the other image conforms with the preset definition condition until it is detected that a preset termination condition is met.
14 . The client computing device of claim 12 , wherein the detecting whether the definition of the image conforms with a preset definition condition-further comprises:
processing the image by a model preconfigured to filter fuzzy images and obtaining an image definition value of the image;
identifying that the definition of the image conforms with the preset definition condition in response to detecting that the image definition value of the image is greater than or equal to a value threshold corresponding to the preset definition condition; and
identifying that the definition of the image fails to conform with the preset definition condition in response to detecting that the image definition value of the image is less than the value threshold corresponding to the preset definition condition.
15 . The client computing device of claim 13 , wherein the acquiring another image from photographed pictures on the photographing page based on a preset rule of extracting frame further comprises:
extracting one frame of image from images corresponding to the photographed pictures at intervals of every predetermined time period; or
extracting one frame of image from images corresponding to the photographed pictures at intervals of every predetermined number of frames.
16 . The client computing device of claim 13 , wherein detecting that a preset termination condition is met further comprises:
in response to detecting that a number of frames extracted from the images corresponding to the photographed pictures reaches a preset image extraction number, terminating a process of obtaining another image and determining image definition; or
in response to detecting that an image definition value of the image is less than a preset minimum value, terminating the process of obtaining another image and determining image definition.
17 . The client computing device of claim 11 , the operations further comprising:
receiving position information indicating a location of the target object in the photographed picture from the server computing device; and
applying the target effect resource to the target object in the photographed picture based on the position information during the video shooting process.
18 . A server computing device, comprising:
at least one memory, at least one processor, and computer programs stored on the at least one memory and executable by the at least one processor, wherein the computer programs, upon execution by the at least one processor, cause the at least one processor to perform operations comprising:
receiving a target image from a client computing device, wherein an image definition of the target image conforms with a preset definition condition;
detecting whether the target image contains any one preset object;
identifying the any one preset object as a target object in response to detecting that the target image contains the any one preset object;
identifying a target effect resource corresponding to the target object; and
transmitting the target effect resource to the client computing device for generating a video by applying the target effect resource to the target object during a video shooting process of the client computing device.
19 . The server computing device of claim 18 , the operations further comprising:
extracting image features of the target image;
comparing the image features with feature information corresponding to preset objects; and
in response to detecting that the image features of the target image match feature information corresponding to the any one preset object, identifying the any one preset object as the target object.
20 . The server computing device of claim 18 , the operations further comprising:
transmitting position information indicating a location of the target object in the photographed picture to the client computing device such that the client computing device applies the target effect resource to the target object in the photographed picture based on the position information during the video shooting process.