Method, apparatus, storage medium and electronic device for generating residual image

By obtaining the pose information of the target object model in the key animation frame, determining and connecting the afterimage vertices, the problems of large memory occupancy and slow rendering speed in the prior art are solved, and more efficient memory usage and rendering speed are achieved.

CN114494544BActive Publication Date: 2025-05-27NETEASE (HANGZHOU) NETWORK CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210146039.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-02-17
Publication Date
2025-05-27
Estimated Expiration
2042-02-17

AI Technical Summary

Technical Problem

In the prior art, afterimages occupy large memory and low rendering speed, resulting in low animation production efficiency and long rendering time.

Method used

By obtaining the pose information of the target object model in the key animation frame, multiple afterimage vertices are determined, and connecting based on the upstream and downstream relationships of these vertices, the afterimage of the target object model is generated, avoiding model copying and blurring.

Benefits of technology

It reduces memory usage, improves the rendering speed of afterimages, and facilitates animators to understand the model structure, and improves animation production efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114494544B_ABST
    Figure CN114494544B_ABST
Patent Text Reader

Abstract

The present disclosure provides a method, apparatus, storage medium and electronic device for generating afterimages, relating to the field of computer technology. Among them, the method for generating afterimages includes: obtaining the pose information of a target object model to be processed at key animation frames; determining a plurality of afterimage vertices corresponding to the target object model according to the pose information of the target object model at key animation frames; and connecting the respective afterimage vertices based on the upstream and downstream relationships corresponding to the respective afterimage vertices to generate an afterimage of the target object model. By connecting the extracted afterimage vertices to generate an afterimage, the present disclosure can not only reduce memory occupancy but also improve the afterimage rendering speed.
Need to check novelty before this filing date? Find Prior Art

Description

Background Art

[0002] A ghost image refers to the situation where, when the screen is switched, the previous frame of the movable object model does not disappear immediately, but appears as a ghost image of the previous frame of the movable object model and appears simultaneously with the next frame of the movable object model. In some animation production processes, sometimes a ghost image effect is added to the movable object model in the animation to enhance the animation expressiveness and thus improve the viewing experience of the player.

[0003] In the related art, when making a ghost image, usually the existing movable object model in the current scene is copied in a 3D production software, then the copied model is blurred, and then its transparency is gradually reduced frame by frame and its roughness is increased to obtain a ghost image model. However, this method will cause a large amount of memory occupation due to the additional model copying, resulting in a slow rendering speed of the ghost image model.

[0004] It should be noted that the information disclosed in the above background art section is only used to enhance the understanding of the background of the present disclosure, and thus may include information that does not constitute the prior art known to those of ordinary skill in the art. Summary of the Invention

[0005] The present disclosure provides a ghost image generation method, a ghost image generation device, a computer-readable storage medium, and an electronic device, thereby at least to a certain extent solving the problem in the related art that the ghost image occupies a large amount of memory and has a low rendering speed.

[0006] Other features and advantages of the present disclosure will become apparent through the following detailed description, or be learned in part through the practice of the present disclosure.

[0007] According to a first aspect of the present disclosure, there is provided a ghost image generation method, the method including: obtaining pose information of a target object model at a key animation frame; determining a plurality of ghost image vertices corresponding to the target object model according to the pose information of the target object model at the key animation frame; and connecting the plurality of ghost image vertices based on the upstream and downstream relationships corresponding to each of the ghost image vertices to generate a ghost image of the target object model.

[0008] In an exemplary embodiment of the present disclosure, the determining a plurality of ghost image vertices corresponding to the target object model according to the pose information of the target object model at the key animation frame includes: determining relative position information of a plurality of model vertices corresponding to the target object model in a model space according to the pose information of the target object model at the key animation frame; and determining a plurality of ghost image vertices from the plurality of model vertices according to the relative position information of the plurality of model vertices in the model space.

[0009] In an exemplary embodiment of the present disclosure, determining a plurality of afterimage vertices from the plurality of model vertices according to the relative position information of the plurality of model vertices in the model space includes: performing a spatial transformation on the relative position information of the plurality of model vertices in the model space to obtain the absolute position information of the plurality of model vertices in the world space; performing a spatial transformation on the absolute position information of the plurality of model vertices in the world space to obtain the relative position information of the plurality of model vertices in the viewing space; and determining afterimage vertices from the plurality of model vertices according to the relative position information of each model vertex in the viewing space.

[0010] In an exemplary embodiment of the present disclosure, determining afterimage vertices from the plurality of model vertices according to the relative position information of each model vertex in the viewing space includes: determining the viewing direction of the viewing camera according to the relative position information of the model vertex in the viewing space; determining whether the angle between the viewing direction of the viewing camera and the normal direction of the model vertex is within a preset angle range; and if the angle between the viewing direction of the viewing camera and the normal direction of the model vertex is within the preset angle range, using the model vertex as an afterimage vertex.

[0011] In an exemplary embodiment of the present disclosure, the method further includes: determining, based on the two-dimensional viewing plane of the viewing camera, whether there is a group of afterimage vertices including overlapping afterimage vertices; and if there is a group of afterimage vertices including overlapping afterimage vertices, determining a replacement vertex corresponding to the group of afterimage vertices according to the distance between the overlapping afterimage vertices included in the group of afterimage vertices and the viewing camera, and replacing the overlapping afterimage vertices included in the group of afterimage vertices with the replacement vertex.

[0012] In an exemplary embodiment of the present disclosure, determining a replacement vertex corresponding to the group of afterimage vertices according to the distance between the overlapping afterimage vertices included in the group of afterimage vertices and the viewing camera includes: using the center point of the overlapping afterimage vertex closest to the viewing camera and the overlapping afterimage vertex farthest from the viewing camera in the group of afterimage vertices as the replacement vertex.

[0013] In an exemplary embodiment of the present disclosure, connecting the afterimage vertices based on the upstream and downstream relationships corresponding to the afterimage vertices to generate an afterimage of the target object model includes: extracting a plurality of afterimage boundary vertices and a plurality of afterimage contour vertices from the afterimage vertices; and connecting the afterimage boundary vertices and the afterimage contour vertices based on the upstream and downstream relationships corresponding to the afterimage vertices to generate an afterimage of the target object model.

[0014] In an exemplary embodiment of the present disclosure, extracting a plurality of afterimage boundary vertices and a plurality of afterimage contour vertices from the afterimage vertices includes: determining whether an afterimage vertex is an afterimage boundary vertex according to the angle between the viewing direction of the observation camera and the normal direction of the afterimage vertex; and determining whether an afterimage vertex is an afterimage contour vertex according to the angle between the model edge connected to the afterimage vertex and any line in the normal plane of the afterimage vertex.

[0015] In an exemplary embodiment of the present disclosure, based on the upstream and downstream relationships corresponding to each of the afterimage vertices, connecting each of the afterimage vertices to generate an afterimage of the target object model further includes: based on the upstream and downstream relationships corresponding to each of the afterimage vertices, connecting each of the afterimage vertices through a specific-shaped curve to generate an afterimage of the target object model, and the specific-shaped curve is thin at both ends and thick in the middle.

[0016] In an exemplary embodiment of the present disclosure, the method further includes: updating the afterimage of the target object model according to the camera state of the observation camera.

[0017] In an exemplary embodiment of the present disclosure, updating the afterimage of the target object model according to the camera state of the observation camera includes: in response to the distance between the observation camera and the target object model changing from less than a preset distance to greater than the preset distance, converting the specific-shaped curve for connection in the afterimage of the target object model into a cylinder structure; and in response to the distance between the observation camera and the target object model changing from greater than the preset distance to less than the preset distance, converting the cylinder structure for connection in the afterimage of the target object model into the specific-shaped curve.

[0018] In an exemplary embodiment of the present disclosure, updating the afterimage of the target object model according to the camera state of the observation camera further includes: if the observation camera rotates, determining new afterimage vertices for the target object model according to the rotation information of the observation camera.

[0019] In an exemplary embodiment of the present disclosure, the afterimages corresponding to the target object model in a plurality of consecutive key animation frames are superimposed and displayed.

[0020] According to a second aspect of the present disclosure, there is provided an afterimage generation device, the device includes: an attitude acquisition module for acquiring the attitude information of a target object model to be processed in a key animation frame; a vertex extraction module for determining a plurality of afterimage vertices corresponding to the target object model according to the attitude information of the target object model in the key animation frame; and an afterimage generation module for connecting each of the afterimage vertices based on the upstream and downstream relationships corresponding to each of the afterimage vertices to generate an afterimage of the target object model.

[0021] According to a third aspect of the present disclosure, there is provided a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the above-mentioned afterimage generation method is implemented.

[0022] According to a fourth aspect of the present disclosure, there is provided an electronic device, including: a processor; and a memory for storing executable instructions of the processor; wherein, the processor is configured to execute the above-mentioned afterimage generation method by executing the executable instructions.

[0023] The technical solution of the present disclosure has the following beneficial effects:

[0024] During the above-mentioned afterimage generation process, the pose information of the target object model to be processed at the key animation frames is obtained; according to the pose information of the target object model at the key animation frames, a plurality of afterimage vertices corresponding to the target object model are determined; based on the upstream and downstream relationships corresponding to each afterimage vertex, each afterimage vertex is connected to generate an afterimage of the target object model. On the one hand, by connecting the extracted afterimage vertices to generate an afterimage, it is not necessary to make a large number of copies and reuses of the target object model in the animation scene, which can not only reduce memory occupancy and memory overhead, but also improve the rendering speed of the afterimage. On the other hand, based on the upstream and downstream relationships of the vertices, each afterimage vertex is connected to form an afterimage line of the target object model, which is not only convenient for animators to understand the model structure to further improve the afterimage production efficiency, but also conducive to forming a cartoon-style afterimage, thus meeting the requirements of the second-dimensional stylized scene.

[0025] It should be understood that the above general description and the following detailed description are only exemplary and explanatory, and cannot limit the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS

[0026] The drawings herein are incorporated into the specification and constitute a part of this specification, showing embodiments consistent with the present disclosure, and are used together with the specification to explain the principles of the present disclosure. Obviously, the drawings in the following description are only some embodiments of the present disclosure, and those of ordinary skill in the art can obtain other drawings based on these drawings without creative efforts.

[0027] Figure 1 A flowchart showing an afterimage generation method in this exemplary embodiment;

[0028] Figure 2 A flowchart showing a method for determining a plurality of afterimage vertices corresponding to a target object model in this exemplary embodiment;

[0029] Figure 3 A schematic diagram showing a target object model in this exemplary embodiment;

[0030] Figure 4 A schematic diagram showing an orthographic view of a cube model in this exemplary embodiment;

[0031] Figure 5 A schematic diagram showing a target object model and its corresponding afterimage in this exemplary embodiment;

[0032] Figure 6A and Figure 6B A schematic diagram showing local model vertices of a target object model in this exemplary embodiment;

[0033] Figure 7 A schematic diagram showing afterimages of a target object model in multiple animation frames in this exemplary embodiment;

[0034] Figure 8 A specific implementation flowchart showing afterimage production in this exemplary embodiment;

[0035] Figure 9A and Figure 9B A schematic diagram showing the generation of a series of afterimages in a game animation scene in this exemplary embodiment;

[0036] Figure 10 A structural block diagram showing an afterimage generation device in this exemplary embodiment;

[0037] Figure 11 An electronic device for implementing the above - mentioned afterimage generation method in this exemplary embodiment. Detailed implementation manners

[0038] Example embodiments will now be described more fully with reference to the accompanying drawings. However, the example embodiments can be implemented in various forms and should not be construed as limited to the examples set forth herein; rather, these embodiments are provided so that this disclosure will be more thorough and complete, and will fully convey the concept of the example embodiments to those skilled in the art. The features, structures, or characteristics described may be combined in any suitable manner in one or more embodiments. In the following description, numerous specific details are provided to give a thorough understanding of the embodiments of the present disclosure. However, those skilled in the art will realize that the technical solutions of the present disclosure can be practiced without one or more of the specific details, or other methods, components, devices, steps, etc. may be employed. In other cases, well - known technical solutions are not shown or described in detail to avoid obscuring the various aspects of the present disclosure.

[0039] In addition, the accompanying drawings are only schematic illustrations of the present disclosure and are not necessarily drawn to scale. The same reference numerals in the drawings denote the same or similar parts, and thus repeated descriptions thereof will be omitted. Some of the block diagrams shown in the drawings are functional entities and do not necessarily correspond to physically or logically independent entities. These functional entities may be implemented in software form, or in one or more hardware modules or integrated circuits, or in different networks and / or processor devices and / or microcontroller devices.

[0040] In the related art, when making afterimages, due to additional model replication, a large amount of memory is occupied. Animators spend a considerable amount of time loading and importing models during the production process, which causes inconvenience to animation production. Moreover, it greatly slows down the rendering speed of the animation scene and consumes a large amount of time cost during post-synthesis or import into the engine.

[0041] In view of the above one or more problems, an exemplary embodiment of the present disclosure provides an afterimage generation method that can be applied to the animation production scene of a game, can leave an afterimage of the movement trace of the target object model, thereby showing the effect of the rapid movement speed of the target object model, such as a ninja dash scene. The afterimage generation method can run on a terminal device or a server. Among them, the terminal device can be a local terminal device, such as a PC (Personal Computer), a mobile phone, a tablet computer, etc. When the afterimage generation method runs on the server, the method can be implemented and executed based on a cloud interaction system, where the cloud interaction system includes a server and a client device.

[0042] Figure 1 An afterimage generation method in this exemplary embodiment is shown, which specifically includes the following steps S110 to S130:

[0043] Step S110, obtaining the pose information of the target object model to be processed at the key animation frames;

[0044] Step S120, determining a plurality of afterimage vertices corresponding to the target object model according to the pose information of the target object model at the key animation frames;

[0045] Step S130, connecting each afterimage vertex based on the upstream and downstream relationships corresponding to each afterimage vertex to generate an afterimage of the target object model.

[0046] In the above process, on the one hand, by connecting the extracted afterimage vertices to generate an afterimage, there is no need to make a large number of copies and reuses of the target object model in the animation scene, which can not only reduce memory occupancy and memory overhead, but also improve the rendering speed of the afterimage. On the other hand, based on the upstream and downstream relationship of vertices, connecting each afterimage vertex can form the afterimage lines of the target object model, which not only facilitates the animator to understand the model structure to further improve the afterimage production efficiency, but also helps to form a cartoon-style afterimage, thus meeting the stylized scene requirements of the second dimension.

[0047] The following will separately Figure 1 describe each step in

[0048] Step S110: Obtain the pose information of the target object model to be processed at the key animation frames.

[0049] The target object model to be processed refers to a movable object model that needs to be processed with an afterimage effect, including but not limited to opaque models such as virtual characters, virtual animals, and anime characters in the target animation, as shown by the model 301 in Figure 3 . The pose information of the target object model at the key animation frames refers to the action, posture and other pose information of the target object model at the key animation frames.

[0050] Step S120: Determine multiple afterimage vertices corresponding to the target object model according to the pose information of the target object model at the key animation frames.

[0051] The afterimage vertices refer to the key vertices for constructing the shape and structure of the afterimage, and specifically can be the model vertices determined according to the pose information of the target object model at the key animation frames.

[0052] In an optional implementation manner, in step S120, determining multiple afterimage vertices corresponding to the target object model according to the pose information of the target object model at the key animation frames can be implemented through the steps shown in Figure 2 , specifically including the following steps S210 to S220:

[0053] Step S210: Determine the relative position information of multiple model vertices corresponding to the target object model in the model space according to the pose information of the target object model at the key animation frames;

[0054] Step S220: Determine multiple afterimage vertices from multiple model vertices according to the relative position information of multiple model vertices in the model space.

[0055] In the above Figure 2 shown steps, by determining multiple afterimage vertices corresponding to the target object model, a basic framework is provided for the construction of the afterimage model.

[0056] Specifically, in step S210, according to the pose information of the target object model at the key animation frames, the relative position information of multiple model vertices corresponding to the target object model in the model space is determined.

[0057] A model vertex refers to a key vertex for constructing the target object model. Usually, the target object model can be composed of internal model vertices and external model vertices. Since the internal model vertices do not affect the visible model appearance of the user, before performing step S210, the model vertices of the target object model can also be depth-detected to eliminate the internal model vertices and retain the external model vertices. In this way, the number of vertices that need to be processed subsequently can be reduced, the efficiency of afterimage generation can be accelerated, and the presented afterimage effect will not be affected.

[0058] The relative position information of the model vertices in the model space can be relative position coordinates based on the coordinate origin of the model space. Here, according to the pose information of the target object model at the key animation frames, the coordinates of each model vertex of the target object model in the model space at this moment can be read through the Python programming interface. It should be noted that the model space is also called the object space or local space. Different target object models have their own independent coordinate spaces. When it moves or rotates, the model space will also move and rotate with it. The bottom center of the target object model can be used as the coordinate origin (0, 0, 0) of the model space.

[0059] Specifically, in step S220, multiple afterimage vertices are determined from multiple model vertices according to the relative position information of the multiple model vertices in the model space.

[0060] In an alternative embodiment, the above determination of multiple afterimage vertices from multiple model vertices according to the relative position information of the multiple model vertices in the model space can be implemented in the following way: the relative position information of the multiple model vertices in the model space is spatially transformed to obtain the absolute position information of the multiple model vertices in the world space; the absolute position information of the multiple model vertices in the world space is spatially transformed to obtain the relative position information of the multiple model vertices in the viewing space; and the afterimage vertices are determined from the multiple model vertices according to the relative position information of each model vertex in the viewing space.

[0061] It should be noted that the world space is a special coordinate system. With the origin of the world coordinates as the center point, the target object model will rotate, translate, and scale in the world space. The viewing space is the space that the viewing camera can observe, which determines the perspective used for rendering the game. In the viewing space, the viewing camera is located at the origin of the viewing space. By performing a spatial transformation on the relative position information of the model vertices, the structure of the afterimage model is obtained and finally an afterimage image is rendered in the viewing space. Compared with the traditional method of copying the model and performing a series of processes such as blurring the copied model, it has a smaller memory overhead.

[0062] Among them, the process of performing a spatial transformation on the relative position information of multiple model vertices in the model space to obtain the absolute position information of multiple model vertices in the world space can be the process of converting the coordinates of the model vertices in the model space to the coordinates in the world space. The specific implementation process can be as follows: First, construct a 4*4 matrix according to the scaling, rotation, and translation of the target object model in the world space where Matrix 3*3 represents the rotation and scaling transformation of the target object model, and Transform 3*1 represents the translation transformation of the target object model. Multiply the 4*4 matrix by the translation standard transformation matrix, rotation standard transformation matrix, and scaling standard transformation matrix, and finally obtain a composite matrix. Use the obtained composite matrix as the transformation matrix Matrix model from the model space to the world space of the target object model. Then calculate Position world = Matrix model Position model , that is, multiply the transformation matrix Matrix model by the coordinates Position model of the model vertices in the model space to obtain the coordinates Position world of the model vertices in the world space.

[0063] Among them, the process of performing a spatial transformation on the absolute position information of multiple model vertices in the world space to obtain the relative position information of multiple model vertices in the viewing space can be the process of transforming the coordinates of the model vertices in the world space to the coordinates in the viewing space. Specifically, the transformation matrix from the world space to the viewing space can be multiplied by the coordinates of the model vertices in the world space to obtain the coordinates of the model vertices in the viewing space.

[0064] Among them, determining the afterimage vertices from multiple model vertices according to the relative position information of each model vertex in the viewing space can be achieved through the following method: Determine the viewing direction of the viewing camera according to the relative position information of the model vertex in the viewing space; Judge whether the angle between the viewing direction of the viewing camera and the normal direction of the model vertex is within a preset angle range; If the angle between the viewing direction of the viewing camera and the normal direction of the model vertex is within the preset angle range, then use the model vertex as the afterimage vertex.

[0065] The viewing direction of the viewing camera refers to the viewing direction of the viewing camera towards the model vertex, and the ray from the viewing camera to the model vertex is the viewing direction of the viewing camera towards the model vertex. The normal of the model vertex can be obtained by reading the relevant data of the model space through the Python programming interface. It should be noted that if the obtained normal direction of the model vertex is not outward-facing, then the normal direction needs to be reversed and saved to ensure that the obtained model normal is outward-facing.

[0066] Specifically, the following method can be used to determine whether the angle between the viewing direction of the viewing camera and the normal direction of the model vertex is within the preset angle range: First, normalize the viewing direction of the viewing camera and the normal direction of the model vertex, then perform a dot product operation to calculate the dot product value, and based on this dot product value, determine whether the angle between the viewing direction of the viewing camera and the normal direction of the model vertex is within the preset angle range, for example, the angle does not exceed 90°. Among them, the process of calculating the dot product value can be shown as follows: Ruest = dot(normalize(radial), normalize(normal)), where dot() represents the dot product operation between normalize(radial) and normalize(normal), normalize() represents the normalization operation, radial is the viewing direction of the viewing camera, and normal is the normal direction of the model vertex. If Ruest is positive, it can be considered that the angle between the viewing direction of the viewing camera and the normal direction of the model vertex is less than 90°; if Ruest is zero, it can be considered that the angle between the viewing direction of the viewing camera and the normal direction of the model vertex is 90°; if Ruest is negative, it can be considered that the angle between the viewing direction of the viewing camera and the normal direction of the model vertex is greater than 90°.

[0067] It should be noted that if the angle between the viewing direction of the viewing camera and the normal direction of the model vertex is greater than 90°, it means that the model vertex is located on the back of the target object model in the viewing space at this time. When the target object model is an opaque model, the viewing camera cannot directly observe the back of the target object model. Therefore, through the above operations, some redundant vertices located on the back of the target object model can be further removed.

[0068] In addition, since the view observed by the observation camera in the observation space is a two-dimensional observation plane, at the position of the model boundary line, overlapping ghost vertices may appear. To facilitate the description of the vertex overlapping state, a cube model is used as an example here for illustration. As Figure 4 shown by the cube model 401 in

[0069] In an alternative embodiment, it is also possible to determine whether there is a ghost vertex group containing overlapping ghost vertices based on the two-dimensional observation plane of the observation camera; if there is a ghost vertex group containing overlapping ghost vertices, then according to the distance between the overlapping ghost vertices included in the ghost vertex group and the observation camera, determine the replacement vertex corresponding to the ghost vertex group, and replace the overlapping ghost vertices included in the ghost vertex group with the replacement vertex.

[0070] An overlapping ghost vertex segment refers to a ghost vertex that overlaps when viewed from the two-dimensional observation plane of the observation camera, and a ghost vertex group is composed of overlapping ghost vertices. Here, the overlapping ghost vertices can be grouped, and the replacement vertex corresponding to each ghost vertex group can be determined, so as to replace the overlapping ghost vertices, thereby simplifying the ghost structure to a certain extent.

[0071] In an alternative embodiment, to determine the replacement vertex corresponding to the ghost vertex group according to the distance between the overlapping ghost vertices included in the ghost vertex group and the observation camera, it can also be determined by the following method: use the center point of the overlapping ghost vertex closest to the observation camera and the overlapping ghost vertex farthest from the observation camera in the ghost vertex group as the replacement vertex.

[0072] In the above process, by using the center point of the overlapping ghost vertex closest to the observation camera and the overlapping ghost vertex farthest from the observation camera in the ghost vertex group as the replacement vertex, multiple overlapping ghost vertices are merged into one ghost vertex.

[0073] Step S130, based on the upstream and downstream relationships corresponding to each ghost vertex, connect each ghost vertex to generate the ghost of the target object model.

[0074] The upstream and downstream relationship of the ghost vertex refers to the connection relationship between the ghost vertex and other ghost vertices. It should be noted that if there is a replacement vertex among the ghost vertices, the connection relationship of the ghost vertex corresponding to the overlapping ghost vertex closest to the observation camera in the ghost vertex group corresponding to the replacement vertex can also be used as the upstream and downstream relationship of the replacement vertex.

[0075] Here, the upstream and downstream relationships of the other model vertices connected to each model vertex can be queried in advance through the API (Application Programming Interface), and stored in a dictionary in the form of key-value pairs. When in use, the dictionary can be directly read according to the correspondence between the afterimage vertices and the model vertices to obtain the upstream and downstream relationships corresponding to each afterimage vertex.

[0076] As Figure 5 shown, after the target object model 301 undergoes the above-mentioned afterimage generation process, the afterimage model 501 can be obtained.

[0077] In an alternative embodiment, in the above step S130, based on the upstream and downstream relationships corresponding to each afterimage vertex, each afterimage vertex is connected to generate the afterimage of the target object model, which can be generated in the following way: extract multiple afterimage boundary vertices and multiple afterimage contour vertices from the afterimage vertices; connect each afterimage boundary vertex and each afterimage contour vertex based on the upstream and downstream relationships corresponding to each afterimage vertex to generate the afterimage of the target object model.

[0078] In the above process, by distinguishing the afterimage contour vertices and the afterimage boundary vertices, the problem of the afterimage structure being chaotic caused by the excessive complexity of the target object model can be avoided.

[0079] In an alternative embodiment, the above-mentioned extraction of multiple afterimage boundary vertices and multiple afterimage contour vertices from the afterimage vertices can be specifically implemented in the following way: judge whether the afterimage vertex is an afterimage boundary vertex according to the angle between the viewing direction of the observation camera and the normal direction of the afterimage vertex; judge whether the afterimage vertex is an afterimage contour vertex according to the angle between the model edge connected to the afterimage vertex and any line in the normal plane of the afterimage vertex.

[0080] The afterimage boundary vertex can be a model vertex that presents the boundary of the target object model in the viewing space, and the afterimage contour vertex can be a model vertex that presents the contour of the target object model in the viewing space.

[0081] If the angle between the viewing direction of the observation camera and the normal direction of the afterimage vertex is 90°, that is, the viewing direction of the observation camera is perpendicular to the normal direction of the afterimage vertex, then it can be considered that the afterimage vertex is a model vertex that can present the boundary of the target object model in the viewing space, that is, the afterimage boundary vertex.

[0082] The normal plane of the afterimage vertex is a plane perpendicular to the normal of the afterimage vertex. Any line can be selected in this normal plane. After normalizing the model edge connected to the afterimage vertex and the selected arbitrary line, a dot product calculation is performed. If the dot product value approaches zero, then this point is considered to be a smooth vertex of the model, as Figure 6AFor the back-of-hand part of the target object model 301 shown, the dot product value between the model edges connected by the vertices on the back of the hand and the edge points in the tangent space is small. If this dot product value is greater than a preset dot product value, that is, when the angle between the model edge connected to the ghost vertex and any line in the normal plane of the ghost vertex is greater than a certain angle, then it can be considered that this ghost vertex is a model vertex presenting the outline of the target object model in the viewing space, that is, a ghost outline vertex. As Figure 6B For the wrist interface part of the target object model 301 shown, there is a relatively large dot product value between the line in the normal plane corresponding to the model vertex pointed by the arrow and the four model edges passing through this model vertex.

[0083] Generally, when determining the outline edges of the target object model, a boundary search method is adopted. To show a hard-edge effect, a very close line is added above and below the interface line between the model vertices for reinforcement. These lines are generally also outline lines. Then, the API interface is used to find these reinforced edges, thereby locating the corresponding outline vertices. However, in some models with a very high level of refinement such as high-poly models, the spacing between edges is very close, making it difficult to locate the reinforced edges, prone to errors, and lacking universal applicability. The method of determining the ghost outline vertices described in this disclosure can enhance the universal adaptability to a certain extent.

[0084] In an alternative embodiment, in step S130 above, based on the upstream and downstream relationships corresponding to each ghost vertex, connecting each ghost vertex to generate the ghost of the target object model can also be achieved in the following way: Based on the upstream and downstream relationships corresponding to each ghost vertex, connecting between each ghost vertex with a specific-shaped curve to generate the ghost of the target object model, and the specific-shaped curve is thin at both ends and thick in the middle.

[0085] The curve for connection is thick in the middle and thin at both ends, which can make the line more layered and enhance the smoothness of the line in the visual presentation effect.

[0086] In addition, when implementing the effect of the above specific-shaped curve, the curve class can be rewritten in advance using the interface of Python, adopting a staged distribution. The line is thin at the vertices of the curve, gradually thickens to the middle position, and then gradually thins at another vertex. Furthermore, the rewritten curve class can also support color information, so as to generate a curve connecting the ghost vertices with a custom color to meet the diverse user needs.

[0087] In an alternative embodiment, the ghost of the target object model can also be updated according to the camera state of the observation camera.

[0088] The camera state can, for example, observe the motion states of the camera such as translation and rotation. The afterimage of the target model is updated according to the camera state, so that the afterimage can change in real time with the viewing angle of the observation camera, enhancing the three-dimensional sense of the afterimage.

[0089] When the camera undergoes translation, that is, when the distance between the observation camera and the target object model changes, in an optional implementation manner, according to the camera state of the observation camera, updating the afterimage of the target object model can be achieved in the following way: in response to the distance between the observation camera and the target object model changing from less than a preset distance to greater than the preset distance, convert the specific shape curve for connection in the afterimage of the target object model into a cylinder structure; in response to the distance between the observation camera and the target object model changing from greater than the preset distance to less than the preset distance, convert the cylinder structure for connection in the afterimage of the target object model into a specific shape curve.

[0090] The preset distance can be a pre-configured distance value. For example, when the observation camera moves away from the target object model and the distance between them exceeds 50 meters, the afterimage of the target object model begins to be converted into an afterimage connected by cylinders; when the observation camera approaches the target object model and the distance between them is less than 50 meters, the afterimage of the target object model adaptively becomes an afterimage connected by a specific shape curve.

[0091] If the accuracy of the target object model is relatively low, the lines will look blurred and lack a sense of hierarchy when viewed from a distance. Changing to a cylinder model at a distance makes the lines thicker, and the setting of being thinner at both ends and thicker in the middle also makes the lines more hierarchical and easier to attract attention.

[0092] It should be noted that when converting the specific shape curve into a cylinder, several points on the curve can be used as the centers, and circles with radii in an interval are extruded outwards and connected upstream and downstream to form a cylinder.

[0093] In an optional implementation manner, according to the camera state of the observation camera, updating the afterimage of the target object model further includes: if the observation camera rotates, determine new afterimage vertices for the target object model according to the rotation information of the observation camera.

[0094] When the observation camera rotates, since the viewing angle rotates and the model vertices that can be observed also change, in this case, it is necessary to find new afterimage vertices again, regenerate the afterimage and overwrite the original afterimage, thereby enhancing the three-dimensional sense of the afterimage.

[0095] In an optional implementation manner, the afterimages corresponding to multiple consecutive key animation frames of the target object model can also be superimposed and displayed.

[0096] Several consecutive key animation frames can be preset from the target animation, and multiple afterimages can be generated according to the pose information of the target object model at these consecutive key animation frames. These afterimages are superimposed and displayed to form a coherent animation ghosting effect, which is convenient for observing the motion logic of the target object model. The specific presentation effect can be as shown in Figure 7 as shown.

[0097] It should be noted that when selecting key animation frames, the time nodes can also be set through the UI (User Interface), and the key animation frames can be determined by automatically calculating the time nodes using a script, so as to determine the afterimages of the target object model at specific key animation frames.

[0098] As shown in Figure 8 as shown, the present disclosure also provides a specific implementation manner for making afterimages, which may include the following steps:

[0099] Step S801, obtaining the pose information of the target object model to be processed at the key animation frame;

[0100] Step S802, determining the relative position information of multiple model vertices corresponding to the target object model in the model space according to the pose information of the target object model at the key animation frame;

[0101] Step S803, performing a spatial transformation on the relative position information of multiple model vertices in the model space to obtain the absolute position information of multiple model vertices in the world space;

[0102] Step S804, performing a spatial transformation on the absolute position information of multiple model vertices in the world space to obtain the relative position information of multiple model vertices in the viewing space;

[0103] Step S805, determining the viewing direction of the viewing camera according to the relative position information of the model vertices in the viewing space;

[0104] Step S806, judging whether the included angle between the viewing direction of the viewing camera and the normal direction of the model vertices does not exceed 90°; if the included angle between the viewing direction of the viewing camera and the normal direction of the model vertices does not exceed 90°, the model vertices are used as afterimage vertices;

[0105] Step S807, based on the two-dimensional viewing plane of the viewing camera, judging whether there is a group of afterimage vertices containing overlapping afterimage vertices; if there is a group of afterimage vertices containing overlapping afterimage vertices, the center point of the overlapping afterimage vertex closest to the viewing camera and the overlapping afterimage vertex farthest from the viewing camera in the group of afterimage vertices is used as a replacement vertex, and the replacement vertex replaces the overlapping afterimage vertices included in the group of afterimage vertices;

[0106] Step S808: Determine whether a residual image vertex is a boundary vertex of the residual image based on the angle between the viewing direction of the observation camera and the normal direction of the residual image vertex; determine whether a residual image vertex is a contour vertex of the residual image based on the angle between any line in the normal plane of the model edge connected to the residual image vertex and the residual image vertex.

[0107] Step S809: Connect the boundary vertices and contour vertices of each residual image based on the upstream and downstream relationships corresponding to each residual image vertex to generate a residual image of the target object model.

[0108] By Figure 8 The produced residual image effect can replace the previous method of blurring and superimposing traditional residual images to reduce transparency, which is more simple and efficient. And since the curve occupies less memory, it can greatly improve the rendering speed of the scene to quickly enter the later stage.

[0109] In addition, Figure 9A and Figure 9B provide schematic diagrams of generating a series of residual images in a game animation scene. Among them, Figure 9A provides a schematic diagram of an initial version of the animation scene without a residual image, Figure 9B On the Figure 9A basis, it provides a schematic diagram of an animation scene containing residual images corresponding to multiple key animation frames.

[0110] The exemplary embodiment of the present disclosure also provides a residual image generation device. As Figure 10 shown, the residual image generation device 1000 may include:

[0111] An attitude acquisition module 1010, configured to acquire the attitude information of the target object model to be processed at a key animation frame;

[0112] A vertex extraction module 1020, configured to determine a plurality of residual image vertices corresponding to the target object model according to the attitude information of the target object model at the key animation frame;

[0113] A residual image generation module 1030, configured to connect the residual image vertices based on the upstream and downstream relationships corresponding to each residual image vertex to generate a residual image of the target object model.

[0114] In an optional embodiment, the vertex extraction module 1020 may include: a vertex position information determination module, configured to determine the relative position information of a plurality of model vertices corresponding to the target object model in the model space according to the attitude information of the target object model at the key animation frame; a residual image vertex determination module, configured to determine a plurality of residual image vertices from the plurality of model vertices according to the relative position information of the plurality of model vertices in the model space.

[0115] In an alternative embodiment, the afterimage vertex determination module may include: a first space conversion module for performing space conversion on the relative position information of multiple model vertices in the model space to obtain the absolute position information of the multiple model vertices in the world space; a second space conversion module for performing space conversion on the absolute position information of the multiple model vertices in the world space to obtain the relative position information of the multiple model vertices in the viewing space; and an afterimage vertex determination sub-module for determining afterimage vertices from the multiple model vertices according to the relative position information of each model vertex in the viewing space.

[0116] In an alternative embodiment, the afterimage vertex determination sub-module may be configured to: determine the viewing direction of the viewing camera according to the relative position information of the model vertex in the viewing space; determine whether the angle between the viewing direction of the viewing camera and the normal direction of the model vertex is within a preset angle range; and if the angle between the viewing direction of the viewing camera and the normal direction of the model vertex is within the preset angle range, use the model vertex as an afterimage vertex.

[0117] In an alternative embodiment, the afterimage generation device 1000 may further include: a coincident vertex determination module for determining whether there is an afterimage vertex group including coincident afterimage vertices based on the two-dimensional viewing plane of the viewing camera; and a vertex replacement module for, if there is an afterimage vertex group including coincident afterimage vertices, determining a replacement vertex corresponding to the afterimage vertex group according to the distance between the coincident afterimage vertices included in the afterimage vertex group and the viewing camera, and replacing the coincident afterimage vertices included in the afterimage vertex group with the replacement vertex.

[0118] In an alternative embodiment, the vertex replacement module may use the center point of the coincident afterimage vertex closest to the viewing camera and the coincident afterimage vertex farthest from the viewing camera in the afterimage vertex group as the replacement vertex.

[0119] In an alternative embodiment, the afterimage generation module 1030 may further include: an afterimage vertex classification determination module for extracting multiple afterimage boundary vertices and multiple afterimage contour vertices from the afterimage vertices; and an afterimage vertex connection module for connecting each afterimage boundary vertex and each afterimage contour vertex based on the upstream and downstream relationships corresponding to each afterimage vertex to generate an afterimage of the target object model.

[0120] In an alternative embodiment, the afterimage vertex classification determination module may be configured to: determine whether an afterimage vertex is an afterimage boundary vertex according to the angle between the viewing direction of the viewing camera and the normal direction of the afterimage vertex; and determine whether an afterimage vertex is an afterimage contour vertex according to the angle between any line in the normal plane of the model edge connected to the afterimage vertex and the afterimage vertex.

[0121] In an alternative embodiment, the afterimage generation module 1030 may further include: an afterimage generation sub-module, configured to connect the afterimage vertices through a specific-shaped curve based on the upstream and downstream relationships corresponding to the respective afterimage vertices, so as to generate an afterimage of the target object model, where the two ends of the specific-shaped curve are thin and the middle is thick.

[0122] In an alternative embodiment, the afterimage generation device 1000 may include: an afterimage update module, configured to update the afterimage of the target object model according to the camera state of the observation camera.

[0123] In an alternative embodiment, the afterimage update module may include: a camera movement processing module, configured to, in response to the distance between the observation camera and the target object model changing from less than a preset distance to greater than the preset distance, convert the specific-shaped curve for connection in the afterimage of the target object model into a cylinder structure; and in response to the distance between the observation camera and the target object model changing from greater than the preset distance to less than the preset distance, convert the cylinder structure for connection in the afterimage of the target object model into a specific-shaped curve.

[0124] In an alternative embodiment, the afterimage update module may further include: a camera rotation processing module, configured to, if the observation camera rotates, determine new afterimage vertices for the target object model according to the rotation information of the observation camera.

[0125] In an alternative embodiment, the afterimage generation device 1000 may include: an overlay display module, configured to overlay and display the afterimages corresponding to the target object model in multiple consecutive key animation frames.

[0126] The specific details of each part in the above afterimage generation device 1000 have been described in detail in the embodiments of the method part. For the details not disclosed, reference may be made to the content of the embodiments in the method part, and thus will not be elaborated here.

[0127] The exemplary embodiments of the present disclosure further provide a computer-readable storage medium, on which a program product capable of implementing the above afterimage generation method of this specification is stored. In some possible embodiments, various aspects of the present disclosure may also be implemented in the form of a program product, which includes program code. When the program product runs on an electronic device, the program code is used to cause the electronic device to execute the steps according to the various exemplary embodiments of the present disclosure described in the above "Exemplary Method" part. The program product may be a portable compact disc read-only memory (CD-ROM) and includes program code, and may run on an electronic device, such as a personal computer. However, the program product of the present disclosure is not limited thereto. In this document, the readable storage medium may be any tangible medium that contains or stores a program, and the program may be used by or in combination with an instruction execution system, apparatus, or device.

[0128] The program product may employ any combination of one or more readable media. The readable media may be a readable signal medium or a readable storage medium. The readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples (a non-exhaustive list) of the readable storage medium include: an electrical connection having one or more wires, a portable 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 disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0129] The computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, in which the readable program code is carried. Such a propagated data signal may take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the foregoing. The readable signal medium may also be any readable medium other than the readable storage medium, which can send, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device.

[0130] The program code contained on the readable medium may be transmitted by any appropriate medium, including but not limited to wireless, wired, optical fiber cable, RF, etc., or any suitable combination of the foregoing.

[0131] The program code for performing the operations of the present disclosure may be written in any combination of one or more programming languages. The programming languages include object-oriented programming languages such as Java, C++, etc., and also include conventional procedural programming languages such as the "C" language or similar programming languages. The program code may be executed entirely on the user computing device, partially on the user device, executed as a stand-alone software package, partially on the user computing device and partially on a remote computing device, or entirely on the remote computing device or server. In the case of a remote computing device, the remote computing device may be connected to the user computing device through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computing device (e.g., by using an Internet service provider to connect through the Internet).

[0132] The exemplary embodiments of the present disclosure also provide an electronic device capable of implementing the above-mentioned afterimage generation method. The following refers to Figure 11 to describe the electronic device 1100 according to such an exemplary embodiment of the present disclosure. Figure 11The illustrated electronic device 1100 is merely an example and should not impose any limitation on the functionality and scope of use of the embodiments of the present disclosure.

[0133] As Figure 11 shown, the electronic device 1100 may be presented in the form of a general-purpose computing device. The components of the electronic device 1100 may include, but are not limited to: at least one processing unit 1110, at least one storage unit 1120, a bus 1130 connecting different system components (including the storage unit 1120 and the processing unit 1110), and a display unit 1140.

[0134] The storage unit 1120 stores program code that can be executed by the processing unit 1110, so that the processing unit 1110 executes the steps according to various exemplary embodiments of the present disclosure described in the "Exemplary Methods" section of this specification above. For example, the processing unit 1110 may execute Figure 1 , Figure 2 , Figure 8 any one or more of the method steps in

[0135] The storage unit 1120 may include a readable medium in the form of a volatile storage unit, such as a random access storage unit (RAM) 1121 and / or a cache storage unit 1122, and may further include a read-only storage unit (ROM) 1123.

[0136] The storage unit 1120 may also include a program / utilities 1124 having a set (at least one) of program modules 1125. Such program modules 1125 include, but are not limited to: an operating system, one or more application programs, other program modules, and program data. Each or some combination of these examples may include an implementation of a network environment.

[0137] The bus 1130 may represent one or more of several types of bus structures, including a storage unit bus or storage unit controller, a peripheral bus, a graphics acceleration port, a processing unit, or a local bus using any of the various bus structures.

[0138] The electronic device 1100 can also communicate with one or more external devices 1200 (such as a keyboard, a pointing device, a Bluetooth device, etc.), and can also communicate with one or more devices that enable a user to interact with the electronic device 1100, and / or communicate with any device (such as a router, a modem, etc.) that enables the electronic device 1100 to communicate with one or more other computing devices. Such communication can be carried out through the input / output (I / O) interface 1150. Moreover, the electronic device 1100 can also communicate with one or more networks (such as a local area network (LAN), a wide area network (WAN), and / or a public network, such as the Internet) through the network adapter 1160. As shown in the figure, the network adapter 1160 communicates with other modules of the electronic device 1100 through the bus 1130. It should be understood that although not shown in the figure, other hardware and / or software modules can be used in combination with the electronic device 1100, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems, etc.

[0139] Through the description of the above embodiments, those skilled in the art can easily understand that the exemplary embodiments described herein can be implemented by software, or can be implemented by the way of software in combination with necessary hardware. Therefore, the technical solutions according to the embodiments of the present disclosure can be embodied in the form of a software product, and the software product can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.) or on a network, including several instructions to enable a computing device (which can be a personal computer, a server, a terminal device, or a network device, etc.) to execute the method according to the exemplary embodiments of the present disclosure.

[0140] In addition, the above-mentioned drawings are only schematic illustrations of the processes included in the method according to the exemplary embodiments of the present disclosure, rather than for limiting purposes. It is easy to understand that the processes shown in the above-mentioned drawings do not indicate or limit the time sequence of these processes. Additionally, it is also easy to understand that these processes can be executed synchronously or asynchronously in, for example, multiple modules.

[0141] It should be noted that although several modules or units of devices for action execution are mentioned in the above detailed description, such a division is not mandatory. In fact, according to the exemplary embodiments of the present disclosure, the features and functions of two or more modules or units described above can be embodied in one module or unit. Conversely, the features and functions of one module or unit described above can be further divided and embodied by multiple modules or units.

[0142] Those skilled in the art to which the present disclosure pertains will appreciate that various aspects of the present disclosure can be implemented as a system, method, or program product. Accordingly, the various aspects of the present disclosure can be embodied in the following forms, namely: a complete hardware implementation, a complete software implementation (including firmware, microcode, etc.), or an implementation combining hardware and software aspects, which can be collectively referred to herein as "circuitry", "module", or "system". After considering the specification and practicing the invention disclosed herein, those skilled in the art will readily conceive of other embodiments of the present disclosure. This application is intended to cover any variations, uses, or adaptations of the present disclosure that follow the general principles of the present disclosure and include well-known knowledge or conventional technical means in the technical field not disclosed in the present disclosure. The specification and embodiments are to be considered illustrative only, and the true scope and spirit of the present disclosure are pointed out by the appended claims.

[0143] It should be understood that the present disclosure is not limited to the exact structures described above and shown in the drawings, and various modifications and changes can be made without departing from its scope. The scope of the present disclosure is defined only by the appended claims.

Claims

1. A method for generating afterimages, characterized in that, the method includes: Obtaining the pose information of the target object model to be processed at key animation frames; Determining a plurality of afterimage vertices corresponding to the target object model according to the pose information of the target object model at key animation frames; Based on the upstream and downstream relationships corresponding to each of the afterimage vertices, connecting each of the afterimage vertices to generate an afterimage of the target object model; wherein, the connecting each of the afterimage vertices based on the upstream and downstream relationships corresponding to each of the afterimage vertices to generate an afterimage of the target object model includes: Extracting a plurality of afterimage boundary vertices and a plurality of afterimage contour vertices from the afterimage vertices; Connecting each of the afterimage boundary vertices and each of the afterimage contour vertices based on the upstream and downstream relationships corresponding to each of the afterimage vertices to generate an afterimage of the target object model.

2. The method according to claim 1, characterized in that, the determining a plurality of afterimage vertices corresponding to the target object model according to the pose information of the target object model at key animation frames includes: Determining the relative position information of a plurality of model vertices corresponding to the target object model in the model space according to the pose information of the target object model at key animation frames; Determining a plurality of afterimage vertices from the plurality of model vertices according to the relative position information of the plurality of model vertices in the model space.

3. The method according to claim 2, characterized in that, the determining a plurality of afterimage vertices from the plurality of model vertices according to the relative position information of the plurality of model vertices in the model space includes: Performing a spatial transformation on the relative position information of the plurality of model vertices in the model space to obtain the absolute position information of the plurality of model vertices in the world space; Performing a spatial transformation on the absolute position information of the plurality of model vertices in the world space to obtain the relative position information of the plurality of model vertices in the observation space; Determining afterimage vertices from the plurality of model vertices according to the relative position information of each model vertex in the observation space.

4. The method according to claim 3, characterized in that, the determining afterimage vertices from the plurality of model vertices according to the relative position information of each model vertex in the observation space includes: Determining the observation direction of the observation camera according to the relative position information of the model vertex in the observation space; Judging whether the included angle between the observation direction of the observation camera and the normal direction of the model vertex is within a preset angle range; If the included angle between the observation direction of the observation camera and the normal direction of the model vertex is within the preset angle range, then taking the model vertex as an afterimage vertex.

5. The method according to claim 1, characterized in that, the method further includes: Based on the two-dimensional observation plane of the observation camera, judging whether there is a group of afterimage vertices including overlapping afterimage vertices; If there is a set of ghost vertices that includes overlapping ghost vertices, determine a replacement vertex corresponding to the set of ghost vertices according to the distance between the overlapping ghost vertices included in the set of ghost vertices and the observation camera, and replace the overlapping ghost vertices included in the set of ghost vertices with the replacement vertex.

6. The method according to claim 5, wherein, the determining a replacement vertex corresponding to the set of ghost vertices according to the distance between the overlapping ghost vertices included in the set of ghost vertices and the observation camera includes: using the center point of the overlapping ghost vertex closest to the observation camera and the overlapping ghost vertex farthest from the observation camera in the set of ghost vertices as the replacement vertex.

7. The method according to claim 1, wherein, the extracting a plurality of ghost boundary vertices and a plurality of ghost contour vertices from the ghost vertices includes: judging whether the ghost vertex is a ghost boundary vertex according to the included angle between the observation direction of the observation camera and the normal direction of the ghost vertex; judging whether the ghost vertex is a ghost contour vertex according to the included angle between the model edge connected to the ghost vertex and any line in the normal plane of the ghost vertex.

8. The method according to claim 1, wherein, the connecting each of the ghost vertices based on the upstream and downstream relationships corresponding to each of the ghost vertices to generate a ghost of the target object model further includes: connecting each of the ghost vertices through a specific shape curve based on the upstream and downstream relationships corresponding to each of the ghost vertices to generate a ghost of the target object model, and the specific shape curve is thin at both ends and thick in the middle.

9. The method according to claim 8, wherein, the method further includes: updating the ghost of the target object model according to the camera state of the observation camera.

10. The method according to claim 9, wherein, the updating the ghost of the target object model according to the camera state of the observation camera includes: in response to the distance between the observation camera and the target object model changing from less than a preset distance to greater than the preset distance, converting the specific shape curve for connection in the ghost of the target object model into a cylinder structure; in response to the distance between the observation camera and the target object model changing from greater than the preset distance to less than the preset distance, converting the cylinder structure for connection in the ghost of the target object model into the specific shape curve.

11. The method according to claim 9, wherein, the updating the ghost of the target object model according to the camera state of the observation camera further includes: if the observation camera rotates, determining new ghost vertices for the target object model according to the rotation information of the observation camera.

12. The method according to claim 1, wherein, the method further includes: superimposing and displaying the ghosts corresponding to multiple consecutive key animation frames of the target object model.

13. A ghost generation device, wherein, the device includes: An attitude acquisition module, configured to acquire the attitude information of a target object model to be processed at key animation frames; A vertex extraction module, configured to determine a plurality of afterimage vertices corresponding to the target object model according to the attitude information of the target object model at key animation frames; An afterimage generation module, configured to connect each of the afterimage vertices based on the upstream and downstream relationships corresponding to each of the afterimage vertices, and generate an afterimage of the target object model; Wherein, the afterimage generation module is configured to: Extract a plurality of afterimage boundary vertices and a plurality of afterimage contour vertices from the afterimage vertices; Connect each of the afterimage boundary vertices and each of the afterimage contour vertices based on the upstream and downstream relationships corresponding to each of the afterimage vertices, and generate an afterimage of the target object model.

14. A computer-readable storage medium, on which a computer program is stored, Characterized in that, The computer program, when executed by a processor, implements the method according to any one of claims 1 to 12.

15. An electronic device, Characterized in that, Comprising: A processor; And A memory, configured to store executable instructions of the processor; Wherein, the processor is configured to execute the method according to any one of claims 1 to 12 by executing the executable instructions.

Citation Information

Patent Citations

  • Residual shadow rendering method and device, storage medium and electronic device

    CN111738935A

  • Ghosting processing method and device, storage medium and electronic equipment

    CN113706504A