State control method and device of virtual eyeball model and electronic equipment

By baking the eyeball composite texture onto the eye material sphere in the game and using a target locator to control the changing state of the eyeball model, the resource consumption problem caused by high-precision models was solved, achieving efficient eyeball model state control and improving game performance.

CN116531751BActive Publication Date: 2026-07-21NETEASE (HANGZHOU) NETWORK CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
NETEASE (HANGZHOU) NETWORK CO LTD
Filing Date
2023-05-23
Publication Date
2026-07-21

AI Technical Summary

Technical Problem

In existing technologies, high-precision virtual eye models lead to excessive resource consumption in games, causing lag and stuttering issues.

Method used

By baking the combined eyeball texture onto the eye material sphere, the changing state of the eyeball model can be determined by utilizing the relative positional changes between the target locator and the initial virtual eyeball model, thus reducing the difficulty of texture drawing and improving the efficiency of state control.

Benefits of technology

While improving state control efficiency, it reduces game resource consumption and enhances the efficiency of eyeball model construction and game performance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116531751B_ABST
    Figure CN116531751B_ABST
Patent Text Reader

Abstract

The application provides a state control method and device of a virtual eyeball model and electronic equipment, relates to the technical field of game models, and the method comprises the following steps: baking eyeball combination maps (including an eyeball map and an eyeball map) to an eye material ball to obtain an initial virtual eyeball model; determining a relative position change of a target locator and the initial virtual eyeball model, determining a change state of the eyeball model based on the relative position change of the target locator and the initial virtual eyeball model, and determining the eyeball model in the change state as a target virtual eyeball model; wherein the target locator is located in the normal direction of the initial virtual eyeball model. The application solves the technical problem in the prior art that a high-precision model is prone to causing a large amount of resource consumption, causing game running lag and poor running, and achieves the effect that the change state of the eyeball model can be controlled only by controlling the target locator, and the consumption of game resources is reduced on the basis of improving the state control efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of game model technology, and in particular to a method, device and electronic device for controlling the state of a virtual eyeball model. Background Technology

[0002] In traditional CG asset eye creation, high-precision eye models are typically built to simulate the effect of human eyes through meticulous detail, and numerous complex controllers are used to control the movement and scaling of the eye. However, games often do not require highly precise eye models, as high-precision models can consume excessive resources, causing game lag and stuttering. Therefore, there is an urgent need for an efficient, low-precision method for controlling the state of the eye. Summary of the Invention

[0003] This application provides a method, device, and electronic device for controlling the state of a virtual eyeball model, which solves the technical problem in the prior art that high-precision models easily generate a lot of resource consumption, causing game lag and poor performance.

[0004] In a first aspect, the present invention provides a method for controlling the state of a virtual eyeball model, the method comprising:

[0005] The eyeball composite texture is baked onto the eye material sphere to obtain the initial virtual eyeball model; the eyeball composite texture includes an eye socket texture and an eyeball texture;

[0006] The relative position change between the target locator and the initial virtual eyeball model is determined, and the changing state of the eyeball model is determined based on the relative position change between the target locator and the initial virtual eyeball model. The eyeball model in the changing state is determined as the target virtual eyeball model; wherein, the target locator is located in the normal direction of the initial virtual eyeball model.

[0007] In a second aspect, the present invention provides a state control device for a virtual eyeball model, the device comprising:

[0008] The texture combination module is used to bake the eyeball combination texture onto the eye material sphere to obtain an initial virtual eyeball model; the eyeball combination texture includes an eye socket texture and an eyeball texture;

[0009] An eyeball model state control module is used to determine the relative position change between the target locator and the initial virtual eyeball model, determine the change state of the eyeball model based on the relative position change between the target locator and the initial virtual eyeball model, and determine the eyeball model in the change state as the target virtual eyeball model; wherein, the target locator is located in the normal direction of the initial virtual eyeball model.

[0010] Thirdly, the present invention provides an electronic device including a processor and a memory, the memory storing computer-executable instructions executable by the processor, the processor executing the computer-executable instructions to implement the state control method of the virtual eyeball model described in any of the foregoing embodiments.

[0011] Fourthly, the present invention provides a computer-readable storage medium storing computer-executable instructions, which, when invoked and executed by a processor, cause the processor to implement the state control method for the virtual eyeball model described in any of the foregoing embodiments.

[0012] The virtual eyeball model state control method, device, and electronic device provided in this application determine the changing state of the eyeball model by the relative position change between a target locator and the initial eyeball model. By controlling the position of the target locator, the changing state of the eyeball model can be controlled accordingly, resulting in the final eyeball model. Furthermore, the combined eyeball texture map, which combines eye socket textures and eyeball textures, reduces the difficulty of texture drawing, thereby reducing the difficulty of constructing the eyeball model and improving the efficiency of eyeball model construction. This method only requires controlling the target locator to control the changing state of the eyeball model, improving state control efficiency while reducing game resource consumption. Attached Figure Description

[0013] To more clearly illustrate the technical solutions in the specific embodiments of this application or the prior art, the drawings used in the description of the specific embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this application. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.

[0014] Figure 1 A flowchart illustrating a state control method for a virtual eyeball model provided in this application embodiment;

[0015] Figure 2 This is a schematic diagram of an eyeball composite texture provided in an embodiment of this application;

[0016] Figure 3 A structural diagram of a state control device for a virtual eyeball model provided in an embodiment of this application;

[0017] Figure 4 This is a structural diagram of an electronic device provided in an embodiment of this application. Detailed Implementation

[0018] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. The components of the embodiments of this application described and shown in the accompanying drawings can generally be arranged and designed in various different configurations.

[0019] Therefore, the following detailed description of the embodiments of this application provided in the accompanying drawings is not intended to limit the scope of the claimed application, but merely to illustrate selected embodiments of the application. All other embodiments obtained by those skilled in the art based on the embodiments of this application without inventive effort are within the scope of protection of this application.

[0020] It should be noted that similar labels and letters in the following figures indicate similar items. Therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures.

[0021] UV mapping is the process of translating a 3D surface with volume and shape onto a flat 2D texture image. One way to visualize this process is to think of an object wrapped as a gift. UV mapping is analogous to carefully unfolding and flattening the wrapping paper (similar to a globe map with the same constraints as UV mapping).

[0022] In traditional CG asset eye creation, high-precision eye models are typically made to simulate the effect of human eyes through meticulous detail, and numerous complex controllers are used to control the movement and scaling of the eye. However, games often do not require highly precise eye models, as high-precision models can easily consume excessive resources, causing game lag and performance issues. Therefore, this application provides a virtual eye model state control method, device, and electronic device that can improve state control efficiency while better controlling game resource consumption.

[0023] The embodiments of this application are applied to Digital Content Creation (DCC) software, used to realize two-dimensional, three-dimensional, dynamic, and image editing functions when creating virtual eyeball models.

[0024] This application provides a method for state control of a virtual eyeball model; see [link to relevant documentation]. Figure 1 As shown, the method mainly includes the following steps S110 to S130:

[0025] Step S110: Bake the eyeball composite texture onto the eye material ball to obtain the initial virtual eyeball model.

[0026] The aforementioned eyeball composite texture includes an eye socket texture and an eyeball texture. The eye socket texture can be a square white texture of a preset size, and the eyeball texture is a black circular texture. The eye socket texture and eyeball texture are grouped together in DCC software to obtain the combined eyeball composite texture. See [link to documentation]. Figure 2 As shown in the diagram, in the grouped eyeball composite map, the eyeball map is a subclass of the orbital map; that is, the orbital map is the class, and the eyeball map is a subclass contained within the orbital map. In this case, when controlling the orbital map, since the eyeball map is a subclass of the orbital map, controlling only the orbital map can achieve overall control of the orbit and the eyeball.

[0027] Optionally, the shape of the eye socket texture can be selected from square, but other shapes such as rectangle, oval, and circle can also be chosen. The color of the eye socket texture, in addition to white, can also be light gray, light yellow, light red, or gradient colors (e.g., light red near the edge of the eye socket, white closer to the eyeball). The shape of the eyeball texture can also be selected from oval, circular (outer ring representing the eyeball outline, inner ring representing the pupil outline), etc. The color of the eyeball texture, in addition to black, can also be blue, brown, gray, tan, etc.

[0028] The shapes and colors of the eye socket and eyeball textures described above are for illustrative purposes only. In practical applications, adjustments can be made according to actual needs.

[0029] The aforementioned eye map can be a single map or a composite map resulting from combining two maps. When it's a single map, the situation described above applies. When it's a composite map resulting from combining two maps, one map can be used as the eye background, and the other as the pupil. These are then combined, with the pupil becoming a subclass of the entire eye map. In this case, the entire eye map corresponds to the main class, and the pupil corresponds to the subclass. By controlling the entire eye map, both the eye background and the pupil can be controlled. Furthermore, the subclass can also be controlled independently, meaning the pupil's state changes can also be controlled separately.

[0030] After obtaining the aforementioned eyeball composite texture, an eye material sphere can be created. By baking the eyeball composite texture onto the eye material sphere, an initial virtual eyeball model can be obtained. This application embodiment mainly relates to the rotation and scaling control of the eyeball model; therefore, the baking operation is not specifically described. In practical applications, appropriate texture baking operations can be performed according to the application environment.

[0031] Step S120: Determine the relative position change between the target locator and the initial virtual eyeball model; determine the change state of the eyeball model based on the relative position change between the target locator and the initial virtual eyeball model; and determine the eyeball model in the change state as the target virtual eyeball model; wherein, the target locator is located in the normal direction of the initial virtual eyeball model.

[0032] The aforementioned target locator is a controller used to control the rotation and scaling of the initial virtual eyeball model through changes in its own position. The relative positional relationship between the target locator and the initial virtual eyeball model is determined accordingly based on the movement state of the target locator. In one embodiment, the relative positional relationship between the target locator and the initial virtual eyeball model may include at least: 1) the offset of the target locator relative to the normal direction of the initial virtual eyeball model; 2) the relative distance between the target locator and the initial virtual eyeball model along the normal direction.

[0033] In one implementation, the changing state of the eye model can include the rotation and scaling of the eye model. The rotation of the eye model can be controlled by the offset of the target locator, and the scaling of the eye model can be controlled by the relative distance between the target locator and the initial virtual eye model.

[0034] Since the initial virtual eyeball model is a sphere, it includes multiple normals. The target locator can be preset with an initial position, which is the direction of the normals of the initial virtual eyeball. For example, the initial position of the initial virtual eyeball model can be preset to the normal direction corresponding to the center of the eyeball texture, or it can be the normal direction corresponding to a preset position of the eyeball texture or eye socket texture.

[0035] This application's embodiments determine the changing state of the eyeball model by monitoring the relative positional changes between the target locator and the initial eyeball model. By controlling the position of the target locator, the changing state of the eyeball model can be controlled accordingly, resulting in the final eyeball model. Furthermore, the combined eyeball texture map, achieved by combining the orbital texture map and the eyeball texture map, reduces the difficulty of texture rendering, thereby reducing the difficulty of constructing the eyeball model and improving its efficiency. This method allows control of the eyeball model's changing state solely by controlling the target locator, improving state control efficiency while reducing game resource consumption.

[0036] The changing states of the aforementioned eye model can include at least the following two main states: 1) eye model rotation, 2) eye model scaling. In order to achieve the effect of eye model rotation and scaling in the game, the specific implementation details are explained in detail below.

[0037] The target locator is located along the normal direction of the initial virtual eyeball model, including the first normal direction. This first normal direction can be preset. Preferably, the first normal direction can be preset to the normal corresponding to the center position of the eyeball for the initial virtual eyeball model. This allows for left and right adjustments based on the center position of the target locator when controlling the eyeball state, providing better reference and improving the ease of controlling the eyeball state. Optionally, the first normal direction can be any normal direction deviating from the center position. This setting can conform to the preferences of artists, thus better aligning with individual operating habits. In practical applications, settings can be selected according to personal preferences.

[0038] In one implementation, determining the relative positional change between the target locator and the initial virtual eye model may include the following steps 1.1) and 1.2):

[0039] Step 1.1): Place the target locator in the first normal direction of the initial virtual eyeball model;

[0040] Step 1.2): When the position of the target locator in the first normal direction of the initial virtual eyeball model changes, determine the relative position change of the moved target locator relative to the initial virtual eyeball model based on the first normal direction.

[0041] The position of the target locator, which is initially located along the first normal direction of the virtual eyeball model, changes. This change can be a deviation from the first normal direction. For example, the initial position of the target locator might be along the normal direction of the eyeball center. When the position of the target locator changes, the changed position becomes the normal direction corresponding to another position away from the eyeball center. By comparing the position of the moved target locator (the new normal direction) with the position of the first normal direction, the relative position change of the moved target locator with the initial virtual eyeball model is determined.

[0042] In one example, if the target locator moves away from the normal in any direction such as up, down, left, or right, then the eye map will shift in the same direction, and the eye model will be in a rotating state.

[0043] The aforementioned normal direction also includes a second normal direction, which is the position of the target locator in the normal direction of the initial virtual eyeball model after the position of the target locator in the first normal direction of the initial virtual eyeball model has changed.

[0044] In one implementation, a change in the position of the target locator along the first normal direction of the initial virtual eye model includes a first position change where the second normal direction of the target locator forms a preset angle with the first normal direction. This preset angle can be determined in response to angle input information or by dragging the initial eye model.

[0045] Regarding step 1.2) above, it may further include the following steps 1.2.1) to 1.2.3):

[0046] Step 1.2.1): When the normal direction of the target locator is adjusted from the first normal direction to the second normal direction of the initial virtual eye model, obtain the second normal direction of the target locator after the first position change. The first position change is the change in the position of the target locator relative to the first normal direction of the initial virtual eye model after it has shifted at a certain angle.

[0047] Step 1.2.2): Determine the offset angle of the target locator based on the angle between the first normal direction and the second normal direction. In one embodiment, when calculating the offset angle of the target locator, it can be directly determined based on the angle between the first normal direction and the second normal direction, or it can be calculated based on the cross product or dot product between the first normal direction and the second normal direction.

[0048] Step 1.2.3): Determine the relative position change of the moved target locator relative to the initial virtual eyeball model based on the offset angle. Once the offset angle of the target locator is determined, this offset angle represents the relative position change of the target locator relative to the initial virtual eyeball model. In other words, the relative position at this time is the target locator rotating according to the offset angle and the offset direction corresponding to the offset angle, so that the eyeball model can offset and move in the same direction and angle as the offset angle.

[0049] Optionally, in addition to determining the relative position change based on the normal direction as described above, step 1.2) can be further determined by steps 1.2.4) to 1.2.6):

[0050] Step 1.2.4): When the target locator is in the first normal direction, a first ray vector is emitted from the position of the initial virtual eyeball model towards the initial position of the target locator. The initial position of the initial virtual eyeball model from which the first ray vector is emitted can be the center of the initial virtual eyeball model, or the edge of the eyeball or the edge of the orbit, but it must satisfy the condition that the position of the emitted ray is on the initial virtual eyeball model in the same direction as the normal direction in which the target locator was located before the position shift. For example, if the target locator was in the first normal direction corresponding to the center of the eyeball before the position shift, then the position of the emitted ray would be the center of the eyeball.

[0051] Step 1.2.5): When the target locator is in the second normal direction, a second ray vector is emitted from the initial position of the virtual eye model towards the current position of the target locator after the movement. The second ray vector is emitted from the same initial position of the initial virtual eye model as the first ray vector was emitted, and the direction of the second ray is the direction pointed to by the target locator after the relative position change.

[0052] Step 1.2.6): Determine the offset angle at which the target locator undergoes its first position change based on the angle between the first ray vector and the second ray vector. The offset angle can be calculated by calculating the cross product of the first ray and the second normal. Alternatively, the dot product of the first ray and the second normal can be calculated, and the offset angle can be determined through transformation.

[0053] Furthermore, after determining the offset angle between the target locator and the initial virtual eyeball model, the change state of the eyeball model is determined based on the relative positional change between the target locator and the initial virtual eyeball model, which may include the following steps 2.1) and 2.2):

[0054] Step 2.1): Determine the rotation angle of the eyeball composite texture based on the offset angle between the target locator and the initial virtual eyeball model. In one implementation, to facilitate control of the eyeball rotation effect via the target locator, the rotation angle of the eyeball composite texture is the same as the offset angle of the target locator, and the offset direction is mirror-symmetrical. That is, when the target locator shifts 20 degrees to the left, the rotation angle displayed by the eyeball composite texture is shifted 20 degrees to the left, while the eyeball texture based on the eyeball model is shifted 20 degrees to the right (i.e., the rotation direction of the eyeball model itself is mirror-symmetrical to the offset direction of the target locator). This mirroring is mainly applicable to left-right related directions; downward rotation only requires adaptive rotation according to the corresponding offset of the target locator.

[0055] Step 2.2) Determine the changing state of the eye model based on the rotation angle of the eye composite map. The offset angle of the target locator can be any direction, so the rotation angle of the eye composite map can also be any angle. For example, if the eye map is flipped upwards by 30 degrees, the changing state of the eye model is the changing state corresponding to the upward flip of the eye (e.g., the white eye state).

[0056] Furthermore, when scaling the eyeball model as a whole, the position of the target locator, which was initially located along the first normal direction of the virtual eyeball model, changes to a second position along the first normal direction. This first normal direction is consistent with the first normal direction described above, and will not be repeated here.

[0057] In the event of a second positional change, the determination of the relative positional change of the moved target locator relative to the initial virtual eyeball model based on the first normal direction can include the following steps 3.1) to 3.2):

[0058] Step 3.1): When the target locator undergoes a second position change along the first normal direction, a third ray vector is emitted from the initial position of the virtual eyeball model towards the current position of the target locator after movement. The position scaling factor of the target locator is determined based on the proportional relationship between the third ray vector and the first ray vector. Assuming that the distance between the target locator and the eyeball before the second position change is La, and the distance between the current position and the eyeball is Lb, the proportional relationship can be determined by calculating the multiple of Lb relative to La, and then the position scaling factor of the target locator can be determined through this proportional relationship.

[0059] Step 3.2) Determine the relative position of the moved target locator with respect to the initial virtual eye model based on the position scaling factor. Optionally, the scaling can be set according to the principle of "nearer is larger, farther is smaller". That is, when the target locator is closer to the eye ball after moving compared to before moving, the state is determined to be magnified, and the magnification factor is the same as the previous one; when the target locator is farther from the eye ball after moving compared to before moving, the state is determined to be reduced, and the reduction factor is the same as the previous one.

[0060] Furthermore, in practical applications, the rotation and scaling of the eye model can be performed sequentially. For example, the eye model can be rotated after scaling or at the scaling position, or it can be scaled at the rotated position after the eye model is rotated. The above two implementation methods can be combined, which will not be elaborated here.

[0061] Once the change in the eye model is determined based on the relative positional change between the target locator and the initial virtual eye model, the scaling type and degree of the eye model can be determined using the positional scaling factor based on the target locator. Scaling types include eye shrinking and eye magnification, and the scaling degree is inversely proportional to the positional scaling factor. For example, when the positional scaling factor decreases from 1 to 0.5, according to the rule of near objects appearing larger and farther objects smaller, the scaling degree can be increased from 1 to 2; when the positional scaling factor is increased by 25%, according to the rule of near objects appearing larger and farther objects smaller, the scaling degree can be reduced by a factor of 4, thus better conforming to the visual effect.

[0062] Furthermore, considering that in actual operation design, operations can be performed for various situations, thereby improving the diversity and flexibility of operations, in an optional implementation, when determining the changing state of the eyeball model, the changing states of the eyeball texture and the eye socket texture can be determined separately.

[0063] For example, the relative position of the eyeball texture can be determined separately to determine the changing state of the eyeball, or the eyeball and eye socket can be calculated simultaneously (i.e., the aforementioned disclosed scheme), or only the eye socket texture can be controlled accordingly, thereby improving the options for operation and enhancing the user experience.

[0064] Furthermore, considering the inherent UV interleaving problem in the DCC software specifications—for example, when the eyeball is moved to the right, if half of the black part of the eyeball crosses the boundary, the missing half will appear on the far left—this application embodiment also provides a solution to eliminate the UV interleaving problem when controlling the changing state of the eyeball model. In one implementation, the first texture map information of the eyeball map and the second texture map information of the eye socket map can be obtained first, the eyeball map can be configured at a preset position of the eye socket map, and the size of the first texture map information can be determined to be no more than a preset proportion of the size of the second texture map information.

[0065] The aforementioned texture information is also known as UV information. When obtaining the first UV information of the eyeball texture and the second UV information of the eye socket texture, after creating the eye material and obtaining the initial virtual eyeball model, a location locator can be created at the origin of the initial virtual eyeball model. This location locator is also known as the aforementioned target locator, and can be a circular controller. Further, in the DCC software, open the Maya Node Editor and create a hidden node, `closestPointOnMesh`. This node cannot be found in the panel; in this embodiment, it is located and created by pressing the Tab key. After obtaining this hidden node, the aforementioned first and second UV information can be calculated.

[0066] The aforementioned preset position can be the center of the eyeball texture map. Alternatively, it can be offset to a certain extent from the center. For ease of processing, the preferred preset position can be the center of the eyeball texture map.

[0067] The aforementioned preset ratio can be 1 / 4, which means that the first UV information of the black eyeball can be set to no more than 1 / 4 of the size of the center of the white texture eye socket. This way, when moving the black eyeball, when it crosses the boundary, there will be no lost part on the other side.

[0068] In summary, the embodiments of this application can generate a virtual eyeball model by creating a circular controller in DCC software and controlling the movement of the circular controller. With this method, only the target locator needs to be controlled to control the changing state of the eyeball model, thereby improving the efficiency of state control and reducing the consumption of game resources.

[0069] Based on the above method embodiments, this application also provides a state control device for a virtual eyeball model, participating in... Figure 3 As shown, the device mainly includes the following parts:

[0070] The texture combination module 310 is used to bake the eyeball combination texture onto the eye material sphere to obtain the initial virtual eyeball model; the eyeball combination texture includes the eye socket texture and the eyeball texture;

[0071] The eye model state control module 320 is used to determine the relative position change between the target locator and the initial virtual eye model, determine the change state of the eye model based on the relative position change between the target locator and the initial virtual eye model, and determine the eye model in the change state as the target virtual eye model; wherein, the target locator is located in the normal direction of the initial virtual eye model.

[0072] The virtual eyeball model state control device provided in this application determines the changing state of the eyeball model by the relative position change between the target locator and the initial eyeball model. By controlling the position of the target locator, the changing state of the eyeball model can be controlled accordingly to obtain the final eyeball model. Furthermore, the combined eyeball texture map, which combines the eye socket texture map and the eyeball texture map, reduces the difficulty of texture drawing, thereby reducing the difficulty of constructing the eyeball model and improving the efficiency of eyeball model construction. With this method, only the target locator needs to be controlled to control the changing state of the eyeball model, improving state control efficiency while reducing the consumption of game resources.

[0073] In one feasible implementation, the normal direction includes a first normal direction, and the aforementioned eyeball model state control module 320 is further configured to:

[0074] Place the target locator in the first normal direction of the initial virtual eyeball model;

[0075] When the position of the target locator in the first normal direction of the initial virtual eyeball model changes, the relative position change of the moved target locator with respect to the initial virtual eyeball model is determined based on the first normal direction.

[0076] In one feasible implementation, the normal direction includes a second normal direction, and the change in the position of the target locator located in the first normal direction of the initial virtual eyeball model includes a first position change in which the second normal direction of the target locator is at a preset angle to the first normal direction;

[0077] The aforementioned eyeball model state control module 320 is also used for:

[0078] When the normal direction of the target locator is adjusted from the first normal direction to the second normal direction of the initial virtual eyeball model, the second normal direction of the target locator after the first position change is obtained;

[0079] The offset angle of the target locator is determined based on the angle between the first normal direction and the second normal direction.

[0080] The relative position change of the target locator with respect to the initial virtual eyeball model is determined based on the offset angle.

[0081] In one feasible implementation, the above-mentioned eyeball model state control module 320 is further used for:

[0082] When the target locator is in the first normal direction, a first ray vector is emitted from the position of the initial virtual eyeball model to the initial position of the target locator;

[0083] When the target locator is in the second normal direction, a second ray vector is emitted from the position of the initial virtual eyeball model to the current position of the target locator after it has moved;

[0084] The offset angle at which the target locator undergoes its first position change is determined based on the angle between the first ray vector and the second ray vector.

[0085] In one feasible implementation, the above-mentioned eyeball model state control module 320 is further used for:

[0086] The rotation angle of the eyeball composite texture is determined based on the offset angle between the target locator and the initial virtual eyeball model.

[0087] The changing state of the eye model is determined based on the rotation angle of the eyeball combination map.

[0088] In one feasible implementation, the change in position of the target locator in the first normal direction of the initial virtual eyeball model includes a second position change along the first normal direction; the aforementioned eyeball model state control module 320 is further configured to:

[0089] When the target locator undergoes a second position change along the first normal direction, a third ray vector is emitted from the position of the initial virtual eyeball model to the current position of the target locator after it has moved. The position scaling factor of the target locator is determined based on the proportional relationship between the third ray vector and the first ray vector.

[0090] The relative position change of the target locator with respect to the initial virtual eyeball model is determined based on the position scaling factor.

[0091] In one feasible implementation, the above-mentioned eyeball model state control module 320 is further used for:

[0092] The scaling type and degree of the eye model are determined based on the position scaling factor of the target locator.

[0093] In one feasible implementation, the eye map in the eye combination map is a subclass of the orbital map, and the aforementioned eye model state control module 320 is further used for:

[0094] Determine the changes in the eyeball texture and the eye socket texture respectively.

[0095] In one feasible embodiment, the above-described device further includes an anti-texture interlacing module, used for:

[0096] Obtain the first texture map information of the eyeball map and the second texture map information of the eye socket map;

[0097] The eyeball texture is positioned at a preset location on the eye socket texture, and the size of the first texture texture information is determined to be no more than the size of the second texture texture information at a preset ratio.

[0098] The virtual eyeball model state control device provided in this application embodiment has the same implementation principle and technical effect as the aforementioned method embodiment. For the sake of brevity, any parts of the virtual eyeball model state control device embodiment not mentioned in the previous embodiment can be referred to the corresponding content in the aforementioned virtual eyeball model state control method embodiment.

[0099] This application also provides an electronic device, such as... Figure 4 The diagram shows the structure of the electronic device 100, which includes a processor 41 and a memory 40. The memory 40 stores computer-executable instructions that can be executed by the processor 41. The processor 41 executes the computer-executable instructions to implement any of the above-mentioned virtual eyeball model state control methods.

[0100] exist Figure 4 In the illustrated embodiment, the electronic device further includes a bus 42 and a communication interface 43, wherein the processor 41, the communication interface 43, and the memory 40 are connected via the bus 42.

[0101] The memory 40 may include high-speed random access memory (RAM) or non-volatile memory, such as at least one disk storage device. Communication between this system network element and at least one other network element is achieved through at least one communication interface 43 (which can be wired or wireless), such as the Internet, wide area network, local area network, metropolitan area network, etc. The bus 42 may be an ISA (Industry Standard Architecture) bus, a PCI (Peripheral Component Interconnect) bus, or an EISA (Extended Industry Standard Architecture) bus, etc. The bus 42 can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 4 The symbol is represented by a single double-headed arrow, but this does not mean that there is only one bus or one type of bus.

[0102] Processor 41 may be an integrated circuit chip with signal processing capabilities. In implementation, each step of the above method can be completed by the integrated logic circuitry in the hardware of processor 41 or by instructions in software form. Processor 41 can be a general-purpose processor, including a Central Processing Unit (CPU), a Network Processor (NP), etc.; it can also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field-Programmable Gate Array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the method disclosed in the embodiments of this application can be directly implemented by a hardware decoding processor, or implemented by a combination of hardware and software modules in the decoding processor. The software modules can reside in random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, registers, or other mature storage media in the art. The storage medium is located in the memory. The processor 41 reads the information in the memory and, in conjunction with its hardware, completes the steps of the state control method for the virtual eyeball model in the aforementioned embodiment.

[0103] This application also provides a computer-readable storage medium storing computer-executable instructions. When these computer-executable instructions are called and executed by a processor, they cause the processor to implement the aforementioned virtual eyeball model state control method. For specific implementation details, please refer to the foregoing method embodiments, which will not be repeated here.

[0104] The computer program product of the virtual eyeball model state control method, device and electronic device provided in the embodiments of this application includes a computer-readable storage medium storing program code. The instructions included in the program code can be used to execute the methods described in the preceding method embodiments. For specific implementation, please refer to the method embodiments, which will not be repeated here.

[0105] Unless otherwise specifically stated, the relative steps, numerical expressions, and values ​​of the components and steps described in these embodiments do not limit the scope of this application.

[0106] If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a processor-executable, non-volatile, computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0107] In the description of this application, it should be noted that the terms "center," "upper," "lower," "left," "right," "vertical," "horizontal," "inner," and "outer," etc., indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings, or the orientation or positional relationship commonly used when the product of the invention is in use. They are used only for the convenience of describing this application and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, they should not be construed as limitations on this application. In addition, the terms "first," "second," and "third," etc., are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.

[0108] Furthermore, terms such as "horizontal," "vertical," and "sag" do not imply that components must be absolutely horizontal or suspended, but rather that they can be slightly tilted. For example, "horizontal" simply means that its direction is more horizontal relative to "vertical," and does not mean that the structure must be completely horizontal, but can be slightly tilted.

[0109] In the description of this application, it should also be noted that, unless otherwise expressly specified and limited, the terms "set up," "install," "connect," and "link" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; and they can refer to the internal connection of two components. Those skilled in the art can understand the specific meaning of the above terms in this application based on the specific circumstances.

[0110] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features therein. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of this application.

Claims

1. A method for state control of a virtual eyeball model, characterized in that, The method includes: The eyeball composite texture is baked onto the eye material sphere to obtain the initial virtual eyeball model; the eyeball composite texture includes an eye socket texture and an eyeball texture; The relative positional change between the target locator and the initial virtual eyeball model is determined. Based on the relative positional change between the target locator and the initial virtual eyeball model, the changing state of the eyeball model is determined, and the eyeball model in the changing state is identified as the target virtual eyeball model. The target locator is located in the normal direction of the initial virtual eyeball model. The target locator is a controller used to control the rotation and scaling of the initial virtual eyeball through its own positional change. The relative positional relationship between the target locator and the initial virtual eyeball model is determined accordingly through the movement state of the target locator.

2. The state control method for the virtual eyeball model according to claim 1, characterized in that, The normal direction includes a first normal direction, and determining the relative positional change between the target locator and the initial virtual eyeball model includes: The target locator is placed in the first normal direction of the initial virtual eyeball model; When the position of the target locator in the first normal direction of the initial virtual eyeball model changes, the relative position change of the moved target locator with respect to the initial virtual eyeball model is determined based on the first normal direction.

3. The state control method for the virtual eyeball model according to claim 2, characterized in that, The normal direction includes a second normal direction. The change in the position of the target locator located in the first normal direction of the initial virtual eyeball model includes a first position change in which the second normal direction of the target locator is at a preset angle to the first normal direction. The relative position change of the target locator with respect to the initial virtual eyeball model after movement is determined based on the first normal direction, including: When the normal direction of the target locator is adjusted from the first normal direction to the second normal direction of the initial virtual eyeball model, the second normal direction of the target locator after the first position change is obtained; The offset angle of the target locator is determined based on the angle between the first normal direction and the second normal direction; The relative position change of the target locator with respect to the initial virtual eyeball model is determined based on the offset angle.

4. The state control method for the virtual eyeball model according to claim 3, characterized in that, Determining the offset angle of the target locator based on the angle between the first normal direction and the second normal direction includes: When the target locator is in the first normal direction, a first ray vector is emitted from the position of the initial virtual eyeball model to the initial position of the target locator; When the target locator is in the second normal direction, a second ray vector is emitted from the position of the initial virtual eyeball model to the current position of the target locator after it has moved; The offset angle at which the target locator undergoes a first position change is determined based on the angle between the first ray vector and the second ray vector.

5. The state control method for a virtual eyeball model according to claim 3 or 4, characterized in that, Determining the changing state of the eye model based on the relative positional change between the target locator and the initial virtual eye model includes: The rotation angle of the eyeball composite texture is determined based on the offset angle between the target locator and the initial virtual eyeball model; The changing state of the eyeball model is determined based on the rotation angle of the eyeball composite texture.

6. The state control method for the virtual eyeball model according to claim 4, characterized in that, The position of the target locator located in the first normal direction of the initial virtual eyeball model changes, including a second position change along the first normal direction; The relative position change of the target locator with respect to the initial virtual eyeball model after movement is determined based on the first normal direction, including: When the target locator undergoes a second position change along the first normal direction, a third ray vector is emitted from the position of the initial virtual eyeball model to the current position of the target locator after it has moved. The position scaling factor of the target locator is determined based on the proportional relationship between the third ray vector and the first ray vector. The relative position change of the target locator relative to the initial virtual eyeball model after movement is determined based on the position scaling factor.

7. The state control method for the virtual eyeball model according to claim 1, characterized in that, Determining the changing state of the eye model based on the relative positional change between the target locator and the initial virtual eye model includes: The scaling type and degree of the eye model are determined based on the position scaling factor of the target locator.

8. The state control method for the virtual eyeball model according to claim 1, characterized in that, The eyeball texture in the combined eyeball texture map is a subclass of the orbital texture map, and determines the changing state of the eyeball model, including: The changes in the eyeball texture and the orbital texture are determined respectively.

9. The state control method for a virtual eyeball model according to claim 8, characterized in that, The method further includes: Obtain the first texture map information of the eyeball map and the second texture map information of the eye socket map; The eyeball texture is positioned at a preset location on the eye socket texture, and the first texture texture information is determined to be the size of the second texture texture information, which does not exceed a preset ratio.

10. A state control device for a virtual eyeball model, characterized in that, The device includes: The texture combination module is used to bake the eyeball combination texture onto the eye material sphere to obtain an initial virtual eyeball model; the eyeball combination texture includes an eye socket texture and an eyeball texture; An eyeball model state control module is used to determine the relative position change between the target locator and the initial virtual eyeball model, determine the changing state of the eyeball model based on the relative position change between the target locator and the initial virtual eyeball model, and identify the eyeball model in the changing state as the target virtual eyeball model; wherein, the target locator is located in the normal direction of the initial virtual eyeball model; the target locator is a controller used to control the rotation and scaling of the initial virtual eyeball through its own position change state; the relative positional relationship between the target locator and the initial virtual eyeball model is determined accordingly through the movement state of the target locator.

11. An electronic device, characterized in that, The device includes a processor and a memory, the memory storing computer-executable instructions that can be executed by the processor, the processor executing the computer-executable instructions to implement the state control method for the virtual eyeball model according to any one of claims 1 to 9.

12. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer-executable instructions, which, when invoked and executed by a processor, cause the processor to implement the state control method for the virtual eyeball model according to any one of claims 1 to 9.