Method and apparatus for processing special image effects

By determining and displaying special effect objects within specific foreground or background areas of an image, the method and device improve image processing to achieve superior visual effects.

JP7553582B2Active Publication Date: 2024-09-18DOUYIN VISION CO LTD
View PDF 8 Cites 0 Cited by

Patent Information

Application Number
JP2022552171
Authority / Receiving Office
JP · JP
Patent Type
Patents
Current Assignee / Owner
Priority Date
2020-02-27
Filing Date
2021-02-24
Publication Date
2024-09-18
Estimated Expiration
2041-02-24

AI Technical Summary

Technical Problem

Existing image special effect processing methods often fail to achieve superior effects when applied to the entire image, leading to strange results, especially when effects like face stickers are used.

Method used

The method and device determine a target display area in an initial image as either a foreground or background region, and display a portion of the special effect object within that area to achieve distinct effects.

Benefits of technology

This approach allows for the special effect object to be displayed in a manner that enhances the image, achieving excellent visual results by distinguishing between foreground and background areas.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 0007553582000004
    Figure 0007553582000004
  • Figure 0007553582000005
    Figure 0007553582000005
  • Figure 0007553582000003
    Figure 0007553582000003
Patent Text Reader

Abstract

The present disclosure discloses an image special effect processing method, apparatus, electronic device, and computer-readable storage medium, wherein the method includes the steps of: determining a target display area in the initial image for the special effect object in response to an instruction to add the special effect object to an initial image, the target display area being a foreground area or a background area of ​​the initial image, the foreground area being an image area in the initial image where the target object is located, and the background area being an image area in the initial image other than the foreground area; and displaying a portion of the special effect object in the target display area in the initial image to obtain a target image. By determining the target display area in the initial image for the special effect object, the embodiment of the present disclosure can display the portion of the special effect object in the target display area in the initial image, thereby distinguishing the special effect object and achieving a relatively excellent effect.
Need to check novelty before this filing date? Find Prior Art

Description

[Technical field]

[0001] The present disclosure relates to the technical field of image special effects processing, and in particular to an image special effects processing method, apparatus, and computer-readable storage medium. [Background technology]

[0002] With the development of smart terminal technology, the functions of smart terminals are becoming more and more diverse. For example, users can use the camera in the terminal to take images (e.g., photos or videos), which has become a new style of leisure for people. However, simple image taking can no longer meet the needs of users. Accordingly, how to apply special effects to the taken images to obtain more interesting images has become the focus of people's attention.

[0003] In the prior art, special effects are usually applied to the entire image, and in some scenes, this special effect processing method cannot achieve good effects; for example, face stickers are usually applied to the face, and if they are applied to the entire image, the entire image will look strange and may not achieve good effects. Summary of the Invention [Problem to be solved by the invention]

[0004] This Summary is provided to introduce ideas in a simplified form, which are described in detail in the Detailed Description section below. This Summary is not intended to identify key features or required features of the claimed technical solution, nor is it intended to limit the scope of the claimed technical solution.

[0005] This disclosure Trying to achieve technical the purposeThe present invention provides a method for processing image special effects, which at least partially solves the technical problem that the processing methods for special effects in the prior art cannot achieve excellent effects. Also provides a processing device for image special effects, a processing hardware device for image special effects, a computer-readable storage medium and a processing terminal for image special effects. [Means for solving the problem]

[0006] In order to achieve the above object, according to one aspect of the present disclosure, the following technical solutions are provided.

[0007] A method for processing special image effects, comprising the steps of: determining a target display area in the initial image for the special effect object in response to a command to add the special effect object to the initial image, the target display area being a foreground area or a background area of ​​the initial image, the foreground area being an image area in the initial image in which the target object is located and the background area being an image area in the initial image other than the foreground area; displaying a portion of the special effect object in the target display area in the initial image to obtain a target image.

[0008] In order to achieve the above object, according to one aspect of the present disclosure, the following technical solutions are provided.

[0009] An image special effect processing device, comprising: a target display area determination module, in response to a command to add a special effect object to an initial image, used to determine a target display area in the initial image of the special effect object, the target display area being a foreground area or a background area of ​​the initial image, the foreground area being an image area in the initial image where the target object is located, and the background area being an image area in the initial image other than the foreground area; a special effect display module used to display a portion of the special effect object in the target display area in the initial image to obtain the target image.

[0010] In order to achieve the above object, according to one aspect of the present disclosure, the following technical solutions are provided.

[0011] An electronic device, a memory used to store non-transitory computer readable instructions; Ko Executes computer-readable instructions A processor , the processor Computer readable instructions and a processor which, when executed, is used to realize the image special effect processing method according to any one of the above aspects.

[0012] In order to achieve the above object, according to one aspect of the present disclosure, the following technical solutions are provided.

[0013] A computer-readable storage medium used to store non-transitory computer-readable instructions, which, when executed by a computer, cause the computer to execute a method for processing image special effects according to any of the above aspects.

[0014] A computer program product comprising computer program instructions, the computer program instructions causing a computer to carry out a method for processing image special effects according to any of the above aspects.

[0015] A computer program, which when executed on a computer, causes the computer to carry out the method for processing special image effects according to any of the above aspects.

[0016] In order to achieve the above object, according to another aspect of the present disclosure, the following technical solutions are further provided.

[0017] A special image effect processing terminal, Record Includes a processor for image special effects. Effect of the Invention

[0018] The embodiments of the present disclosure determine a target display area in an initial image of a special effect object, so that a portion of the special effect object in the target display area can be displayed in the initial image, so as to distinguish and display the special effect object, thereby achieving a relatively excellent effect.

[0019] The above description is only an outline of the technical solution of the present disclosure, which can be implemented based on the contents of the specification in order to more clearly understand the technical solution of the present disclosure, and in order to make the above and other objectives, features and advantages of the present disclosure more comprehensible, the following gives preferred embodiments and is described in detail in conjunction with the drawings as follows: [Brief description of the drawings]

[0020] The above and other features, advantages and aspects of each embodiment of the present disclosure will become more apparent by reference to the following specific embodiments in conjunction with the accompanying drawings, in which the same or similar drawing reference numerals indicate the same or similar elements. It should be understood that the drawings are illustrative and that the original elements and elements are not necessarily drawn to scale. [Figure 1a] 1 is a flowchart of a method for processing image special effects according to an embodiment of the present disclosure. [Figure 1b] FIG. 2 is a schematic diagram of a first interface provided in the image special effect processing method according to an embodiment of the present disclosure. [Figure 1c] FIG. 11 is a schematic diagram of a second interface provided in the image special effect processing method according to an embodiment of the present disclosure. [Diagram 2] FIG. 2 is a structural schematic diagram of an image special effect processing device according to an embodiment of the present disclosure; [Diagram 3] FIG. 1 is a structural schematic diagram of an electronic device according to an embodiment of the present disclosure. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

[0021] Hereinafter, the embodiments of the present disclosure will be described in detail with reference to the drawings. Although certain embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be implemented in various forms and should not be construed as being limited to the embodiments described herein, but rather, these embodiments are provided to allow a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the present disclosure only serve as examples and do not limit the scope of protection of the present disclosure.

[0022] It should be understood that the steps described in the method embodiments of the present disclosure may be performed in a different order or in parallel. Furthermore, method embodiments may include additional steps or omit the performance of illustrated steps. The scope of the present disclosure is not limited in this respect.

[0023] As used herein, the term "including" and variations thereof are open ended, i.e., including but not limited to. The term "based on" means "based at least in part on." The term "in one embodiment" means "at least one embodiment." The term "other embodiments" means "at least one other embodiment." The term "some embodiments" means "at least some embodiments." Relevant definitions of other terms are provided below in the description. EXAMPLES

[0024] In order to solve the technical problem that the special effect processing method in the prior art cannot achieve a relatively good effect, the embodiment of the present disclosure provides an image special effect processing method. As shown in Figure 1a, the image special effect processing method mainly includes the following steps S11 to S12:

[0025] In step S11, in response to a command to add a special effect object to an initial image, a target display area in the initial image for the special effect object is determined, the target display area being a foreground area or a background area of ​​the initial image, the foreground area being an image area in the initial image in which a target object is located, and the background area being an image area in the initial image other than the foreground area.

[0026] Specifically, the initial image may be a video image input in real time, for example, a live video in a short video application, or a video image pre-stored in the terminal. The image may be a still image, i.e., a picture. Here, the terminal may be, for example, a mobile terminal such as a smartphone or a tablet computer, or a fixed terminal such as a desktop computer.

[0027] Here, the command to add a special effect object may include an identifier or a storage location of the special effect object, and the corresponding special effect object is locally obtained from the Internet, a server, or a terminal based on the identifier or storage location, or the command to add a special effect object includes a special effect object, and in this case, there is no need to separately obtain the corresponding special effect object, and the special effect object is directly parsed from the command.

[0028] Here, the added special effect object may be one or more, and in the case of more than one, the target display area in the initial image of each special effect object is determined. The target display area is the foreground area or the background area of ​​the initial image. Specifically, the user can select a corresponding special effect object according to needs, and the target display area is determined based on the type of the selected special effect object. For example, if the special effect object is a special effect (e.g., a face sticker) used to display in the foreground area, the target display area of ​​the special effect object is determined to be the foreground area, if the special effect object is a special effect (e.g., a barrage) used to display in the background area, the target display area of ​​the special effect object is determined to be the background area, and if the special effect object marks the edge of the foreground area, the target display area of ​​the special effect object is determined to be the background area. region is determined to be the edge of the foreground region. Take the initial image as an example, if the special effect object selected by the user is a face sticker, generate an additional command for special effect according to the face sticker, where the additional command for special effect includes a target display area, and the target display area is the foreground region.

[0029] When determining the foreground region and background region of the initial image, the foreground region and background region of the initial image can be separated using a method in the prior art. For example, a target recognition algorithm is used to recognize an image, an image region where a target object is located is obtained, and the image region where the target object is located is removed to become a background region. Here, the target object may be a face, a human torso, etc. For example, if the image is a face image, a face recognition algorithm can be used to recognize a face region in the image, and the face region is the foreground region and the remaining region in the image is the background region.

[0030] In step S12, a portion of the special effect object in the target display area is displayed on the initial image to obtain a target image.

[0031] Specifically, if the target display area is a foreground area, the part of the special effect object in the foreground area is displayed in the initial image, and if the target display area is a background area, the part of the special effect object in the background area is displayed in the initial image. If the target display area is an edge of the foreground area, the edge of the foreground area is marked, for example, the edge line of the foreground area is represented by a colored line or dot.

[0032] In this embodiment, by determining a target display area in the initial image of a special effect object, a portion of the special effect object in the target display area is displayed in the initial image, so that the special effect object can be displayed distinctively and a relatively excellent effect can be achieved.

[0033] In one alternative embodiment, step S12 specifically includes steps S121 to S123.

[0034] In step S121, an overlapping area between the position area of ​​the special effect object in the initial image and the target display area is determined.

[0035] Here, the special effect object is displayed in a portion of a plurality of target display areas, and an overlapping area between the position area of ​​each portion in the initial image and the target display area is determined. For example, when the special effect object includes a portion displayed in a foreground area and a portion displayed in a background area, the foreground area and the background area on the initial image are determined, respectively.

[0036] In step S122, the portion of the special effect object in the overlapping region is divided and set as a target display object.

[0037] For example, if the special effect object includes a portion displayed in a foreground region and a portion displayed in a background region, the portion displayed in the foreground region and the portion displayed in the background region of the special effect object are each divided.

[0038] In step S123, the target display object is displayed on top of the overlapping region of the initial image to obtain a target image.

[0039] For example, the special effect object includes a portion displayed in the foreground region and a portion displayed in the background region, and the target display object is a portion displayed in the foreground region and a portion displayed in the background region, and the portion displayed in the foreground region and the portion displayed in the background region are displayed corresponding to the foreground region and background region of the initial image.

[0040] In an alternative embodiment, the method further comprises step S13.

[0041] In step S13, Special In response to the user's operation on a special effect parameter setting option in a special effect setting interface, the instructions are generated to add a special effect object to the initial image, wherein the special effect parameter setting option is used by the user to set the special effect object and the target display area, and the instructions are used to indicate the special effect object and the target display area.

[0042] Specifically, a special effect parameter setting option may be provided in the special effect setting interface, and the special effect parameter setting options may be multiple, including a foreground special effect that is a special effect option to be displayed in the foreground area, a background special effect that is a special effect option to be displayed in the background area, a special effect option to mark the edge of the foreground area, etc., as shown in Fig. 1b. A user may select setting parameters based on these options, and may add multiple background special effects and / or foreground special effects, and after the user determines that the selection of setting parameters is completed, the user may generate an instruction to add a special effect object by triggering a decision button on the special effect setting interface.

[0043] Furthermore, step S13 specifically includes steps S131 to S133.

[0044] In step S131, the special effect object is determined in response to a selection operation in the special effect navigation tree of the first interface.

[0045] Specifically, as shown in Fig. 1c, a special effect navigation tree can be provided in the first interface, the special effect navigation tree includes special effect options, the special effect options being at least two, i.e., a foreground special effect option and a background special effect option, in which the foreground special effect option includes at least one foreground special effect, and the background special effect option includes at least one background special effect. A user can select a required special effect object from the special effect options in the special effect navigation tree.

[0046] In step S132, in response to a selection operation on a display area setting option on the second interface, the target display area is determined.

[0047] Here, the second interface and the first interface may be the same display interface.

[0048] In step S133, a command is generated based on the special effect object and the target display area.

[0049] Furthermore, step S11 specifically includes, when the special effect object to be added includes multiple sub special effect objects, a step of determining a target display area of ​​each sub special effect object respectively.

[0050] Accordingly, step S12 specifically includes a step of determining the display order of each sub-special effect object in the special effect object, and a step of sequentially displaying portions of each sub-special effect object in the special effect object in the target display area in the initial image based on the display order of each sub-special effect object in the special effect object, to obtain a target image.

[0051] Moreover, before performing step S12, the method further includes step S14.

[0052] In step S14, the special effect ON state is set in response to a user's ON trigger operation in the ON / OFF option in the special effect setting interface.

[0053] Step S12 specifically involves, if the special effect is currently in an on state, displaying a portion of the special effect object in the target display area in the initial image, and acquiring a target image.

[0054] Specifically, a special effect on / off option is provided in the special effect setting interface, allowing the user to select whether to distinguish between the foreground and background regions when adding a special effect object, and if the user wants to distinguish between the foreground and background regions, the special effect on / off option needs to be turned on, which triggers the execution of the above operation of determining the foreground and background regions of the image and subsequent steps. If the user does not want to distinguish between the foreground and background regions, the special effect on / off option needs to be turned off, which means that the foreground and background regions are not distinguished when displaying the special effect object, and the special effect object can be displayed at any position in the initial image.

[0055] As will be understood by those skilled in the art, obvious modifications (eg, overlapping the listed modes) or equivalent substitutions can be made based on the above embodiments.

[0056] The above describes each step in the embodiment of the method for processing image special effects based on the above order, but those skilled in the art will understand that the steps in the embodiment of the present disclosure do not necessarily need to be performed based on the above order, and may be performed in other orders such as reverse order, parallel order, cross order, etc. In addition to the above steps, those skilled in the art may add other steps. These obvious modifications or equivalent replacement methods should also fall within the scope of protection of the present disclosure, and will not be described here.

[0057] The following are examples of the apparatus of the present disclosure, which can be used to perform steps implemented in the method embodiments of the present disclosure. For ease of explanation, only parts relevant to the embodiments of the present disclosure are shown, and reference is made to the method embodiments of the present disclosure when specific technical details are not disclosed. EXAMPLES

[0058] In order to solve the technical problem that the special effect processing method in the prior art cannot achieve good effects, the embodiment of the present disclosure provides an image special effect processing device, which can execute the steps in the embodiment of the image special effect processing method described in the above embodiment 1. As shown in Figure 2, the device mainly includes a target display area determination module 21 and a special effect display module 22, in which: The target display area determination module 21 is used to determine a target display area in the initial image for the special effect object in response to an instruction to add the special effect object to the initial image, the target display area being a foreground area or a background area of ​​the initial image, the foreground area being an image area in the initial image in which the target object is located, and the background area being an image area in the initial image other than the foreground area. A special effect display module 22 is used to display the portion of the special effect object in the target display area on the initial image to obtain a target image.

[0059] Furthermore, the special effect display module 22 is specifically used to determine an overlap area between the position area of ​​the special effect object in the initial image and the target display area, divide a portion of the special effect object in the overlap area and make it a target display object, display the target display object on top of the overlap area of ​​the initial image, and obtain a target image.

[0060] Furthermore, the device further comprises: The instruction generation module 23 includes an instruction generation module 23 used to generate the instruction for adding a special effect object to an initial image in response to the user's operation on a special effect parameter setting option in the special effect setting interface, the special effect parameter setting option being used by the user to set the special effect object and the target display area, and the instruction being used to indicate the special effect object and the target display area.

[0061] Furthermore, the command generation module 23 is specifically used to determine the special effect object in response to a selection operation on a special effect navigation tree of the first interface, to determine the target display area in response to a selection operation on a display area setting option on the second interface, and to generate the command based on the special effect object and the target display area.

[0062] Furthermore, when the special effect object to be added includes multiple sub-special effect objects, the target display area determination module 21 is specifically used to determine the target display area of ​​each sub-special effect object in the special effect object. In response to this, the special effect display module 22 is specifically used to determine the display order of each sub-special effect object in the special effect object, and sequentially display the portions of the target display area of ​​each sub-special effect object in the special effect object in the initial image in sequence based on the display order of each sub-special effect object in the special effect object, to obtain a target image.

[0063] Furthermore, the device further comprises: a special effect on / off module 24 used for setting a special effect on state in response to a user's on-trigger operation of an on / off option on the special effect setting interface; The special effect display module 22 is specifically used to display the part of the special effect object in the target display area in the initial image when the special effect is currently in an on state, to obtain a target image.

[0064] Furthermore, the special effect object is a sticker and / or a frame for marking the target display area.

[0065] For detailed explanations of the operation principle of the embodiment of the image special effect processing device, the technical effects achieved, etc., please refer to the relevant explanations in the embodiment of the image special effect processing method, and the explanations will be omitted here. EXAMPLES

[0066] Referring now to FIG. 3, a structural schematic diagram of an electronic device 300 suitable for implementing the embodiments of the present disclosure is shown. Electronic equipment 300The electronic devices include, but are not limited to, mobile terminals such as mobile phones, notebook computers, digital broadcast receivers, PDAs (Personal Digital Assistants), PADs (Portable Android Devices, tablet computers), PMPs (Personal Multimedia Players), and in-vehicle terminals (e.g., in-vehicle navigation terminals), as well as fixed terminals such as digital TVs and desktop computers. Note that the electronic devices shown in FIG. 3 are merely examples and do not limit the functions and scope of use of the embodiments of the present disclosure.

[0067] 3, the electronic device 300 may include a processing unit (e.g., a central processing unit, an image processor, etc.) 301, which may perform various appropriate operations and processes based on programs stored in a read-only memory (ROM) 302 or programs loaded from a storage device 308 into a random access memory (RAM) 303. The RAM 303 further stores various types of programs and data required for the operation of the electronic device 300. The processing unit 301, the ROM 302, and the RAM 303 are interconnected by a bus 304. An input / output (I / O) interface 305 is also connected to the bus 304.

[0068] Typically, input devices 306 including, for example, a touch panel, touch pad, keyboard, mouse, camera, microphone, accelerometer, gyroscope, etc., output devices 307 including, for example, a liquid crystal display (LCD), speaker, vibrator, etc., storage devices 308 including, for example, a magnetic tape, hard disk, etc., and communication devices 309 may be connected to the I / O interface 305. To exchange data, the communication devices 309 allow wireless or wired communication between the electronic device 300 and other devices. Although FIG. 3 illustrates the electronic device 300 with various devices, it should be understood that not all of the illustrated devices need be implemented or provided. Alternatively, more or fewer devices may be implemented or provided.

[0069] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowcharts may be implemented as a computer software program. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program carried on a non-transitory computer-readable medium, the computer program including a program code for performing the method shown in the flowchart. In such an embodiment, the computer program may be downloaded and installed from a network via the communication device 309, or may be installed from the storage device 308, or may be installed from the ROM 302. When the computer program is executed by the processing device 301, it performs the functions defined in the method according to the embodiment of the present disclosure.

[0070] It should be noted that the computer-readable medium of the present disclosure may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of computer-readable storage media include, but are not limited to, an electrical connection having one or more leads, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (Electrical Programmable ROM, EPROM, or flash memory), an optical fiber, a portable compact disc read-only memory (Compact Disc ROM, CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present disclosure, the computer-readable storage medium may be any tangible medium that contains or stores a program, which may be used in or in connection with an instruction execution system, apparatus, or device. Further, in this disclosure, a computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave on which computer-readable program code is carried. Such propagated data signals may take various forms, including, but not limited to, electromagnetic signals, optical signals, or any suitable superposition of the above. A computer-readable signal medium may also be any computer-readable medium other than a computer-readable storage medium, which may transmit, propagate, or transmit a program for use in or in connection with an instruction execution system, apparatus, or device. The program code contained in the computer-readable medium may be transmitted by any suitable medium, including, but not limited to, electrical wires, optical cables, RF (Radio Frequency), etc., or any suitable superposition of these.

[0071] In some embodiments, the clients and servers may communicate using any now known or later developed network protocol, such as HTTP (HyperText Transfer Protocol), and may interconnect with any form or medium of digital data communication (e.g., a communications network). Examples of communications networks include a local area network (Local Area Network, "LAN"), a wide area network (Wide Area Network, "WAN"), the Internet (e.g., the Internet), and end-to-end networks (e.g., an ad hoc end-to-end network), as well as any now known or later developed network.

[0072] The computer readable medium may be included in the electronic device, or may exist separately and not integrated into the electronic device.

[0073] The computer-readable medium carries one or more programs which, when executed by the electronic device, cause the electronic device to perform the following steps in response to an instruction to add a special effect object to an initial image: determine a target display area in the initial image for the special effect object, the target display area being a foreground or background area of ​​the initial image, the foreground area being an image area in the initial image in which a target object is located, and the background area being an image area in the initial image other than the foreground area; and displaying a portion of the special effect object in the target display area in the initial image to obtain a target image.

[0074] Computer program code for carrying out the operations of the present disclosure may be written in one or more programming languages ​​or a combination thereof, including, but not limited to, object-oriented programming languages ​​such as Java, Smalltalk, C++, and the like, as well as conventional procedural programming languages ​​such as "C" or similar programming languages. The program code may run entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., connected via the Internet using an Internet Service Provider).

[0075] The flowcharts and block diagrams in the drawings illustrate possible architectures, functions, and operations of systems, methods, and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flowcharts or block diagrams may represent a module, program segment, or part of code, including one or more executable instructions for implementing a certain logical function. It should be noted that in some alternative implementations, the functions depicted in the blocks may occur in a different order than that depicted in the drawings. For example, two successively depicted blocks may in fact be executed substantially in parallel, or may be executed in a reverse order depending on the functionality involved. Also, each block in the block diagrams or flowcharts and the superposition of blocks in the block diagrams or flowcharts may be realized using a system based on dedicated hardware that executes a certain function or operation, or may be realized using a superposition of dedicated hardware and computer instructions.

[0076] The units according to the embodiments of the present disclosure may be realized in the form of software or hardware. Here, the name of the unit may not necessarily constitute a limitation on the unit itself. do not .

[0077] The functions described herein may be performed, at least in part, by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include Field Programmable Gate Arrays (FPGAs), Application Specific Integrated Circuits (ASICs), Application Specific Standard Parts (ASSPs), Systems on Chips (SOCs), Complex Programmable Logic Devices (CPLDs), etc.

[0078] In the context of this disclosure, a machine-readable medium may be a tangible medium that can contain or store a program for use in or in connection with an instruction execution system, device, or apparatus. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium includes, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or apparatus, or any suitable superposition of the above. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memories (RAMs), read-only memories (ROMs), erasable programmable read-only memories (EPROMs or flash memories), optical fibers, compact disk read-only memories (CD-ROMs), optical storage devices, magnetic storage devices, or any suitable superposition of the above.

[0079] According to one or more embodiments of the present disclosure, a method for processing image special effects is provided, determining a target display area in the initial image for a special effect object in response to a command to add the special effect object to the initial image, the target display area being a foreground area or a background area of ​​the initial image, the foreground area being an image area in the initial image in which a target object is located, and the background area being an image area in the initial image other than the foreground area; displaying a portion of the special effect object in the target display area in the initial image to obtain a target image.

[0080] Furthermore, the step of displaying the portion of the special effect object in the target display area in the initial image to obtain a target image further comprises: determining an overlap area between a position area of ​​the special effect object in the initial image and the target display area; dividing a portion of the special effect object in the overlapping region as a target display object; and displaying the target object on top of the overlapping area of ​​the initial image to obtain a target image.

[0081] Furthermore, the method comprises: The method further includes generating the instructions for adding a special effect object to an initial image in response to the user's operation on a special effect parameter setting option in the special effect setting interface, the special effect parameter setting option being used by the user to set the special effect object and the target display area, and the instructions being used to indicate the special effect object and the target display area.

[0082] Further, the step of generating instructions for adding a special effect object to an initial image further comprises: determining the special effect object in response to a selection operation in a special effect navigation tree of a first interface; determining the target display area in response to a selection operation on a display area setting option on a second interface; generating the instructions based on the special effect object and the target display area.

[0083] Further, the step of determining a target display area in the initial image of the special effect object further comprises: If the special effect object to be added includes multiple sub-special effect objects, the method includes determining the target display area of ​​each sub-special effect object, respectively.

[0084] Accordingly, the step of displaying the portion of the special effect object in the target display area in the initial image to obtain a target image comprises: determining a display order of each of the sub-special effect objects in the special effect object; The method includes a step of sequentially displaying a portion of each sub-special effect object in the special effect object in the target display area in the initial image based on a display order of each sub-special effect object in the special effect object, thereby obtaining a target image.

[0085] Furthermore, the method comprises: The method further includes the step of setting a special effect ON state in response to a user's ON trigger operation of an ON / OFF option in the special effect setting interface; The step of displaying the portion of the special effect object in the target display area in the initial image and obtaining a target image specifically involves, when the special effect is currently on, displaying the portion of the special effect object in the target display area in the initial image and obtaining a target image.

[0086] Furthermore, the special effect object is a sticker and / or a frame for marking the target display area.

[0087] According to one or more embodiments of the present disclosure, there is provided an image special effect processing device, a target display area determination module, in response to a command to add a special effect object to an initial image, for determining a target display area in the initial image for the special effect object, the target display area being a foreground area or a background area of ​​the initial image, the foreground area being an image area in the initial image where a target object is located, and the background area being an image area in the initial image other than the foreground area; a special effect display module used to display a portion of the special effect object in the target display area in the initial image to obtain a target image.

[0088] Furthermore, the special effect display module is specifically used to determine an overlap area between the position area of ​​the special effect object in the initial image and the target display area, divide a portion of the special effect object in the overlap area and make it a target display object, display the target display object on top of the overlap area of ​​the initial image, and obtain a target image.

[0089] Furthermore, the device The instruction generation module further includes an instruction generation module used to generate the instructions for adding a special effect object to an initial image in response to the user's operation on a special effect parameter setting option in the special effect setting interface, the special effect parameter setting option being used by the user to set the special effect object and the target display area, and the instructions being used to indicate the special effect object and the target display area.

[0090] Furthermore, the command generation module is specifically used to determine the special effect object in response to a selection operation on a special effect navigation tree of a first interface, to determine the target display area in response to a selection operation on a display area setting option on a second interface, and to generate the command based on the special effect object and the target display area.

[0091] In addition, the target display area determination module is specifically used to determine the target display area of ​​each sub-special effect object in the special effect object when the special effect object to be added includes multiple sub-special effect objects. Accordingly, the special effect display module is specifically used to determine the display order of each sub-special effect object in the special effect object, and sequentially display the parts of the target display area of ​​each sub-special effect object in the special effect object in the initial image according to the display order of each sub-special effect object in the special effect object to obtain a target image.

[0092] Furthermore, the device Further comprising a special effect on / off module, which is used for setting a special effect on state in response to a user's on-trigger operation of an on / off option on the special effect setting interface; The special effect display module is specifically used for displaying a part of the special effect object in the target display area in the initial image when the special effect is currently in an on state, to obtain a target image.

[0093] Furthermore, the special effect object is a sticker and / or a frame for marking the target display area.

[0094] According to one or more embodiments of the present disclosure, there is provided an electronic device, comprising: a memory used to store non-transitory computer readable instructions; before Executing the computer readable instructions A processor , the processor The computer readable instructions and a processor which, when executed, is used to realize the image special effect processing method.

[0095] According to one or more embodiments of the present disclosure, a computer-readable storage medium is provided, which is used to store non-transitory computer-readable instructions, which, when executed by a computer, cause the computer to perform the above-mentioned image special effect processing method.

[0096] According to one or more embodiments of the present disclosure, a computer program product is provided, comprising computer program instructions for causing a computer to execute the above-mentioned image special effect processing method.

[0097] According to one or more embodiments of the present disclosure, a computer program is provided, which, when executed on a computer, causes the computer to perform the above-mentioned image special effect processing method.

[0098] The above description is merely a description of the preferred embodiments of the present disclosure and the technical principles applied. As can be understood by those skilled in the art, the scope of the disclosure of the present disclosure is not limited to the technical solution by the specific superposition of the above technical features, but also covers other technical solutions by any superposition of the above technical features or their equivalent features without departing from the idea of ​​the above disclosure. For example, the above features may be substituted with technical features having similar functions (but not limited to) disclosed in the present disclosure to form technical solutions.

[0099] Moreover, although operations are shown in a particular order, this should not be understood as requiring that these operations be performed in the particular order shown, or in sequential order. In certain circumstances, multitasking and parallel processing may be advantageous. Similarly, although the above description includes some specific implementation details, these should not be construed as limiting the scope of the disclosure. Certain features that are described in the context of separate embodiments may also be implemented in a single embodiment in an overlapping manner. Conversely, various features that are described in the context of a single embodiment may also be implemented in multiple embodiments, separately or in any suitable partial overlapping manner.

[0100] Although the present subject matter has been described in language specific to structural features or methodological acts, it should be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or acts described above. Rather, the specific features and acts described above are merely examples by which the claims may be implemented.

[0101] This application claims priority to a Chinese patent application, application number 202010122421.7, entitled "Method and apparatus for processing image special effects," filed with the China Patent Office on February 27, 2020, the entire contents of which are incorporated herein by reference.

Claims

1. A method for processing special image effects, comprising the steps of: determining a target display area in the initial image for a special effects object in response to a command to add the special effects object to the initial image, the target display area being a foreground area or a background area of ​​the initial image, the foreground area being an image area in the initial image in which a target object is located and the background area being an image area in the initial image other than the foreground area, the special effects object including a portion that is displayed in the foreground area and a portion that is displayed in the background area; displaying a first portion of the special effect object in the target display area on the initial image to obtain a target image, the special effect object including the first portion and a second portion, the second portion of the special effect object being located outside the target display area and not displayed; The step of displaying a first portion of the special effect object in the target display area in the initial image and acquiring a target image includes: determining an overlap area between a position area of ​​the special effect object in the initial image and the target display area; dividing the first portion of the overlapping region of the special effect object as a target display object; and displaying the target display object on top of the overlapping area of ​​the initial image to obtain a target image. Processing methods.

2. The processing method includes: generating the instruction for adding a special effect object to an initial image in response to a user's operation on a special effect parameter setting option in a special effect setting interface, the special effect parameter setting option being used by the user to set the special effect object and the target display area, and the instruction being used to indicate the special effect object and the target display area. The method of claim 1.

3. the step of generating instructions for adding a special effect object to an initial image in response to a user operation on a special effect parameter setting option in the special effect setting interface, comprising: determining the special effect object in response to a selection operation in a special effect navigation tree of a first interface; determining the target display area in response to a selection operation on a display area setting option on a second interface; and generating the command based on the special effect object and the target display area. The method of claim 2.

4. The step of determining a target display area in the initial image of the special effect object comprises: When the special effect object includes a plurality of sub-special effect objects, determining a target display area of ​​each sub-special effect object in the special effect object, Accordingly, the step of displaying a first portion of the special effect object in the target display area in the initial image to obtain a target image includes: determining a display order of each of the sub-special effect objects in the special effect object; and displaying a first portion of each of the sub-special effect objects in the special effect object in the initial image in sequence based on a display order of the sub-special effect objects in the special effect object to obtain a target image. The processing method according to any one of claims 1 to 3.

5. The processing method includes: The method further includes the step of setting a special effect ON state in response to a user's ON trigger operation of an ON / OFF option in the special effect setting interface; The step of displaying a first portion of the special effect object in the target display area on the initial image and obtaining a target image is specifically characterized in that, when the special effect is currently in an on state, the step of displaying the first portion of the special effect object in the target display area on the initial image and obtaining a target image. The processing method according to any one of claims 1 to 4.

6. The processing method according to any one of claims 1 to 5, characterized in that the special effect object is one of a sticker and a frame marking the target display area.

7. An image special effect processing device, comprising: a target display area determination module, in response to a command to add a special effect object to an initial image, for determining a target display area in the initial image for the special effect object, the target display area being a foreground area or a background area of ​​the initial image, the foreground area being an image area in the initial image where a target object is located, the background area being an image area in the initial image other than the foreground area, the special effect object including a portion displayed in the foreground area and a portion displayed in the background area; a special effect display module used to display a first portion of the special effect object in the target display area on the initial image to obtain a target image, the special effect object including the first portion and a second portion, the second portion of the special effect object being located outside the target display area and not displayed; Displaying a first portion of the special effect object in the target display area on the initial image to obtain a target image, determining an overlap area between a position area of ​​the special effect object in the initial image and the target display area; Dividing the first portion of the overlapping region of the special effect object into a target display object; and displaying the target display object on top of the overlapping area of ​​the initial image to obtain a target image. Processing unit.

8. An electronic device, a memory used to store non-transitory computer readable instructions; A processor for executing the computer-readable instructions, the processor being used to realize the processing method according to any one of claims 1 to 6 when the processor executes the computer-readable instructions. electronic equipment.

9. A computer-readable storage medium used to store non-transitory computer-readable instructions, which, when executed by a computer, cause the computer to execute the processing method according to any one of claims 1 to 6.

10. A computer program causing a computer to execute the processing method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • Image processing method and device, terminal device and storage medium thereof

    CN108012091A

  • Image special effect processing method and device and live video terminal

    CN110012352A

  • Image synthesizer and image synthesizing method

    JP2016184864A

  • Picture creation game machine, display method, and program

    JP2018181044A

  • Photograph creation game machine, control method and program

    JP2019192061A