The present application is based on and claims priority under 35 U.S.C. § 119 to Japanese Patent Application No. 2020-192228, filed on Nov. 19, 2020, the contents of which are incorporated herein by reference in their entirety.
The present invention relates to a recording medium, an information processing method, and an information processing apparatus.
Conventionally, there is known an image generating apparatus that arranges a plurality of objects in an object space that is a virtual three-dimensional space, and generates a view image from a given viewpoint. In this type of image generating apparatus, the motion of a display object is often illustrated based on motion data. On the basis of the motion data, an object of a game character configured by primitive planes such as a polygon or curved surfaces, is operated in an object space. This enables the expression of the motions or the like of a game character that sequentially change.
In order to increase the degree of variety of the motions of the game character, it is desirable to prepare as many pieces of motion data as possible with respect to one game character (see, for example, Patent Document 1).
In the technique described in Patent Document 1, the motions of the object are corrected in real time and used, based on the position information of the correction point and the reference motion data in a certain frame, so that a reference point included in a given part of the object to which a plurality of parts are connected, is arranged at a given correction point. Accordingly, the degree of variety of the motions of the displayed object can be increased without preparing so many pieces of motion data in advance.
However, when the motion of a person riding a vehicle is corrected by the technique disclosed in Patent Document 1, there has been a problem that, for example, the motion of the person riding the vehicle may become unnatural depending on the movement of the vehicle and the environment.
A problem to be addressed by an embodiment of the present invention is to realize natural motions of an object that is riding another object, while reducing the burden of creating motions.
According to one aspect of the present invention, there is provided a non-transitory computer-readable recording medium storing a program that causes a computer to execute a process performed in an information processing apparatus, the process including correcting a second motion of a second object that is riding a first object that moves based on a first motion, such that a predetermined position of the second object is arranged at a predetermined position of the first object; correcting the second motion such that a posture of the second object is based on a movement of the first object or an environment; and displaying an image of the second object that is riding the first object based on the corrected second motion.
Hereinafter, embodiments for carrying out the present invention will be described with reference to the drawings.
First, an information processing apparatus according to an embodiment will be described with reference to
The information processing apparatus of
The communication device 104 is a communication device such as a network circuit that controls communication. The input device 106 is an input device such as a touch pad, a controller, a mouse, a keyboard, a camera, a microphone, or the like. The display device 108 is an output device such as a display, a speaker, or the like. A touch panel is implemented by combining a touch pad and a display.
The hardware configuration illustrated in
Motion data is an example of information that defines the motion of an object of a vehicle, such as a horse or a motorcycle, or an object of a person riding the vehicle. Object data is an example of information of an object that is a vehicle, such as a horse and a motorcycle, for which the motion is defined by motion data, and an object that is a person riding the vehicle. Hereinafter, an object that is a vehicle, such as a horse and a motorcycle, is referred to as a “vehicle object”. An object riding the vehicle object is referred to as a “rider object”.
The control unit 200 performs the overall control of the information processing apparatus. The overall control of the information processing apparatus includes, for example, control of causing an object to move in an object space unit based on motion data. The control unit 200 is implemented by performing a process described in a program, by the CPU 100. The control unit 200 includes a ride target object selecting unit 220, a motion selecting unit 222, a motion correcting unit 224, a posture correcting unit 226, and a display control unit 228.
The ride target object selecting unit 220 selects an object that is the ride target from among the objects displayed in the object space. The ride target objects selected by the ride target object selecting unit 220 are a vehicle object and a rider object.
The motion selecting unit 222 selects the motion to be applied to the object that is the ride target, from the motion data of the object that is the ride target. For example, the motion selecting unit 222 selects the motion data to be applied to the vehicle object selected by the ride target object selecting unit 220 and the motion data to be applied to the rider object selected by the ride target object selecting unit 220.
When the motion correction of the rider object is performed as described below, the motion selecting unit 222 selects motion data of a posture (a neutral posture) that serves as a reference for correction by the motion correcting unit 224, which will be described later, as the motion data to be applied to the rider object.
The motion correcting unit 224 corrects the motion data to be applied to the rider object selected by the motion selecting unit 222 as described below and applies the corrected motion data to the rider object so that the motion of the vehicle object can be matched with the motion of the rider object riding the vehicle object.
For example, when the vehicle object is a bicycle and the rider object is a person, the motion correcting unit 224 corrects the motion of the rider object so that the hand follows the handle position, the foot follows the pedal position, and the backside follows the saddle position.
The posture correcting unit 226 corrects the motion of the rider object so that the posture of the rider object is based on the movement (action or shifting) of the vehicle object or the environment (a slope or a step), so that the motion of the rider object riding a vehicle object becomes natural.
The display control unit 228 causes the display unit 204 to display an image of the rider object riding a vehicle object, based on the motion corrected by the motion correcting unit 224 and the posture correcting unit 226.
The operation unit 202 accepts various operations of a user with respect to the input device 106. The display unit 204 displays various screens on the display device 108 according to the control of the display control unit 228. The operation unit 202 is implemented by controlling the input device 106 by the CPU 100 according to a program. The display unit 204 is implemented by controlling the display device 108 by the CPU 100 according to a program. The user's various operations with respect to the input device 106 refer to operations performed by the user on the operation unit 202 in order to cause the CPU 100 to execute operations. The display unit 204 displays various screens according to the control of the control unit 200. The communication unit 206 communicates via a network or the like. The communication unit 206 is implemented when the CPU 121 executes a program and controls the communication device 104 according to the program.
In the example described below, a vehicle object 1002 is a horse and a rider object 1000 is a person.
The rider object 1000 illustrated on the left in
The upper right example of
The lower right example of
Accordingly, in the present embodiment, motion correction and posture correction of the rider object 1000 are performed as illustrated in
In
With respect to the rider object 1000 illustrated on the left in
The upper right example of
In the lower right example of
In step S12, the motion selecting unit 222 selects the motion to be applied to the rider object 1000 and the motion to be applied to the vehicle object 1002 that are ride targets, respectively. Here, an example of selecting motion data of a neutral posture of the rider object 1000 that is a ride target will be described. When a special motion is to be implemented by the rider object 1000, motion data exclusively used for the special motion is selected.
In step S14, if “motion correction to be performed” is set with respect to the selected motion of the rider object 1000, the motion correcting unit 224 performs the processes of steps S16 and S18. In step S16, the motion correcting unit 224 corrects the motion data selected by the motion selecting unit 222 to be applied to the rider object 1000 so that the hand and foot of the rider object 1000 are respectively arranged at the positions of the hand and foot attach nodes of the vehicle object 1002.
In step S16 and step S18, for example, the motion correcting unit 224 and the posture correcting unit 226 adjust the position and a posture angle of the rider attach node represented by a triangular mark in
The posture correcting unit 226 corrects the motion of the rider object so that the posture of the rider object 1000 is based on the movement (action or shifting) of the vehicle object 1002 or the environment (a slope or a step).
For example, when the vehicle object 1002 on which the rider object 1000 is riding accelerates, the posture correcting unit 226 makes a correction such that the posture angle of the rider object 1000 (for example, the angle from the hip to the spine, the angle of the head, or the like) is tilted backward in accordance with the acceleration ratio. As an example of the calculation method of the acceleration ratio, the acceleration ratio can be calculated by using the equation of (“movement amount in the previous frame”−“movement amount in the current frame”)/“movement amount in the previous frame”. As an example of the posture angle correction method, when the coordinates at which the head of the rider object 1000 is positioned in the previous frame are set to 100% and the coordinates at which the head is positioned in the current frame are set to 0%, the coordinates of the interpolation target are calculated by the acceleration ratio (0% to 100%), and the angle correction is performed toward the calculated coordinates. Similarly, when the moving vehicle object 1002 on which the rider object 1000 is riding decelerates, the posture correcting unit 226 makes a correction so that the posture angle of the rider object 1000 is tilted forward in accordance with the deceleration ratio. Note that, in order to prevent the posture angle from being unnatural, the correction of the posture angle of the rider object 1000 by the posture correcting unit 226 may be performed upon defining an upper limit angle by which the posture can be tilted, for each of the front, rear, left, and right directions. Further, in order to prevent the posture angle from being unnatural, the correction of the posture angle of the rider object 1000 by the posture correcting unit 226 may be performed by gradually changing the angle such as in the order of the hip, the lower part of the spine, and the upper part of the spine. Further, in order to prevent the posture angle from being unnatural, the correction of the posture angle of the rider object 1000 by the posture correcting unit 226 may be performed by defining an upper limit angle by which the posture angle can be tilted for each frame.
For example, when the vehicle object 1002 on which the rider object 1000 is riding is on a slope, the posture correcting unit 226 acquires the ground angle and corrects the posture angle of the rider object 1000 so as to cancel out the acquired ground angle.
Further, the posture correcting unit 226 corrects the posture angle of the rider object 1000 so that, when the vehicle object 1002 on which the rider object 1000 is riding takes an action of rising up, the posture of the rider object 1000 is close to a perpendicular state (the original posture angle).
For example, when the vehicle object 1002 on which the rider object 1000 is riding passes over a step, the posture correcting unit 226 acquires the size of the step and corrects the posture angle of the rider object 1000 so that an oscillation corresponding to the acquired size of the step occurs.
In step S14, if “motion correction to be performed” is not set with respect to the selected motion of the rider object 1000, the motion correcting unit 224 skips the processes of step S16 and step S18. For example, the setting of “motion correction to be performed” is set in association with the rider object 1000 and the vehicle object 1002 that are the ride targets.
In step S20, the display control unit 228 displays an image of the rider object 1000 in the state of riding on the vehicle object 1002 on the display unit 204 based on the motion corrected by the motion correcting unit 224 and the posture correcting unit 226.
The motion correction process of step S16 is performed by, for example, the procedure illustrated in
In step S32, the motion correcting unit 224 corrects the motion of the rider object 1000 so as to set the positions of the hand and foot of the rider object 1000 to the positions of the hand and foot attach nodes of the vehicle object 1002.
In step S34, the motion correcting unit 224 sets the position of the backside of the rider object 1000 to the position of the rider attach node and corrects the motion of the rider object 100 so that the posture angle of the rider object 1000 is close to a perpendicular state (the original posture angle).
If the motion data illustrated in
Further, when the motion correction and the posture correction according to the present embodiment are turned off, various motions, such as a motion in which the rider object stands on the vehicle object or a motion in which the rider object jumps on the vehicle object, can be implemented without unnaturally deforming the posture of the rider object. The switching of the motion correction and the posture correction according to the present embodiment between ON and OFF may be set such that only a portion (e.g., only the hand and foot) is turned off depending on the motion to be implemented.
According to the present embodiment, when it is desired to cause the vehicle object and the rider object to perform different motions from each other, the motion of the vehicle object is used to correct and use the motion data of the neutral posture of the rider object, and, therefore, it is possible to reduce the motion data of the rider object required for moving the rider object in accordance with various motions of the vehicle object.
Accordingly, the natural motion of the rider object that is riding the vehicle object can be implemented while reducing the burden of creating motion data for the rider object.
According to one embodiment of the present invention, natural motions of an object that is riding another object can be realized, while reducing the burden of creating motions.
The recording medium, the information processing method, and the information processing apparatus are not limited to the specific embodiments described in the detailed description, and variations and modifications may be made without departing from the spirit and scope of the present invention. Further, the matters described in the above-described embodiments may take other configurations to the extent not inconsistent, and may be combined to the extent not inconsistent.
Number | Date | Country | Kind |
---|---|---|---|
2020-192228 | Nov 2020 | JP | national |