Image generation program, recording medium, and image generation method
The image generation program addresses high calculation loads in cloth simulations by constraining and updating control point positions to prevent cloth overlap, enhancing simulation efficiency and realism.
Patent Information
- Application Number
- JP2021179087
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Filing Date
- 2021-11-01
- Publication Date
- 2025-09-11
- Estimated Expiration
- 2041-11-01
AI Technical Summary
Existing cloth simulation technologies face high calculation loads due to collision detection between overlapping cloth pieces, leading to a punch-through phenomenon.
An image generation program that calculates target positions for control points on overlapping cloth objects, sets planes based on these positions, constrains the positions to prevent overlap, and updates them to generate images, reducing calculation load while preventing cloth penetration.
The program effectively suppresses the punch-through phenomenon between cloth objects while minimizing the increase in calculation load, allowing for natural movement and realistic cloth simulations.
Smart Images

Figure 0007737868000001 
Figure 0007737868000002 
Figure 0007737868000003
Abstract
Description
[Technical Field]
[0001] The present invention relates to an image generating program, a recording medium, and an image generating method. [Background technology]
[0002] Conventionally, methods for simulating deformable objects using spring models have been known. For example, Patent Document 1 describes a cloth simulation technology that determines the shape of a flexible object such as cloth, clothing, or hair using a model in which the vertices of the polygons are virtual mass points and adjacent mass points are connected by virtual springs. [Prior art documents] [Patent documents]
[0003] [Patent Document 1] Japanese Patent Application Laid-Open No. 2005-99952 Summary of the Invention [Problem to be solved by the invention]
[0004] When using the above-mentioned cloth simulation technology to represent, for example, the clothing worn by a character's body, there is a possibility that pieces of cloth may interfere with each other due to the recent increase in precision in character design. In order to prevent the phenomenon of pieces of cloth penetrating each other, it is possible to perform collision detection processing between pieces of cloth (so-called collision), but this poses the problem of an extremely high calculation load.
[0005] The present invention has been made in consideration of such problems, and aims to suppress an increase in the calculation load while: Object An object of the present invention is to provide an image generation program, a recording medium, and an image generation method that can suppress the occurrence of the punch-through phenomenon between two images. [Means for solving the problem]
[0006] In order to achieve the above-mentioned object, the image generation program of the present invention causes an information processing device to function as a target position calculation processing unit that calculates target positions of a first control point set on the first object and a plurality of second control points set on the second object through a predetermined simulation process for deforming each of a first object and a second object that have at least a portion overlapping in the viewpoint direction; a plane setting processing unit that sets a plane based on the target positions of some of the plurality of second control points that correspond to the first control point to be processed; a first target position constraint processing unit that constrains the target positions of the first control points so that they do not exceed the plane; a control point update processing unit that updates the positions of the first control points and the second control points so that they approach the target positions; and an image generation processing unit that generates images of the first object and the second object based on the updated positions of the first control points and the second control points.
[0007] In order to achieve the above object, a recording medium of the present invention is a recording medium that stores the image generation program and is readable by an information processing device.
[0008] In order to achieve the above-mentioned object, the image generation method of the present invention is an image generation method executed by an information processing device, and includes the steps of: calculating target positions of a first control point set on the first object and a plurality of second control points set on the second object by a predetermined simulation process for deforming each of a first object and a second object that have at least a portion overlapping in the viewing direction; setting a plane based on the target positions of some of the second control points that correspond to the first control points to be processed among the plurality of second control points; constraining the target positions of the first control points so that they do not exceed the plane; updating the positions of the first control points and the second control points so that they approach the target positions; and generating images of the first object and the second object based on the updated positions of the first control points and the second control points. [Effects of the Invention]
[0009] According to the image generation program of the present invention, the increase in the calculation load is suppressed, Object This can prevent the occurrence of the punch-through phenomenon. [Brief explanation of the drawings]
[0010] [Figure 1] 1 is a system configuration diagram showing an example of the overall configuration of a game system common to the first and second embodiments. [Figure 2] 1 is a block diagram illustrating an example of a functional configuration of an information processing device according to a first embodiment. [Figure 3] FIG. 10 is a front view showing an example of a Japanese clothing object worn by a character. [Figure 4] FIG. 1 is a diagram showing an example of a plurality of rectangles that form a three-dimensional object that resembles a square piece of cloth, and a diagram showing an example of a mechanical model assumed when performing calculations required to draw the three-dimensional object. [Figure 5] 10 is a diagram illustrating an example of a configuration of control points for a sleeve portion of a Japanese clothing object. [Figure 6] 10 is a conceptual diagram showing an example of a control point configuration in a cross section perpendicular to the axis of symmetry of the sleeve portion, for explaining pairs set by the pair setting processing unit. FIG. [Figure 7] FIG. 10 is a conceptual diagram illustrating an example of a control point configuration by extracting a part of the lower end side of a sleeve, for explaining pairs set by the pair setting processing unit. [Figure 8] 10A and 10B are diagrams for explaining an example of a constraint process performed by a first target position constraint processing unit. [Figure 9] 4 is a flowchart illustrating an example of a processing procedure executed by the information processing device according to the first embodiment. [Figure 10] FIG. 10 is a block diagram illustrating an example of a functional configuration of an information processing device according to a second embodiment. [Figure 11] 10 is a diagram illustrating an example of a configuration of control points at the hem of a Japanese clothing object. FIG. [Figure 12]10 is a diagram illustrating an example of a control point group located on a horizontal cross section, which is set by a control point group setting processing unit. FIG. [Figure 13] 10 is a diagram illustrating an example of a reference line set by a reference line setting processing unit. FIG. [Figure 14] 10A and 10B are diagrams illustrating an example of a separation distance and a length distance set by a distance setting processing unit. [Figure 15] 10 is a diagram illustrating an example of a predetermined shape set by a distance setting processing unit. FIG. [Figure 16] 10A and 10B are diagrams for explaining an example of a constraint process performed by a first target position constraint processing unit. [Figure 17] 10 is a flowchart illustrating an example of a processing procedure executed by an information processing device according to a second embodiment. [Figure 18] FIG. 2 is a block diagram illustrating an example of a hardware configuration of an information processing device. DETAILED DESCRIPTION OF THE INVENTION
[0011] Hereinafter, embodiments of the present invention will be described with reference to the drawings. Note that in each of the embodiments described below, the present invention will be described as being applied to a game, that is, a game is provided by executing an image generation program and an image generation method of the present invention on an information processing device, but the application is not limited to games.
[0012] <0. Overall structure of the game system> An example of the overall configuration of a game system 1 common to all embodiments will be described using Fig. 1. As shown in Fig. 1, the game system 1 includes an information processing device 3, a game controller 5, and a display device 7. The game controller 5 and the display device 7 are connected to the information processing device 3 so as to be able to communicate with each other via wire or wirelessly.
[0013] The information processing device 3 is, for example, a stationary game console. However, it is not limited to this and may be, for example, a portable game console that is integrated with an input unit, a display unit, etc. In addition to game consoles, it may also be, for example, a computer manufactured and sold, such as a server computer, a desktop computer, a notebook computer, a tablet computer, etc., or a telephone manufactured and sold, such as a smartphone, a mobile phone, a phablet, etc.
[0014] A player performs various operation inputs using a game controller 5. In the example shown in Fig. 1, the game controller 5 has, for example, a cross key 9, a plurality of buttons 10, a joystick 11, a touchpad 12, and the like.
[0015] 1. First Embodiment First, we will explain the first embodiment of the present invention. In the first embodiment, pairs are set for each control point of two overlapping cloth objects in a clothing object worn by a character, and constraint processing is performed on each pair to prevent the cloth objects from penetrating each other.
[0016] (1-1. Functional configuration of information processing device) An example of the functional configuration of the information processing device 3 according to the first embodiment will be described with reference to FIG. 2 and FIGS.
[0017] As shown in FIG. 2, the information processing device 3 has a target position calculation processing unit 13, a symmetry axis setting processing unit 15, a pair setting processing unit 17, a first normal calculation processing unit 19, a first offset setting processing unit 21, a plane setting processing unit 23, a first target position constraint processing unit 25, a control point update processing unit 27, and an image generation processing unit 29.
[0018] The target position calculation processing unit 13 calculates the target positions of a plurality of first control points set on the first cloth object and a plurality of second control points set on the second cloth object by a predetermined simulation process for deforming each of a first cloth object (an example of a first object) and a second cloth object (an example of a second object) that overlap at least partially in the viewpoint direction.
[0019] The "viewpoint direction" refers to the direction in which the viewpoint faces in the game image, i.e., the direction in which the virtual camera for generating the image faces. "A first cloth object and a second cloth object that at least partially overlap in the viewpoint direction" refer to two cloth objects that are drawn overlapping at least partially in the game image. For example, as shown in FIG. 3, when a character 31 is wearing a kimono object 33, these are two cloth objects that are drawn overlapping at least partially and arranged close to each other, such as a front cloth object and a back cloth object that are drawn overlapping at the hanging portion 33b of a sleeve 33a, or an outer cloth object and an inner cloth object that are drawn overlapping at the collar 33d of a hem 33c, which is the portion below the obi (sash) of the kimono object 33.
[0020] The "predetermined simulation process" is not particularly limited as long as it is a process capable of simulating the deformation of a cloth object, but a so-called cloth (cloth) simulation process capable of simulating the deformation of a cloth object is preferable. Specifically, a simulation process that performs mechanical calculations using an elastic spring model may be used. FIG. 4(a) is an explanatory diagram showing an example of a plurality of rectangles that form a three-dimensional object that resembles, for example, a square piece of cloth, and FIG. 4(b) is an explanatory diagram showing an example of a mechanical model assumed when performing calculations required to render the three-dimensional object shown in FIG. 4(a).
[0021] When performing the calculations required to render the three-dimensional object shown in Figure 4(a), a spring model is assumed in which the vertices of each rectangle are mass points, adjacent mass points are connected by springs, and each mass point receives force from adjacent mass points (two or three adjacent mass points for mass points at the edge of a piece of cloth) via these springs, as shown in Figure 4(b). With this spring model, for example, when rendering the movement of pulling the edge of a piece of cloth, it is possible to calculate the force acting on the mass point corresponding to the edge of the cloth, the force acting on the mass point adjacent to that mass point, and the force acting on the mass point adjacent to that mass point, making it possible to calculate the change in shape of a three-dimensional object that resembles cloth.
[0022] Additionally, position-based physical simulation (PBD: Position Based Dynamics, paper "Position Based Dynamics", http: / / matthias-mueller-fischer.ch / publications / posBasedDyn.pdf) can be used as a cloth simulation process. PBD is a method of performing physics calculations without velocity information, using the current position, the previous position, and the frame update time Δt (for example, 16.67 ms at 60 fps).
[0023] In addition to the above simulation processes, various other simulation processes can be adopted as long as they are methods that can simulate cloth-like movement. For convenience of explanation, in this specification, the predetermined simulation process executed by target position calculation processing unit 13 will also be referred to as "cloth simulation," and the target position calculated by target position calculation processing unit 13 will also be referred to as "target position by cloth simulation."
[0024] Returning to Figure 2, the symmetry axis setting processor 15 sets an axis of symmetry at the portion where the first cloth object and the second cloth object are connected. For example, if the first cloth object and the second cloth object are the front and back cloth objects of the hanging portion 33b of the sleeve portion 33a of the kimono object 33, the "connecting portion" refers to the fold at the bottom end of the hanging portion 33b, and the "axis of symmetry" is the axis corresponding to the fold. Note that the axis of symmetry does not necessarily have to be a straight line, and may be a broken line or a curved line.
[0025] FIG. 5 shows an example of a symmetry axis set by the symmetry axis setting processor 15. In the example shown in FIG. 5, a plurality of control points 39 are set for the sleeve portion 33a of the kimono object 33. The control points 39 are arranged, for example, in a grid pattern. A symmetry axis 41 is set to connect the plurality of control points 39 located at the fold at the bottom end of the hanging portion 33b of the sleeve portion 33a, where a first cloth object 35, which is the front cloth object, is connected to a second cloth object 37, which is the back cloth object. For ease of explanation, in this specification, of the plurality of control points 39 set for the kimono object 33, the control point 39 set for the first cloth object 35 will be referred to as a "first control point 39a," and the control point 39 set for the second cloth object 37 will be referred to as a "second control point 39b." When there is no need to distinguish between these, they will simply be referred to as "control points 39."
[0026] Returning to FIG. 2, the pair setting processor 17 sets, as a pair, a first control point 39a to be processed and a second control point 39b located in an area that is line-symmetrical with respect to the first control point 39a across the symmetry axis 41. "Line symmetry" means that when the first cloth object 35 and the second cloth object 37 are laid out on a plane, their positions are line-symmetrical in control point units (the number of control points) across the symmetry axis 41. The "line-symmetrical area" does not refer to a pinpoint position that is line-symmetrical, but rather to an area having a predetermined size that includes the line-symmetrical position. Therefore, the number of second control points 39b located in the line-symmetrical area is not limited to one, and may be multiple. For example, the pair setting processing unit 17 may set a pair of one first control point 39a to be processed and one second control point 39b that is located in a position that is linearly symmetrical to the first control point 39a across the axis of symmetry 41, and may also set each of the multiple second control points 39b that are located around the one second control point 39b that is located in the linearly symmetrical position as a pair.
[0027] 6 and 7 show examples of pairs set by the pair setting processor 17. Note that FIG. 6 is a cross-sectional view illustrating an example of a control point configuration in a cross section perpendicular to the symmetry axis 41 of the sleeve portion 33a, and FIG. 7 is a perspective view illustrating an example of a control point configuration by extracting a portion of the lower end of the sleeve portion 33a. In the example shown in FIGS. 6 and 7, a single first control point 39a (shown with dotted hatching) to be processed is paired with a single second control point 39b (shown with horizontal striped hatching) that is located at a position that is line-symmetrical with respect to the symmetry axis 41, and four second control points 39b (shown with vertical striped hatching) that are located above, below, left, and right of the single second control point 39b located at the line-symmetrical position. In other words, a total of five pairs are set with respect to the single first control point 39a to be processed. Note that in FIGS. 6 and 7, to clearly identify the pairs, the two control points that make up each pair are connected by a connecting line 43.
[0028] Since the first control point 39a and the second control point 39b paired in this way are located at roughly opposite positions, the occurrence of punch-through between the cloths can be efficiently suppressed by performing the constraint processing described below on each pair. The number of second control points 39b paired with one first control point 39a to be processed may be one, or may be more than the above five (for example, 13, 25, etc.). Increasing the number increases the calculation load, but the range over which the constraint processing is performed expands, thereby improving the effectiveness of suppressing the punch-through phenomenon. In this embodiment, by using the above five points, it is possible to suppress both an increase in the calculation load and the occurrence of the punch-through phenomenon.
[0029] Returning to FIG. 2, the first normal calculation processor 19 calculates a normal at the target position of the second control point 39b constituting the pair to be processed based on the positional relationship with the adjacent second control point 39b. When multiple (e.g., five) pairs are set for one first control point 39a, the first normal calculation processor 19 calculates a normal for each second control point 39b in each pair. The method for calculating the normal is not particularly limited. For example, the normal of the second control point 39b to be processed may be calculated by calculating the cross product of two vectors connecting the target position of the second control point 39b to be processed and each of the target positions of two second control points 39b adjacent to the second control point 39b. FIG. 8 shows an example of a normal N1 set by the first normal calculation processor 19.
[0030] Returning to FIG. 2, the first offset setting processor 21 sets a first offset distance, which is the distance between the target position of the second control point 39b constituting the pair to be processed by the cloth simulation and the normal N1 direction to the plane, which will be described later. When multiple pairs (e.g., five pairs) are set for one first control point 39a, the first offset setting processor 21 sets a first offset distance for each of the second control points 39b in the pair. FIG. 8 shows an example of the first offset distance Offset1 set by the first offset setting processor 21. Note that the offset distance does not necessarily have to be set.
[0031] Returning to FIG. 2, the plane setting processing unit 23 sets a plane based on the target positions of some of the second control points 39b among the multiple second control points 39b that correspond to the first control point 39a to be processed. The "some of the second control points 39b" refers to, for example, the second control points 39b that form pairs with the first control point 39a to be processed. When multiple pairs (e.g., five pairs) are set for one first control point 39a, the plane setting processing unit 23 sets a plane for each of the second control points 39b in the pair. Specifically, the plane setting processing unit 23 sets a plane so that it is perpendicular to the normal N1 at the target position of the second control point 39b that forms the pair to be processed. Furthermore, when the first offset distance is set by the first offset setting processing unit 21, the plane setting processing unit 23 sets the plane at a position offset by the first offset distance in the direction of the normal N1 from the target position of the second control point 39b.
[0032] Fig. 8 shows an example of a plane set by the plane setting processing unit 23. As shown in Fig. 8, a plane 45 is set at a position offset by a first offset distance Offset1 in the direction of the normal line N1 from the target position of the second control point 39b so as to be perpendicular to the normal line N1.
[0033] 2, the first target position constraint processing unit 25 constrains the target position of the first control point 39a to be processed so that it does not exceed a plane 45 that is set based on the target positions of the second control points 39b that make up the pair. Furthermore, when multiple pairs (for example, five pairs) are set for one first control point 39a to be processed, the first target position constraint processing unit 25 executes the above-described constraint processing for each pair, and constrains the target position of the first control point 39a to be processed so that it does not exceed each of the multiple planes 45 that are set based on the target positions of the second control points 39b that make up each pair.
[0034] Fig. 8 shows an example of the constraint processing by the first target position constraint processing unit 25. As shown in Fig. 8, the target position of the first control point 39a is constrained (limited) to be located in an area closer to the first control point 39a than the plane 45 so as not to reach an area closer to the second control point 39b than the plane 45.
[0035] In the above, the first control point 39a is the subject of the constraint processing, and the target position of the first control point 39a is constrained (restricted) by a plane 45 set based on the second control point 39b. However, conversely, the second control point 39b may be the subject of the constraint processing, and the target position of the second control point 39b may be constrained (restricted) by a plane 45 set based on the first control point 39a.
[0036] 2, the control point update processor 27 updates the positions of the plurality of first control points 39a so that they each approach the target positions calculated by the target position calculation processor 13 and constrained by the constraint processing described above. In other words, the movement of the first control points 39a due to the cloth simulation is limited to within the range constrained by the constraint processing described above. The control point update processor 27 also updates the positions of the plurality of second control points 39b so that they each approach the target positions calculated by the target position calculation processor 13 due to the cloth simulation.
[0037] The image generation processing unit 29 generates images of the first cloth object 35 and the second cloth object 37 based on the positions of the first control point 39 a and the second control point 39 b updated by the control point update processing unit 27 .
[0038] The processing in each processing unit described above is not limited to these examples of division of processing, and may be performed by a smaller number of processing units (for example, one processing unit), or by further subdivided processing units. The functions of each processing unit described above are implemented by a game program executed by CPU 101 (see FIG. 18 described below), but some of them may be implemented by actual devices such as dedicated integrated circuits such as ASICs and FPGAs, or other electrical circuits.
[0039] (1-2. Processing procedure executed by the information processing device) Next, an example of a processing procedure executed by the information processing device 3 according to the first embodiment will be described with reference to FIG.
[0040] In step S5, the information processing device 3 causes the symmetry axis setting processing unit 15 to set the symmetry axis 41 at the location where the first cloth object 35 and the second cloth object 37 are connected.
[0041] In step S10, the information processing device 3 causes the pair setting processing unit 17 to set pairs of first control points 39a and second control points 39b that are line-symmetrical with respect to the axis of symmetry 41 set in step S5 for the plurality of control points 39 set for the sleeve portion 33a of the kimono object 33. At this time, one first control point 39a and one second control point 39b may be set as a one-to-one pair, or, as described above, one first control point 39a may be set as a pair with multiple (for example, five) second control points 39b.
[0042] In step S15, the information processing device 3 identifies a pair to be processed from among the plurality of pairs set in step S10.
[0043] In step S20, the information processing device 3 executes a cloth simulation using the target position calculation processing unit 13, and calculates a target position by the cloth simulation for each of the first control point 39a and the second control point 39b that form the pair identified in step S15 above.
[0044] In step S25, the information processing device 3 causes the first normal calculation processing unit 19 to calculate a normal N1 at the target position of the paired second control point 39b based on the positional relationship with the adjacent second control point 39b.
[0045] In step S30, the information processing device 3 causes the first offset setting processing unit 21 to set a first offset distance in the direction of the normal N1 relative to the target position of the second control point 39b that forms the pair.
[0046] In step S35, the information processing device 3 sets, by the plane setting processing unit 23, a plane 45 perpendicular to the normal line N1 at a position offset by the first offset distance set in step S30 in the direction of the normal line N1 from the target position of the second control point 39b that forms the pair.
[0047] In step S40, the information processing device 3 causes the first target position constraint processing unit 25 to constrain the target position of the first control point 39a calculated in step S20 above so that it does not exceed the plane 45 set in step S35 above.
[0048] In step S45, the information processing device 3 determines whether or not the processing of steps S20 to S40 has been completed for all pairs set for each control point 39 of the sleeve portion 33a. "All pairs" refers to pairs set for all first control points 39a set in the first cloth object 35 of the sleeve portion 33a, and includes multiple pairs if one control point 39a is set for all pairs. If the processing has not been completed for all pairs (step S45: NO), the process returns to the previous step S15, and after identifying the next pair to be processed, the processing of steps S20 to S40 is repeated. On the other hand, if the processing has been completed for all pairs (step S45: YES), the process proceeds to step S50.
[0049] In step S50, the information processing device 3 uses the control point update processing unit 27 to update the position of the first control point 39a and the position of the second control point 39b so that they approach the target positions based on the cloth simulation calculated in step S20 above and constrained by the constraint processing in step S40 described above.
[0050] In step S55, the information processing device 3 generates images of the first cloth object 35 and the second cloth object 37 based on the positions of the first control point 39a and the second control point 39b updated in step S50, using the image generation processing unit 29. This ends this flowchart.
[0051] The above-described processing procedure is an example, and at least some of the procedures may be deleted or changed, or other procedures may be added. Furthermore, the order of at least some of the procedures may be changed, or multiple procedures may be combined into a single procedure.
[0052] (1-3. Effects of the First Embodiment) As described above, the game program of the first embodiment causes the information processing device 3 to function as: a target position calculation processor 13 that calculates target positions of a plurality of first control points 39a set on the first cloth object 35 and a plurality of second control points 39b set on the second cloth object 37 by cloth simulation processing to deform each of the first cloth object 35 and the second cloth object 37, at least a portion of which overlap in the viewpoint direction; a plane setting processor 23 that sets a plane 45 based on target positions determined by cloth simulation of some of the second control points 39b that correspond to the first control point 39a to be processed among the plurality of second control points 39b; a first target position constraint processor 25 that constrains the target position determined by cloth simulation of the first control point 39a so that it does not exceed the plane 45; a control point update processor 27 that updates the positions of the first control point 39a and the second control point 39b so that they approach the target positions determined by cloth simulation; and an image generation processor 29 that generates images of the first cloth object 35 and the second cloth object 37 based on the updated positions of the first control point 39a and the second control point 39b.
[0053] In this embodiment, for a first cloth object 35 and a second cloth object 37 that at least partially overlap, cloth simulation processing is used to calculate the target positions of a plurality of first control points 39a set on the first cloth object 35 and a plurality of second control points 39b set on the second cloth object 37. At this time, a plane 45 is set based on the target positions determined by cloth simulation of some of the second control points 39b that correspond to the first control points 39a being processed, and the target positions of the first control points 39a are constrained so that they do not exceed the plane 45. By performing this constraint processing on the entire cloth objects 35, 37, it is possible to prevent the cloth objects 35, 37 from penetrating each other. Furthermore, because the movement of each first control point 39a is constrained (restricted) by the plane 45 set based on some of the second control points 39b that correspond to the first control points 39a, the calculation load can be reduced compared to when the movement of each first control point 39a is restricted by collision detection with the second control points 39b of the entire second cloth object 37. Therefore, it is possible to suppress the occurrence of the punch-through phenomenon between the fabrics while suppressing an increase in the calculation load.
[0054] In addition, in this embodiment, the game program may cause the information processing device 3 to further function as a symmetry axis setting processing unit 15 that sets a symmetry axis 41 at the location where the first cloth object 35 and the second cloth object 37 are connected, and a pair setting processing unit 17 that sets a first control point 39a to be processed and a second control point 39b located in an area that is linearly symmetrical to the first control point 39a via the symmetry axis 41 as a pair.In this case, the plane setting processing unit 23 may set a plane 45 based on the target position of the second control point 39b that forms the pair, and the first target position constraint processing unit 25 may constrain the target position of the first control point 39a that forms the pair so that it does not exceed the plane 45.
[0055] In this embodiment, a first control point 39a to be processed and a second control point 39b located in an area that is line-symmetrical to the first control point 39a across a symmetry axis 41 are set as a pair. The target position of the paired first control point 39a is then constrained so that it does not exceed a plane 45 that is set based on the target position of the paired second control point 39b. By performing this constraint processing on the pair on the entire cloth objects 35, 37, it is possible to prevent the cloth objects 35, 37 from penetrating each other. Because the paired first control point 39a and second control point 39b are located in positions that are roughly opposite each other, performing the above constraint processing between these control points can efficiently prevent the cloth objects from penetrating each other.
[0056] Furthermore, in this embodiment, the movement of each first control point 39a is constrained (limited) by a plane 45 set based on the second control point 39b paired with that first control point 39a, which significantly reduces the calculation load compared to when the movement of each first control point 39a is limited by collision detection with the second control point 39b of the entire second cloth object 37. This embodiment is particularly effective in cases where two cloth objects 35, 37 overlap by being folded back on the axis of symmetry 41, such as the sleeve 33a of the kimono object 33.
[0057] In addition, in this embodiment, the game program may further cause the information processing device 3 to function as a first normal calculation processing unit 19 that calculates the normal N1 at the target position of a pair of second control points 39b based on the positional relationship with adjacent second control points 39b, and in that case, the plane setting processing unit 23 may set the plane 45 so that it is perpendicular to the normal N1.
[0058] In this case, no matter what shapes the cloth objects 35, 37 take on through cloth simulation, it is possible to prevent the cloth objects 35, 37 from penetrating each other.
[0059] In addition, in this embodiment, the game program may further cause the information processing device 3 to function as a first offset setting processing unit 21 that sets a first offset distance, which is the distance in the direction of the normal N1 between the target position of the second control point 39b that forms a pair and the plane 45, and in that case, the plane setting processing unit 23 may set the plane 45 at a position offset by the first offset distance from the target position of the second control point 39b.
[0060] Generally, the positions of control points set on a cloth object may not coincide with the positions where the cloth object is actually displayed (for example, the position of a mesh). In this embodiment, the first offset distance is set to an appropriate value according to the amount of difference in position, thereby further enhancing the effect of suppressing the occurrence of the punch-through phenomenon between the cloth objects. Furthermore, the first offset distance can adjust the gap between the first cloth object 35 and the second cloth object 37. Therefore, when the first offset distance is applied to the hanging portion 33b of the sleeve 33a of the Japanese clothing object 33 worn by a character, for example, it becomes possible to adjust the thickness of the hanging portion 33b.
[0061] In addition, in this embodiment, the pair setting processing unit 17 sets a pair of one first control point 39a to be processed and one second control point 39b that is located at a position that is linearly symmetrical to the first control point 39a via the symmetry axis 41, and also sets a pair of one first control point 39a and each of multiple second control points 39b that are located around the one second control point 39b, and the plane setting processing unit 23 sets multiple planes 45 based on the target positions of each of the multiple second control points 39b that make up the pair, and the first target position constraint processing unit 25 may constrain the target position of the first control point 39a that makes up the pair so that it does not exceed each of the multiple planes 45.
[0062] If one first control point 39a to be processed and one second control point 39b located at a position that is line-symmetrical across the symmetry axis 41 are set as a one-to-one pair and constraint processing is performed on the pair, for example, if the movement of the cloth objects 35, 37 is large, there is a possibility that a punch-through phenomenon will occur between the cloth objects 35, 37. In this embodiment, by setting pairs not only for the one second control point 39b located at a position that is line-symmetrical, but also for the second control points 39b located around that second control point 39b (for example, four second control points 39b on the top, bottom, left, and right sides), and performing constraint processing, it is possible to further increase the effect of suppressing the occurrence of punch-through between the cloth objects.
[0063] In this embodiment, the first cloth object 35 and the second cloth object 37 are the front and back cloth objects in the hanging portion 33b of the sleeve portion 33a of the kimono object 33 worn by the character 31, and the symmetry axis setting processing unit 15 may set the symmetry axis 41 at the folded portion of the lower end of the sleeve portion 33a.
[0064] When the character 31 wears the kimono object 33, for example, if the character 31 moves a lot, a punch-through phenomenon may occur in which the back fabric penetrates through the front fabric at the hanging portion 33b of the sleeve 33a from the arm. In this embodiment, the occurrence of such a punch-through phenomenon can be suppressed, and the movement of the kimono object 33 can be expressed more naturally.
[0065] 2. Second Embodiment Next, a second embodiment of the present invention will be described. In the second embodiment, for two overlapping cloth objects in a clothing object worn by a character, constraint processing is performed on each cloth object for each control point group based on a cross section viewed from a direction approximately perpendicular to the overlapping direction, thereby preventing the occurrence of a phenomenon in which cloth objects penetrate each other.
[0066] (2-1. Functional configuration of information processing device) An example of the functional configuration of the information processing device 3 according to the second embodiment will be described with reference to Fig. 10 and Fig. 11 to Fig. 16. In Fig. 10, the same components as those in Fig. 2 are denoted by the same reference numerals, and the description thereof will be omitted as appropriate.
[0067] As shown in Figure 10, the information processing device 3 has the aforementioned target position calculation processing unit 13, a control point group setting processing unit 47, a reference line setting processing unit 49, a distance setting processing unit 51, a second target position constraint processing unit 53, a curve setting processing unit 55, a nearby point calculation processing unit 57, a second normal calculation processing unit 59, a second offset setting processing unit 61, the aforementioned plane setting processing unit 23, the aforementioned first target position constraint processing unit 25, the aforementioned control point update processing unit 27, and the aforementioned image generation processing unit 29.
[0068] The processing contents of the target position calculation processing unit 13 are the same as those in the first embodiment, and therefore a description thereof will be omitted.
[0069] The control point group setting processor 47 sets a control point group including first control points 39a and second control points 39b located on a cross section viewed from a direction approximately perpendicular to the direction in which the first cloth object (an example of a first object) and the second cloth object (an example of a second object) overlap. The "cross section viewed from a direction approximately perpendicular to the direction of overlap" refers to a cross section viewed from an up-down direction approximately perpendicular to the front-to-back direction, i.e., a horizontal cross section, when, for example, the first cloth object and the second cloth object are an outer cloth object and an inner cloth object that are drawn overlapping at the collar part 33d of the hem part 33c, which is the part below the obi of the kimono object 33, and the overlapping direction is the front-to-back direction of the character's body.
[0070] 11 and 12 show an example of a control point group located on a cross section, which is set by the control point group setting processor 47. As shown in Fig. 11, a plurality of control points 39 are set for the hem portion 33c of the kimono object 33. The control points 39 are arranged, for example, in a grid pattern. At the front collar portion 33d of the hem portion 33c, a first cloth object 62, which is an outer cloth object, and a second cloth object 64, which is an inner cloth object, at least partially overlap with each other.
[0071] FIG. 12 shows an example of a control point group located on the horizontal cross section XII-XII in FIG. 11. For ease of explanation, FIG. 12 shows a simplified illustration with a reduced number of control points 39. As shown in FIG. 12, the control point group 39G includes a plurality of first control points 39a (shown by dot hatching) set on the first cloth object 62, which is the outer cloth object; a plurality of second control points 39b (shown by horizontal stripe hatching) set on the second cloth object 64, which is the inner cloth object; and a plurality of third control points 39c (shown by grid hatching) set on the cloth object 63 on the fixed side (behind the character) of the hem 33c that is not subject to cloth simulation processing. The control point group setting processor 47 sequentially sets the control point group G to be processed for the entire hem 33c while changing the height of the horizontal cross section one step at a time in the vertical direction.
[0072] 10, the reference line setting processor 49 sets a reference line connecting, among the multiple first control points 39a included in the control point group G set by the control point group setting processor 47, a first control point 39a at an end opposite to the overlapping portion 65 between the first cloth object 62 and the second cloth object 64, and, among the multiple second control points 39b included in the same control point group G, a second control point 39b at an end opposite to the overlapping portion 65. The reference line is set as a straight line. FIG. 13 shows an example of a reference line 67 set by the reference line setting processor 49.
[0073] 10, the distance setting processor 51 sets the separation distance from the reference line 67 in a direction perpendicular to the reference line 67 set by the reference line setting processor 49 so as to form a predetermined shape based on the length distance from the end of the reference line 67 in a direction along the reference line 67. The "predetermined shape" is not particularly limited, but is preferably a shape that reproduces, for example, the arrangement of the second control points 39b in the initial shape of the second cloth object 64. The predetermined shape may be defined, for example, by a function that outputs the separation distance according to an input value of the length distance.
[0074] The second target position constraint processing unit 53 constrains the target position of the second control point 39b included in the control point group G so that the distance between the target position of the second control point 39b and the reference line 67 in a direction perpendicular to the reference line 67 does not exceed the predetermined shape set by the distance setting processing unit 51. The second target position constraint processing unit 53 also constrains the target position of the second control point 39b included in the control point group G so that the length distance between the target position of the second control point 39b and the end of the reference line 67 in the direction along the reference line 67 does not exceed a predetermined threshold value (for example, the total length of the reference line 67).
[0075] FIG. 14 shows an example of the separation distance and length distance set by the distance setting processor 51. FIG. 15 shows an example of the predetermined shape set by the distance setting processor 51. Note that FIG. 14 is a diagram showing the second cloth object 64 and the reference line 67 extracted from FIG. 13 . As shown in FIG. 14 , the separation distance Hi is the separation distance between the target position (shown by the thick line in the figure) of the second control point 39b to be processed and the reference line 67, the length distance Di is the length distance between the end of the reference line 67, and the total length of the reference line 67 is Dmax. Also, as shown in FIG. 15 , the predetermined shape is defined by the function Hi = f(Di). In this case, the second target position constraint processor 53 constrains the target position of the second control point 39b to be processed so that the separation distance Hi does not exceed the predetermined shape defined by the function Hi = f(Di) and the length distance Di does not exceed the threshold value Dmax. This constraint processing is performed for all second control points 39b included in the control point group G.
[0076] 10, the curve setting processing unit 55 sets a curve that connects the target positions of the plurality of second control points 39b included in the control point group G. The type of curve is not particularly limited, but a spline curve or the like that has a light calculation load is preferable. FIG. 16 shows an example of a curve 69 set by the curve setting processing unit 55.
[0077] Returning to Fig. 10, the nearby point calculation processor 57 calculates the closest point on the curve 69 to the target position of one first control point 39a to be processed. The closest point is calculated based on an equation (e.g., an equation for a spline curve) that represents the target position of the first control point 39a to be processed and the curve 69. Fig. 16 shows an example of the closest point 71 calculated by the nearby point calculation processor 57. Note that in Fig. 16, the target position of the first control point 39a to be processed is indicated by a thick line.
[0078] 10, the second normal calculation processor 59 calculates the normal to the closest point 71 calculated by the neighboring point calculation processor 57 based on the shape of the curve 69. The normal is calculated based on the position of the closest point 71 and an equation representing the curve 69 (for example, an equation for a spline curve). FIG. 16 shows an example of the normal N2 calculated by the second normal calculation processor 59.
[0079] 10, the second offset setting processor 61 sets a second offset distance, which is the distance between the closest point 71 and a plane in the direction of a normal N2, which will be described later. Fig. 16 shows an example of the second offset distance Offset2 set by the second offset setting processor 61. Note that the offset distance does not necessarily have to be set.
[0080] Returning to FIG. 10 , the plane setting processor 23 sets a plane based on the target positions of some of the second control points 39b among the multiple second control points 39b that correspond to the first control point 39a to be processed. The "some of the second control points 39b" refers to, for example, the second control points 39b included in the control point group G that includes the first control point 39a to be processed. Specifically, the plane setting processor 23 sets the plane so that it is parallel to the tangent to the curve 69 set by the curve setting processor 55. The "tangent" is a straight line that touches the curve 69 at the closest point 71 calculated by the nearest point calculation processor 57. In other words, the plane setting processor 23 sets the plane so that it is perpendicular to the normal N2 calculated by the second normal calculation processor 59. Furthermore, if the second offset distance is set by the second offset setting processor 61, the plane setting processor 23 sets the plane at a position offset by the second offset distance from the position of the closest point 71 in the direction of the normal N2.
[0081] Fig. 16 shows an example of a plane set by the plane setting processing unit 23. As shown in Fig. 16, a plane 73 is set at a position offset by a second offset distance Offset2 from the position of the closest point 71 in the direction of the normal line N2 so as to be perpendicular to the normal line N2.
[0082] Returning to FIG. 10, the first target position constraint processing unit 25 constrains the target position of the first control point 39a to be processed and included in the control point group G so that it does not exceed the plane 73 set by the plane setting processing unit 23.
[0083] 16 shows an example of the constraint processing by the first target position constraint processing unit 25. As shown in Fig. 16, the target position of the first control point 39a is constrained (limited) to be located in an area closer to the first control point 39a than the plane 73 so as not to reach an area closer to the second control point 39b than the plane 73. This constraint processing is executed for all first control points 39a included in the control point group G.
[0084] The calculation and constraint process of the target position of each control point 39 described above is performed sequentially for the group of control points G arranged in multiple stages in the vertical direction relative to the hem portion 33c, thereby determining the target position of each control point 39 for the entire hem portion 33c.
[0085] 10, the control point update processor 27 updates the positions of the first control point 39a and the second control point 39b so that they approach the target positions constrained by the above-mentioned constraint processing, which are the target positions calculated by the target position calculation processor 13 in the cloth simulation. In other words, the movements of the first control point 39a and the second control point 39b in the cloth simulation are limited to within the range constrained by the above-mentioned constraint processing.
[0086] The image generation processing unit 29 generates images of the first cloth object 62 and the second cloth object 64 of the hem 33c of the kimono object 33 based on the positions of the first control point 39a and the second control point 39b updated by the control point update processing unit 27.
[0087] The processing in each processing unit described above is not limited to these examples of division of processing, and may be performed by a smaller number of processing units (for example, one processing unit), or by further subdivided processing units. The functions of each processing unit described above are implemented by a game program executed by CPU 101 (see FIG. 18 described below), but some of them may be implemented by actual devices such as dedicated integrated circuits such as ASICs and FPGAs, or other electrical circuits.
[0088] (2-2. Processing Procedures Executed by Information Processing Device) Next, an example of a processing procedure executed by the information processing device 3 according to the second embodiment will be described with reference to FIG.
[0089] In step S105, the information processing device 3 causes the control point group setting processing unit 47 to identify the control point group G to be processed.
[0090] In step S110, the information processing device 3 performs cloth simulation using the target position calculation processing unit 13, and calculates target positions using the cloth simulation for the first control point 39a and the second control point 39b included in the control point group G identified in step S105 above.
[0091] In step S115, the information processing device 3 sets, by the reference line setting processing unit 49, a reference line 67 connecting the target position of the first control point 39a at the end opposite the overlapping portion 65 among the multiple first control points 39a included in the control point group G, and the target position of the second control point 39b at the end opposite the overlapping portion 65 among the multiple second control points 39b included in the same control point group G.
[0092] In step S120, the information processing device 3 sets the distance from the reference line 67 set in step S115 above using the distance setting processing unit 51 so that a predetermined shape is formed based on the length distance from the end of the reference line 67.
[0093] In step S125, the information processing device 3 constrains the target position of the second control point 39b by the second target position constraint processing unit 53 so that the distance Hi between the target position of the second control point 39b included in the control point group G and the reference line 67 does not exceed the specified shape set in the above step S120.
[0094] In step S130, the information processing device 3 constrains the target position of the second control point 39b included in the control point group G using the second target position constraint processing unit 53 so that the length distance Di between the target position of the second control point 39b included in the control point group G and the end of the reference line 67 does not exceed a predetermined threshold value Dmax.
[0095] The information processing device 3 sequentially executes the processes of step S125 and step S130 for all second control points 39b included in the control point group G identified in step S105. As a result, the target positions of all second control points 39b included in the control point group G are determined.
[0096] In step S135, the information processing device 3 sets a curve 69 connecting the target positions of the plurality of second control points 39b included in the control point group G by the curve setting processing unit 55.
[0097] In step S140, the information processing device 3 calculates, using the adjacent point calculation processing unit 57, the closest point 71 on the curve 69 calculated in step S135, which is closest to the target position of the first control point 39a to be processed among the multiple first control points 39a included in the control point group G.
[0098] In step S145, the information processing device 3 causes the second normal calculation processing unit 59 to calculate the normal N2 of the closest point 71 calculated in step S140, based on the shape of the curve 69.
[0099] In step S150, the information processing device 3 sets, by the second offset setting processing unit 61, a second offset distance which is the distance in the direction of the normal N2 between the closest point 71 calculated in step S140 and the plane 73 to be set later.
[0100] In step S155, the information processing device 3 sets, by the plane setting processing unit 23, a plane 73 at a position offset from the position of the closest point 71 in the direction of the normal N2 by the second offset distance set in step S150 above, so that the plane 73 is perpendicular to the normal N2.
[0101] In step S160, the information processing device 3 causes the first target position constraint processing unit 25 to constrain the target position of the first control point 39a to be processed so that it does not go beyond the plane 73 set in step S155.
[0102] The information processing device 3 sequentially performs the processes of steps S140 to S160 on all of the first control points 39a included in the control point group G identified in step S105. As a result, the target positions of all of the first control points 39a included in the control point group G are determined.
[0103] In step S165, the information processing device 3 determines whether or not the above-described processing has been completed for all control point groups G set on the hem 33c of the kimono object 33. If the processing has not been completed (step S165: NO), the process returns to the previous step S105, and after identifying the next control point group G to be processed, the processing of steps S110 to S160 is repeated. On the other hand, if the processing has been completed (step S165: YES), the process proceeds to step S170.
[0104] In step S170, the information processing device 3 causes the control point update processing unit 27 to update the position of the first control point 39a and the position of the second control point 39b so that they approach the target positions based on the cloth simulation calculated in step S110 above and constrained by the constraint processing in steps S125, S130, and S160 described above.
[0105] In step S175, the information processing device 3 generates images of the first cloth object 62 and the second cloth object 64 based on the positions of the first control point 39a and the second control point 39b updated in step S170, using the image generation processing unit 29. This ends this flowchart.
[0106] The above-described processing procedure is an example, and at least some of the procedures may be deleted or changed, or other procedures may be added. Furthermore, the order of at least some of the procedures may be changed, or multiple procedures may be combined into a single procedure.
[0107] (2-3. Effects of the Second Embodiment) As described above, the game program of the second embodiment may further cause the information processing device 3 to function as a control point group setting processing unit 47 that sets a control point group G including the first control point 39a and the second control point 39b located on a cross section viewed from a direction approximately perpendicular to the direction in which the first cloth object 62 and the second cloth object 64 overlap.In this case, the plane setting processing unit 23 may set a plane 73 based on the target position of the second control point 39b included in the control point group G, and the first target position constraint processing unit 25 may constrain the target position of the first control point 39a included in the control point group G so that it does not exceed the plane 73.
[0108] In this embodiment, a control point group G is set that includes first control point 39a and second control point 39b located on a cross section viewed from a direction approximately perpendicular to the direction in which the first cloth object 62 and the second cloth object 64 overlap, and a plane 73 is set based on the target position of second control point 39b included in control point group G. Then, the target position of first control point 39a included in control point group G is constrained so that it does not exceed plane 73. By performing this constraint processing on all of the cloth objects 62, 64, it is possible to prevent the cloth objects 62, 64 from penetrating each other.
[0109] In this embodiment, the constraint processing is performed on the control points 39a and 39b included in the control point group G located on the horizontal cross section of the hem portion 33c. This significantly reduces the calculation load compared to when a collision detection process is performed between the first control points 39a of the entire first cloth object 62 and the second control points 39b of the entire second cloth object 64.
[0110] In this embodiment, the first cloth object 62 may be located closer to the viewpoint than the second cloth object 64, and the game program may further cause the information processing device 3 to function as a curve setting processing unit 55 that sets a curve 69 connecting the second control points 39b included in the control point group G, and in that case, the plane setting processing unit 23 may set a plane 73 so that it is parallel to the tangent to the curve 69.
[0111] In this embodiment, a curve 69 is set that connects the second control points 39b included in the control point group G among the multiple second control points 39b set on the second cloth object 64 located on the opposite side from the viewpoint (below, inside, or back side), and a plane 73 is set so as to be parallel to the tangent to the curve 69. Then, the target positions of the first control points 39a included in the control point group G among the first control points 39a set on the first cloth object 62 located on the viewpoint side (above, outside, or front side) are constrained so as not to exceed the plane 73. By performing this constraint processing on all of the cloth objects 62, 64, it is possible to prevent the cloth objects 62, 64 from penetrating each other.
[0112] Furthermore, in this embodiment, a curve 69 is set connecting the second control points 39b, and constraint processing is performed based on this curve 69, thereby achieving smoother movement of the cloth objects 62, 64 compared to when constraint processing is performed simply by determining between control points.
[0113] This embodiment is particularly effective in cases where both ends of a cylindrically rolled cloth object (two cloth objects 62, 64) overlap at the collar 33d, such as the hem 33c of the Japanese clothing object 33.
[0114] In addition, in this embodiment, the game program may cause the information processing device 3 to further function as a nearby point calculation processing unit 57 that calculates the closest point 71 on the curve 69 that is closest to the first control point to be processed, and a second normal calculation processing unit 59 that calculates the normal N2 of the closest point 71 based on the shape of the curve 69, and in that case, the plane setting processing unit 23 may set the plane 73 so that it is perpendicular to the normal N2.
[0115] In this case, no matter what shapes the cloth objects 62, 64 take on through cloth simulation, it is possible to prevent the cloth objects 62, 64 from penetrating each other.
[0116] In addition, in this embodiment, the game program may further cause the information processing device 3 to function as a second offset setting processing unit 61 that sets a second offset distance, which is the distance in the direction of the normal N2 between the closest point 71 and the plane 73, and in that case, the plane setting processing unit 23 may set the plane 73 at a position offset by the second offset distance from the position of the closest point 71.
[0117] As mentioned above, the positions of the control points set for a cloth object may not coincide with the positions where the cloth object is actually displayed (for example, the position of a mesh). In this embodiment, the second offset distance is set to an appropriate value according to the amount of difference in position, thereby further preventing the occurrence of the phenomenon of pieces of cloth punching through each other. Furthermore, the second offset distance can adjust the gap between the first cloth object 62 and the second cloth object 64. Therefore, when applied to, for example, the collar portion 33d of the hem 33c of a Japanese clothing object 33 worn by a character, it is possible to adjust the gap at the collar portion 33d.
[0118] In this embodiment, the game program may also cause the information processing device 3 to further function as a reference line setting processing unit 49 that sets a reference line 67 connecting a first control point 39a, of the multiple first control points 39a included in the control point group G, at the end opposite the overlapping portion 65 between the first cloth object 62 and the second cloth object 64, and a second control point 39b, of the multiple second control points 39b included in the control point group G, at the end opposite the overlapping portion 65; a distance setting processing unit 51 that sets the distance Hi from the reference line 67 in a direction perpendicular to the reference line 67 so that it becomes a predetermined shape based on the length distance Di from the end of the reference line 67 in a direction along the reference line 67; and a second target position constraint processing unit 53 that constrains the target position of the second control point 39b included in the control point group G so that the distance Hi between the target position of the second control point 39b and the reference line 67 in the direction perpendicular to the reference line 67 does not exceed the predetermined shape.
[0119] In this case, the movement of the second control point 39b can be restricted to the area inside the predetermined shape, and the deformation of the second cloth object 64 can be restricted and stabilized within the predetermined shape. This more reliably prevents the second cloth object 64 from penetrating through the first cloth object 62. Furthermore, the shape of the second cloth object 64 can be adjusted according to the settings of the predetermined shape.
[0120] In this embodiment, the first cloth object 62 and the second cloth object 64 may be an outer cloth object and an inner cloth object that overlap at the collar portion 33d of the hem portion 33c of the Japanese clothing object 33 worn by the character.
[0121] When a character wears a kimono object 33, for example, if the character moves a lot, a punch-through phenomenon may occur in which the inner fabric penetrates the outer fabric at the collar 33d of the hem 33c where the fabric overlaps. In this embodiment, the occurrence of such a punch-through phenomenon can be suppressed, and the movement of the kimono object 33 can be expressed more naturally.
[0122] <3. Modifications, etc.> The present invention is not limited to the above-described embodiment, and various modifications are possible within the scope of the spirit and technical concept of the present invention.
[0123] For example, although the above description has been given using an example in which the clothing worn by a character is Japanese clothing, the present invention may also be applied to cases in which two pieces of cloth interfere with each other in Western clothing or other clothing. Furthermore, the first object and the second object are not limited to the cloth that constitutes clothing. For example, the above-described processing may be applied to flexible objects attached to a character, such as cloth equipment (headbands, bandanas, etc.) and cloth or paper carried items (pieces of cloth, scrolls, flags, etc.), or flexible objects that are part of the body, such as hair. For example, the present invention may be applied to interference between clothing and cloth or paper carried items, between clothing and hair, or between other flexible objects attached to a character. In the case of an object such as hair, the "predetermined simulation processing" is preferably a so-called string simulation processing that can simulate the deformation of an object such as a string or rope.
[0124] Furthermore, although the above description has been given using an example in which multiple first control points 39a are set for the first object, multiple first control points 39a do not necessarily need to be set, and a single first control point 39a may be set depending on the type of first object (e.g., a ball, etc.).
[0125] Furthermore, although the above description has been given of the case where the image generation program is a game program, the image generation program can also be applied to technical fields other than games, such as CG animation, computer simulation, CAD, etc.
[0126] Furthermore, in addition to what has already been described above, the methods according to the above-described embodiments and modifications may be appropriately combined and used. Although not specifically illustrated, the above-described embodiments and modifications may be implemented with various modifications within the scope of their spirit.
[0127] <4. Hardware configuration of information processing device> Next, an example of a hardware configuration of the information processing device 3 that realizes each processing unit implemented by a program executed by the CPU 101 and the like described above will be described with reference to FIG.
[0128] 18, the information processing device 3 includes, for example, a CPU 101, a ROM 103, a RAM 105, a GPU 106, a dedicated integrated circuit 107 constructed for a specific application, such as an ASIC or an FPGA, an input device 113, an output device 115, a recording device 117, a drive 119, a connection port 121, and a communication device 123. These components are connected to each other via a bus 109, an input / output interface 111, etc., so that signals can be transmitted between them.
[0129] The game program can be recorded in, for example, the ROM 103, the RAM 105, or a recording device 117 such as a hard disk.
[0130] The game program may also be temporarily or permanently (non-temporarily) recorded on a removable recording medium 125, such as a magnetic disk such as a flexible disk, various optical disks such as CDs, MO disks, and DVDs, or a semiconductor memory. Such recording medium 125 may also be provided as a so-called package software. In this case, the game program recorded on such recording medium 125 may be read by drive 119 and recorded on the recording device 117 via input / output interface 111, bus 109, etc.
[0131] The game program may also be stored, for example, on a download site, another computer, or another storage device (not shown). In this case, the game program is transferred via a network NW such as a LAN or the Internet, and the communication device 123 receives the program. The program received by the communication device 123 may then be recorded in the storage device 117 via the input / output interface 111, the bus 109, or the like.
[0132] The game program may also be recorded in, for example, an appropriate externally connected device 127. In this case, the game program may be transferred via an appropriate connection port 121 and recorded in the recording device 117 via the input / output interface 111, the bus 109, etc.
[0133] The CPU 101 then executes various processes in accordance with the programs recorded in the recording device 117, thereby realizing processes by the target position calculation processor 13, symmetry axis setting processor 15, pair setting processor 17, first normal calculation processor 19, first offset setting processor 21, plane setting processor 23, first target position constraint processor 25, control point update processor 27, image generation processor 29, control point group setting processor 47, reference line setting processor 49, distance setting processor 51, second target position constraint processor 53, curve setting processor 55, neighboring point calculation processor 57, second normal calculation processor 59, second offset setting processor 61, and the like. In this case, the CPU 101 may, for example, directly read and execute the programs from the recording device 117, or may first load the programs into the RAM 105 and then execute them. Furthermore, when the CPU 101 receives a program via the communication device 123, the drive 119, or the connection port 121, the CPU 101 may, for example, directly execute the received program without recording it in the recording device 117.
[0134] Furthermore, the CPU 101 may perform various processes based on signals and information input from an input device 113, such as a microphone, mouse, keyboard, etc. (not shown), including the game controller 5 described above, as needed.
[0135] The GPU 106 performs processing for image display, such as rendering processing, in response to instructions from the CPU 101 .
[0136] Then, the CPU 101 and the GPU 106 output the results of the above processing from an output device 115, which may include, for example, the above-mentioned display device 7. Furthermore, the CPU 101 and the GPU 106 may transmit the processing results via the communication device 123 or the connection port 121, as necessary, or may record the results in the recording device 117 or the recording medium 125.
Explanation of Symbols
[0137] 1 Game system 3 Information processing device 5 Game controller 7 Display device 13 Target position calculation processing unit 15 Symmetry axis setting processing unit 17 Pair setting processing unit 19 First normal line calculation processing unit 21 First offset setting processing unit 23 Plane setting processing unit 25 First target position constraint processing unit 27 Control point update processing unit 29 Image generation processing unit 31 Character 33 Kimono object 33a Sleeve part 33b Hanging part 33c Hem part 33d Lapel part 35 First cloth object (first object) 37 Second cloth object (second object) 39a First control point 39b Second control point 41 Symmetry axis 45 Plane 47 Control point group setting processing unit 49 Reference line setting processing unit 51 Distance setting processing unit 73 plane 125 Recording Media Di length distance G Control points Hi separation distance N1 normal N2 normal Offset1 First offset distance Offset2 Second offset distance
Claims
1. An information processing device a target position calculation processing unit that calculates target positions of a first control point set on the first object and a plurality of second control points set on the second object by a predetermined simulation process for deforming each of a first object and a second object at least partially overlapping in a viewpoint direction; a plane setting processing unit that sets a plane based on the target positions of some of the second control points that correspond to the first control points to be processed, among the plurality of second control points; a first target position constraint processing unit that constrains the target position of the first control point so that it does not exceed the plane; a control point update processing unit that updates the positions of the first control point and the second control point so as to approach the target position; an image generation processing unit that generates images of the first object and the second object based on the updated positions of the first control point and the second control point; An image generation program to function as a.
2. The information processing device a symmetry axis setting processing unit that sets a symmetry axis at a portion where the first object and the second object are connected; a pair setting processing unit that sets, as a pair, the first control point to be processed and the second control point located in an area that is line-symmetrical with respect to the first control point with respect to the symmetry axis; It further functions as The plane setting processing unit setting the plane based on the target positions of the second control points that make up the pair; The first target position constraint processing unit constraining the target position of the first control point of the pair so that it does not exceed the plane; The image generating program according to claim 1 .
3. The information processing device a first normal calculation processing unit that calculates a normal at the target position of the second control point that constitutes the pair based on a positional relationship with an adjacent second control point; It further functions as The plane setting processing unit setting the plane perpendicular to the normal line; The image generating program according to claim 2 .
4. The information processing device a first offset setting processing unit that sets a first offset distance that is a distance in the normal direction between the target position of the second control point that constitutes the pair and the plane; It further functions as The plane setting processing unit setting the plane at a position offset by the first offset distance from the target position of the second control point; The image generating program according to claim 3 .
5. The pair setting processing unit one first control point to be processed and one second control point that exists at a position that is line-symmetrical with respect to the one first control point via the symmetry axis are set as the pair, and the one first control point and each of the plurality of second control points that exist around the one second control point are also set as the pair; The plane setting processing unit setting a plurality of planes based on the target positions of the plurality of second control points constituting the pair; The first target position constraint processing unit constraining the target positions of the first control points constituting the pair so as not to exceed the plurality of planes; 5. The image generating program according to claim 2.
6. The first object and the second object The cloth objects are the front and back of the sleeves of the kimono object worn by the character, The symmetry axis setting processing unit The axis of symmetry is set at the folded-back portion at the lower end of the sleeve portion.
6. The image generating program according to claim 2.
7. The information processing device a control point group setting processing unit that sets a control point group including the first control point and the second control point located on a cross section seen from a direction substantially perpendicular to a direction in which the first object and the second object overlap; It further functions as The plane setting processing unit setting a plane based on the target position of the second control point included in the control point group; The first target position constraint processing unit constraining the target position of the first control point included in the control point group so that it does not exceed the plane; The image generating program according to claim 1 .
8. the first object is located closer to the viewpoint than the second object, The information processing device a curve setting processing unit that sets a curve connecting the second control points included in the control point group; It further functions as The plane setting processing unit Setting the plane so as to be parallel to the tangent of the curve. The image generating program according to claim 7.
9. The information processing device a nearest point calculation processing unit that calculates the nearest point on the curve that is nearest to the first control point to be processed; a second normal calculation processing unit that calculates a normal to the closest point based on the shape of the curve; It further functions as The plane setting processing unit setting the plane perpendicular to the normal line; The image generating program according to claim 8.
10. The information processing device a second offset setting processing unit that sets a second offset distance that is a distance in the normal direction between the closest point and the plane; It further functions as The plane setting processing unit setting the plane at a position offset by the second offset distance from the position of the closest point; The image generating program according to claim 9.
11. The information processing device a reference line setting processing unit that sets a reference line connecting one of the first control points included in the control point group at an end opposite to an overlapping portion between the first object and the second object, and one of the second control points included in the control point group at an end opposite to the overlapping portion; a distance setting processing unit that sets a distance from the reference line in a direction perpendicular to the reference line so as to form a predetermined shape based on a length distance from an end of the reference line in a direction along the reference line; a second target position constraint processing unit that constrains the target position of the second control point included in the control point group so that a distance between the target position of the second control point and the reference line in a direction perpendicular to the reference line does not exceed the predetermined shape; To further function as The image generating program according to any one of claims 8 to 10.
12. The first object and the second object The outer and inner cloth objects overlap at the collar of the kimono object worn by the character.
12. The image generating program according to claim 7.
13. the image generation program is a game program; The image generating program according to any one of claims 1 to 12.
14. 14. A recording medium readable by an information processing device, on which the image generating program according to claim 1 is recorded.
15. An image generation method executed by an information processing device, comprising: calculating target positions of a first control point set on the first object and a plurality of second control points set on the second object by a predetermined simulation process for deforming each of a first object and a second object at least partially overlapping in a viewpoint direction; setting a plane based on the target positions of some of the second control points corresponding to the first control points to be processed, among the plurality of second control points; constraining the target position of the first control point so that it does not exceed the plane; updating the positions of the first control point and the second control point so as to approach the target position; generating images of the first object and the second object based on the updated positions of the first control points and the second control points; An image generating method comprising:
Citation Information
Patent Citations
Drawing computer, computer program and recording medium
JP2005099952A
Simulation device, simulation method, and program
JP2006146806A
Simulation device, simulation method, and program
JP2006146807A
Simulation of assembly of fabric pieces
JP2014235748A
Image generation program, recording medium, and image generation method
JP2019174871A