CN115414669A - Motion sensing game method and device based on running posture and computer readable storage medium - Google Patents

Motion sensing game method and device based on running posture and computer readable storage medium Download PDF

Info

Publication number
CN115414669A
CN115414669A CN202211059989.4A CN202211059989A CN115414669A CN 115414669 A CN115414669 A CN 115414669A CN 202211059989 A CN202211059989 A CN 202211059989A CN 115414669 A CN115414669 A CN 115414669A
Authority
CN
China
Prior art keywords
running
player
preset
data
value
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202211059989.4A
Other languages
Chinese (zh)
Inventor
郭超
姚远
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Shimi Network Technology Co ltd
Original Assignee
Shenzhen Shimi Network Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Shimi Network Technology Co ltd filed Critical Shenzhen Shimi Network Technology Co ltd
Priority to CN202211059989.4A priority Critical patent/CN115414669A/en
Publication of CN115414669A publication Critical patent/CN115414669A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • AHUMAN NECESSITIES
    • A63SPORTS; GAMES; AMUSEMENTS
    • A63FCARD, BOARD, OR ROULETTE GAMES; INDOOR GAMES USING SMALL MOVING PLAYING BODIES; VIDEO GAMES; GAMES NOT OTHERWISE PROVIDED FOR
    • A63F13/00Video games, i.e. games using an electronically generated display having two or more dimensions
    • A63F13/55Controlling game characters or game objects based on the game progress
    • AHUMAN NECESSITIES
    • A63SPORTS; GAMES; AMUSEMENTS
    • A63FCARD, BOARD, OR ROULETTE GAMES; INDOOR GAMES USING SMALL MOVING PLAYING BODIES; VIDEO GAMES; GAMES NOT OTHERWISE PROVIDED FOR
    • A63F13/00Video games, i.e. games using an electronically generated display having two or more dimensions
    • A63F13/55Controlling game characters or game objects based on the game progress
    • A63F13/57Simulating properties, behaviour or motion of objects in the game world, e.g. computing tyre load in a car race game
    • AHUMAN NECESSITIES
    • A63SPORTS; GAMES; AMUSEMENTS
    • A63FCARD, BOARD, OR ROULETTE GAMES; INDOOR GAMES USING SMALL MOVING PLAYING BODIES; VIDEO GAMES; GAMES NOT OTHERWISE PROVIDED FOR
    • A63F13/00Video games, i.e. games using an electronically generated display having two or more dimensions
    • A63F13/80Special adaptations for executing a specific game genre or game mode
    • A63F13/816Athletics, e.g. track-and-field sports

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Human Computer Interaction (AREA)
  • Theoretical Computer Science (AREA)
  • Position Input By Displaying (AREA)

Abstract

The invention discloses a motion sensing game method, device and computer readable storage medium based on running postures, wherein the method comprises the following steps: after a preset running motion sensing game is started, acquiring player posture data detected by a motion sensing device; judging whether the player finishes running actions meeting preset standards in a running action data period according to the player posture data; if yes, calculating the running speed of the player according to the posture data of the player in the data period; generating a running instruction according to the running speed; and controlling the game object to execute the matched running action according to the running instruction. The scheme has the advantages of accurate game operation and strong game experience.

Description

Motion sensing game method and device based on running posture and computer readable storage medium
Technical Field
The invention relates to the technical field of motion sensing games, in particular to a motion sensing game method and device based on a running posture and a computer readable storage medium.
Background
Currently, the motion sensing game architecture in the market is generally a motion sensing action architecture based on an Inertial Measurement Unit (IMU). Such a motion sensing motion architecture generally maps a motion gesture of a user in a game, and cannot map a motion speed of a player. Therefore, in some motion sensing games (such as running motion sensing games), when a player plays the game, the game action can only be executed at a fixed speed, but cannot be adaptively changed according to the actual action speed of the player, so that the game experience of the player is influenced.
Disclosure of Invention
The embodiment of the application provides a motion sensing game method based on a running posture, and aims to solve the problem that a motion sensing game cannot map the actual running speed of a player in real time.
In order to achieve the above object, an embodiment of the present application provides a motion sensing game method based on a running posture, including:
after a preset running motion sensing game is started, acquiring player posture data detected by a motion sensing device;
judging whether the player finishes running actions meeting preset standards in a running action data period according to the player posture data;
if yes, calculating the running speed of the player according to the posture data of the player in the data period;
generating a running instruction according to the running speed;
and controlling the game object to execute the matched running action according to the running instruction.
In one embodiment, before determining whether the player completes the running motion meeting the preset standard within the data cycle of the running motion according to the player posture data, the method further comprises:
and determining a data cycle of the player for completing a running action from the player posture data according to a preset rule.
In one embodiment, the player pose data includes an angle value;
the preset rules include:
Figure BDA0003824326230000021
make a<b<c<d, and f a =f b >f c =f d
At the same time, the user can select the required time,
Figure BDA0003824326230000022
let n be 1 <m<n 2 And is and
Figure BDA0003824326230000023
then, n 1 To n 2 A data period of a running motion;
wherein (n) 1 ,n 2 ) F is the angle value of the corresponding time.
In an embodiment, the angle values include an x-axis angle value and a y-axis angle value;
judging whether the player finishes the running action meeting the preset standard in a running action data period according to the player posture data, wherein the running action comprises the following steps:
if the x-axis angle value and the y-axis angle value simultaneously satisfy the following conditions in the data period, determining that the player completes the running action meeting the preset standard, wherein the conditions include:
at least one x-axis angle value is not smaller than a preset x-axis wave peak value, and at least one x-axis angle value is not larger than a preset x-axis wave valley value;
at least one y-axis angle value is not smaller than a preset y-axis wave peak value, and at least one y-axis angle value is not larger than a preset y-axis wave valley value.
In one embodiment, before determining whether the player completes a running motion meeting a preset criterion within a data cycle of a running motion according to the player posture data, the method further comprises:
the angle values are filtered to improve the smoothness of the data.
In one embodiment, filtering the angle value to improve smoothness of the data includes:
filtering the angle values by using a moving average filter, wherein the output value of a moving window of the moving average filter is set to be the minimum of the sum of squares of each sampling value in the window, and the following formula is satisfied:
Figure BDA0003824326230000031
Figure BDA0003824326230000032
wherein, the formula (2) is obtained by solving the limit of the formula (1), wherein, N is the filtering order of the sliding window, X is the output value of the sliding window, and X is the output value of the sliding window K Are the sample values in a sliding window.
In an embodiment, the method further comprises:
and adjusting the preset x-axis wave peak value, the preset x-axis wave valley value, the preset y-axis wave peak value and the preset y-axis wave valley value according to the current game difficulty.
In one embodiment, the player pose data comprises a speed parameter;
calculating a running speed of the player from the player pose data within the data period, comprising:
calculating the average value of all speed parameters in the data period as the running speed.
In order to achieve the above object, an embodiment of the present application further provides a motion sensing game device based on a running gesture, including a memory, a processor, and a motion sensing game program based on a running gesture stored in the memory and executable on the processor, where the processor implements the motion sensing game method based on a running gesture when executing the motion sensing game program based on a running gesture.
To achieve the above object, an embodiment of the present application further provides a computer-readable storage medium, where a running gesture-based somatosensory game program is stored, and when executed by a processor, the running gesture-based somatosensory game program implements a running gesture-based somatosensory game method according to any one of the above aspects.
According to the motion sensing game method based on the running posture, after the fact that the running action of the player is determined to meet the preset standard is completed, the running speed of the player is calculated based on the posture data of the player in a data period, and a running instruction is generated based on the calculated running speed, so that the running speed of the player can be mapped in the game in real time, and the game experience of the player is improved. In addition, the running speed of the player obtained through calculation of the posture data of the player in one data period can be obtained, the calculated speed which is closer to the actual running speed of the player can be obtained, the running speed of the player can be accurately mapped, and the operation experience of the player is improved. Therefore, compared with the traditional motion sensing running game with invariable running speed, the motion sensing game method has the advantages of accurate game operation and strong game experience.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the structures shown in the drawings without creative efforts.
FIG. 1 is a block diagram of a motion sensing game device according to an embodiment of the present invention;
fig. 2 is a flowchart illustrating a motion sensing game method based on a running gesture according to an embodiment of the present invention.
The implementation, functional features and advantages of the objects of the present invention will be further explained with reference to the accompanying drawings.
Detailed Description
It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
For a better understanding of the above technical solutions, exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be embodied in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the disclosure to those skilled in the art.
It should be noted that in the claims, any reference signs placed between parentheses shall not be construed as limiting the claim. The word "comprising" does not exclude the presence of elements or steps not listed in a claim. The word "a" or "an" preceding an element does not exclude the presence of a plurality of such elements. The invention may be implemented by means of hardware comprising several distinct elements, and by means of a suitably programmed computer. In the unit claims enumerating several means, several of these means can be embodied by one and the same item of hardware. The use of "first," "second," and "third," etc. do not denote any order, and such words are to be interpreted as names.
As shown in fig. 1, fig. 1 is a schematic structural diagram of a server 1 (also called a motion sensing game device based on a running gesture) in a hardware operating environment according to an embodiment of the present invention.
The server provided by the embodiment of the invention comprises equipment with a display function, such as Internet of things equipment, an intelligent air conditioner with a networking function, an intelligent lamp, an intelligent power supply, AR/VR equipment with a networking function, an intelligent sound box, an automatic driving automobile, a PC, a smart phone, a tablet personal computer, an electronic book reader, a portable computer and the like.
As shown in fig. 1, the server 1 includes: memory 11, processor 12, and network interface 13.
The memory 11 includes at least one type of readable storage medium, which includes flash memory, a hard disk, a multimedia card, a card type memory (e.g., SD or DX memory, etc.), a magnetic memory, a magnetic disk, an optical disk, and the like. The memory 11 may in some embodiments be an internal storage unit of the server 1, for example a hard disk of the server 1. The memory 11 may also be an external storage device of the server 1 in other embodiments, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and the like, provided on the server 1.
Further, the memory 11 may also include an internal storage unit of the server 1 and also an external storage device. The memory 11 may be used to temporarily store data that has been output or will be output, as well as application software installed in the server 1 and various types of data, such as codes of the motion sensing game program 10 based on a running posture.
The processor 12 may be a Central Processing Unit (CPU), a controller, a microcontroller, a microprocessor or other data Processing chip in some embodiments, and is used for executing program codes stored in the memory 11 or Processing data, such as executing the motion sensing game program 10 based on the running posture.
The network interface 13 may optionally comprise a standard wired interface, a wireless interface (e.g. WI-FI interface), typically used for establishing a communication connection between the server 1 and other electronic devices.
The network may be the internet, a cloud network, a wireless fidelity (Wi-Fi) network, a Personal Area Network (PAN), a Local Area Network (LAN), and/or a Metropolitan Area Network (MAN). Various devices in the network environment may be configured to connect to the communication network according to various wired and wireless communication protocols. Examples of such wired and wireless communication protocols may include, but are not limited to, at least one of: transmission control protocol and internet protocol (TCP/IP), user Datagram Protocol (UDP), hypertext transfer protocol (HTTP), file Transfer Protocol (FTP), zigBee, EDGE, IEEE802.11, optical fidelity (Li-Fi), 802.16, IEEE802.11 s, IEEE802.11g, multi-hop communications, wireless Access Points (APs), device-to-device communications, cellular communication protocol, and/or bluetooth (Blue Tooth) communication protocol, or a combination thereof.
Optionally, the server may further comprise a user interface, which may include a Display (Display), an input unit such as a Keyboard (Keyboard), and an optional user interface may also include a standard wired interface, a wireless interface. Alternatively, in some embodiments, the display may be an LED display, a liquid crystal display, a touch-sensitive liquid crystal display, an OLED (Organic Light-Emitting Diode) touch device, or the like. The display, which may also be referred to as a display screen or display unit, is used for displaying information processed in the server 1 and for displaying a visualized user interface.
While fig. 1 shows only a server 1 having components 11-13 and a motion sensing game program 10 based on a running gesture, those skilled in the art will appreciate that the configuration shown in fig. 1 is not limiting of the server 1 and may include fewer or more components than shown, or some components in combination, or a different arrangement of components.
In this embodiment, the processor 12 may be configured to call the motion sensing game program based on the running gesture stored in the memory 11, and perform the following operations:
after a preset running motion sensing game is started, acquiring player posture data detected by a motion sensing device;
judging whether the player finishes running actions meeting preset standards in a running action data period according to the player posture data;
if yes, calculating the running speed of the player according to the posture data of the player in the data period;
generating a running instruction according to the running speed;
and controlling the game object to execute the matched running action according to the running instruction.
In one embodiment, the processor 12 may be configured to call the somatosensory game program stored in the memory 11 based on the running posture, and perform the following operations:
before determining whether the player completes the running motion meeting the preset standard within the data period of the running motion according to the player posture data, the method further comprises the following steps:
and determining a data period of a running action completed by the player from the player posture data according to a preset rule.
In one embodiment, the processor 12 may be configured to call the somatosensory game program stored in the memory 11 based on the running posture, and perform the following operations:
the player pose data comprises an angle value;
the preset rules include:
Figure BDA0003824326230000071
a is caused to be<b<c<d, and f a =f b >f c =f d
At the same time, the user can select the desired position,
Figure BDA0003824326230000072
let n be 1 <m<n 2 And is and
Figure BDA0003824326230000073
then, n 1 To n 2 A data period of a running motion;
wherein (n) 1 ,n 2 ) F is the angle value of the corresponding time.
In one embodiment, the processor 12 may be configured to call the somatosensory game program stored in the memory 11 based on the running posture, and perform the following operations:
the angle values include an x-axis angle value and a y-axis angle value;
judging whether the player finishes the running action meeting the preset standard in a running action data period according to the player posture data, wherein the running action meeting the preset standard comprises the following steps:
if the x-axis angle value and the y-axis angle value simultaneously satisfy the following conditions in the data period, determining that the player completes the running action meeting the preset standard, wherein the conditions include:
at least one x-axis angle value is not smaller than a preset x-axis wave peak value, and at least one x-axis angle value is not larger than a preset x-axis wave valley value;
at least one y-axis angle value is not smaller than a preset y-axis wave peak value, and at least one y-axis angle value is not larger than a preset y-axis wave valley value.
In one embodiment, the processor 12 may be configured to call the somatosensory game program stored in the memory 11 based on the running posture, and perform the following operations:
before determining whether the player completes the running motion meeting the preset standard within the data period of the running motion according to the player posture data, the method further comprises the following steps:
the angle values are filtered to improve the smoothness of the data.
In an embodiment, the processor 12 may be configured to call the motion sensing game program based on the running gesture stored in the memory 11, and perform the following operations:
filtering the angle values to improve data smoothness, comprising:
filtering the angle values by using a moving average filter, wherein the output value of a moving window of the moving average filter is set to be the minimum of the sum of squares of each sampling value in the window, and the following formula is satisfied:
Figure BDA0003824326230000091
Figure BDA0003824326230000092
wherein, the formula (2) is obtained by solving the limit of the formula (1), wherein, N is the filtering order of the sliding window, X is the output value of the sliding window, and X is the output value of the sliding window K Are the sample values in a sliding window.
In one embodiment, the processor 12 may be configured to call the somatosensory game program stored in the memory 11 based on the running posture, and perform the following operations:
the method further comprises the following steps:
and adjusting the preset x-axis wave peak value, the preset x-axis wave valley value, the preset y-axis wave peak value and the preset y-axis wave valley value according to the current game difficulty.
In one embodiment, the processor 12 may be configured to call the somatosensory game program stored in the memory 11 based on the running posture, and perform the following operations:
the player pose data comprises a velocity parameter;
calculating a running speed of the player from the player pose data within the data period, comprising:
calculating the average value of all speed parameters in the data period as the running speed.
Based on the hardware architecture of the motion sensing game device based on the running posture, the embodiment of the motion sensing game method based on the running posture is provided. The invention discloses a motion sensing game method based on a running posture, and aims to solve the problem that a motion sensing game cannot map the actual running speed of a player in real time.
Referring to fig. 2, fig. 2 is a diagram illustrating an embodiment of a motion sensing game method based on a running gesture according to the present invention, where the motion sensing game method based on a running gesture includes the following steps:
and S10, acquiring player posture data detected by the body sensing equipment after a preset running type body sensing game is started.
Among them, the running-like feeling game is a game that requires a player to run in reality. Among them, the running-type feeling game may be race, relay, long distance, intermittence, etc. Certainly, the running type feeling game is not limited to the above types, and may also include other games, which are not illustrated here, and all games that require a player to run in reality to realize a game instruction may be considered as the running type feeling game mentioned in the technical solution of the present application.
Further, the preset running motion sensing game runs on a terminal, and the terminal can be a desktop computer, a notebook computer, a game host, a portable game host, a smart phone, a tablet computer, a smart watch, a smart television and the like.
Here, the motion sensing device refers to a device capable of detecting posture data of a player, and in general, the motion sensing device is configured to include a six-axis IMU sensor including a three-axis accelerometer and a three-axis gyroscope, the six-axis IMU sensor detecting posture data of the player by detecting a change in three-axis acceleration and a change in three-axis angular velocity of the player. Specifically, the motion sensing device is wearable, and the form thereof includes, but is not limited to, the following: a bracelet, a glove watch, a headband, a hat, a vest, a body-building ring and a game handle.
Specifically, when the player posture data is transmitted to the terminal, the embedded algorithm of the motion sensing detection device converts the detected three-axis acceleration data and three-axis angular velocity data into velocity parameters, angle values, space coordinates and the like which can be directly called by the terminal, and then transmits the velocity parameters, the angle values, the space coordinates and the like to the terminal.
Further, before playing, the motion sensing device needs to establish communication connection with the terminal, and wired connection or wireless connection can be established between the motion sensing device and the terminal. For example, when the somatosensory device establishes a wired connection with the terminal, the wired connection can be based on at least one of a USB2.0 protocol, a USB3.0 protocol, a thunder and lightning 3 protocol and a thunder and lightning 4 protocol; and when the somatosensory device is wirelessly connected with the terminal, the somatosensory device can be based on at least one of a Bluetooth protocol, a WiFi protocol, an infrared protocol, a 2.4G communication protocol and an NFC protocol.
And S20, judging whether the running action meeting the preset standard is finished by the player in a running action data period according to the player posture data.
When the motion sensing device detects that the player completes a complete front-back swing arm action, the player is considered to complete a complete running action. Specifically, when the motion sensing game is played, the player performs periodic motions, such as a swing arm motion, a leg swing motion, a striding motion, and the like, and accordingly, the motion sensing posture data acquired when the player runs is also periodic. Thus, the terminal can determine a time period for the player to complete a running action based on the periodicity of the player's pose data. Since this time period is accompanied by a large amount of player posture data, we define the time period during which the player completes one running action as a data period.
Further, after determining a data period of a running action of the player, the terminal may determine whether the player has completed the running action meeting the preset criteria according to the posture data of the player in the data period. The preset standard is used for requiring that the running intensity of the player must reach a certain intensity, and the terminal generates a corresponding running instruction and maps the running instruction in the game only when the running intensity of the player in reality is enough.
And S30, if yes, calculating the running speed of the player according to the posture data of the player in the data period.
The motion sensing device sends the player posture data to the terminal at a fixed frequency, which is usually set to 50hz, that is, the motion sensing device sends 50 packets to the terminal within 1 second, and each packet includes the player posture data detected by the motion sensing device at a corresponding time. The player pose data includes, without limitation, three-axis (x, y, and z) angle values, velocity parameters, and spatial coordinates.
Specifically, after determining a data period for a player to complete a running action, the pose data for a player to complete a running action may be further determined based on the start and end times of the data period. Since the player pose data includes speed parameters, a running speed at which the player performs a running action can be calculated based on the speed parameters.
It can be understood that, the running speed of the player completing the current running action is calculated according to all the speed parameters in one data cycle, and the obtained running speed of the player is closer to the actual running speed of the player, so that the accuracy of the calculation of the running speed of the player is improved.
And S40, generating a running instruction according to the running speed.
Specifically, when it is determined that the player has finished running motions that meet the preset criteria, and after calculating the running speed of the player, the terminal may generate a corresponding running instruction based on a mapping relationship between the preset running speed and the running motions. The running action in the game can be matched with the actual action of the player based on the preset mapping relation between the running speed and the running action, and then the game action can be adaptively changed according to the actual running speed, so that the game experience of the player is improved.
And S50, controlling the game object to execute a matched running action according to the running instruction.
Here, the game object is an object that is controlled by a player during a game, and may be a game character of the player or an object in the game.
Specifically, after the running speed of the player is determined, the running action corresponding to the running speed can be generated in the game, and thus the running speed of the player can be displayed in the motion sensing game in real time.
It can be understood that, in the motion sensing game method based on the running posture in the technical scheme of the application, after the running action meeting the preset standard is determined to be completed by the player, the running speed of the player is calculated based on the player posture data of the player in a data period, and the running instruction is generated based on the calculated running speed, so that the running speed of the player can be mapped in the game in real time, and the game experience of the player is improved. In addition, the running speed of the player obtained through calculation of the posture data of the player in one data period can be obtained, the calculated speed which is closer to the actual running speed of the player can be obtained, the running speed of the player can be accurately mapped, and the operation experience of the player is improved. Therefore, compared with the traditional motion sensing running game with invariable running speed, the motion sensing game method has the advantages of accurate game operation and strong game experience.
In some embodiments, before determining whether the player completes a running action meeting a preset criterion in a data cycle of the running action according to the player posture data, the motion sensing game method of the present application further includes:
and determining a data period of a running action completed by the player from the player posture data according to a preset rule.
Specifically, since the running action has a certain periodicity, the period rule of the running action can be obtained by testing the data to obtain the required preset rule. After determining the preset rule, we can embed the preset rule into the game, so that the terminal can directly call the preset rule to determine the data cycle of a running action completed by a player when the game runs.
Specifically, the player pose data includes angle values, including specifically an x-axis angle value, a y-axis angle value, and a z-axis angle value. Here, the x-axis, the y-axis, and the z-axis together form a geodetic coordinate system in which the x-axis represents the front-rear direction, the y-axis represents the up-down direction, and the z-axis represents the left-right direction.
In some embodiments, the preset rules include:
Figure BDA0003824326230000131
a is caused to be<b<c<d, and f a =f b >f c =f d
At the same time, the user can select the desired position,
Figure BDA0003824326230000132
let n be 1 <m<n 2 And is and
Figure BDA0003824326230000133
then n is 1 To n 2 A data period of a running motion;
wherein (n) 1 ,n 2 ) The time intervals are continuous, and f is the angle value of the corresponding time.
Specifically, f is an angle value of any one of the x-axis, the y-axis and the z-axis, and the angle value of any one of the axes can be selected according to the preset rule to confirm that the player completes a data cycle of the running action.
Specifically, it can be seen from the experimental data that the time-dependent change curve of the angle values in the player posture data is similar to a sinusoidal curve when the player is performing a running action. Therefore, we make a preset rule according to the sine curve.
According to the sine curve, if a, b, c and d belong to n 1 To n 2 Interval, and the angle values f corresponding to a, b, c and d a 、f b 、f c 、f d There is a relationship of f a =f b >f c =f d Then, explain n 1 To n 2 Are respectively located at sineTwo 1/2 cycles before and after the curve, that is, an interval in which the current data interval is greater than or equal to one cycle of the sinusoidal curve can be determined according to the above condition.
Further, if m is present, m belongs to n 1 To n 2 Interval of n 1 <m<n 2 And is and
Figure BDA0003824326230000134
then the specification is at n 1 To n 2 Within the interval, at least three angular values pass through the zero point (i.e., the start or initial point of the sinusoid).
Therefore, it is considered that n is n according to the above conditions 1 To n 2 The interval coincides with an interval of one cycle of the sine curve, and n 1 And n 2 Respectively, the two endpoints of the interval. Then n can be adjusted 1 To n 2 The interval is regarded as a data period of one complete running motion played by the user.
It can be understood that in the above manner, we can accurately divide a data period in which the player completes one running motion from continuous data based on the periodicity of the posture data of the running motion.
In some embodiments, determining whether the player has completed a running action meeting a predetermined criterion within a data cycle of the running action according to the player posture data includes:
if the x-axis angle value and the y-axis angle value simultaneously satisfy the following conditions in the data period, determining that the player completes the running action meeting the preset standard, wherein the conditions include:
at least one x-axis angle value is not smaller than a preset x-axis wave peak value, and at least one x-axis angle value is not larger than a preset x-axis wave valley value;
at least one y-axis angle value is not smaller than a preset y-axis wave peak value, and at least one y-axis angle value is not larger than a preset y-axis wave valley value.
The angle values of the player posture data include an x-axis angle value, a y-axis angle value and a z-axis angle value, and when the player performs running exercise, the periodicity and the intensity of changes of the x-axis angle value and the y-axis angle value are more obvious than those of the z-axis angle value, so that in practical application, the x-axis angle value and the y-axis angle value are selected to judge whether the running action of the player is standard.
Specifically, for the x-axis angle value, after it is determined that the player completes a standard running action, the terminal traverses all the x-axis angle values in the data period, and while traversing, the terminal compares the x-axis angle value being traversed with a preset x-axis wave peak value and a preset x-axis wave valley value, and determines whether the current x-axis angle value is greater than or equal to the preset x-axis wave peak value and whether the current x-axis angle value is less than or equal to the preset x-axis wave valley value, wherein if the current x-axis angle value is a positive value, the terminal determines whether the current x-axis angle value is greater than or equal to the preset x-axis wave peak value; if the current x-axis angle value is a negative value, the terminal can judge whether the current x-axis angle value is smaller than or equal to a preset x-axis valley value.
Similarly, for the y-axis angle value, the terminal also traverses all the y-axis angle values in the data period, and compares the traversed y-axis angle value with a preset y-axis wave peak value and a preset y-axis wave valley value during traversal.
When the x-axis angle value and the y-axis angle value satisfy the two conditions, it can be determined that the player has completed the running action meeting the preset standard. It should be noted that the preset x-axis peak value and the preset x-axis valley value may be understood as a criterion for determining the running intensity and the running completion of the player by the terminal, and the larger the absolute value of the preset x-axis peak value and the preset x-axis valley value is, the higher the requirement on the running intensity and the running completion is, whereas the smaller the absolute value of the preset x-axis peak value and the preset x-axis valley value is, the lower the requirement on the running intensity and the running completion is.
Can understand, whether the action of running that accords with the default standard is accomplished in order to judge the player according to x axle angle value and y axle angle value simultaneously, can improve the accuracy of judging the action of running to the player like this, and then improve the operation precision of feeling the recreation and with the matching degree of reality action, promote player's gaming experience.
In some embodiments, before determining from the player posture data whether the player has completed a running action meeting a preset criterion within a data period of a running action, the method further comprises:
the angle values are filtered to improve the smoothness of the data.
Specifically, the smoothness of the enhanced data is that the graph of the filtered angle value is smoother than the graph of the original angle value, and the essence is that data with obvious abnormality in the angle value is filtered out by filtering, so that the smoothness of the waveform is enhanced.
For example, the angle value may be filtered by using a sliding average method, a variance method, or a normalization method.
It can be understood that the credibility of the angle value detected by the motion sensing device can be improved by filtering the angle value, so that the matching degree between the angle value and the real action data of the player can be improved after Kalman filtering.
In some embodiments, filtering the angle value to improve the smoothness of the data comprises:
filtering the angle values by using a moving average filter, wherein the output value of a moving window of the moving average filter is set to be the minimum of the sum of squares of each sampling value in the window, and the following formula is satisfied:
Figure BDA0003824326230000151
Figure BDA0003824326230000152
wherein, the formula (2) is obtained by solving the limit of the formula (1), wherein, N is the filtering order of the sliding window, X is the output value of the sliding window, and X is the output value of the sliding window K Are the sample values in a sliding window.
Specifically, the moving average filtering is to set a sliding window to slide on data along the time direction, output one value as a filtered value at each sliding, and slide only the length of one sample value at each sliding. Here, the filtering order of the sliding window can also be understood as the length of the window, i.e. the number of sampling values that the window can cover, and the sampling values refer to the original data of the player posture.
Generally, the output value of the sliding window is the average value of each sampling value in the window, and in the technical solution of the present application, the sum of the square of the output value of the sliding window and each sampling value in the window is required to be minimum. Thus, compared with the mode of outputting the average value, the method can be closer to the true value, namely, the filtering effect on the noise in the data is better.
It will be appreciated that the above described approach enables efficient and accurate filtering of the angle values. Of course, the design of the present application is not limited thereto, and in other embodiments, the angle value may be filtered by a conventional moving average method.
In some embodiments, the method of the present application further comprises:
and adjusting the preset x-axis wave peak value, the preset x-axis wave valley value, the preset y-axis wave peak value and the preset y-axis wave valley value according to the current game difficulty.
The current game difficulty can be represented by game level, game task and difficulty level. The player can select the game intensity matched with the physical quality of the player to play the game according to the actual situation of the player on the game interface on the terminal.
Specifically, a preset x-axis wave peak value, a preset x-axis wave valley value, a preset y-axis wave peak value and a preset y-axis wave valley value which are matched with different game difficulties can be preset in a game. So, alright adaptation different recreation degree of difficulty adjustment are accomplished the intensity of the action of running, and then help can be fit for the player of different fitness and play to promote player's running experience.
In some embodiments, calculating the running speed of the player from the player pose data within the data period comprises:
calculating the average value of all speed parameters in the data period as the running speed.
Specifically, after the action period of the player is determined, the terminal can obtain the starting and stopping time when the player completes one running action, further, the average value can be calculated according to the speed parameters of all the time within the starting and stopping time, the average value is used as the running speed when the player completes the running action, and further, the matching performance of the game action and the real running speed is improved. Of course, in other embodiments, the running speed of the player can also be taken as the median of all the speed parameters.
In addition, the embodiment of the present invention further provides a computer-readable storage medium, which may be any one of or any combination of a hard disk, a multimedia card, an SD card, a flash memory card, an SMC, a Read Only Memory (ROM), an Erasable Programmable Read Only Memory (EPROM), a portable compact disc read only memory (CD-ROM), a USB memory, and the like. The computer-readable storage medium includes a motion sensing game program 10 based on a running gesture, and the specific embodiment of the computer-readable storage medium of the present invention is substantially the same as the specific embodiment of the motion sensing game method based on a running gesture and the server 1, and will not be described again.
As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, system, or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present invention is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
While preferred embodiments of the present invention have been described, additional variations and modifications in those embodiments may occur to those skilled in the art once they learn of the basic inventive concepts. Therefore, it is intended that the appended claims be interpreted as including preferred embodiments and all such alterations and modifications as fall within the scope of the invention.
It will be apparent to those skilled in the art that various changes and modifications may be made in the present invention without departing from the spirit and scope of the invention. Thus, if such modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include such modifications and variations.

Claims (10)

1. A motion sensing game method based on a running posture is characterized by comprising the following steps:
after a preset running motion sensing game is started, acquiring player posture data detected by a motion sensing device;
judging whether the player finishes running action meeting preset standard in a running action data period according to the player posture data;
if yes, calculating the running speed of the player according to the posture data of the player in the data period;
generating a running instruction according to the running speed;
and controlling the game object to execute the matched running action according to the running instruction.
2. The method for motion sensing game based on running gesture according to claim 1, wherein before determining whether the player has completed a running motion meeting a preset criterion within a data period of a running motion according to the player posture data, the method further comprises:
and determining a data cycle of the player for completing a running action from the player posture data according to a preset rule.
3. The running gesture-based somatosensory gaming method of claim 2, wherein the player pose data comprises an angle value;
the preset rules include:
Figure FDA0003824326220000011
b、c、d∈(n 1 ,n 2 ) Let a be<b<c<d, and f a =f b >f c =f d
At the same time, the user can select the required time,
Figure FDA0003824326220000012
let n be 1 <m<n 2 And is made of
Figure FDA0003824326220000013
Then, n 1 To n 2 A data period of a running motion;
in the formula (n) 1 ,n 2 ) The time intervals are continuous, and f is the angle value of the corresponding time.
4. The method of running gesture-based somatosensory gaming of claim 3, wherein the angle values comprise an x-axis angle value and a y-axis angle value;
judging whether the player finishes the running action meeting the preset standard in a running action data period according to the player posture data, wherein the running action meeting the preset standard comprises the following steps:
if the x-axis angle value and the y-axis angle value simultaneously satisfy the following conditions in the data period, determining that the player completes the running action meeting the preset standard, wherein the conditions include:
at least one x-axis angle value is not smaller than a preset x-axis wave peak value, and at least one x-axis angle value is not larger than a preset x-axis wave valley value;
at least one y-axis angle value is not smaller than a preset y-axis wave peak value, and at least one y-axis angle value is not larger than a preset y-axis wave valley value.
5. The running gesture-based somatosensory gaming method according to claim 4, wherein before determining from the player posture data whether the player has completed a running action meeting a preset criterion within a data period of a running action, the method further comprises:
the angle values are filtered to improve the smoothness of the data.
6. The method of claim 5, wherein filtering the angle value to improve data smoothness comprises:
filtering the angle values by using a moving average filter, wherein the output value of a moving window of the moving average filter is set to be the minimum of the sum of squares of each sampling value in the window, and the following formula is satisfied:
Figure FDA0003824326220000021
Figure FDA0003824326220000022
wherein, the formula (2) is obtained by solving the limit of the formula (1), wherein, N is the filtering order of the sliding window, X is the output value of the sliding window, and X is the output value of the sliding window K Are the sample values in a sliding window.
7. The method of running gesture-based somatosensory gaming of claim 4, wherein the method further comprises:
and adjusting the preset x-axis wave peak value, the preset x-axis wave valley value, the preset y-axis wave peak value and the preset y-axis wave valley value according to the current game difficulty.
8. A running gesture-based somatosensory gaming method according to claim 1 or 4, wherein the player gesture data comprises a velocity parameter;
calculating a running speed of the player from the player pose data within the data period, comprising:
calculating the average value of all speed parameters in the data period as the running speed.
9. A running gesture-based motion sensing game apparatus, comprising a memory, a processor, and a running gesture-based motion sensing game program stored in the memory and executable on the processor, wherein the processor, when executing the running gesture-based motion sensing game program, implements the running gesture-based motion sensing game method according to any one of claims 1 to 8.
10. A computer-readable storage medium, wherein the computer-readable storage medium has stored thereon a running gesture-based somatosensory game program which, when executed by a processor, implements the running gesture-based somatosensory game method according to any one of claims 1-8.
CN202211059989.4A 2022-08-31 2022-08-31 Motion sensing game method and device based on running posture and computer readable storage medium Pending CN115414669A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211059989.4A CN115414669A (en) 2022-08-31 2022-08-31 Motion sensing game method and device based on running posture and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211059989.4A CN115414669A (en) 2022-08-31 2022-08-31 Motion sensing game method and device based on running posture and computer readable storage medium

Publications (1)

Publication Number Publication Date
CN115414669A true CN115414669A (en) 2022-12-02

Family

ID=84199691

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211059989.4A Pending CN115414669A (en) 2022-08-31 2022-08-31 Motion sensing game method and device based on running posture and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN115414669A (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070243931A1 (en) * 2006-04-14 2007-10-18 Nintendo Co., Ltd. Game apparatus and game program
CN107747950A (en) * 2017-09-28 2018-03-02 上海惠芽信息技术有限公司 Step recording method and device
US20180224930A1 (en) * 2015-08-04 2018-08-09 Board Of Regents Of The Nevada System Of Higher Education, On Behalf Of The University Of Nevada, Immersive virtual reality locomotion using head-mounted motion sensors
CN110263870A (en) * 2019-06-26 2019-09-20 深圳市悦动天下科技有限公司 Moving state identification method, apparatus, intelligent terminal and storage medium
CN110694252A (en) * 2019-10-09 2020-01-17 成都乐动信息技术有限公司 Running posture detection method based on six-axis sensor
CN114949839A (en) * 2022-06-14 2022-08-30 深圳十米网络科技有限公司 Swimming posture-based motion sensing game method

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070243931A1 (en) * 2006-04-14 2007-10-18 Nintendo Co., Ltd. Game apparatus and game program
US20180224930A1 (en) * 2015-08-04 2018-08-09 Board Of Regents Of The Nevada System Of Higher Education, On Behalf Of The University Of Nevada, Immersive virtual reality locomotion using head-mounted motion sensors
CN107747950A (en) * 2017-09-28 2018-03-02 上海惠芽信息技术有限公司 Step recording method and device
CN110263870A (en) * 2019-06-26 2019-09-20 深圳市悦动天下科技有限公司 Moving state identification method, apparatus, intelligent terminal and storage medium
CN110694252A (en) * 2019-10-09 2020-01-17 成都乐动信息技术有限公司 Running posture detection method based on six-axis sensor
CN114949839A (en) * 2022-06-14 2022-08-30 深圳十米网络科技有限公司 Swimming posture-based motion sensing game method

Similar Documents

Publication Publication Date Title
US10222868B2 (en) Wearable device and control method using gestures
US20220226728A1 (en) Route navigation system within a game application environment
CN114949839A (en) Swimming posture-based motion sensing game method
EP3007030A1 (en) Portable device and control method via gestures
CN115414669A (en) Motion sensing game method and device based on running posture and computer readable storage medium
CN116196611A (en) Somatosensory game method based on waving action
CN116173492A (en) Motion sensing game method based on boxing motion
TW202117588A (en) Human body portion tracking method and human body portion tracking system
CN117138325A (en) Motion sensing rope skipping game method based on function fitting
CN115282589A (en) Somatosensory game method based on rope skipping action
CN115006840A (en) Somatosensory online game method, device and computer-readable storage medium
CN115845356A (en) Motion sensing game method based on swiping action
CN115531867A (en) Operation method of running somatosensory game
US20230398431A1 (en) Implementing translation action based motion sensing game
CN116271783A (en) Somatosensory tug-of-war game method, device, equipment and computer readable storage medium
CN116271785A (en) Somatosensory game method based on slapping action
CN115337627A (en) Boxing motion sensing game method and device and computer readable storage medium
CN115253270A (en) Table tennis ball feeling game method
CN115445201A (en) Skating motion sensing game method and device and computer readable storage medium
Wronski Design and implementation of a hand tracking interface using the nintendo wii remote
CN117991901A (en) Motion-based somatosensory game method
CN116251343A (en) Somatosensory game method based on throwing action
CN117180744A (en) Game operation method based on bar-shaped somatosensory controller
CN115869611A (en) Somatosensory game method based on climbing action
CN116129518A (en) Somatosensory operation method based on gesture recognition

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination