Special effect processing method and device, electronic equipment and storage medium

By responding to special effect trigger operations in the special effect creation tool, obtaining and displaying special effect preview images, and supporting the selection of special effect elements and dynamic check box updates, the problem of restricting dynamic special effect display of static template images is solved, and flexible and diverse special effect editing is achieved Experience.

CN119496936AActive Publication Date: 2025-02-21BEIJING ZITIAO NETWORK TECH CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202311041770.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-08-17
Publication Date
2025-02-21
Estimated Expiration
2043-08-17

AI Technical Summary

Technical Problem

During the special effects production process, the static template image restricts the dynamic display of the special effects elements, causing the user to be unable to preview the dynamic display effect of the special effects elements during the editing process.

Method used

By responding to the special effect trigger operation, obtaining the pending image and displaying the special effect preview image in the target display area, supporting the selection of special effect elements and the display of selected boxes. The position of the selected box is updated according to the movement of the effect element, making sure the selected box follows the effect element.

Benefits of technology

It realizes dynamic display and editing of special effects elements in the special effects preview scene, improves the flexibility and diversity of the special effects editing process, and ensures that users can preview and edit dynamic special effects elements.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119496936A_ABST
    Figure CN119496936A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a special effect processing method and device, electronic equipment and a storage medium. The method comprises the steps that in response to a special effect triggering operation, a to-be-processed image is acquired, a special effect preview image corresponding to the to-be-processed image is displayed in a target display area, and at least one special effect element is displayed in the special effect preview image; in response to a selection triggering operation for the special effect element, taking the selected special effect element as a target element, and displaying a selected box corresponding to the target element; and when it is detected that the display position of the target element in the target display area is changed or the special effect type corresponding to the target element is a preset type, updating the display position of the selected box in the target display area based on the changed display position of the target element. According to the technical scheme, in the preview scene of the special effect, dynamic display and editing of the special effect elements are supported, the to-be-edited special effect elements can be identified through the selected box, and the selected box can follow the special effect elements.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present disclosure relate to the field of human-computer interaction technology, and in particular, to a special effect processing method, device, electronic device, and storage medium. Background Art

[0002] In the image processing or video production scenario, the application of special effect production tools is very popular among users. Generally, different types of special effects can be produced based on the special effect production tools according to the special effect preview effect, and then the produced special effects can be applied to the image or video.

[0003] In the related art, when special effects are produced based on special effects production work, a static template image is generally used as an input source for special effects production, and the special effects objects included in the static image are all facing the screen. When the user needs to preview the special effects, the effect of the special effects on the template image will be displayed.

[0004] However, there are many types of special effects. In some special effects, special effect elements can move with the movement of the special effect object, and the static display of the special effect elements is often displayed on the static template image, which makes it impossible for users to preview the dynamic display effect of the special effect elements during the special effect editing process, affecting the user's preview experience. Summary of the invention

[0005] The embodiments of the present disclosure provide a special effect processing method, device, electronic device and storage medium to realize dynamic display and editing of special effect elements in a special effect preview scenario, and can mark the special effect elements to be edited in the form of a selection box, and ensure that the selection box can follow the effect of the special effect element to be edited.

[0006] In a first aspect, an embodiment of the present disclosure provides a special effect processing method, the method comprising:

[0007] In response to the special effect triggering operation, an image to be processed is acquired, and a special effect preview image corresponding to the image to be processed is displayed in a target display area, wherein at least one special effect element is displayed in the special effect preview image;

[0008] In response to a selection trigger operation on the special effect element, taking the selected special effect element as a target element, and displaying a selection box corresponding to the target element;

[0009] When it is detected that the display position of the target element in the target display area has changed or the special effect type corresponding to the target element is a preset type, the display position of the selection box in the target display area is updated based on the changed display position of the target element, wherein the shape of the outer contour line of the selection box is a preset shape.

[0010] In a second aspect, the embodiments of the present disclosure further provide a special effects processing device, the device comprising:

[0011] A special effect trigger module, configured to obtain an image to be processed in response to a special effect trigger operation, and display a special effect preview image corresponding to the image to be processed in a target display area, wherein at least one special effect element is displayed in the special effect preview image;

[0012] An element selection module, for responding to a selection trigger operation on the special effect element, taking the selected special effect element as a target element, and displaying a selection box corresponding to the target element;

[0013] A display update module is used to update the display position of the selection box in the target display area based on the changed display position of the target element when it is detected that the display position of the target element in the target display area has changed or the special effect type corresponding to the target element is a preset type, wherein the shape of the outer contour line of the selection box is a preset shape.

[0014] In a third aspect, an embodiment of the present disclosure further provides an electronic device, the electronic device comprising:

[0015] one or more processors;

[0016] a storage device for storing 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 special effects processing method as described in any one of the embodiments of the present disclosure.

[0018] In a fourth aspect, the embodiments of the present disclosure further provide a storage medium comprising computer executable instructions, which, when executed by a computer processor, are used to execute the special effects processing method as described in any one of the embodiments of the present disclosure.

[0019] The technical solution of the disclosed embodiment obtains the image to be processed in response to the special effect trigger operation, and displays the special effect preview image corresponding to the image to be processed in the target display area, wherein at least one special effect element is displayed in the special effect preview image, providing the user with an interactive entrance for processing the special effect element. Furthermore, in response to the selection trigger operation for the special effect element, the selected special effect element is used as the target element, and a check box corresponding to the target element is displayed, supporting the editing of the special effect element, and being able to accurately obtain the special effect element selected by the user and mark it with a check box for the user to view. Finally, when it is detected that the display position of the target element in the target display area changes or the target element is selected, the special effect element is displayed. When the corresponding special effect type is a preset type, the display position of the selection box in the target display area is updated based on the display position of the target element after the change, thereby solving the problem in the related art that for special effect elements that move with the movement of the special effect object, the user cannot preview the dynamic display effects of the special effect elements during the editing process of these special effect elements, and the like. The dynamic display and editing effects of the special effect elements are achieved in the special effect preview scenario, and the special effect elements to be edited can be marked in the form of a selection box, and the selection box can be guaranteed to follow the special effect elements to be edited, thereby improving the flexibility of the special effect editing process and enhancing the diversity of special effect editing methods. BRIEF DESCRIPTION OF THE DRAWINGS

[0020] The above and other features, advantages and aspects of the embodiments of the present disclosure will become more apparent with reference to the following detailed description in conjunction with the accompanying drawings. Throughout the accompanying drawings, the same or similar reference numerals represent the same or similar elements. It should be understood that the drawings are schematic and the originals and elements are not necessarily drawn to scale.

[0021] Figure 1 A flowchart of a special effect processing method provided by an embodiment of the present disclosure;

[0022] Figure 2 A flowchart of a special effect processing method provided by an embodiment of the present disclosure;

[0023] Figure 3 A flowchart of a special effect processing method provided by an embodiment of the present disclosure;

[0024] Figure 4 A schematic diagram showing a target element and a corresponding selection box displayed in a target display area provided by an embodiment of the present disclosure;

[0025] Figure 5 A flowchart of a special effect processing method provided by an embodiment of the present disclosure;

[0026] Figure 6 A structural schematic diagram of a special effect processing device provided by an embodiment of the present disclosure;

[0027] Figure 7 A schematic diagram of the structure of an electronic device provided by an embodiment of the present disclosure. DETAILED DESCRIPTION

[0028] Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although certain embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure can be implemented in various forms and should not be construed as being limited to the embodiments described herein, which are instead provided for a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the present disclosure are only for exemplary purposes and are not intended to limit the scope of protection of the present disclosure.

[0029] It should be understood that the various steps described in the method embodiments of the present disclosure may be performed in different orders and / or in parallel. In addition, the method embodiments may include additional steps and / or omit the steps shown. The scope of the present disclosure is not limited in this respect.

[0030] The term "including" and its variations used herein are open inclusions, i.e., "including but not limited to". The term "based on" means "based at least in part on". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments". The relevant definitions of other terms will be given in the following description.

[0031] It should be noted that the concepts such as "first" and "second" mentioned in the present disclosure are only used to distinguish different devices, modules or units, and are not used to limit the order or interdependence of the functions performed by these devices, modules or units.

[0032] It should be noted that the modifications of "one" and "plurality" mentioned in the present disclosure are illustrative rather than restrictive, and those skilled in the art should understand that unless otherwise clearly indicated in the context, it should be understood as "one or more".

[0033] The names of the messages or information exchanged between multiple devices in the embodiments of the present disclosure are only used for illustrative purposes and are not used to limit the scope of these messages or information.

[0034] It is understandable that before using the technical solutions disclosed in the embodiments of the present disclosure, the types, scope of use, usage scenarios, etc. of the personal information involved in the present disclosure should be informed to the user and the user's authorization should be obtained in an appropriate manner in accordance with relevant laws and regulations.

[0035] For example, in response to receiving an active request from a user, a prompt message is sent to the user to clearly prompt the user that the operation requested to be performed will require obtaining and using the user's personal information. Thus, the user can autonomously choose whether to provide personal information to software or hardware such as an electronic device, application, server, or storage medium that performs the operation of the technical solution of the present disclosure according to the prompt message.

[0036] As an optional but non-limiting implementation, in response to receiving an active request from the user, the prompt information may be sent to the user in the form of a pop-up window, in which the prompt information may be presented in text form. In addition, the pop-up window may also carry a selection control for the user to choose "agree" or "disagree" to provide personal information to the electronic device.

[0037] It is understandable that the above notification and the process of obtaining user authorization are merely illustrative and do not constitute a limitation on the implementation of the present disclosure. Other methods that meet the relevant laws and regulations may also be applied to the implementation of the present disclosure.

[0038] It is understandable that the data involved in this technical solution (including but not limited to the data itself, the acquisition or use of the data) shall comply with the requirements of relevant laws, regulations and relevant provisions.

[0039] Before introducing the present technical solution, an example description of the application scenario can be given. When the input source for special effects production is a dynamic video frame, the special effects added to the special effects object in the dynamic video frame can move with the movement of the special effects object. In this case, the special effects selection box drawn with preset parameters in the related technology is difficult to match with the selected special effects. Moreover, the related technology does not support editing of special effects in the scenario of dynamic video frames, resulting in the user being unable to preview the display effect of the special effects from multiple angles during the special effects editing process, affecting the user's experience.

[0040] The technical solution of the disclosed embodiment can be applied to the scene of determining the check box corresponding to the special effect element displayed in the special effect preview image when the input source of the special effect production tool is a dynamic video frame. Exemplarily, in the process of making special effect props, the special effect display effect of the special effect props can be determined based on the special effect preview image, and for any special effect props added to the special effect object, the check box corresponding to the special effect prop can be drawn based on the predetermined check box drawing parameters, so that the user can edit the corresponding special effect prop based on the check box. However, in the case where the input source of the special effect production is a dynamic video frame, the special effect added to the special effect object in the dynamic video frame can move with the movement of the special effect object, while the check box cannot move with the movement of the special effect. Thus, in the scene of the dynamic video frame, it is impossible or difficult to edit the special effect based on the check box, resulting in the user being unable to preview the display effect of the special effect during the special effect editing process. At this time, based on the technical solution of the embodiment of the present disclosure, when displaying a special effect preview image including at least one special effect element, any special effect element can be selected as the target element, and a check box corresponding to the target element can be displayed. Furthermore, when it is detected that the display position corresponding to the target element has changed, the display position of the check box can be updated according to the updated display position of the target element. Thus, the effect of dynamic display and editing of special effect elements in the special effect preview scene is achieved, and the special effect element to be edited can be marked in the form of a check box, and the check box can be guaranteed to follow the special effect element to be edited.

[0041] Before introducing the present technical solution, it should be noted that the device for executing the special effect processing method provided by the embodiment of the present disclosure can be integrated into the application software that currently supports the special effect element processing function, and the software can be installed in an electronic device. Optionally, the electronic device can be a mobile terminal or a PC, etc. The application software can be a type of software that processes the special effect elements added to the image. The specific application software will not be described here one by one, as long as the special effect element processing can be realized. It can also be a specially developed application program, which is integrated in the software that realizes the special effect element processing, or integrated in the corresponding page. The user can realize the processing of the special effect elements through the page integrated in the PC.

[0042] Figure 1 A flow chart of a special effect processing method provided by an embodiment of the present disclosure is applicable to a situation where, when a special effect element in a special effect preview image moves, a selection box of the special effect element moves along with the movement of the special effect element. The method can be executed by a special effect processing device, which can be implemented in the form of software and / or hardware, and optionally, by an electronic device, which can be a mobile terminal, a PC or a server, etc.

[0043] like Figure 1 As shown, the method of this embodiment may specifically include:

[0044] S110. In response to a special effect triggering operation, an image to be processed is acquired, and a special effect preview image corresponding to the image to be processed is displayed in a target display area, wherein at least one special effect element is displayed in the special effect preview image.

[0045] In this embodiment, in the application software or application program supporting the special effect processing function, a control for triggering the special effect can be developed in advance. Then, when it is detected that the user triggers the control, the trigger operation can be responded to, thereby obtaining the image to be processed.

[0046] Among them, the image to be processed may be an image that needs to be processed with special effects. Optionally, the image to be processed may be an image captured based on the terminal device, or an image pre-stored by the application software from the storage space. The terminal device may refer to an electronic product with an image capture function, such as a camera, a smart phone, and a tablet computer. In actual applications, when it is detected that a user triggers a special effect operation, the terminal device may be oriented to the special effect object to realize the acquisition of the image to be processed; or, when it is detected that a user triggers a special effect operation, multiple images associated with the special effect are determined in a specific database, and then one or more of the images may be determined as the image to be processed according to a pre-set screening rule.

[0047] It should be noted that the technical solution of this embodiment can be executed during the process of the user shooting a video, that is, a special effects video can be generated in real time based on the special effects elements selected by the user and the shot video, or the video uploaded by the user can be used as the original data basis to generate a special effects video based on the solution of this embodiment.

[0048] In practical applications, the image to be processed can usually be obtained only when certain special effect operations are triggered. Optionally, the special effect triggering operation may include at least one of the following: triggering special effect props; audio information triggering special effect wake-up words; the current body movement is consistent with the preset body movement.

[0049] In this embodiment, a control for triggering special effects props can be pre-set. When the user triggers the control, a special effects prop display interface can be popped up in the display interface, and multiple special effects props can be displayed in the display interface. The user can trigger the corresponding special effects props. When it is detected that the user triggers the special effects props corresponding to the image to be processed, it can be explained that the special effects triggering operation is triggered. Another implementation method can be: the user's audio information can be collected in advance, and the collected audio information can be analyzed and processed. Furthermore, the text corresponding to the audio information can be identified. If the recognized text includes a pre-set wake-up word, for example, the wake-up word can be: "Please take a picture of the current image" or "Please turn on the XX special effects function" and other types of words, it means that the image to be processed in the display interface can be obtained. Another implementation method can be: some body movements can be set as special effects triggering actions in advance. When it is detected that the body movements currently made by the special effects object in the field of view of the terminal device are consistent with the pre-set body movements, it can be determined that the special effects operation is triggered. Optionally, the preset body movement can be raising a hand, opening the mouth, or turning the head.

[0050] In this embodiment, when an image to be processed is acquired, a special effect preview image corresponding to the image to be processed can be displayed in the target display area. The target display area can be understood as a special effect preview area for performing special effect processing on the image. The special effect preview image can be understood as an image obtained after adding special effect elements to the image to be processed. At least one special effect element is displayed in the special effect preview image. The special effect element can be a special effect prop added to an image or video so that the image or video presents a corresponding special effect display effect. It should be noted that the special effect element displayed in the special effect preview image can be one or more.

[0051] It should be noted that, in response to the special effect trigger operation, while obtaining the image to be processed, the element identifications of multiple candidate special effect elements can also be displayed in the special effect display area. In actual applications, the user can input a selection trigger operation for the candidate special effect element through an input device. Furthermore, when a selection trigger operation for any candidate special effect element is detected, the candidate special effect element corresponding to the selection trigger operation can be used as a special effect element added to the image to be processed. Furthermore, a special effect preview image corresponding to the image to be processed can be obtained and displayed in the target display area.

[0052] S120 . In response to a selection trigger operation on a special effect element, the selected special effect element is taken as a target element, and a selection box corresponding to the target element is displayed.

[0053] In this embodiment, each special effect element displayed in the special effect preview image can be set to a selectable state in advance. Furthermore, when the special effect element is a selected special effect element, the special effect element is subsequently processed.

[0054] In actual applications, the selection trigger operation for the special effect element can be any operation acting on the special effect element. Optionally, a click operation for the special effect element. Specifically, when it is detected that the user inputs a click operation on the special effect element displayed in the special effect preview image through an input device or a touch point, the special effect element can be used as the selected special effect element. Then, the special effect element can be subsequently processed. Among them, the click operation can be a single click operation or multiple click operations (such as a double-click operation, etc.). In order to facilitate user operation, the selection trigger operation for the special effect element can also be that when it is detected that the user's pause time on the special effect element based on the input device or the touch point reaches a preset time, the special effect element can be used as the selected special effect element. Then, the special effect element can be subsequently processed.

[0055] In a specific implementation, after the special effect preview image is displayed in the target display area, the user can select from the special effect elements displayed in the special effect preview image. When a selection trigger operation for a special effect element input by the user through an input device or a touch point is detected, the selection trigger operation can be responded to, and the special effect element can be used as a selected special effect element and the special effect element can be used as a target element. Furthermore, a check box corresponding to the target element can be determined and displayed in the target display area.

[0056] Among them, the target element can be understood as a special effect element that needs to be processed by special effect editing. The check box can be understood as a bounding box used to characterize that the target element is in a selected state, and the bounding box can surround the boundary of the target element. The shape of the outer contour line of the check box is a preset shape. The preset shape can be any shape, and optionally, the preset shape can be a regular shape. In this embodiment, the shape of the outer contour line of the check box can be any regular shape. Optionally, the regular shape can at least include a symmetrical shape. The symmetrical shape can be understood as a shape including a central axis of symmetry. Exemplarily, the symmetrical shape can be a rectangle, a circle or other symmetrical shapes. It should be noted that the advantage of the outer contour line shape of the check box being a regular shape is that it is convenient for users to perform multi-dimensional editing of special effect elements through the check box, and it simplifies the amount of calculation data in the special effect element editing process, improves the editing efficiency of the special effect element and the special effect display effect of the special effect element.

[0057] In actual applications, when a selection trigger operation for a special effect element is detected, the selection trigger operation can be responded to, the selected special effect element is used as the target element, and a check box corresponding to the target element is displayed. Then, the editing state of the target element can be switched to an editable state, and a corresponding editing trigger operation can be input for the target element. Thus, the target element can be edited according to the editing trigger operation.

[0058] Based on this, after displaying the check box corresponding to the target element, the method further includes: editing the target element in response to an edit trigger operation input for the target element.

[0059] The editing trigger operation may be understood as an editing operation acting on a target element. Optionally, the editing trigger operation may include at least one of a display information adjustment trigger operation, a deletion trigger operation, and a replacement trigger operation.

[0060] Among them, the display information adjustment trigger operation can be understood as a trigger operation for adjusting the display information of the target element in the target display area. The display information adjustment operation may include any operation for adjusting the display information corresponding to the target element. Optionally, the display information adjustment operation includes at least one of a display size adjustment trigger operation, a display position adjustment trigger operation, and a display color adjustment trigger operation. The display size adjustment trigger operation can be understood as a trigger operation for adjusting the display size of the target element in the target display area. Exemplarily, the display size adjustment trigger operation may include a display size increase trigger operation or a display size decrease trigger operation. The display position adjustment trigger operation can be understood as a trigger operation for adjusting the display position of the target element in the target display area. It should be noted that the display size adjustment trigger operation and the display position adjustment trigger operation can be implemented in a variety of ways, and optionally, they can include a drag trigger operation or a parameter change input operation. The display color adjustment trigger operation can be understood as a trigger operation for adjusting the display color of the target element in the target display area.

[0061] The delete trigger operation can be understood as an operation corresponding to deleting the target element from the target display area. The replace trigger operation can be understood as a trigger operation corresponding to replacing the target element in the selected box.

[0062] In actual applications, after determining the target element and displaying the check box corresponding to the target element, an edit trigger operation can be input for the target element. When an edit trigger operation for the target element is detected, a response is made to the detected edit trigger operation. Furthermore, the target element can be edited according to the edit trigger operation, and the edited target element and the check box corresponding to the edited target element are displayed.

[0063] It should be noted that the check box corresponding to the target element can also be used to receive the user's editing operation on the target element, and then the display state of the target element can be updated based on the editing operation. In actual applications, when the check box corresponding to the target element is displayed, the element editing operation on the target element can be input for the check box. Then, after detecting the element editing operation on the check box, the element editing operation can be responded to, and the target element can be updated based on the element editing operation.

[0064] In actual applications, the check box corresponding to the target element can be used to receive an element edit trigger operation for the target element. Therefore, after the check box corresponding to the target element is displayed in the target display area, the element edit trigger operation can be input into the displayed check box. Furthermore, the target element can be edited based on the input element edit trigger operation.

[0065] Based on this, after displaying the check box corresponding to the target element, the method further includes: in response to a zoom trigger operation input to the check box, zooming the check box and the target element corresponding to the check box.

[0066] In this embodiment, when the check box corresponding to the target element is displayed in the target display area, the check box can be in an editable state, and then, when an edit trigger operation is received for the check box, the check box and the target element corresponding to the check box can be edited.

[0067] In this embodiment, there are multiple ways to generate the zoom trigger operation, such as determining based on a drag trigger operation or determining based on an input parameter, etc. Optionally, in response to the zoom trigger operation input for the selected box, zooming the selected box and the target element corresponding to the selected box includes: in response to the drag trigger operation input for the selected box, zooming the selected box and the target element corresponding to the selected box.

[0068] The drag trigger operation for the selected box input may be an operation corresponding to the movement of any point in the selected box as a starting point in the target display area based on an input device (such as a mouse, etc.). Optionally, the drag trigger operation may include operations such as stretching, compressing, or diagonally stretching or compressing the border of the selected box.

[0069] In actual applications, after the check box corresponding to the target element is displayed in the target display area, any point in the check box can be used as a starting point to control the point to move in the target display area through an input device to achieve a drag trigger operation on the check box. Furthermore, when it is detected that the pause time of the point at any position in the target display area reaches a preset time length, the position of the pause point at this time can be used as the end point, and it is determined that the input of the drag trigger operation is completed. Furthermore, the check box and the target element corresponding to the check box can be scaled according to the input drag trigger operation.

[0070] Optionally, in response to a zoom trigger operation input for the selected box, the selected box and the target element corresponding to the selected box are zoomed, including: responding to a zoom editing parameter input for the selected box, and zooming the selected box and the target element corresponding to the selected box based on the zoom editing parameter.

[0071] Among them, the zoom editing parameters can be understood as the parameters that the selected box and the target element corresponding to the selected box should rely on during the zooming process, and can also be understood as the parameters used to determine the final effect presented by the selected box and the target element corresponding to the selected box.

[0072] In actual applications, an element editing control can be pre-set. And, when the target element is determined, at least one display attribute parameter corresponding to the check box corresponding to the target element can be obtained. When a trigger operation for the element editing control is detected, the parameter editing page can be displayed based on the display interface. Furthermore, according to the determined special effect element editing requirements, the corresponding scaling editing parameters can be entered in the editing box corresponding to at least one display attribute parameter displayed in the parameter editing page. Thus, the selected box and the target element corresponding to the selected box can be scaled based on the input scaling editing parameters. The advantage of this setting is that the special effect element can be edited based on the check box, thereby simplifying the special effect editing method and improving the special effect editing efficiency.

[0073] Exemplarily, it is assumed that the outer contour shape of the selected box corresponding to the target element is a rectangle. When a zoom trigger operation is input to the selected box, any point on the outer contour of the rectangular box can be determined as the zoom trigger starting point through an input device (such as a mouse, etc.) or a touch point, and the axis of symmetry corresponding to the zoom trigger starting point in the rectangular box is determined, and the direction corresponding to the axis of symmetry can be used as the zoom direction of the selected box. Furthermore, the selected box can be scaled in the scaling direction. For example, if the zoom trigger starting point is located on the wide border line of the rectangular box, the rectangular box can be scaled in the direction of the long border line according to the zoom trigger operation.

[0074] It should be noted that the advantage of the symmetrical shape of the outer contour of the selection box is that it is convenient for users to perform multi-dimensional editing processing on the selection box, reducing the amount of data generated during the editing process, thereby improving the editing response efficiency and editing display effect.

[0075] S130. When it is detected that the display position of the target element in the target display area changes or the special effect type corresponding to the target element is a preset type, update the display position of the selection box in the target display area based on the changed display position of the target element.

[0076] The display position of the target element in the target display area can be understood as the corresponding position of the target element when it is displayed in the target display area. Correspondingly, the display position of the check box in the target display area can be understood as the corresponding position of the check box when it is displayed in the target display area.

[0077] Among them, the preset type can be understood as a predetermined special effect type. The preset type may include multiple special effect types. Optionally, the preset type may include at least a follow-up special effect. The follow-up special effect can be understood as a type of special effect prop that moves with the movement of the special effect object. The follow-up special effect may include a special effect element that moves with the movement of the special effect object. The special effect object may be understood as an object to which special effect elements are added in the image to be processed. Optionally, the special effect object may include the user's facial features, the user's limbs, pets, plants or buildings, etc. Exemplarily, the follow-up special effects may include facial effects, AR tracking effects or other follow-up special effect elements, etc.

[0078] In this embodiment, the determination method of whether the display position of the target element in the target display area has changed may include multiple methods. Optionally, determining whether the display position of the target element in the target display area has changed may be that, for each frame of the special effect preview image, the display coordinates of the display position of the target element in the current frame of the special effect preview image may be determined, and then, the display coordinates of the display position of the target element in the previous frame of the special effect preview image may be determined. Further, the display coordinates of the two display positions may be compared, and when it is detected that the display coordinates of the two display positions are inconsistent, it may be determined that the display position of the target element in the target display area has changed. Alternatively, since the special effect image processing process involved in this embodiment is displayed in the target display area in the form of a camera stream, that is, the acquired image to be processed may be any frame of the acquired video, and the special effect object in each frame of the image to be processed may move or change the body movement, etc. Therefore, when adding a special effect element to the image to be processed, when determining the display position of the target element in the target display area, the special effect type of the target element may be determined. Furthermore, when the special effect type of the target element is a preset special effect type, it can be determined that the display position of the target element in the target display area has changed. Alternatively, it can be determined that the display position of the target element in the target display area has changed by other means.

[0079] In actual applications, after determining the target element displayed in the special effect preview image, the element attribute parameters corresponding to the target element can be obtained. Then, the special effect type corresponding to the target element can be determined based on the obtained element attribute parameters. Furthermore, when it is determined that the special effect type corresponding to the target element is a preset type, it can be determined that the display position of the target element in the target display area has changed.

[0080] It should be noted that, since the special effect preview image displayed in the target display area may change dynamically as the special effect object moves, the target element displayed in the special effect preview image may also change. Based on this, before determining that the display position of the target element in the target display area has changed, the special effect preview image may be detected to determine the target element in the special effect preview image. Furthermore, it may be determined whether the display position of the target element in the target display area has changed according to the special effect type corresponding to the target element.

[0081] In practical applications, after determining the target element and displaying the check box corresponding to the target element in the target display area, the display position of the target element in the target display area can be detected to determine whether the display position of the target element in the target display area has changed. Alternatively, the special effect type corresponding to the target element can also be determined to determine whether the special effect type corresponding to the target element is a preset type. Further, in the case where it is detected that the display position of the target element in the target display area has changed, the display position of the target element after the change can be determined. Alternatively, in the case where it is detected that the special effect type corresponding to the target element is a preset type, the display position of the target element after the change can be determined. Furthermore, the display position of the check box in the target display area can be updated according to the display position of the target element after the change. Thereby, the check box can always move with the target element.

[0082] The technical solution of the disclosed embodiment obtains the image to be processed in response to the special effect trigger operation, and displays the special effect preview image corresponding to the image to be processed in the target display area, wherein at least one special effect element is displayed in the special effect preview image, providing the user with an interactive entrance for processing the special effect element. Furthermore, in response to the selection trigger operation for the special effect element, the selected special effect element is used as the target element, and a check box corresponding to the target element is displayed, supporting the editing of the special effect element, and being able to accurately obtain the special effect element selected by the user and mark it with a check box for the user to view. Finally, when it is detected that the display position of the target element in the target display area changes or the target element is selected, the special effect element is displayed. When the corresponding special effect type is a preset type, the display position of the selection box in the target display area is updated based on the display position of the target element after the change, thereby solving the problem in the related art that for special effect elements that move with the movement of the special effect object, the user cannot preview the dynamic display effects of the special effect elements during the editing process of these special effect elements, and the like. The dynamic display and editing effects of the special effect elements are achieved in the special effect preview scenario, and the special effect elements to be edited can be marked in the form of a selection box, and the selection box can be guaranteed to follow the special effect elements to be edited, thereby improving the flexibility of the special effect editing process and enhancing the diversity of special effect editing methods.

[0083] Figure 2 A flowchart of a special effect processing method provided by an embodiment of the present disclosure. The technical solution of this embodiment is based on the above embodiment. When the special effect type of the target element is detected to be a preset type, it is determined that the display position of the target element in the target display area has changed. For specific implementation methods, please refer to the description of this embodiment. Among them, the technical features that are the same or similar to the above embodiments are not repeated here.

[0084] like Figure 2As shown, the method of this embodiment may specifically include:

[0085] S210. In response to a special effect triggering operation, obtain an image to be processed, and display a special effect preview image corresponding to the image to be processed in a target display area, wherein at least one special effect element is displayed in the special effect preview image.

[0086] S220: In response to a selection trigger operation on a special effect element, the selected special effect element is used as a target element, and a selection box corresponding to the target element is displayed.

[0087] S230: When a special effect frame refresh signal is detected, the special effect preview image is detected to determine a target element in the special effect preview image.

[0088] Among them, the special effect frame refresh signal can be understood as a signal for refreshing the map frame corresponding to the special effect element displayed in the image. It should be noted that the special effect frame refresh signal is for the map frame corresponding to the special effect element displayed in the image. However, the image frame refresh signal can be for the entire image frame. Exemplarily, assuming that the special effect elements displayed in the special effect preview image include special effect element 1, special effect element 2 and special effect element 3, when the special effect frame refresh signal is detected, the map frames corresponding to special effect element 1, special effect element 2 and special effect element 3 can be refreshed. When the image frame refresh signal is detected, the special effect preview image frame can be refreshed. It should also be noted that the special effect refresh rate corresponding to the special effect frame refresh signal can be less than or equal to the image refresh rate corresponding to the image frame refresh signal. The advantage of this setting is that when the special effect element is displayed in the image, it can be ensured that the special effect element always moves with the movement of the special effect object, thereby improving the special effect image display effect.

[0089] In this embodiment, the target element in the special effect preview image can be determined in a variety of ways. Optionally, the target element determination method can include check box detection or element identification detection. In practical applications, when the target element is determined, the check box corresponding to the target element will be displayed in the target display area. Therefore, when the special effect frame refresh signal is detected, the previous frame of the special effect preview image can be detected to detect each special effect element displayed in the special effect preview image. Further, when it is detected that the check box corresponding to any special effect element exists in the special effect preview image, the special effect element can be determined as the target element and the target element is determined to exist in the special effect preview image. Alternatively, for the current frame of the special effect preview image, in response to the selection trigger operation for the special effect element displayed in the special effect preview image, the selected special effect element is used as the target element, and the flag corresponding to the target element is set in the image attribute corresponding to the special effect preview image. Further, when the special effect frame refresh signal is detected, the image attribute corresponding to the special effect preview image can be obtained, and the acquired image attribute can be detected to determine whether the image attribute includes the flag corresponding to the target element. Furthermore, when the image attribute includes a flag bit of the target element, it can be determined that the target element exists in the special effect preview image. Alternatively, the target element in the special effect preview image can be determined by other methods, which are not specifically limited in the embodiments of the present disclosure.

[0090] In practical applications, the special effect frame refresh signal can be detected regularly or periodically. Further, when the special effect frame refresh signal is detected, the special effect preview image can be detected to determine whether there is a selected special effect element in the special effect preview image.

[0091] S240: When there is a target element in the special effect preview image, a display position of the target element in the target display area is detected, or a special effect type corresponding to the target element is detected based on a preset type.

[0092] In this embodiment, when it is determined that there is a selected special effect element in the special effect preview image, that is, when there is a target element in the special effect preview image, the display position of the target element in the target display area can be checked to determine whether the display position of the target element in the target display area has changed. Alternatively, when it is determined that there is a target element in the special effect preview image, the special effect type corresponding to the target element can be determined. Furthermore, a preset type can be obtained, and the preset type can be compared with the determined special effect type to determine whether the special effect type corresponding to the target element is the preset type. Thus, when it is detected that the special effect type corresponding to the target element is the preset type, it can be determined that the display position of the target element in the target display area has changed. The advantage of such a setting is that the effect of refreshing the special effect element selection box when the special effect frame is refreshed is achieved, and then, the effect of ensuring that the selection box can change with the change of the special effect element is achieved.

[0093] S250. When it is detected that the display position of the target element in the target display area changes or the special effect type corresponding to the target element is a preset type, update the display position of the selection box in the target display area based on the changed display position of the target element.

[0094] It should be noted that, for the target element displayed in the special effect preview image, the target element can be updated not only according to the special effect change mode corresponding to the special effect element, but also according to the user's editing operation information on the target element. Therefore, before updating the display position of the check box in the target display area based on the display position after the target element changes, it is also possible to detect whether the target element is being edited by the user. Furthermore, the basis for updating the display position of the check box in the target display area can be determined based on the detection result.

[0095] In actual applications, users can edit special effects through input devices or touch points. When the user moves or zooms / rotates with two fingers, the interface will be called to update the special effect parameters of the target element, thereby changing the size, position and rotation angle of the target element. However, when the image to be processed is a dynamic video frame, the user's operation will also affect these parameters. Considering that the user's operation should be the main factor in the special effect editing situation. Therefore, it is possible to determine whether the target element is currently in the user operation state. Then, after receiving the special effect frame refresh signal, it can be determined whether to update the parameter changes caused by the algorithm according to the operation state of the target element. If so, the parameter changes caused by the algorithm are not updated, but the interface is directly called to update the changes caused by the user operation, thereby achieving the effect that the user operation priority is higher than the special effect element algorithm priority.

[0096] Based on this, before updating the display position of the selection box in the target display area based on the display position after the target element changes, it also includes: determining the operation state of the target element; when the target element is not operated by the user, obtaining the display position of the target element after the change based on the preset change method.

[0097] Among them, the operation state can be understood as the trigger operation of the special effect element by the user. Optionally, the operation state includes a state being operated by the user and a state not being operated by the user. The state being operated by the user can be understood as the state that is currently being triggered to edit by the user, and can also be understood as the state corresponding to the user currently inputting the editing trigger operation to the special effect element through the input device. The state not being operated by the user can be understood as the state that is not currently triggered to edit by the user. The preset change mode can be understood as the preset special effect change mode corresponding to the special effect element. The preset change mode is associated with the special effect type corresponding to the target element. In practical applications, when determining special effect elements of different special effect types, the special effect change mode corresponding to the special effect element of each special effect type can be predetermined. Furthermore, the preset change mode corresponding to the special effect element of each special effect type can be obtained, and the preset change mode is associated with the special effect type to determine the mapping between the special effect type and the preset change mode.

[0098] In this embodiment, there may be multiple ways to determine the operation state of the target element. Optionally, an element attribute parameter corresponding to the target element may be obtained, and the element attribute parameter may include an operation state attribute parameter. Furthermore, the operation state of the target element may be determined based on the obtained operation state attribute parameter. Alternatively, a user gesture detection may be performed on the target element to determine whether the target element is in a user gesture editing state. Furthermore, the operation state of the target element may be determined based on the judgment result. Alternatively, the operation state of the target element may also be determined by other means, which is not specifically limited in the embodiments of the present disclosure.

[0099] In actual applications, when it is determined that the display position of the target element in the target display area has changed, the operation state of the target element can be determined. Further, when it is determined that the target element is in a state where it is not operated by the user, the preset change mode corresponding to the target element can be obtained according to the special effect type of the target element. Then, the target element can be processed according to the preset change mode to determine the display position of the target element after the change. Then, the display position of the target element after the change can be obtained, and the display position of the selection box in the target display area can be updated based on the display position of the target element after the change. The advantage of such a setting is that the effect that the selection box can change based on the change of the special effect element is achieved, and the update flexibility of the selection box is improved.

[0100] In actual applications, in order to improve user experience and meet the user's editing needs for special effect elements, when it is determined that the target element is in the state of being operated by the user, the user's editing operation on the target element can be used as the priority of display position change. Furthermore, the display position of the target element after the change can be determined according to the user's editing operation on the target element.

[0101] Optionally, after determining the operation state of the target element, the method further includes: when the target element is in a state of being operated by the user, acquiring a changed display position of the target element based on user operation information.

[0102] The user operation information can be understood as the information obtained after the user performs an editing operation on the target element. In actual applications, after determining the target element in the special effect preview image and displaying the corresponding check box in the target display area, the user can input an editing trigger operation to the check box through an input device or a touch point. Furthermore, the user operation information can be generated according to the received editing trigger operation.

[0103] In actual applications, when it is determined that the target element is being operated by the user, the edit trigger operation of the selected box of the target element can be detected. Then, the detected edit trigger operation can be responded to and user operation information can be generated. Thus, the display position of the target element after the change can be determined according to the user operation information. The advantage of this setting is that it achieves the effect of user operation priority being higher than the special effect change algorithm priority, ensures that the special effect editing is mainly based on user operation, and improves the user's editing experience of special effect elements.

[0104] The technical solution of the disclosed embodiment obtains an image to be processed in response to a special effect trigger operation, and displays a special effect preview image corresponding to the image to be processed in a target display area, wherein at least one special effect element is displayed in the special effect preview image. Then, in response to a selection trigger operation for the special effect element, the selected special effect element is used as a target element, and a check box corresponding to the target element is displayed. Further, when a special effect refresh frame signal is detected, the special effect preview image is detected to determine the target element in the special effect preview image. When the target element exists in the special effect preview image, the display position of the target element in the target display area is detected, or the special effect type corresponding to the target element is detected based on a preset type. Finally, when it is detected that the display position of the target element in the target display area changes or the special effect type corresponding to the target element is a preset type, the display position of the check box in the target display area is updated based on the changed display position of the target element, thereby achieving an effect of determining whether the display position of the target element changes based on the special effect type of the target element, improving the detection efficiency of the change of the display position of the target element, and further improving the updating efficiency of the display position of the check box.

[0105] Figure 3 A flowchart of a special effect processing method provided by an embodiment of the present disclosure. The technical solution of this embodiment is based on the above embodiment, and draws and displays a check box corresponding to the target element based on the screen display coordinates and screen rotation angle corresponding to at least one element key point corresponding to the target element. For specific implementation methods, please refer to the description of this embodiment. Among them, the technical features that are the same or similar to the above embodiments are not repeated here.

[0106] like Figure 3 As shown, the method of this embodiment may specifically include:

[0107] S310. In response to a special effect triggering operation, an image to be processed is acquired, and a special effect preview image corresponding to the image to be processed is displayed in a target display area, wherein at least one special effect element is displayed in the special effect preview image.

[0108] S320: In response to a selection trigger operation on a special effect element, the selected special effect element is taken as a target element, at least one element key point corresponding to the target element is determined, and the screen display coordinates corresponding to the element key point are determined.

[0109] Among them, the element key point can be understood as the key point corresponding to the special effect element in the model space, and the key point can be used to construct the special effect model of the special effect element in the model space. It should be noted that the element key point can be located on the outer contour of the target element, or outside the outer contour of the target element, or inside the outer contour of the target element, etc. The position of the element key point is associated with the shape and size of the determined selection box. It should also be noted that the element key point corresponding to the target element can be used to construct the selection box corresponding to the target element. Therefore, the number of element key points corresponding to the target element can correspond to the outer contour shape of the selection box corresponding to the target element. The number of element key points corresponding to the target element can be one or more. Optionally, the number of element key points can be 4. Exemplarily, when the shape of the selection box corresponding to the target element is a rectangle, the number of element key points corresponding to the target element can be 4. The screen display coordinates can be understood as the coordinate information of the element key point in the screen space, and can also be understood as the position information of the element key point displayed on the screen. The screen display coordinates can be

[0110] In practical applications, when the target element is determined, the element original data corresponding to the target element can be obtained. Then, at least one element key point corresponding to the target element can be determined according to the element attribute parameters of the target element and the predetermined selection box shape. Furthermore, the three-dimensional coordinates of the key points of the element in the model space can be obtained from the obtained element original data, and the three-dimensional coordinates of the key points can be converted into screen display coordinates according to the coordinate conversion relationship between the model space and the screen space. Thus, the mapping of the element key points from the three-dimensional model space to the two-dimensional screen space can be completed.

[0111] S330: Determine the screen rotation angle corresponding to the target element.

[0112] Among them, the screen rotation angle can be understood as the rotation angle of the target element in the three-dimensional model space. In this embodiment, the screen rotation angle can at least include the roll angle (i.e., the Roll angle) in the Euler angle. Those skilled in the art can understand that the Euler angle is a group of three independent angle parameters used to determine the position of a fixed-point rotating rigid body, which consists of a pitch angle, a yaw angle, and a roll angle. The roll angle included in the screen rotation angle can be understood as the angle obtained by rotating the target element counterclockwise or clockwise in a plane perpendicular to the screen with the midline of the plane as the axis.

[0113] In actual applications, the display position of the target element in the target display area may be dynamically changed. Therefore, during the display position change process of the target element, for each display position change moment, the screen rotation angle corresponding to the current display position change moment may be determined based on the original element data of the target element. Thus, the screen rotation angle corresponding to the target element may be obtained.

[0114] S340: Draw a check box corresponding to the target element based on the screen display coordinates and the screen rotation angle, and display the check box.

[0115] In this embodiment, after the screen display coordinates and the screen rotation angle corresponding to the target element are obtained, the selection box corresponding to the target element can be determined and drawn based on the screen display coordinates and the screen rotation angle.

[0116] In actual applications, after determining the screen display coordinates and screen rotation angle of the element key point corresponding to the target element, multiple candidate bounding boxes can be determined based on the determined screen display coordinates, and each candidate bounding box can correspond to a candidate rotation angle. Then, a candidate bounding box whose candidate rotation angle matches the screen rotation angle can be selected from the multiple candidate bounding boxes according to the determined screen rotation angle. Then, a selected box corresponding to the target element can be determined according to the selected candidate bounding box.

[0117] It should be noted that, since the selected box corresponding to the target element may be a border surrounding the target element, when determining the selected box corresponding to the target element, the minimum enclosing box corresponding to the target element may be determined first. Then, the selected box corresponding to the target element may be determined based on the minimum enclosing box.

[0118] Optionally, drawing a check box corresponding to the target element based on the screen display coordinates and the screen rotation angle includes: drawing a minimum enclosing box corresponding to the target element based on the screen display coordinates and the screen rotation angle, and determining the check box corresponding to the target element based on the minimum enclosing box.

[0119] The minimum bounding box can be understood as a frame with the smallest size that can enclose the target element, or can be understood as a bounding box that is closest to the boundary of the target element.

[0120] In practical applications, when the screen display coordinates corresponding to the target element are obtained, the screen display coordinates corresponding to each element key point include a horizontal coordinate and a vertical coordinate. Then, the maximum horizontal coordinate, the minimum horizontal coordinate, the maximum vertical coordinate and the minimum vertical coordinate can be determined from the screen display coordinates corresponding to at least one element key point that has been determined. Further, a straight line can be drawn from the element key point including the maximum horizontal coordinate to the horizontal axis in the screen space coordinate system; a straight line can be drawn from the element key point including the minimum horizontal coordinate to the horizontal axis in the screen space coordinate system; a straight line can be drawn from the element key point including the maximum vertical coordinate to the vertical axis in the screen space system; a straight line can be drawn from the element key point including the minimum vertical coordinate to the vertical axis in the screen space system. Since the rotation direction of the straight line drawn through the element key point is not determined, multiple candidate frames with different rotation angles can be obtained. Then, the screen rotation angle corresponding to the target element can be obtained, and a candidate frame matching the screen rotation angle can be determined from multiple candidate frames according to the screen rotation angle, and the determined candidate frame can be used as the minimum enclosing frame corresponding to the target element. Then, a selected frame corresponding to the target element can be determined based on the minimum enclosing frame. The advantage of this setting is that no matter what screen rotation angle the target element is at, the selection box is guaranteed to always surround the target element. Figure 4 This is a schematic diagram showing the target element and the corresponding check box displayed in the target display area. Figure 4 As shown, the user's head can be used as the object of the special effect, the star glasses special effect can be used as the target element, and the border surrounding the star glasses special effect is the selection box. When the user's head moves to the side facing the screen, the star glasses special effect will also move with the user's face. At this time, the screen display coordinates and screen rotation angle corresponding to the star glasses special effect can be determined. Furthermore, according to the determined screen display coordinates and screen rotation angle, the selection box corresponding to the moved star glasses special effect can be drawn. Thereby, the effect of ensuring that the corresponding selection box always surrounds the target element when the target element is not facing the screen directly can be achieved.

[0121] In actual applications, there may be multiple ways to determine the check box corresponding to the target element, and each of the ways will be described below.

[0122] The first method may be: using the minimum bounding box as the selected box corresponding to the target element.

[0123] In practical applications, after determining the minimum bounding box corresponding to the target element, the minimum bounding box can be directly used as the selected box corresponding to the target element.

[0124] The second method may be: scaling the minimum bounding box according to a preset ratio, and using the scaled minimum bounding box as a selection box corresponding to the target element.

[0125] The preset ratio can be understood as a preset border scaling ratio. The preset ratio can be any value. The preset ratio can be the ratio between the border size of the minimum bounding box and the border size of the selected box. For example, if the preset ratio is 1:2, the border size of the minimum bounding box can be doubled, and the enlarged minimum bounding box can be used as the selected box corresponding to the target element.

[0126] In this embodiment, the determination method of the preset ratio may include multiple methods, such as database retrieval or real-time editing. Optionally, the preset ratio may be associated with the special effect type of the special effect element. For special effect elements of different special effect types, different preset ratios may be determined, and a mapping between the special effect type and the preset ratio may be established and stored in a relevant database. Further, after obtaining the target element, the corresponding preset ratio may be retrieved from the relevant database according to the special effect type of the target element, so as to scale the minimum bounding box based on the retrieved preset ratio. Alternatively, a scaling ratio setting control may be pre-set, and then, when a trigger operation for the control is detected, a ratio setting page may be displayed in the target display area, and the ratio setting page may include a ratio setting item. Further, in response to an edit trigger operation for the ratio setting item, a preset ratio is obtained. Then, the minimum bounding box may be scaled according to the preset ratio that has been obtained. Alternatively, the preset ratio for scaling the minimum bounding box may also be obtained in other ways, and the embodiment of the present disclosure does not specifically limit this.

[0127] In practical applications, after obtaining the minimum bounding box corresponding to the target element, the preset ratio corresponding to the target element can be determined. Then, the minimum bounding box can be scaled according to the determined preset ratio, and the scaled minimum bounding box can be used as the selected box corresponding to the target element.

[0128] The third method may be: determining an inscribed circle or a circumscribed circle of a minimum bounding box as a selection box corresponding to the target element.

[0129] The inscribed circle may be a circle that is tangent to each border of the minimum bounding box, and the circumscribed circle may be a circle that intersects each vertex of the minimum bounding box.

[0130] In practical applications, in order to facilitate users to edit the target element based on the check box, the shape of the check box corresponding to the target element can be determined as a circle. In the case where the shape of the check box is a circle, after obtaining the minimum bounding box corresponding to the target element, the inscribed circle or circumscribed circle of the minimum bounding box can be determined. Then, the determined inscribed circle or circumscribed circle can be used as the check box corresponding to the target element.

[0131] A fourth method may be: using the target pixel point in the minimum bounding box as the center point of the border, and using the preset distance as the radius of the border; and determining a selected box corresponding to the target element based on the center point of the border and the radius of the border.

[0132] The target pixel point can be understood as any pixel point located inside the minimum bounding box. For example, the target pixel point can be the center point of the minimum bounding box. The preset distance can be a preset frame construction distance. The preset distance can be any value.

[0133] In practical applications, after obtaining the minimum bounding box corresponding to the target element, a pixel point can be randomly selected from the minimum bounding box as the target pixel point, and the target pixel point can be used as the center point of the frame. After that, a preset distance can be obtained and used as the radius of the frame. Then, a bounding box can be drawn with the center point of the frame as the center and the radius of the frame as the radius, and the drawn bounding box can be used as the selected box corresponding to the target element.

[0134] It should be noted that the advantages of using multiple methods to determine the selected box are: enhancing the diversity of the selected box and improving the flexibility of determining the selected box.

[0135] S350: When it is detected that the display position of the target element in the target display area has changed or the special effect type corresponding to the target element is a preset type, update the display position of the selection box in the target display area based on the changed display position of the target element.

[0136] The technical solution of the disclosed embodiment obtains an image to be processed in response to a special effect trigger operation, and displays a special effect preview image corresponding to the image to be processed in a target display area, wherein at least one special effect element is displayed in the special effect preview image. Then, in response to a selection trigger operation for the special effect element, the selected special effect element is taken as the target element, at least one element key point corresponding to the target element is determined, and the screen display coordinates corresponding to the element key point are determined, and the screen rotation angle corresponding to the target element is determined. Further, a check box corresponding to the target element is drawn based on the screen display coordinates and the screen rotation angle, and the check box is displayed. Finally, when it is detected that the display position of the target element in the target display area changes or the special effect type corresponding to the target element is a preset type, the display position of the check box in the target display area is updated based on the changed display position of the target element, thereby achieving the effect of drawing a check box that can surround the special effect element in a two-dimensional screen space, and further, ensuring that the check box always changes with the change of the special effect element.

[0137] Figure 5The flowchart of a special effect processing method provided by the embodiment of the present disclosure is shown in FIG. The embodiment of the present disclosure is an optional embodiment of the above-mentioned embodiments. Figure 5 As shown, the method of the embodiment of the present disclosure may include the following steps:

[0138] 1. For the special effects engine layer, when it is determined that the special effects frame refresh time has been reached, a special effects frame refresh signal can be sent based on the script;

[0139] 2. For the special effects editing layer, the frame refresh signal is detected periodically or regularly. When a special effects frame refresh signal is detected, the detected special effects frame refresh signal can be modified into a signal detectable by the client and the modified signal can be forwarded to the client;

[0140] 3. For the client, when receiving the special effect frame refresh signal, the special effect preview image is detected to determine whether the special effect preview image includes the selected special effect element, that is, the target element. If so, step 4 is executed;

[0141] 4. Determine whether the special effect type of the target element is a follow-up special effect. If so, proceed to step 5;

[0142] 5. Determine whether the target element is in the state of being operated by the user. If so, execute step 6; if not, execute step 7;

[0143] 6. Prioritize the user's operation information on the target element, and obtain the display position of the target element after the change based on the operation information;

[0144] 7. Refresh the special effect data of the current editing layer according to the preset change mode corresponding to the target element. Then, the display position of the target element after the change can be obtained;

[0145] 8. For the special effect editing layer, the original data corresponding to the target element is obtained from the special effect engine layer. The original data may include the 3D world coordinates, size and Euler angle data of at least one element key point corresponding to the target element;

[0146] 9. Based on the mapping relationship between the world coordinate system and the screen coordinate system, the three-dimensional world coordinates of the key points of the element are converted into screen display coordinates;

[0147] 10. Calculate the minimum bounding box based on the screen display coordinates and the roll angle in the Euler angle data;

[0148] 11. For the client, a selection box corresponding to the target element can be drawn based on the minimum bounding box.

[0149] It should be noted that the special effects engine layer, special effects editing layer and client can be different application layers all deployed in the same terminal device; or they can be application layers deployed in different terminal devices respectively, and each terminal device is interconnected.

[0150] The technical solution of the disclosed embodiment obtains the image to be processed in response to the special effect trigger operation, and displays the special effect preview image corresponding to the image to be processed in the target display area, wherein at least one special effect element is displayed in the special effect preview image, providing the user with an interactive entrance for processing the special effect element. Furthermore, in response to the selection trigger operation for the special effect element, the selected special effect element is used as the target element, and a check box corresponding to the target element is displayed, supporting the editing of the special effect element, and being able to accurately obtain the special effect element selected by the user and mark it with a check box for the user to view. Finally, when it is detected that the display position of the target element in the target display area changes or the target element is selected, the special effect element is displayed. When the corresponding special effect type is a preset type, the display position of the selection box in the target display area is updated based on the display position of the target element after the change, thereby solving the problem in the related art that for special effect elements that move with the movement of the special effect object, the user cannot preview the dynamic display effects of the special effect elements during the editing process of these special effect elements, and the like. The dynamic display and editing effects of the special effect elements are achieved in the special effect preview scenario, and the special effect elements to be edited can be marked in the form of a selection box, and the selection box can be guaranteed to follow the special effect elements to be edited, thereby improving the flexibility of the special effect editing process and enhancing the diversity of special effect editing methods.

[0151] Figure 6 A structural diagram of a special effect processing device provided by an embodiment of the present disclosure is shown in FIG. Figure 6 As shown, the device includes: a special effect triggering module 410, an element selecting module 420 and a display updating module 430.

[0152] Among them, the special effect trigger module 410 is used to respond to the special effect trigger operation, obtain the image to be processed, and display the special effect preview image corresponding to the image to be processed in the target display area, wherein at least one special effect element is displayed in the special effect preview image; the element selection module 420 is used to respond to the selection trigger operation for the special effect element, take the selected special effect element as the target element, and display the selection box corresponding to the target element; the display update module 430 is used to update the display position of the selection box in the target display area based on the changed display position of the target element when it is detected that the display position of the target element in the target display area changes or the special effect type corresponding to the target element is a preset type, wherein the shape of the outer contour line of the selection box is a preset shape.

[0153] On the basis of the above technical solutions, the device further includes: an image detection module and a special effect type determination module.

[0154] An image detection module, for detecting the special effect preview image to determine the target element in the special effect preview image when a special effect refresh frame signal is detected before it is determined that the display position of the target element in the target display area has changed after the special effect type corresponding to the target element is detected to be a preset type;

[0155] The special effect type determination module is used to detect the display position of the target element in the target display area when the target element exists in the special effect preview image, or to detect the special effect type corresponding to the target element based on a preset type.

[0156] On the basis of the above technical solutions, the device further includes: an editing trigger operation response module.

[0157] An editing trigger operation response module is used to edit the target element in response to an editing trigger operation input for the target element after a check box corresponding to the target element is displayed, wherein the editing trigger operation includes at least one of a display information adjustment trigger operation, a deletion trigger operation, and a replacement trigger operation, and the display information adjustment operation includes at least one of a display size adjustment trigger operation, a display position adjustment trigger operation, and a display color adjustment trigger operation.

[0158] On the basis of the above technical solutions, the device further includes: an operation state determination module and a display position first acquisition module.

[0159] An operation state determination module, used to determine the operation state of the target element, wherein the operation state includes a state of being operated by a user and a state of not being operated by a user;

[0160] The first display position acquisition module is used to obtain the display position of the target element after the target element is changed based on a preset change method when the target element is in the state of not being operated by the user, wherein the preset change method is associated with the special effect type corresponding to the target element.

[0161] On the basis of the above technical solutions, the device further includes: a second display position acquisition module.

[0162] The second display position acquisition module is used to acquire the changed display position of the target element based on the user operation information when the target element is in the state of being operated by the user.

[0163] On the basis of the above technical solutions, the element selection module 420 includes: a key point determination unit, a rotation angle determination unit and a selection box drawing unit.

[0164] A key point determination unit, used to determine at least one element key point corresponding to the target element, and determine the screen display coordinates corresponding to the element key point;

[0165] A rotation angle determination unit, configured to determine a screen rotation angle corresponding to the target element, wherein the screen rotation angle at least includes a roll angle in the Euler angle;

[0166] A check box drawing unit is used to draw a check box corresponding to the target element based on the screen display coordinates and the screen rotation angle, and display the check box.

[0167] On the basis of the above technical solutions, the selected frame drawing unit includes: a minimum bounding box drawing sub-unit.

[0168] The minimum enclosing frame drawing subunit is used to draw a minimum enclosing frame corresponding to the target element based on the screen display coordinates and the screen rotation angle, and determine a selection frame corresponding to the target element based on the minimum enclosing frame.

[0169] On the basis of the above-mentioned technical solutions, a minimum enclosing box drawing subunit is used to perform at least one of the following operations: using the minimum enclosing box as a selected box corresponding to the target element; scaling the minimum enclosing box according to a preset ratio, and using the scaled minimum enclosing box as a selected box corresponding to the target element; determining an inscribed circle or a circumscribed circle of the minimum enclosing box as a selected box corresponding to the target element.

[0170] Based on the above technical solutions, the device further includes: an element scaling processing module.

[0171] The element zoom processing module is used to respond to the zoom trigger operation input to the selection box and perform zoom processing on the selection box and the target element corresponding to the selection box.

[0172] On the basis of the above technical solutions, the preset shape is a regular shape, and the regular shape at least includes a symmetrical shape.

[0173] On the basis of the above-mentioned technical solutions, the preset types at least include follow-up special effects, and the follow-up special effects include special effect elements that move along with the movement of the special effect object.

[0174] The technical solution of the disclosed embodiment obtains the image to be processed in response to the special effect trigger operation, and displays the special effect preview image corresponding to the image to be processed in the target display area, wherein at least one special effect element is displayed in the special effect preview image, providing the user with an interactive entrance for processing the special effect element. Furthermore, in response to the selection trigger operation for the special effect element, the selected special effect element is used as the target element, and a check box corresponding to the target element is displayed, supporting the editing of the special effect element, and being able to accurately obtain the special effect element selected by the user and mark it with a check box for the user to view. Finally, when it is detected that the display position of the target element in the target display area changes or the target element is selected, the special effect element is displayed. When the corresponding special effect type is a preset type, the display position of the selection box in the target display area is updated based on the display position of the target element after the change, thereby solving the problem in the related art that for special effect elements that move with the movement of the special effect object, the user cannot preview the dynamic display effects of the special effect elements during the editing process of these special effect elements, and the like. The dynamic display and editing effects of the special effect elements are achieved in the special effect preview scenario, and the special effect elements to be edited can be marked in the form of a selection box, and the selection box can be guaranteed to follow the special effect elements to be edited, thereby improving the flexibility of the special effect editing process and enhancing the diversity of special effect editing methods.

[0175] The special effects processing device provided in the embodiments of the present disclosure can execute the special effects processing method provided in any embodiment of the present disclosure, and has the functional modules and beneficial effects corresponding to the execution method.

[0176] It is worth noting that the various units and modules included in the above-mentioned device are only divided according to functional logic, but are not limited to the above-mentioned division, as long as the corresponding functions can be achieved; in addition, the specific names of the functional units are only for the convenience of distinguishing each other, and are not used to limit the protection scope of the embodiments of the present disclosure.

[0177] Figure 7 This is a schematic diagram of the structure of an electronic device provided by an embodiment of the present disclosure. Figure 7 , which shows an electronic device (eg, Figure 7 The terminal device in the embodiment of the present disclosure may include but is not limited to mobile terminals such as mobile phones, notebook computers, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablet computers), PMPs (portable multimedia players), vehicle-mounted terminals (such as vehicle-mounted navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Figure 7 The electronic device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.

[0178] like Figure 7 As shown, the electronic device 500 may include a processing device (e.g., a central processing unit, a graphics processing unit, etc.) 501, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 502 or a program loaded from a storage device 508 into a random access memory (RAM) 503. In the RAM 503, various programs and data required for the operation of the electronic device 500 are also stored. The processing device 501, the ROM 502, and the RAM 503 are connected to each other via a bus 504. An edit / output (I / O) interface 505 is also connected to the bus 504.

[0179] Typically, the following devices may be connected to the I / O interface 505: an input device 506 including, for example, a touch screen, a touch pad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; an output device 507 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; a storage device 508 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 509. The communication device 509 may allow the electronic device 500 to communicate with other devices wirelessly or by wire to exchange data. Although Figure 7 The electronic device 500 is shown with various devices, but it should be understood that it is not required to implement or possess all the devices shown. More or fewer devices may be implemented or possessed instead.

[0180] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowchart can 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, and the computer program contains program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through a communication device 509, or installed from a storage device 508, or installed from a ROM 502. When the computer program is executed by the processing device 501, the above-mentioned functions defined in the method of the embodiment of the present disclosure are executed.

[0181] The names of the messages or information exchanged between multiple devices in the embodiments of the present disclosure are only used for illustrative purposes and are not used to limit the scope of these messages or information.

[0182] The electronic device provided by the embodiment of the present disclosure and the special effects processing method provided by the above embodiment belong to the same inventive concept. The technical details not fully described in this embodiment can be referred to the above embodiment, and this embodiment has the same beneficial effects as the above embodiment.

[0183] The embodiments of the present disclosure provide a computer storage medium on which a computer program is stored. When the program is executed by a processor, the special effect processing method provided by the above embodiments is implemented.

[0184] It should be noted that the computer-readable medium disclosed above may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program that may be used by or in combination with an instruction execution system, device or device. In the present disclosure, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, in which a computer-readable program code is carried. This propagated data signal may take a variety of forms, including but not limited to an electromagnetic signal, an optical signal, or any suitable combination of the above. The computer readable signal medium may also be any computer readable medium other than a computer readable storage medium, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer readable medium may be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (radio frequency), etc., or any suitable combination of the above.

[0185] In some embodiments, the client and the server may communicate using any currently known or future developed network protocol such as HTTP (HyperText Transfer Protocol), and may be interconnected with any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network ("LAN"), a wide area network ("WAN"), an internet (e.g., the Internet), and a peer-to-peer network (e.g., an ad hoc peer-to-peer network), as well as any currently known or future developed network.

[0186] The computer-readable medium may be included in the electronic device, or may exist independently without being incorporated into the electronic device.

[0187] The computer-readable medium carries one or more programs. When the one or more programs are executed by the electronic device, the electronic device: in response to a special effect trigger operation, obtains an image to be processed, and displays a special effect preview image corresponding to the image to be processed in a target display area, wherein at least one special effect element is displayed in the special effect preview image; in response to a selection trigger operation for the special effect element, takes the selected special effect element as a target element, and displays a selection box corresponding to the target element; when it is detected that the display position of the target element in the target display area changes or the special effect type corresponding to the target element is a preset type, updates the display position of the selection box in the target display area based on the changed display position of the target element, wherein the shape of the outer contour line of the selection box is a preset shape.

[0188] Computer program code for performing 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 conventional procedural programming languages, such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving a remote computer, the remote computer may be connected to the user's computer through 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., through the Internet using an Internet service provider).

[0189] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some implementations as replacements, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0190] The units involved in the embodiments described in the present disclosure may be implemented by software or hardware. The name of a unit does not limit the unit itself in some cases. For example, the first acquisition unit may also be described as a "unit for acquiring at least two Internet Protocol addresses".

[0191] The functions described above 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 products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), and the like.

[0192] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0193] According to one or more embodiments of the present disclosure, [Example 1] provides a special effect processing method, the method comprising:

[0194] In response to the special effect triggering operation, an image to be processed is acquired, and a special effect preview image corresponding to the image to be processed is displayed in a target display area, wherein at least one special effect element is displayed in the special effect preview image;

[0195] In response to a selection trigger operation on the special effect element, taking the selected special effect element as a target element, and displaying a selection box corresponding to the target element;

[0196] When it is detected that the display position of the target element in the target display area has changed or the special effect type corresponding to the target element is a preset type, the display position of the selection box in the target display area is updated based on the changed display position of the target element, wherein the shape of the outer contour line of the selection box is a preset shape.

[0197] According to one or more embodiments of the present disclosure, [Example 2] provides the method of Example 1, further comprising:

[0198] Optionally, before updating the display position of the check box in the target display area based on the changed display position of the target element, the method further includes:

[0199] In the case where a special effect frame refresh signal is detected, detecting the special effect preview image to determine a target element in the special effect preview image;

[0200] In the case where the target element exists in the special effect preview image, the display position of the target element in the target display area is detected, or the special effect type corresponding to the target element is detected based on a preset type.

[0201] According to one or more embodiments of the present disclosure, [Example 3] provides the method of Example 1, further comprising:

[0202] Optionally, after displaying the check box corresponding to the target element, the method further includes:

[0203] In response to an edit trigger operation input for the target element, the target element is edited, wherein the edit trigger operation includes at least one of a display information adjustment trigger operation, a deletion trigger operation, and a replacement trigger operation, and the display information adjustment operation includes at least one of a display size adjustment trigger operation, a display position adjustment trigger operation, and a display color adjustment trigger operation.

[0204] According to one or more embodiments of the present disclosure, [Example 4] provides the method of Example 1, further comprising:

[0205] Optionally, before updating the display position of the check box in the target display area based on the changed display position of the target element, the method further includes:

[0206] Determine the operation state of the target element, wherein the operation state includes a state of being operated by a user and a state of not being operated by a user;

[0207] When the target element is in the state where no user operation is performed, a display position of the target element after the change based on a preset change mode is obtained, wherein the preset change mode is associated with a special effect type corresponding to the target element.

[0208] According to one or more embodiments of the present disclosure, [Example 5] provides the method of Example 4, further comprising:

[0209] Optionally, after determining the operation state of the target element, the method further includes:

[0210] When the target element is in the state of being operated by the user, the changed display position of the target element is acquired based on the user operation information.

[0211] According to one or more embodiments of the present disclosure, [Example 6] provides the method of Example 1, further comprising:

[0212] Optionally, displaying a check box corresponding to the target element includes:

[0213] Determine at least one element key point corresponding to the target element, and determine the screen display coordinates corresponding to the element key point;

[0214] Determine a screen rotation angle corresponding to the target element, wherein the screen rotation angle at least includes a roll angle in the Euler angle;

[0215] A check box corresponding to the target element is drawn based on the screen display coordinates and the screen rotation angle, and the check box is displayed.

[0216] According to one or more embodiments of the present disclosure, [Example 7] provides the method of Example 6, further comprising:

[0217] Optionally, drawing a check box corresponding to the target element based on the screen display coordinates and the screen rotation angle includes:

[0218] A minimum enclosing box corresponding to the target element is drawn based on the screen display coordinates and the screen rotation angle, and a selection box corresponding to the target element is determined based on the minimum enclosing box.

[0219] According to one or more embodiments of the present disclosure, [Example 8] provides the method of Example 7, further comprising:

[0220] Optionally, determining the selected box corresponding to the target element based on the minimum bounding box includes at least one of the following operations:

[0221] Using the minimum bounding box as a selected box corresponding to the target element;

[0222] Scaling the minimum bounding box according to a preset ratio, and using the scaled minimum bounding box as a selected box corresponding to the target element;

[0223] An inscribed circle or a circumscribed circle of the minimum bounding box is determined as a selected box corresponding to the target element.

[0224] According to one or more embodiments of the present disclosure, [Example 9] provides the method of Example 1, further comprising:

[0225] Optionally, after displaying the check box corresponding to the target element, the method further includes:

[0226] In response to a zoom trigger operation input for the selection box, the selection box and the target element corresponding to the selection box are zoomed.

[0227] According to one or more embodiments of the present disclosure, [Example 10] provides the method of Example 1, further comprising:

[0228] Optionally, the preset shape is a regular shape, and the regular shape at least includes a symmetrical shape.

[0229] According to one or more embodiments of the present disclosure, [Example 11] provides the method of Example 1, further comprising:

[0230] Optionally, the preset type includes at least a follow-up special effect, and the follow-up special effect includes a special effect element that moves along with the movement of the special effect object.

[0231] According to one or more embodiments of the present disclosure, [Example 12] provides a special effect processing device, the device comprising:

[0232] A special effect trigger module, configured to obtain an image to be processed in response to a special effect trigger operation, and display a special effect preview image corresponding to the image to be processed in a target display area, wherein at least one special effect element is displayed in the special effect preview image;

[0233] An element selection module, for responding to a selection trigger operation on the special effect element, taking the selected special effect element as a target element, and displaying a selection box corresponding to the target element;

[0234] A display update module is used to update the display position of the selection box in the target display area based on the changed display position of the target element when it is detected that the display position of the target element in the target display area has changed or the special effect type corresponding to the target element is a preset type, wherein the shape of the outer contour line of the selection box is a preset shape.

[0235] The above description is only a preferred embodiment of the present disclosure and an explanation of the technical principles used. Those skilled in the art should understand that the scope of disclosure involved in the present disclosure is not limited to the technical solutions formed by a specific combination of the above technical features, but should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the above disclosed concept. For example, the above features are replaced with the technical features with similar functions disclosed in the present disclosure (but not limited to) by each other to form a technical solution.

[0236] In addition, although each operation is described in a specific order, this should not be understood as requiring these operations to be performed in the specific order shown or in a sequential order. Under certain circumstances, multitasking and parallel processing may be advantageous. Similarly, although some specific implementation details are included in the above discussion, these should not be interpreted as limiting the scope of the present disclosure. Some features described in the context of a separate embodiment can also be implemented in a single embodiment in combination. On the contrary, the various features described in the context of a single embodiment can also be implemented in multiple embodiments individually or in any suitable sub-combination mode.

[0237] Although the subject matter has been described in language specific to structural features and / or methodological logical actions, it should be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or actions described above. On the contrary, the specific features and actions described above are merely example forms of implementing the claims.

Claims

1. A special effect processing method, characterized in that: include: In response to the special effect triggering operation, an image to be processed is acquired, and a special effect preview image corresponding to the image to be processed is displayed in a target display area, wherein at least one special effect element is displayed in the special effect preview image; In response to a selection trigger operation on the special effect element, taking the selected special effect element as a target element, and displaying a selection box corresponding to the target element; When it is detected that the display position of the target element in the target display area has changed or the special effect type corresponding to the target element is a preset type, the display position of the selection box in the target display area is updated based on the changed display position of the target element, wherein the shape of the outer contour line of the selection box is a preset shape.

2. The special effect processing method according to claim 1, characterized in that: Before updating the display position of the check box in the target display area based on the changed display position of the target element, the method further includes: In the case where a special effect frame refresh signal is detected, detecting the special effect preview image to determine a target element in the special effect preview image; In the case where the target element exists in the special effect preview image, the display position of the target element in the target display area is detected, or the special effect type corresponding to the target element is detected based on a preset type.

3. The special effect processing method according to claim 1, characterized in that: After displaying the check box corresponding to the target element, the method further includes: In response to an edit trigger operation input for the target element, the target element is edited, wherein the edit trigger operation includes at least one of a display information adjustment trigger operation, a deletion trigger operation, and a replacement trigger operation, and the display information adjustment operation includes at least one of a display size adjustment trigger operation, a display position adjustment trigger operation, and a display color adjustment trigger operation.

4. The special effect processing method according to claim 1, characterized in that: Before updating the display position of the check box in the target display area based on the changed display position of the target element, the method further includes: Determine the operation state of the target element, wherein the operation state includes a state of being operated by a user and a state of not being operated by a user; When the target element is in the state of being operated by the user, the changed display position of the target element is acquired based on the user operation information.

5. The special effect processing method according to claim 4, characterized in that: After determining the operation state of the target element, the method further includes: When the target element is in the state where no user operation is performed, a display position of the target element after the change based on a preset change mode is obtained, wherein the preset change mode is associated with a special effect type corresponding to the target element.

6. The special effect processing method according to claim 1, characterized in that: The displaying a check box corresponding to the target element includes: Determine at least one element key point corresponding to the target element, and determine the screen display coordinates corresponding to the element key point; Determine a screen rotation angle corresponding to the target element, wherein the screen rotation angle at least includes a roll angle in the Euler angle; A check box corresponding to the target element is drawn based on the screen display coordinates and the screen rotation angle, and the check box is displayed.

7. The special effect processing method according to claim 6, characterized in that: Drawing a check box corresponding to the target element based on the screen display coordinates and the screen rotation angle includes: A minimum enclosing box corresponding to the target element is drawn based on the screen display coordinates and the screen rotation angle, and a selection box corresponding to the target element is determined based on the minimum enclosing box.

8. The special effect processing method according to claim 7, characterized in that: The determining, based on the minimum bounding box, a selected box corresponding to the target element comprises at least one of the following operations: Using the minimum bounding box as a selected box corresponding to the target element; Scaling the minimum bounding box according to a preset ratio, and using the scaled minimum bounding box as a selected box corresponding to the target element; An inscribed circle or a circumscribed circle of the minimum bounding box is determined as a selected box corresponding to the target element.

9. The special effect processing method according to claim 1, characterized in that: After displaying the check box corresponding to the target element, the method further includes: In response to a zoom trigger operation input for the selection box, the selection box and the target element corresponding to the selection box are zoomed.

10. The special effect processing method according to claim 1, characterized in that: The preset shape is a regular shape, and the regular shape at least includes a symmetrical shape.

11. The special effect processing method according to claim 1, characterized in that: The preset types at least include follow-up special effects, and the follow-up special effects include special effect elements that move along with the movement of the special effect object.

12. A special effect processing device, characterized in that: include: A special effect trigger module, configured to obtain an image to be processed in response to a special effect trigger operation, and display a special effect preview image corresponding to the image to be processed in a target display area, wherein at least one special effect element is displayed in the special effect preview image; An element selection module, for responding to a selection trigger operation on the special effect element, taking the selected special effect element as a target element, and displaying a selection box corresponding to the target element; A display update module is used to update the display position of the selection box in the target display area based on the changed display position of the target element when it is detected that the display position of the target element in the target display area has changed or the special effect type corresponding to the target element is a preset type, wherein the shape of the outer contour line of the selection box is a preset shape.

13. An electronic device, characterized in that: The electronic device comprises: one or more processors; a storage device for storing 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 special effect processing method as described in any one of claims 1-11.

14. A storage medium containing computer executable instructions, characterized in that: The computer executable instructions are used to execute the special effect processing method as described in any one of claims 1 to 11 when executed by a computer processor.

Citation Information

Patent Citations

  • Image special effect generation method, device and electronic device

    CN109064387A

  • Special effect production method and device, electronic equipment and storage medium

    CN113938618A

  • Beauty makeup special effect generation method and device, equipment, storage medium and program product

    CN114723600A

  • XR application development preview method and device, electronic equipment and readable storage medium

    CN115002438A

  • Special effect display method and device, electronic equipment and storage medium

    CN116225592A