CN112330728A - Image processing method, image processing device, electronic equipment and readable storage medium - Google Patents

Image processing method, image processing device, electronic equipment and readable storage medium Download PDF

Info

Publication number
CN112330728A
CN112330728A CN202011381285.XA CN202011381285A CN112330728A CN 112330728 A CN112330728 A CN 112330728A CN 202011381285 A CN202011381285 A CN 202011381285A CN 112330728 A CN112330728 A CN 112330728A
Authority
CN
China
Prior art keywords
image
input
template
processed
windows
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202011381285.XA
Other languages
Chinese (zh)
Inventor
李琳
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Vivo Mobile Communication Co Ltd
Original Assignee
Vivo Mobile Communication Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Vivo Mobile Communication Co Ltd filed Critical Vivo Mobile Communication Co Ltd
Priority to CN202011381285.XA priority Critical patent/CN112330728A/en
Publication of CN112330728A publication Critical patent/CN112330728A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/30Determination of transform parameters for the alignment of images, i.e. image registration
    • G06T7/33Determination of transform parameters for the alignment of images, i.e. image registration using feature-based methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/149Segmentation; Edge detection involving deformable models, e.g. active contour models
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/74Image or video pattern matching; Proximity measures in feature spaces
    • G06V10/75Organisation of the matching processes, e.g. simultaneous or sequential comparisons of image or video features; Coarse-fine approaches, e.g. multi-scale approaches; using context analysis; Selection of dictionaries
    • G06V10/751Comparing pixel values or logical combinations thereof, or feature values having positional relevance, e.g. template matching

Abstract

The application discloses an image processing method, an image processing device, electronic equipment and a readable storage medium, and belongs to the technical field of image processing. Acquiring image characteristics of an image to be processed; displaying at least one image template corresponding to the image features; receiving a first input acting on the at least one image template; responding to the first input, and carrying out image processing on the image to be processed according to an image template selected by the first input to obtain a target image; and displaying the target image. The problem that in the related technology, the pictures are selected and edited manually by a user, and flexible editing and typesetting cannot be performed according to the characteristics in the pictures, so that image editing is inconvenient is solved.

Description

Image processing method, image processing device, electronic equipment and readable storage medium
Technical Field
The present application belongs to the field of image processing technologies, and in particular, to an image processing method, an image processing apparatus, an electronic device, and a readable storage medium.
Background
Along with the popularization and development of the intelligent terminal, the camera imaging effect of the intelligent terminal is improved, and a user likes to take a picture to record life and share the picture or the image to a social network. At present, most interesting photos are manually synthesized in a later period, and the method is very inconvenient for some users without photo editing bases. For example, to synthesize a heart-shaped interesting photo, a user needs to manually edit the material, and for some users who take small photos, the user is difficult to edit the interesting photo.
In the process of implementing the present application, the inventor finds that at least the following problems exist in the prior art:
at present, interesting photos uploaded to a social network by a user are manually selected, edited and typeset by the user, great inconvenience exists for people who do not use a picture editing and typesetting tool, and flexible editing and typesetting cannot be performed according to features in the photos in the related technology.
In view of the above problems, no effective solution has been proposed.
Content of application
An object of the embodiments of the present application is to provide an image processing method, an apparatus, an electronic device, and a readable storage medium, which can solve the problem in the related art that it is inconvenient to edit an image because a user is relied on to manually select and edit a photo, and the typesetting cannot be flexibly edited according to the features in the photo.
In order to solve the technical problem, the present application is implemented as follows:
in a first aspect, an embodiment of the present application provides an image processing method, where the method includes: acquiring image characteristics of an image to be processed; displaying at least one image template corresponding to the image features; receiving a first input acting on the at least one image template; responding to the first input, and carrying out image processing on the image to be processed according to an image template selected by the first input to obtain a target image; and displaying the target image.
In a second aspect, an embodiment of the present application provides an image processing apparatus, including: the device comprises an acquisition unit, a processing unit and a processing unit, wherein the acquisition unit is used for acquiring the image characteristics of an image to be processed; the first display unit is used for displaying at least one image template corresponding to the image characteristics; a receiving unit for receiving a first input acting on the at least one image template; the processing unit is used for responding to the first input and carrying out image processing on the image to be processed according to the image template selected by the first input so as to obtain a target image; and the second display unit is used for displaying the target image.
In a third aspect, an embodiment of the present application provides an electronic device, which includes a processor, a memory, and a program or instructions stored on the memory and executable on the processor, and when executed by the processor, the program or instructions implement the steps of the image processing method according to the first aspect.
In a fourth aspect, the present application provides a readable storage medium, on which a program or instructions are stored, which when executed by a processor implement the steps of the image processing method according to the first aspect.
In a fifth aspect, an embodiment of the present application provides a chip, where the chip includes a processor and a communication interface, where the communication interface is coupled to the processor, and the processor is configured to execute a program or instructions to implement the image processing method according to the first aspect.
In the embodiment of the application, the image characteristics of the image to be processed are determined; displaying at least one image template corresponding to the image characteristics; receiving a first input acting on at least one image template; responding to the first input, and performing image processing on the image to be processed according to the image template selected by the first input to obtain a target image; and displaying the target image. The method and the device realize flexible image processing of the image to be processed according to the image characteristics, reduce manual dependence on users, improve convenience of image processing, and further solve the problem that in the related art, the images cannot be flexibly edited and typesetted according to the characteristics in the photos due to the fact that the photos are manually selected and edited by the users, and therefore image editing is inconvenient.
Drawings
FIG. 1 is a schematic diagram of a hardware environment for an alternative image processing method according to an embodiment of the present invention;
FIG. 2 is a flow chart illustrating an alternative image processing method according to an embodiment of the present invention;
FIG. 3a is a schematic diagram of an alternative image processing interface according to an embodiment of the present invention;
FIG. 3b is a schematic diagram of yet another alternative image processing interface according to an embodiment of the present invention;
FIG. 4a is a schematic diagram of an alternative image to be processed according to an embodiment of the present invention;
FIG. 4b is a schematic diagram of yet another alternative image processing interface according to an embodiment of the present invention;
FIG. 4c is a schematic illustration of an alternative target image in accordance with an embodiment of the present invention;
FIG. 5 is a schematic diagram of yet another alternative image processing interface according to an embodiment of the present invention;
FIG. 6 is a schematic diagram of yet another alternative image processing interface according to an embodiment of the present invention;
FIG. 7 is a schematic diagram of yet another alternative image processing interface according to an embodiment of the present invention;
FIG. 8 is a schematic diagram of an alternative image processing apparatus according to an embodiment of the present invention;
fig. 9 is a schematic structural diagram of an alternative electronic device according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are some, but not all, embodiments of the present application. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
The terms first, second and the like in the description and in the claims of the present application are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the application are capable of operation in sequences other than those illustrated or described herein. In addition, "and/or" in the specification and claims means at least one of connected objects, a character "/" generally means that a preceding and succeeding related objects are in an "or" relationship.
The image processing method provided by the embodiment of the present application is described in detail below with reference to the accompanying drawings through specific embodiments and application scenarios thereof.
According to an aspect of the embodiments of the present invention, there is provided an image processing method, optionally, as an optional implementation manner, the image processing method may be but is not limited to be applied in an environment as shown in fig. 1, where fig. 1 is a schematic diagram of a hardware environment of the image processing method according to the embodiments of the present invention. As shown in fig. 1, the electronic terminal 10 includes an input part 100, an image capturing part 200, a processor 300, and a display part 400.
In this embodiment, the electronic terminal 10 obtains the image to be processed through the image to be processed input by the input component 100 or the image acquisition component 200, displays the image to be processed in the first preview window 410 of the display component 400, determines the image characteristics of the image to be processed through the processor 300, and displays at least one image template corresponding to the image characteristics in the second preview window 420 of the display component 400; receiving a first input acting on at least one image template; in response to the first input, the processor 300 performs image processing on the image to be processed according to the image template selected by the first input to obtain a target image; the target image is displayed in the first preview window 410. According to the image processing method and device, flexible image processing is performed on the image to be processed according to the image characteristics, manual dependence on a user is reduced, and convenience of image processing is improved.
In this embodiment, the terminal system of the electronic terminal includes, but is not limited to, an Android system, an iOS system, a Linux system, and the like, and the terminal system of the electronic terminal is not limited in this embodiment.
According to an embodiment of the present application, an image processing method is provided. As shown in fig. 2, the method may specifically include the following steps:
s202, acquiring image characteristics of an image to be processed;
s204, displaying at least one image template corresponding to the image characteristics;
s206, receiving a first input acting on at least one image template;
s208, responding to the first input, and performing image processing on the image to be processed according to the image template selected by the first input to obtain a target image;
and S210, displaying the target image.
In this embodiment, the image to be processed may be an image or a video frame in any format, and may be acquired in real time by an electronic terminal, or may be a designated image input into a preset application program.
In this embodiment, the image features include, but are not limited to, gesture features, color features, facial features such as expression features and mouth shape features. The above is merely an example, and does not set any limit to the image features in the present embodiment.
In this embodiment, the image characteristics of the image to be processed are obtained by performing image recognition on the image to be processed, and in addition, recognition modes of the image characteristics of the image to be processed include, but are not limited to, object recognition, character recognition, expression recognition and other image recognition modes.
As an optional technical solution, in this embodiment, the performing image recognition on the image to be processed includes, but is not limited to: and carrying out image recognition on the multiple images to be processed to obtain the same image characteristics of the multiple images to be processed, and determining image templates corresponding to the same image characteristics. It should be noted that, a plurality of the reference numbers here refers to the number of the images to be processed being two or more. Specifically, similar image features of a plurality of images to be processed are determined to be the same image features, then image templates corresponding to the same image features are determined, and the plurality of images to be processed are processed uniformly or in batch. The plurality of images to be processed include, but are not limited to, a plurality of photos obtained through a camera continuous shooting mode, or a plurality of photos in a photo album selected by a user, and a plurality of video frames in a video.
It should be noted that the image template is determined according to the image features of the image to be processed, and the image template is associated with the image features. For example, in one example, the expression feature in the image to be processed is recognized as "happy", and the image template of the image to be processed is determined as the relevant image template corresponding to "happy"; in another example, if the gesture feature to be processed is recognized as "love heart", the image template of the image to be processed is determined as the relevant image template corresponding to the "love heart".
In a specific application scene, image features of an image to be processed displayed in a first preview window are acquired, and the first preview window can be a preview interface of a mobile phone camera or an editing preview interface of the image to be processed in a preset application program and is used for displaying all or part of the image to be processed. When the image features of the image to be processed are obtained, at least one image template corresponding to the image features is displayed in a second preview window, the second preview window is used for displaying the image template, and the image template can be a template of a target image, such as a jigsaw template, a component template, a cropping template, and the like. The jigsaw template is a template formed by splicing a plurality of images, the component template is a template for adding preset components (components such as flowers, sun, characters and the like) on the images, and the cutting template is a template for cutting the images according to preset shapes or sizes. The above image template is only an example, and does not produce any limitation to the image template in the present embodiment.
In the present embodiment, the first input includes, but is not limited to, a click, a long press, a slide, etc. selection operation on a virtual key or a preset control in the touchable display screen. But also a click, long press or slide operation on a physical key. In particular, the first input is made to an image template displayed in the second preview window. The image template selected by the user can be determined by receiving the first input, and the image to be processed is processed through the image template selected by the user.
Specifically, the image processing method includes, but is not limited to, stitching, adding components, clipping, adding filters, and the like for the image to be processed.
And finally, displaying a target image in the first preview interface, wherein the target image is an image obtained by processing the image to be processed according to the corresponding image template, and the first preview interface further comprises a cancelling and storing control for storing the target image or cancelling the editing of the image to be processed.
By the embodiment, the image characteristics of the image to be processed are determined; displaying at least one image template corresponding to the image characteristics; receiving a first input acting on at least one image template; responding to the first input, and performing image processing on the image to be processed according to the image template selected by the first input to obtain a target image; and displaying the target image. The image processing method and the device realize flexible image processing of the image to be processed according to the image characteristics, reduce manual dependence on users and improve convenience of image processing.
Optionally, in this embodiment, acquiring image features of the image to be processed includes, but is not limited to: determining an image acquisition mode of a preset application program in the electronic terminal; acquiring images according to an image acquisition mode, and displaying images to be processed; and carrying out image recognition on the image to be processed to obtain image characteristics.
Specifically, in this embodiment, after the image capture mode is selected, image capture is performed to obtain an image to be processed, the image to be processed is displayed in the first preview window, and image recognition is performed on the image to be processed. In one example, for example, an automatic editing photographing mode is selected from a camera application of a mobile phone, a photo is previewed on a photo preview interface after photographing, and image recognition is performed on the preview photo to obtain image features of the preview photo.
The image is collected after the image collection mode is set, after the image is collected, the image to be processed can be directly subjected to image recognition to obtain the image characteristics, the image characteristics of the image to be processed can be directly obtained without manual selection of a user, and convenience of image processing is improved.
Optionally, in this embodiment, the image feature includes at least one of: gesture features, mouth shape features, expression features.
Specifically, the image recognition of the image to be processed to obtain the image features includes but is not limited to: performing gesture recognition on the image to be processed to obtain gesture characteristics of the image to be processed; or, carrying out mouth shape recognition on the image to be processed to obtain mouth shape characteristics of the image to be processed; or, performing facial recognition on the image to be processed to obtain the expression characteristics of the image to be processed. Specifically, in the present embodiment, the image recognition of the image to be processed includes, but is not limited to: and performing gesture recognition and mouth shape recognition on the image to be processed to obtain mouth shape characteristics and face recognition to respectively obtain corresponding image characteristics. Through the embodiment, different image characteristics can be obtained based on different identification modes respectively, so that different image templates can be obtained, and the diversity of image processing is increased.
Optionally, in this embodiment, the displaying at least one image template corresponding to the image feature includes, but is not limited to: inquiring an image template matched with the image characteristics in a preset database; if at least one image template matched with the image features exists, displaying the at least one image template; and if the image template matched with the image features does not exist, displaying prompt information, wherein the prompt information is used for indicating that the image template matched with the image features does not exist.
Specifically, in the present embodiment, after the image features of the image to be processed are determined, an image template matching the image features is queried in a preset database, and the image template is queried based on the image features. The preset database may be a database of the cloud server, or may also be a local database of the electronic terminal, which is not limited in this embodiment. After finding that there is an image template matching the image feature, displaying the image template in a second preview window, for example, displaying the image template in a image template preview interface of the camera. And if not, displaying prompt information in the second preview window, wherein the prompt information is used for prompting that no image template matched with the image characteristics exists. It should be noted that, in this embodiment, the number of the image templates displayed in the second preview window is not limited, and may be specifically set according to practical experience.
By the embodiment, the image template matched with the image features is inquired in the preset database, and the inquiry result is displayed, so that the matching degree of the image template for image processing and the image to be processed can be improved, and the flexible processing of the image to be processed is realized.
Optionally, in this embodiment, after querying the preset database for the image template matching the image feature, the method further includes, but is not limited to: if the image template matched with the image characteristics does not exist, acquiring the use frequency respectively corresponding to a plurality of image templates in a preset database; selecting a preset number of target image templates according to the use frequencies respectively corresponding to the plurality of image templates; and displaying a preset number of target image templates.
Specifically, in this embodiment, if there is no image template matching with the image features in the preset database, the image templates are sorted according to the frequency of use of the image templates in the preset database, then the arrangement order of the image templates is obtained to obtain a preset number of target image templates, and the target image templates are displayed in the second preview window. It should be noted that the preset number may be set according to practical experience, and is not limited in this embodiment.
In another example, in the case where there is no image template matching the image feature, the image template matching the similar image feature is displayed by determining the similar image feature having a similarity greater than a preset threshold with respect to the image feature, querying a preset database for the image template matching the similar image feature.
Through the embodiment, under the condition that the image template matched with the image characteristics does not exist, the image template is pushed according to the use frequency of the image template, so that the pushed image template can adapt to the use habit of a user, and the pushing accuracy of the image template is improved.
Optionally, in this embodiment, the image template includes a component template, and the component template includes at least one preset component, where, in response to the first input, performing image processing on the image to be processed according to the image template selected by the first input includes, but is not limited to: receiving a second input acting on at least one preset component, wherein the second input is used for adjusting the position of the preset component; and responding to the second input, and determining the position of the preset component at the image to be processed according to the second input.
Specifically, in this embodiment, in the case that the image template selected by the first input is a component template, the component template includes at least one preset component. For example, in the image processing interface schematic diagram shown in fig. 3a, in a graphical user interface of an electronic terminal, an image to be processed 302 is displayed in a first preview window 310, an image template 304, an image template 306, and an image template 308 are displayed in a second preview window 320, and the image template selected by the first input is the image template 306. In FIG. 3b, a second input is received to the preset component 3060 in the image template 306, the preset component 3060 is selected and dragged, and the position of the preset component 3060 and the image 302 to be processed is adjusted.
Through the embodiment, the positions of the preset assembly and the image to be processed are adjusted by receiving the second input acting on the preset assembly, so that the image processing can be performed according to the input of the user, and the use experience of the user is improved.
Optionally, in this embodiment, the image template includes a tile template, where the tile template includes N image windows distributed according to preset positions, and the image windows are used to fill the image, where, in response to the first input, performing image processing on the image to be processed according to the image template selected by the first input includes, but is not limited to: receiving a third input acting on the puzzle template; and responding to a third input, and filling the image to be processed into N image windows respectively, wherein N is a positive integer greater than 1.
Specifically, in the present embodiment, an image feature is taken as an example for explanation, and as shown in fig. 4a, image recognition is performed on the to-be-processed image 40 in the first preview window 410 to determine that the image feature of the to-be-processed image 40 is the gesture feature. As shown in fig. 4b, a matching tile template is queried according to the gesture features of the image 40 to be processed, and a tile template 402 (a heart-shaped template consisting of a plurality of image windows) and a tile template 404 (a double heart-shaped template consisting of a plurality of image windows) matching the gesture features are displayed in a second preview window 420, and a third input acting on the image template 402 is received. As shown in fig. 4c, the target images 42 processed by the tile template 402 are displayed in the first preview window, and the image windows in the target images 42 are respectively filled with the images to be processed 40.
Through the embodiment, the jigsaw template is selected through the third input, the image to be processed is processed according to the jigsaw template, the image processing according to the input of the user can be achieved, and the use experience of the user is improved.
Optionally, in this embodiment, in response to the third input, the filling the to-be-processed image into the N image windows respectively includes, but is not limited to: receiving a fourth input to the M image windows; responding to a fourth input, and filling a first image to be processed into M image windows, wherein the first image to be processed is a current image to be processed; receiving a fifth input to the P image windows; responding to a fifth input, and controlling the electronic terminal to acquire Q second images to be processed; and filling Q second images to be processed into P image windows, wherein M, P and Q are positive integers, the sum of M and P is N, and Q is less than or equal to P.
In the above example, in the case where the image template obtained by the image feature matching is a jigsaw template, the images to be processed may be respectively filled in the plurality of image windows of the jigsaw template. In this embodiment, different images to be processed may be filled in for different image windows respectively. After determining the jigsaw template according to the current image to be processed, selecting different image windows, and then selecting the pre-stored image or acquiring the image in real time to fill the image windows. It should be noted that, in this example, the number of image windows filled in the image to be processed is not limited, and may be set according to practical experience.
In one example, such as the image processing interface diagram shown in fig. 5, a selected tile template 500 is displayed in the first preview window 50, and the tile template includes an image window 502 and an image window 504. Dragging the photo A to the image window 502 through a dragging operation to realize filling the photo A into the image window 502; by clicking the image window 504, the photographing window 52 and the import window 54 are displayed in the first preview window, the camera is called to photograph by selecting the photographing window 52, then a new photo obtained by photographing is filled in the window 504, the photo stored in the album is accessed by selecting the photographing window 54, and the selected photo is filled in the image window 504.
Through the embodiment, the flexible processing of the image window in the jigsaw template is realized, so that the diversity in the image processing process is increased.
As an optional technical solution, in this embodiment, the jigsaw template is determined according to a first image feature of a third image to be processed, where the third image to be processed is a current image to be processed; wherein, in response to the third input, filling the to-be-processed image into the N image windows respectively further includes but is not limited to: obtaining R fourth images to be processed; acquiring second image characteristics respectively corresponding to the R fourth images to be processed; and determining a target jigsaw template in the plurality of jigsaw templates according to the sum R +1 of the number of the third image to be processed and the R second images to be processed, the first image characteristics and the R second image characteristics, wherein R is a positive integer.
Specifically, after determining a plurality of puzzle templates through the gesture feature of the first photo, if R photos are continuously taken, after the end of taking, the gesture feature, the image feature of the R photos, and the number R +1 are combined to further screen the puzzle templates matching therewith, so that the number of picture windows required by the puzzle templates corresponds to the total number R +1 of photos actually taken by the user.
Optionally, in this embodiment, in response to the third input, the filling the to-be-processed image into the N image windows respectively includes, but is not limited to: receiving a sixth input, wherein the sixth input acts on two of the N image windows; in response to a sixth input, the images to be processed in the two image windows are swapped.
In a specific application scenario, as shown in the schematic image processing interface diagram shown in fig. 6, a target image 62 edited from a tile template is displayed in a first preview window 60, where the target image includes an image window 610 and an image window 612, an image filled in the image window 610 is an image 620, and an image filled in the image window 612 is an image 622. In one example, the images in the two image windows are exchanged by selecting the image window 610 and the image window 612 and clicking a preset virtual button 64. In another example, the image to be processed in the image window 610 can be selected and dragged into the image window 620, so as to realize the exchange of the images to be processed in the two image windows.
With the above embodiment, the position exchange adjustment of the images to be processed in the two image windows is realized by the sixth input acting on the two image windows in the jigsaw template.
Optionally, in this embodiment, in response to the first input, performing image processing on the image to be processed according to the image template selected by the first input to obtain the target image, further including but not limited to: processing an image to be processed according to an image template selected by a first input to obtain a first image; receiving a seventh input acting on the preset control, wherein the seventh input is used for selecting a filter of the first image; in response to the seventh input, the first image is processed according to the filter to obtain a target image.
In a specific application scenario, as shown in the schematic image processing interface diagram shown in fig. 7, a first image 710 obtained after processing based on an image template is displayed in the first preview window 70, then a filter is selected in the third preview window 72 through a seventh input, and then the first image 710 is processed according to the filter.
By the embodiment, the first image is obtained after the image to be processed is processed based on the image template, and the first image can be further processed according to the filter effect selected by the seventh input, so that the processing mode of image processing is enriched.
Optionally, in this embodiment, after the image to be processed is processed according to the image template selected by the first input in response to the first input to obtain the target image, the method further includes, but is not limited to: and setting the image characteristics and the image template selected by the first input as a common template.
Specifically, in this embodiment, after the user finishes processing the image to be processed according to the image template, the image feature of the user and the image template are saved as common templates, so as to implement learning of the habit of the user. Specifically, facial features, gesture features, expression features and the like of the user can be stored, and in the subsequent image processing process, the corresponding common template can be quickly searched according to the image features, so that the searching speed of the image template is increased, and the user experience is improved.
Optionally, in this embodiment, after setting the image feature and the image template selected by the first input as the common templates, the method further includes, but is not limited to: and under the condition that the image characteristics corresponding to the third image to be processed are the same as those corresponding to the common template, displaying the common template in a second preview window.
In a specific application scene, after the image features and the image template selected by the first input are set as the common template, in the subsequent image processing process, if the image features of the image to be processed are the same as the corresponding image features in the common template, the common template is directly displayed in the second preview window. It should be noted that, in this embodiment, the third to-be-processed image is used to indicate the to-be-processed image after the image template is saved as the common template, that is, before the third to-be-processed image is subjected to image processing, other to-be-processed images having the same image characteristics as the third to-be-processed image have completed image processing.
As another optional way, in this embodiment, in the case that the image features corresponding to the third to-be-processed image are the same as the image features corresponding to the common templates, the common templates are preferentially displayed or highlighted in the second preview window, so as to improve the pushing efficiency of the image templates.
The common template is displayed in the second preview window under the condition that the image characteristics corresponding to the third image to be processed are the same as those corresponding to the common template, so that the pushing efficiency of the common template is improved, and the user experience is improved.
By the embodiment, the image characteristics of the image to be processed are determined; displaying at least one image template corresponding to the image features in a second preview window; receiving a first input acting on at least one image template; responding to the first input, and performing image processing on the image to be processed according to the image template selected by the first input to obtain a target image; the target image is displayed in a first preview window. The method and the device realize flexible image processing of the image to be processed according to the image characteristics, reduce manual dependence on users, improve convenience of image processing, and further solve the problem that in the related art, the images cannot be flexibly edited and typesetted according to the characteristics in the photos due to the fact that the photos are manually selected and edited by the users, and therefore image editing is inconvenient.
It should be noted that, in the image processing method provided in the embodiment of the present application, the execution subject may be an image processing apparatus, or a control module in the image processing apparatus for executing the method of loading image processing. In the embodiment of the present application, a method for executing load image processing by an image processing apparatus is taken as an example, and the method for processing an image provided in the embodiment of the present application is described.
According to another aspect of the embodiments of the present application, an image processing apparatus is provided, as shown in fig. 8, the image processing apparatus may specifically include:
1) an obtaining unit 802, configured to obtain an image feature of an image to be processed;
2) a first display unit 804, configured to display at least one image template corresponding to the image feature;
3) a receiving unit 806 for receiving a first input acting on the at least one image template;
4) the processing unit 808, configured to, in response to the first input, perform image processing on the image to be processed according to an image template selected by the first input to obtain a target image;
5) a second display unit 810 for displaying the target image.
Optionally, in this embodiment, the image feature includes at least one of: gesture feature, mouth shape feature, expression feature
Optionally, in this embodiment, the first display unit 804 includes:
1) the query module is used for querying an image template matched with the image characteristics in a preset database;
2) the second display module is used for displaying at least one image template in the second preview window if at least one image template matched with the image characteristics exists;
3) and the prompt module is used for displaying prompt information on the preset window if the image template matched with the image characteristics does not exist, wherein the prompt information is used for indicating that the image template matched with the image characteristics does not exist.
Optionally, in this embodiment, the first display unit 804 further includes:
1) the second determining module is used for acquiring the use frequency respectively corresponding to the plurality of image templates in the preset database if the image template matched with the image feature does not exist after the image template matched with the image feature is inquired in the preset database;
2) the selecting module is used for selecting a preset number of target image templates according to the use frequencies respectively corresponding to the plurality of image templates;
3) and the third display module is used for displaying the preset number of target image templates in the second preview window.
Optionally, in this embodiment, the image template includes preset components, wherein the processing unit 808 includes:
1) the first receiving module is used for receiving a second input acting on the preset component, wherein the second input is used for adjusting the position of the preset component;
2) and the third determining module is used for responding to the second input and determining the position of the preset component at the image to be processed according to the second input.
Optionally, in this embodiment, the image template includes a tile template, where the tile template includes N image windows distributed according to preset positions, and the image windows are used to fill images, where the processing unit 808 includes:
1) a second receiving module for receiving a third input to the puzzle template;
2) and the filling module is used for responding to the third input and filling the image to be processed into the N image windows respectively, wherein N is a positive integer greater than 1.
Optionally, in this embodiment, the filling module includes:
1) a first receiving submodule for receiving a fourth input applied to the M image windows;
2) a first filling sub-module, configured to fill a first to-be-processed image into the M image windows in response to the fourth input, where the first to-be-processed image is a current to-be-processed image;
3) a second receiving submodule for receiving a fifth input applied to the P image windows;
4) the image acquisition submodule is used for responding to the fifth input and controlling the electronic terminal to acquire Q second images to be processed;
5) a second filling sub-module for filling the Q second images to be processed into the P image windows,
m, P and Q are positive integers, wherein the sum of M and P is N, and Q is less than or equal to P.
The image processing apparatus in the embodiment of the present application may be an apparatus, or may be a component, an integrated circuit, or a chip in a terminal. The device can be mobile electronic equipment or non-mobile electronic equipment. By way of example, the mobile electronic device may be a mobile phone, a tablet computer, a notebook computer, a palm top computer, a vehicle-mounted electronic device, a wearable device, an ultra-mobile personal computer (UMPC), a netbook or a Personal Digital Assistant (PDA), and the like, and the non-mobile electronic device may be a server, a Network Attached Storage (NAS), a Personal Computer (PC), a Television (TV), a teller machine or a self-service machine, and the like, and the embodiments of the present application are not particularly limited.
The image processing apparatus in the embodiment of the present application may be an apparatus having an operating system. The operating system may be an Android (Android) operating system, an ios operating system, or other possible operating systems, and embodiments of the present application are not limited specifically.
The image processing apparatus provided in the embodiment of the present application can implement each process implemented by the image processing apparatus in the method embodiments of fig. 1 to fig. 7, and is not described herein again to avoid repetition.
By the image processing device provided by the embodiment, the image characteristics of the image to be processed are determined; displaying at least one image template corresponding to the image characteristics; receiving a first input acting on at least one image template; responding to the first input, and performing image processing on the image to be processed according to the image template selected by the first input to obtain a target image; and displaying the target image. The method and the device realize flexible image processing of the image to be processed according to the image characteristics, reduce manual dependence on users, improve convenience of image processing, and further solve the problem that in the related art, the images cannot be flexibly edited and typesetted according to the characteristics in the photos due to the fact that the photos are manually selected and edited by the users, and therefore image editing is inconvenient.
Optionally, an electronic device is further provided in this embodiment of the present application, and includes a processor 910, a memory 909, and a program or an instruction stored in the memory 909 and capable of being executed on the processor 910, where the program or the instruction is executed by the processor 910 to implement each process of the above-mentioned embodiment of the image processing method, and can achieve the same technical effect, and in order to avoid repetition, details are not described here again.
It should be noted that the electronic devices in the embodiments of the present application include the mobile electronic devices and the non-mobile electronic devices described above.
Fig. 9 is a schematic diagram of a hardware structure of an electronic device implementing an embodiment of the present application.
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, and a processor 910.
Those skilled in the art will appreciate that the electronic device 900 may further include a power source (e.g., a battery) for supplying power to various components, and the power source may be logically connected to the processor 910 through a power management system, so as to manage charging, discharging, and power consumption management functions through the power management system. The electronic device structure shown in fig. 9 does not constitute a limitation of the electronic device, and the electronic device may include more or less components than those shown, or combine some components, or arrange different components, and thus, the description is not repeated here.
A processor 910, configured to obtain an image feature of an image to be processed;
a display unit 906, configured to display at least one image template corresponding to the image feature;
a user input unit 907 for receiving a first input acting on the at least one image template;
a processor 910, configured to, in response to the first input, perform image processing on the image to be processed according to an image template selected by the first input to obtain a target image;
a display unit 906 for displaying the target image.
It should be understood that, in the embodiment of the present application, the input Unit 904 may include a Graphics Processing Unit (GPU) 9041 and a microphone 9042, and the Graphics Processing Unit 9041 processes image data of a still picture or a video obtained by an image capturing device (such as a camera) in a video capturing mode or an image capturing 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, or the like. The user input unit 907 includes a touch panel 9071 and other input devices 9072. A touch panel 9071 also referred to as a touch screen. The touch panel 9071 may include two parts, a touch detection device and a touch controller. Other input devices 9072 may include, but are not limited to, a physical keyboard, function keys (e.g., volume control keys, switch keys, etc.), a trackball, a mouse, and a joystick, which are not described in detail herein. Memory 909 can be used to store software programs as well as various data including, but not limited to, application programs and operating systems. The processor 910 may integrate an application processor, which primarily handles operating systems, user interfaces, applications, etc., and a modem processor, which primarily handles wireless communications. It is to be appreciated that the modem processor described above may not be integrated into processor 910.
The image characteristics of the image to be processed are obtained through the electronic equipment provided in the embodiment; displaying at least one image template corresponding to the image characteristics; receiving a first input acting on at least one image template; responding to the first input, and performing image processing on the image to be processed according to the image template selected by the first input to obtain a target image; and displaying the target image. The method and the device realize flexible image processing of the image to be processed according to the image characteristics, reduce manual dependence on users, improve convenience of image processing, and further solve the problem that in the related art, the images cannot be flexibly edited and typesetted according to the characteristics in the photos due to the fact that the photos are manually selected and edited by the users, and therefore image editing is inconvenient.
The embodiment of the present application further provides a readable storage medium, where a program or an instruction is stored on the readable storage medium, and when the program or the instruction is executed by a processor, the program or the instruction implements each process of the method embodiment of the image processing method, and can achieve the same technical effect, and in order to avoid repetition, details are not repeated here.
The processor is the processor in the electronic device described in the above embodiment. The readable storage medium includes a computer readable storage medium, such as a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and so on.
The embodiment of the present application further provides a chip, where the chip includes a processor and a communication interface, the communication interface is coupled to the processor, and the processor is configured to execute a program or an instruction to implement each process of the method embodiment of the image processing method, and can achieve the same technical effect, and details are not repeated here to avoid repetition.
It should be understood that the chips mentioned in the embodiments of the present application may also be referred to as system-on-chip, system-on-chip or system-on-chip, etc.
It should be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element. Further, it should be noted that the scope of the methods and apparatus of the embodiments of the present application is not limited to performing the functions in the order illustrated or discussed, but may include performing the functions in a substantially simultaneous manner or in a reverse order based on the functions involved, e.g., the methods described may be performed in an order different than that described, and various steps may be added, omitted, or combined. In addition, features described with reference to certain examples may be combined in other examples.
Through the above description of the embodiments, those skilled in the art will clearly understand that the method of the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but in many cases, the former is a better implementation manner. Based on such understanding, the technical solutions of the present application may be embodied in the form of a software product, which is stored in a storage medium (such as ROM/RAM, magnetic disk, optical disk) and includes instructions for enabling a terminal (such as a mobile phone, a computer, a server, an air conditioner, or a network device) to execute the method according to the embodiments of the present application.
While the present embodiments have been described with reference to the accompanying drawings, it is to be understood that the invention is not limited to the precise embodiments described above, which are meant to be illustrative and not restrictive, and that various changes may be made therein by those skilled in the art without departing from the spirit and scope of the invention as defined by the appended claims.

Claims (16)

1. An image processing method, characterized in that the method comprises:
acquiring image characteristics of an image to be processed;
displaying at least one image template corresponding to the image features;
receiving a first input acting on the at least one image template;
responding to the first input, and carrying out image processing on the image to be processed according to an image template selected by the first input to obtain a target image;
and displaying the target image.
2. The method of claim 1, wherein the image features comprise at least one of:
gesture features, mouth shape features, expression features.
3. The method of claim 1, wherein displaying at least one image template corresponding to the image feature comprises:
inquiring an image template matched with the image characteristics in a preset database;
if at least one image template matched with the image features exists, displaying the at least one image template;
and if the image template matched with the image features does not exist, displaying prompt information, wherein the prompt information is used for indicating that the image template matched with the image features does not exist.
4. The method according to claim 3, wherein after querying a preset database for the image template matching the image feature, further comprising:
if the image template matched with the image characteristics does not exist, acquiring the use frequency respectively corresponding to the plurality of image templates in the preset database;
selecting a preset number of target image templates according to the use frequencies respectively corresponding to the plurality of image templates;
and displaying the preset number of target image templates.
5. The method of claim 1, wherein the image template comprises a component template including at least one preset component therein, wherein,
responding to the first input, and performing image processing on the image to be processed according to the image template selected by the first input comprises the following steps:
receiving a second input acting on the at least one preset component, wherein the second input is used for adjusting the position of the preset component;
and responding to the second input, and determining the position of the preset component in the image to be processed according to the second input.
6. The method of claim 1, wherein the image template comprises a puzzle template comprising N image windows distributed according to preset positions, the image windows being used for filling images, wherein,
responding to the first input, and performing image processing on the image to be processed according to the image template selected by the first input comprises the following steps:
receiving a third input acting on the puzzle template;
and responding to the third input, and respectively filling the image to be processed into the N image windows, wherein N is a positive integer greater than 1.
7. The method of claim 6, wherein the filling the image to be processed into the N image windows respectively in response to the third input comprises:
receiving a fourth input acting on the M image windows;
filling a first image to be processed into the M image windows in response to the fourth input, wherein the first image to be processed is a current image to be processed;
receiving a fifth input acting on the P image windows;
responding to the fifth input, and controlling the electronic terminal to acquire Q second images to be processed;
filling the Q second images to be processed into the P image windows;
wherein M, P and Q are positive integers, the sum of M and P is N, and Q is less than or equal to P.
8. An image processing apparatus, characterized in that the apparatus comprises:
the device comprises an acquisition unit, a processing unit and a processing unit, wherein the acquisition unit is used for acquiring the image characteristics of an image to be processed;
the first display unit is used for displaying at least one image template corresponding to the image characteristics;
a receiving unit for receiving a first input acting on the at least one image template;
the processing unit is used for responding to the first input and carrying out image processing on the image to be processed according to the image template selected by the first input so as to obtain a target image;
and the second display unit is used for displaying the target image.
9. The apparatus of claim 8, wherein the image features comprise at least one of:
gesture features, mouth shape features, expression features.
10. The apparatus of claim 8, wherein the first display unit comprises:
the query module is used for querying an image template matched with the image characteristics in a preset database;
the second display module is used for displaying at least one image template if at least one image template matched with the image characteristics exists;
and the prompt module is used for displaying prompt information if the image template matched with the image features does not exist, wherein the prompt information is used for indicating that the image template matched with the image features does not exist.
11. The apparatus of claim 10, wherein the first display unit further comprises:
the second determining module is used for acquiring the use frequency respectively corresponding to the plurality of image templates in the preset database if the image template matched with the image feature does not exist after the image template matched with the image feature is inquired in the preset database;
the selecting module is used for selecting a preset number of target image templates according to the use frequencies respectively corresponding to the plurality of image templates;
and the third display module is used for displaying the preset number of target image templates.
12. The apparatus of claim 8, wherein the image template comprises preset components, wherein the processing unit comprises:
the first receiving module is used for receiving a second input acting on the preset component, wherein the second input is used for adjusting the position of the preset component;
and the third determining module is used for responding to the second input and determining the position of the preset component at the image to be processed according to the second input.
13. The apparatus of claim 8, wherein the image template comprises a puzzle template, the puzzle template comprises N image windows distributed according to preset positions, the image windows are used for filling images, and wherein the processing unit comprises:
a second receiving module for receiving a third input to the puzzle template;
and the filling module is used for responding to the third input and filling the image to be processed into the N image windows respectively, wherein N is a positive integer greater than 1.
14. The apparatus of claim 13, wherein the fill module comprises:
a first receiving submodule for receiving a fourth input applied to the M image windows;
a first filling sub-module, configured to fill a first to-be-processed image into the M image windows in response to the fourth input, where the first to-be-processed image is a current to-be-processed image;
a second receiving submodule for receiving a fifth input applied to the P image windows;
the image acquisition submodule is used for responding to the fifth input and controlling the electronic terminal to acquire Q second images to be processed;
a second filling sub-module, configured to fill the Q second images to be processed into the P image windows;
wherein M, P and Q are positive integers, the sum of M and P is N, and Q is less than or equal to P.
15. An electronic device comprising a processor, a memory and a program or instructions stored on the memory and executable on the processor, the program or instructions, when executed by the processor, implementing the steps of the image processing method according to any one of claims 1 to 7.
16. A readable storage medium, characterized in that it stores thereon a program or instructions which, when executed by a processor, implement the steps of the image processing method according to any one of claims 1 to 7.
CN202011381285.XA 2020-11-30 2020-11-30 Image processing method, image processing device, electronic equipment and readable storage medium Pending CN112330728A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011381285.XA CN112330728A (en) 2020-11-30 2020-11-30 Image processing method, image processing device, electronic equipment and readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011381285.XA CN112330728A (en) 2020-11-30 2020-11-30 Image processing method, image processing device, electronic equipment and readable storage medium

Publications (1)

Publication Number Publication Date
CN112330728A true CN112330728A (en) 2021-02-05

Family

ID=74308294

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011381285.XA Pending CN112330728A (en) 2020-11-30 2020-11-30 Image processing method, image processing device, electronic equipment and readable storage medium

Country Status (1)

Country Link
CN (1) CN112330728A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113791721A (en) * 2021-08-31 2021-12-14 北京达佳互联信息技术有限公司 Picture processing method and device, electronic equipment and storage medium
WO2024041425A1 (en) * 2022-08-23 2024-02-29 北京字跳网络技术有限公司 Multimedia processing method and apparatus, and device and medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2016144800A1 (en) * 2015-03-06 2016-09-15 Matthew Lee Method and device for capturing images using image templates
CN107578459A (en) * 2017-08-31 2018-01-12 北京麒麟合盛网络技术有限公司 Expression is embedded in the method and device of candidates of input method
WO2018213946A1 (en) * 2017-05-20 2018-11-29 深圳信炜科技有限公司 Image recognition method, image recognition device, electronic device, and computer storage medium
CN111339420A (en) * 2020-02-28 2020-06-26 北京市商汤科技开发有限公司 Image processing method, image processing device, electronic equipment and storage medium
CN111833234A (en) * 2020-07-10 2020-10-27 京东方科技集团股份有限公司 Image display method, image processing apparatus, and computer-readable storage medium

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2016144800A1 (en) * 2015-03-06 2016-09-15 Matthew Lee Method and device for capturing images using image templates
WO2018213946A1 (en) * 2017-05-20 2018-11-29 深圳信炜科技有限公司 Image recognition method, image recognition device, electronic device, and computer storage medium
CN107578459A (en) * 2017-08-31 2018-01-12 北京麒麟合盛网络技术有限公司 Expression is embedded in the method and device of candidates of input method
CN111339420A (en) * 2020-02-28 2020-06-26 北京市商汤科技开发有限公司 Image processing method, image processing device, electronic equipment and storage medium
CN111833234A (en) * 2020-07-10 2020-10-27 京东方科技集团股份有限公司 Image display method, image processing apparatus, and computer-readable storage medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113791721A (en) * 2021-08-31 2021-12-14 北京达佳互联信息技术有限公司 Picture processing method and device, electronic equipment and storage medium
WO2024041425A1 (en) * 2022-08-23 2024-02-29 北京字跳网络技术有限公司 Multimedia processing method and apparatus, and device and medium

Similar Documents

Publication Publication Date Title
CN111612873B (en) GIF picture generation method and device and electronic equipment
CN112135046B (en) Video shooting method, video shooting device and electronic equipment
CN113093968B (en) Shooting interface display method and device, electronic equipment and medium
CN111857512A (en) Image editing method and device and electronic equipment
CN112954210A (en) Photographing method and device, electronic equipment and medium
CN113794834B (en) Image processing method and device and electronic equipment
CN112532882B (en) Image display method and device
CN112672061B (en) Video shooting method and device, electronic equipment and medium
CN111669495B (en) Photographing method, photographing device and electronic equipment
CN112269522A (en) Image processing method, image processing device, electronic equipment and readable storage medium
CN112330728A (en) Image processing method, image processing device, electronic equipment and readable storage medium
CN113079316A (en) Image processing method, image processing device and electronic equipment
CN113067983A (en) Video processing method and device, electronic equipment and storage medium
CN113194256B (en) Shooting method, shooting device, electronic equipment and storage medium
CN112449110B (en) Image processing method and device and electronic equipment
CN112306347B (en) Image editing method, image editing device and electronic equipment
CN111885298B (en) Image processing method and device
CN112685119A (en) Display control method and device and electronic equipment
CN112822394A (en) Display control method and device, electronic equipment and readable storage medium
CN112287141A (en) Photo album processing method and device, electronic equipment and storage medium
CN114584704A (en) Shooting method and device and electronic equipment
CN114025100A (en) Shooting method, shooting device, electronic equipment and readable storage medium
CN113271378A (en) Image processing method and device and electronic equipment
CN113271379A (en) Image processing method and device and electronic equipment
CN113873168A (en) Shooting method, shooting device, electronic equipment and medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination