An image effect processing method and system based on mirror setting switching

By pre-using a mirror image of the original image for face detection in the image processing system and performing mirroring again when the mirror setting state changes, the problem of special effects failure caused by mirror setting switching is solved, achieving stable and reliable special effects output and efficient image processing.

CN116205848BActive Publication Date: 2026-07-03BEIJINGLUOTA INFORMATION TECHNOLOGYCO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
BEIJINGLUOTA INFORMATION TECHNOLOGYCO LTD
Filing Date
2022-12-12
Publication Date
2026-07-03

AI Technical Summary

Technical Problem

In image processing systems, the face detector restarts when mirror settings are switched, causing special effects processing to fail, affecting image display and user experience.

Method used

By pre-using a mirrored image of the original image for face detection, and then mirroring it again when the system mirror settings switch, a special effects image is generated, avoiding the need for the face detector to restart.

Benefits of technology

It improves the stability and reliability of image effects processing, reduces the image texture acquisition and face detection process, and improves the efficiency of effects processing and user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116205848B_ABST
    Figure CN116205848B_ABST
Patent Text Reader

Abstract

This application discloses an image effects processing method and system based on mirror setting switching. The technical solution provided by this application involves acquiring a first mirror image, performing texture acquisition on the first mirror image to obtain a first texture image, and inputting the first mirror image into a face detector to output a first face detection signal. When the image mirror setting state switches from a mirror state to a non-mirror state, mirror processing is performed on the first mirror image, the first texture image, and the first face detection signal to obtain corresponding second mirror image, second texture image, and second face detection signal. An effects-processed image is generated based on the second mirror image, the second face detection signal, and the second texture image. Using the above technical means can avoid the situation where the effects fail due to a face detector restart, improving the stability and reliability of image effects processing. Stable and reliable effects output enhances the user experience.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of image processing technology, and in particular to an image effects processing method and system based on mirror settings switching. Background Technology

[0002] Currently, image mirroring technology is involved in many applications in daily life. For example,

[0003] During live video streaming, the camera-captured image is mirrored by default. The mirrored image is then input into a face detector to detect facial landmarks. Based on these landmarks, appropriate effects (such as beauty filters) are added to the mirrored image to optimize the live stream display. If the user cancels the default image mirroring setting, the original camera-captured image will be used directly for effects processing.

[0004] However, when the system switches from the default mirrored setting to a non-mirrorized setting, the image input to the system's face detector changes, causing the face detector to restart. During this process, the face detector does not output facial landmarks, thus rendering image effects ineffective. This affects the image display quality and results in a relatively poor user experience. Summary of the Invention

[0005] This application provides an image effects processing method and system based on mirror setting switching, which can ensure the stability and reliability of image effects processing when mirror settings are switched, and solves the technical problem that image effects processing fails when the system switches from the default mirror setting to a non-mirror setting.

[0006] In a first aspect, embodiments of this application provide an image effects processing method based on mirroring settings switching, comprising:

[0007] A first mirror image is acquired, a first texture image is obtained by performing texture acquisition on the first mirror image, and the first mirror image is input into a face detector to output a first face detection signal. The first mirror image is obtained by mirroring the original image.

[0008] The image mirroring setting state of the detection system is such that when the image mirroring setting state is switched from mirrored state to non-mirrored state, the first mirrored image, the first texture image and the first face detection signal are mirrored respectively to obtain the corresponding second mirrored image, the second texture image and the second face detection signal.

[0009] A special effects image is generated based on the second mirror image, the second face detection signal, and the second texture image.

[0010] In a second aspect, embodiments of this application provide an image effects processing system based on mirror setting switching, comprising:

[0011] The acquisition module is configured to acquire a first mirror image, perform texture acquisition on the first mirror image to obtain a first texture image, input the first mirror image into a face detector, and output a first face detection signal. The first mirror image is obtained by mirroring the original image.

[0012] The processing module is configured to detect the image mirroring setting state of the system. When the image mirroring setting state switches from mirrored state to non-mirrored state, it performs mirroring processing on the first mirrored image, the first texture image, and the first face detection signal to obtain the corresponding second mirrored image, the second texture image, and the second face detection signal.

[0013] The generation module is configured to generate special effects images based on the second mirror image, the second face detection signal, and the second texture image.

[0014] In a third aspect, embodiments of this application provide an image effects processing device based on mirror setting switching, comprising:

[0015] Memory and one or more processors;

[0016] The memory is configured to store one or more programs;

[0017] When the one or more programs are executed by the one or more processors, the one or more processors implement the image effects processing method based on mirror settings switching as described in the first aspect.

[0018] In a fourth aspect, embodiments of this application provide a storage medium containing computer-executable instructions, which, when executed by a computer processor, are configured to perform the image effects processing method based on mirror setting switching as described in the first aspect.

[0019] In a fifth aspect, embodiments of this application provide a computer program product containing instructions that, when executed on a computer or processor, cause the computer or processor to perform the image effects processing method based on mirror setting switching as described in the first aspect.

[0020] This embodiment of the application acquires a first mirrored image, performs texture acquisition on the first mirrored image to obtain a first textured image, and inputs the first mirrored image into a face detector to output a first face detection signal. The first mirrored image is obtained by mirroring the original image. The system detects the image mirroring setting state. When the image mirroring setting state switches from mirrored to non-mirrored, the first mirrored image, the first textured image, and the first face detection signal are mirrored to obtain corresponding second mirrored images, second textured images, and second face detection signals. A special effects image is generated based on the second mirrored image, the second face detection signal, and the second textured image. By using the above technical means, face detection is performed using a mirrored image of the original image beforehand. When the system's image mirroring setting state switches from mirrored to non-mirrored, the mirrored data is mirrored again to generate a special effects image. This eliminates the need to change the input of the face detector, thus avoiding the situation where the special effects fail due to a face detector restart, improving the stability and reliability of image special effects processing. Stable and reliable special effects output enhances the user experience.

[0021] Furthermore, by re-mirroring the already mirrored data, the image texture acquisition and face detection processes are reduced, thereby improving the efficiency of special effects image generation and further enhancing the user experience. Attached Figure Description

[0022] Figure 1 This is a flowchart of an image effects processing method based on mirror settings switching provided in an embodiment of this application;

[0023] Figure 2 This is a flowchart illustrating the production process of special effects processed images in the embodiments of this application;

[0024] Figure 3 This is a flowchart of the image mirroring process in an embodiment of this application;

[0025] Figure 4 This is a schematic diagram of facial key points in an embodiment of this application;

[0026] Figure 5 This is a schematic diagram of face angle rotation according to an embodiment of this application;

[0027] Figure 6 This is a schematic diagram of the structure of an image effects processing system based on mirror setting switching provided in an embodiment of this application;

[0028] Figure 7 This is a schematic diagram of the structure of an image effects processing device based on mirror setting switching provided in an embodiment of this application. Detailed Implementation

[0029] To make the objectives, technical solutions, and advantages of this application clearer, specific embodiments of this application will be described in further detail below with reference to the accompanying drawings. It should be understood that the specific embodiments described herein are merely for explaining this application and not for limiting it. It should also be noted that, for ease of description, only the parts relevant to this application are shown in the drawings, not all of them. Before discussing exemplary embodiments in more detail, it should be mentioned that some exemplary embodiments are described as processes or methods depicted as flowcharts. Although the flowcharts describe operations (or steps) as sequential processes, many of these operations can be performed in parallel, concurrently, or simultaneously. Furthermore, the order of the operations can be rearranged. The process can be terminated when its operation is completed, but may also have additional steps not included in the drawings. The process can correspond to a method, function, procedure, subroutine, subprogram, etc.

[0030] The image effects processing method based on mirror setting switching provided in this application aims to perform face detection using a mirror image of the original image beforehand. When the system image mirror setting changes from mirrored to non-mirrored, the previously mirrored data is mirrored again to generate the effects image. This avoids the situation where the face detector restarts when the system mirror setting changes, causing the effects to fail, thus improving the stability and reliability of image effects processing.

[0031] For traditional image mirroring effects, taking live streaming as an example, during a live stream, since most streamers use front-facing cameras, the live stream will default to mirrored output. If the streamer wants to display text or other content, or doesn't want a mirrored output, they can manually click the mirror settings button to cancel the mirroring. This will change the display on both the streamer's and viewers' ends to a non-mirrored state, making it easier to view text or other content that shouldn't be mirrored, thus improving the user experience.

[0032] However, during live streaming, when a user clicks the screen mirroring setting button to switch the live stream from mirrored to non-mirrored mode, the image input to the system's face detector changes. This change causes the face detector to restart, resulting in no facial key points being output. Since special effects processing requires generating images based on face detection points, the special effects processing also fails. This affects the image display effect and leads to a relatively poor user experience. Therefore, this application provides an image special effects processing method based on mirroring setting switching to solve the technical problem of image special effects processing failure when the system switches from the default mirrored setting to a non-mirrored setting.

[0033] Example:

[0034] Figure 1 A flowchart of an image effects processing method based on mirror setting switching according to an embodiment of this application is provided. This method can be executed by an image effects processing device based on mirror setting switching. This device can be implemented through software and / or hardware, and can consist of two or more physical entities, or a single physical entity. Generally, this device can be a computer, mobile phone, or tablet image processing device.

[0035] The following description uses the image effects processing device based on mirror setting switching as an example to illustrate the image effects processing method based on mirror setting switching. (Refer to...) Figure 1 The image effects processing method based on mirror settings switching specifically includes:

[0036] S110. Obtain a first mirror image, perform texture acquisition on the first mirror image to obtain a first texture image, input the first mirror image into a face detector, and output a first face detection signal. The first mirror image is obtained by mirroring the original image.

[0037] S120, Detecting the image mirroring setting state of the system, when the image mirroring setting state is switched from mirroring state to non-mirroring state, mirroring processing is performed on the first mirrored image, the first texture image and the first face detection signal respectively to obtain the corresponding second mirrored image, the second texture image and the second face detection signal.

[0038] S130. Generate a special effects image based on the second mirror image, the second face detection signal, and the second texture image.

[0039] In this embodiment of the application, during image effects processing based on the system's image mirroring settings, the system's image mirroring setting state is determined. This state includes a mirrored state and a non-mirrored state, with the system's default image mirroring setting being the mirrored state. Based on the current system image mirroring setting state, appropriate image data is adaptively selected for effects processing to achieve the desired effects for the user.

[0040] Furthermore, regardless of whether the image is mirrored or not, when generating the special effects image, the original image captured by the camera is first converted into a mirrored image through mirroring. This mirrored image is then input into a face detector for face detection, obtaining the face detection signal from the mirrored image. A texture image is then acquired through texture acquisition. Next, based on the system's real-time image mirroring setting, if the current system image mirroring setting is mirrored, the mirrored image, its corresponding texture image, and the face detection signal are directly used for special effects processing to generate the special effects image. If the current system image mirroring setting is not mirrored, the mirrored image obtained from the previously pre-processed original image, along with its corresponding texture image and face detection signal, undergoes mirroring again. The result of this second mirroring process is then used for special effects processing to generate the special effects image.

[0041] Throughout the process, the original image is preprocessed to ensure that the image input to the face detector is always a mirror image of the original image. Subsequently, if the system's image mirroring setting is switched to a non-mirror state, the image can be mirrored again to transform the base data for image effects processing. This prevents the image input to the face detector from changing when the system's image mirroring setting switches from mirrored to non-mirrored mode. This avoids face detector restarts, ensures stable output of images for effects processing, prevents image effects from failing, and improves the reliability and stability of image effects processing.

[0042] Specifically, refer to Figure 2 Steps a1-a7 correspond to the original images captured by the camera. First, the images are mirrored to obtain a mirrored image, which is defined as the first mirrored image. Wherein, if the camera and...

[0043] If the image effects processing device based on mirror settings switching is two different entities, then the mirror processing of the original image can be performed on either the camera or the image effects processing device based on mirror settings switching.

[0044] The image mirroring processing in this embodiment is a horizontal image mirroring process. During the mirroring process, assuming the original image has a height of h and a width of w, after the horizontal mirroring transformation, the pixel at point p(x0, y0) in the original image becomes the pixel value at coordinate p'(w-x0, y0) in the new image. If (x0, y0) represents the coordinates of the original image and (x1, y1) represents the coordinates of the image after the horizontal mirroring transformation, then the relationship between the two images can be expressed as:

[0045]

[0046] Based on the above image mirror relationship formula, the first mirror image of the original image can be obtained. For example... Figure 3As shown, the original image 11 can be mirrored to obtain the first mirror image 12.

[0047] Further, a texture image is obtained by performing texture acquisition on the first mirror image, which is defined as the first texture image. The first mirror image is then input into a face detector for face detection, and the corresponding face detection signal is obtained, which is defined as the first face detection signal. There are many methods for texture acquisition and face detection of face images. This application does not impose fixed limitations on the specific implementation method, and will not elaborate further here.

[0048] Furthermore, based on the first mirrored image, the first texture image, and the first face detection signal, it is first determined whether the current image mirroring setting state of the system has switched from mirrored state to non-mirrored state, so as to perform image effect processing according to different image mirroring setting states.

[0049] Specifically, when the image mirroring setting is in mirrored state, a special effects image is generated based on a first mirrored image, a first texture image, and a first face detection signal. During special effects processing, the first face detection signal and the first mirrored image are used to locate the positions on the first texture image where special effects need to be added. For example, pupil recognition is performed using the first mirrored image, and the lip position is located using facial key points from the first face detection signal. Then, based on the located positions on the first texture image, the system rendering engine adds special effects to the corresponding positions, thereby generating the corresponding special effects image, which is then output and displayed.

[0050] On the other hand, when the image mirroring setting switches from mirrored to non-mirrored state, an adaptive transformation of the base data used for special effects processing is required. Since the user requires a non-mirrored display, the first mirrored image needs to be mirrored again to obtain a second mirrored image. The mirroring process of the first mirrored image is the reverse process of the mirroring process of the original image described above. That is, let (x0, y0) represent the coordinates of the original image, and (x1, y1) represent the coordinates of the first mirrored image after horizontal mirroring transformation. Then, the second mirrored image obtained by mirroring the first mirrored image is actually the original image. The relationship between the two images can be expressed as:

[0051]

[0052] Based on the above image mirror relationship formula, the second mirror image can be obtained for subsequent image effects processing.

[0053] Similarly, the first texture image and the first face detection signal are also mirrored to obtain the corresponding second texture image and second face detection signal. It should be noted that in this embodiment, the first texture image and the first face detection signal are directly mirrored to obtain the second texture image and the second face detection signal, instead of performing texture acquisition and face detection on the second mirrored image. This eliminates the need for texture acquisition and face detection processes, and improves the efficiency of acquiring the second texture image and the second face detection signal through a relatively faster mirroring process.

[0054] The mirroring method for the texture image can refer to the image mirroring method described above. By determining the x-coordinate of each pixel in the first texture image, after mirroring, the x-coordinate of the corresponding pixel is 1-x. Since it is a left-right mirroring process, there is no need to adjust the y-coordinate of the pixel. Referring to the above method, the second texture image can be obtained by calculating the coordinates of each pixel using a fragment shader. The specific image mirroring and texture mirroring in this application are not fixed and will not be elaborated here.

[0055] The first face detection signal includes first face key point information, and the second face detection signal includes second face key point information. When the first face detection signal is mirrored to obtain the corresponding second face detection signal, the face key point information is obtained by swapping the face points of the first face key point information according to the mirror direction.

[0056] Specifically, facial landmark information assigns a fixed order to the points at each location. (See reference...) Figure 4 Since the face detection signal is subsequently used for special effects processing functions such as beautification, stickers, and makeup, these functions require a fixed order of facial key points. If only image mirroring is performed, the order of the facial key points will change; for example, point 0 will become point 32, and point 32 will become point 0. Therefore, without mirroring the facial key points, stickers and beautification / makeup effects will not function correctly. Therefore, after obtaining the second mirror image from the first mirror image, additional mirroring processing of the first face detection signal is required. This involves swapping the facial key point positions according to the mirror direction to reset the facial key points.

[0057] When swapping facial landmarks in the first facial landmark information according to a mirror direction, the horizontal coordinates of two symmetrical facial landmarks in the first facial landmark information are swapped. The mirror formula for facial landmarks is as follows:

[0058] new_pointX = (imageWidth - old_pointX)

[0059] swap(pointX_a, pointX_b)

[0060] Where `imageWidth` represents the size of the first mirror image, `old_pointX` represents the x-coordinate of the facial landmark in the first mirror image, `new_pointX` represents the x-coordinate of the facial landmark in the second mirror image, `pointX_a` and `pointX_b` represent the x-coordinates of two symmetrical facial landmarks, and `swap` represents swapping these two x-coordinates. Figure 4 As shown, points 0 and 32 are symmetrical key points. By swapping their horizontal coordinates, the facial key points at these locations can be mirrored. Similarly, by swapping the horizontal coordinates of each point in the first facial key point information according to the mirror direction, the mirroring process is completed, resulting in the second facial key point information. This ensures that the order of the facial key points after mirroring is not disordered.

[0061] In addition, the first face detection signal also includes a first yaw angle and a first roll angle, and the second face detection signal includes a second yaw angle and a second roll angle; when the first face detection signal is mirrored to obtain the corresponding second face detection signal, the first yaw angle and the first roll angle are rotated in the mirror direction to obtain the second yaw angle and the second roll angle.

[0062] Reference Figure 5 Since the face image undergoes a mirror transformation, its corresponding pose angles also need to be changed. Therefore, in this embodiment of the application, the first yaw angle and the first roll angle are inverted to obtain the second yaw angle and the second roll angle, in order to ensure that the face pose angles after mirror processing are accurately corresponded.

[0063] Subsequently, special effects processing is applied to the second texture image based on the second mirror image and the second face detection signal, outputting a processed image. During the special effects processing, the second face detection signal and the second mirror image are used to locate the positions on the second texture image where special effects need to be added. For example, pupil recognition is performed using the second mirror image, and the lip position is located using facial key points from the second face detection signal. Then, based on the located positions on the second texture image, the system rendering engine adds special effects at the corresponding positions, thereby generating the corresponding processed image, which is then output and displayed. This completes the image mirroring processing for different image mirroring settings in this embodiment of the application.

[0064] For example, in a live streaming scenario, the camera captures the live feed, and the captured face orientation reflects the real-world orientation (the image is not mirrored). When the user uses the front-facing camera, due to the default image mirroring setting, the original image is mirrored (the image is now mirrored) and then sent to the face detector for facial landmark detection. Then, depending on whether the user needs a mirrored image, if so, it is directly sent to the effects module for effects processing. If the user needs a non-mirrored image, it first undergoes a mirroring process to mirror the already mirrored image again, while simultaneously mirroring the texture image and face detection signal. The processed data is then sent to the effects module for effects processing. At this point, the desired effects can be displayed on both the broadcaster's end and the client's end.

[0065] The above describes a process where a first mirrored image is acquired, a first texture image is obtained by performing texture acquisition on the first mirrored image, and the first mirrored image is input into a face detector to output a first face detection signal. The first mirrored image is obtained by mirroring the original image. The system detects the image mirroring setting state. When the image mirroring setting state switches from mirrored to non-mirrored, the first mirrored image, the first texture image, and the first face detection signal are mirrored to obtain corresponding second mirrored images, second texture images, and second face detection signals. A special effects image is generated based on the second mirrored image, the second face detection signal, and the second texture image. By using this technique, face detection is performed using a mirrored image of the original image beforehand. When the system's image mirroring setting state switches from mirrored to non-mirrored, the mirrored data is mirrored again to generate a special effects image. This eliminates the need to change the input to the face detector, thus avoiding the situation where a face detector restart causes the special effects to fail, improving the stability and reliability of image special effects processing. Stable and reliable special effects output enhances the user experience. Furthermore, by re-mirroring the already mirrored data, the image texture acquisition and face detection processes are reduced, thereby improving the efficiency of special effects image generation and further enhancing the user experience.

[0066] Based on the above embodiments, Figure 6 This is a schematic diagram of an image effects processing system based on mirror settings switching, provided in this application. (Reference) Figure 6 The image effects processing system based on mirror setting switching provided in this embodiment specifically includes: an acquisition module 21, a processing module 22, and a generation module 23.

[0067] The acquisition module 21 is configured to acquire a first mirror image, perform texture acquisition on the first mirror image to obtain a first texture image, input the first mirror image into a face detector, output a first face detection signal, and obtain the first mirror image by mirroring the original image.

[0068] The processing module 22 is configured to detect the image mirroring setting state of the system. When the image mirroring setting state switches from mirroring state to non-mirroring state, it performs mirroring processing on the first mirrored image, the first texture image and the first face detection signal respectively to obtain the corresponding second mirrored image, the second texture image and the second face detection signal.

[0069] The generation module 23 is configured to generate a special effects image based on the second mirror image, the second face detection signal, and the second texture image.

[0070] Specifically, the first face detection signal includes first face key point information, and the second face detection signal includes second face key point information;

[0071] The first mirror image, the first texture image, and the face detection signal are respectively mirrored to obtain the corresponding second mirror image, second texture image, and second face detection signal, including:

[0072] The first facial landmark information is obtained by swapping the facial landmarks in a mirror direction. Specifically, the horizontal coordinates of two symmetrical facial landmarks in the first facial landmark information are swapped.

[0073] Specifically, the first face detection signal includes a first yaw angle and a first roll angle, and the second face detection signal includes a second yaw angle and a second roll angle;

[0074] The first mirror image, the first texture image, and the face detection signal are respectively mirrored to obtain the corresponding second mirror image, second texture image, and second face detection signal, including:

[0075] The first yaw angle and the first roll angle are rotated in the mirror direction to obtain the second yaw angle and the second roll angle.

[0076] After the image mirroring setting status of the detection system, it also includes:

[0077] When the image mirroring setting is in mirror state, a special effects image is generated based on the first mirror image, the first texture image, and the first face detection signal.

[0078] A special effects image is generated based on a second mirror image, a second face detection signal, and a second texture image, including:

[0079] The second texture image is processed with special effects based on the second mirror image and the second face detection signal, and the processed image is output.

[0080] The above describes a process where a first mirrored image is acquired, a first texture image is obtained by performing texture acquisition on the first mirrored image, and the first mirrored image is input into a face detector to output a first face detection signal. The first mirrored image is obtained by mirroring the original image. The system detects the image mirroring setting state. When the image mirroring setting state switches from mirrored to non-mirrored, the first mirrored image, the first texture image, and the first face detection signal are mirrored to obtain corresponding second mirrored images, second texture images, and second face detection signals. A special effects image is generated based on the second mirrored image, the second face detection signal, and the second texture image. By using this technique, face detection is performed using a mirrored image of the original image beforehand. When the system's image mirroring setting state switches from mirrored to non-mirrored, the mirrored data is mirrored again to generate a special effects image. This eliminates the need to change the input to the face detector, thus avoiding the situation where a face detector restart causes the special effects to fail, improving the stability and reliability of image special effects processing. Stable and reliable special effects output enhances the user experience. Furthermore, by re-mirroring the already mirrored data, the image texture acquisition and face detection processes are reduced, thereby improving the efficiency of special effects image generation and further enhancing the user experience.

[0081] The image effects processing system based on mirror setting switching provided in this application embodiment can be configured to execute the image effects processing method based on mirror setting switching provided in the above embodiment, and has corresponding functions and beneficial effects.

[0082] Based on the above practical examples, this application also provides an image effects processing device based on mirror setting switching, see reference. Figure 7The image effects processing device based on mirror setting switching includes a processor 31, a memory 32, a communication module 33, an input device 34, and an output device 35. The memory 32, as a computer-readable storage medium, can be configured to store software programs, computer-executable programs, and modules, such as the program instructions / modules corresponding to the image effects processing method based on mirror setting switching described in any embodiment of this application (e.g., the acquisition module, processing module, and generation module in the image effects processing system based on mirror setting switching). The communication module 33 is configured to perform data transmission. The processor 31 executes various functional applications and data processing of the device by running the software programs, instructions, and modules stored in the memory, thereby implementing the aforementioned image effects processing method based on mirror setting switching. The input device 34 can be configured to receive input digital or character information and generate key signal inputs related to user settings and function control of the device. The output device 35 may include a display screen or other display device. The image effects processing device based on mirror setting switching provided above can be configured to execute the image effects processing method based on mirror setting switching provided in the above embodiments, possessing corresponding functions and beneficial effects.

[0083] Based on the above embodiments, this application also provides a storage medium containing computer-executable instructions. When executed by a computer processor, these computer-executable instructions are configured to perform an image effects processing method based on mirror setting switching. The storage medium can be any type of memory device or storage device. Of course, the computer-executable instructions provided in this application are not limited to the image effects processing method based on mirror setting switching described above; they can also execute related operations within the image effects processing method based on mirror setting switching provided in any embodiment of this application.

[0084] Based on the above embodiments, this application also provides a computer program product. The technical solution of this application, in essence or in other words, the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. The computer program product is stored in a storage medium and includes several instructions to cause a computer device, mobile terminal, or processor therein to execute all or part of the steps of the image effect processing method based on mirror setting switching described in the various embodiments of this application.

Claims

1. An image effect processing method based on mirror setting switching, characterized in that, include: A first mirror image is acquired, a first texture image is obtained by performing texture acquisition on the first mirror image, and the first mirror image is input into a face detector to output a first face detection signal. The first mirror image is obtained by mirroring the original image. When the image mirroring setting state of the detection system switches from mirrored state to non-mirrored state, the first mirrored image, the first texture image, and the first face detection signal are mirrored to obtain the corresponding second mirrored image, second texture image, and second face detection signal. The first face detection signal includes first facial key point information, a first yaw angle, and a first roll angle. The second face detection signal includes second facial key point information, a second yaw angle, and a second roll angle. When mirroring the first face detection signal to obtain the corresponding second face detection signal, the first facial key point information is obtained by swapping the facial points in the mirror direction. The first yaw angle and the first roll angle are rotated in the mirror direction to obtain the second yaw angle and the second roll angle. A special effects image is generated based on the second mirror image, the second face detection signal, and the second texture image.

2. The image special effect processing method based on mirror setting switching according to claim 1, characterized in that, The step of swapping the facial landmarks of the first person in a mirror image direction includes: Swap the horizontal coordinates of two face points that are symmetrical in the mirror direction in the first face key point information.

3. The image special effect processing method based on mirror setting switching according to claim 1, characterized in that, Following the image mirroring setting state of the detection system, the following is also included: When the image mirroring setting is in mirror state, a special effects image is generated based on the first mirrored image, the first texture image, and the first face detection signal.

4. The image effect processing method based on mirror setting switching according to claim 1, characterized in that, The process of generating a special effects image based on the second mirror image, the second face detection signal, and the second texture image includes: Based on the second mirror image and the second face detection signal, the second texture image is processed with special effects to output a special effects processed image.

5. An image effects processing system based on mirror setting switching, characterized in that, include: The acquisition module is configured to acquire a first mirror image, perform texture acquisition on the first mirror image to obtain a first texture image, input the first mirror image into a face detector, and output a first face detection signal. The first mirror image is obtained by mirroring the original image. The processing module is configured to detect the image mirroring setting state of the system. When the image mirroring setting state switches from mirrored state to non-mirrored state, it performs mirroring processing on the first mirrored image, the first texture image, and the first face detection signal to obtain the corresponding second mirrored image, the second texture image, and the second face detection signal. The first face detection signal includes first face key point information, a first yaw angle, and a first roll angle. The second face detection signal includes second face key point information, a second yaw angle, and a second roll angle. When performing mirroring processing on the first face detection signal to obtain the corresponding second face detection signal, the first face key point information is obtained by swapping the face points in the mirror direction, and the first yaw angle and the first roll angle are rotated in the mirror direction to obtain the second yaw angle and the second roll angle. The generation module is configured to generate a special effects image based on the second mirror image, the second face detection signal, and the second texture image.

6. An image effects processing device based on mirror setting switching, characterized in that, include: Memory and one or more processors; The memory is configured to store one or more programs; When the one or more programs are executed by the one or more processors, the one or more processors implement the image effects processing method based on mirror settings switching as described in any one of claims 1-4.

7. A storage medium containing computer-executable instructions, characterized in that, The computer-executable instructions, when executed by a computer processor, are configured to perform the image effects processing method based on mirror setting switching as described in any one of claims 1-4.

8. A computer program product, characterized in that, The computer program product contains instructions that, when executed on a computer or processor, cause the computer or processor to perform the image effects processing method based on mirror setting switching as described in any one of claims 1-4.