Webcam-Based Exergame for Motor Recovery with Physical Assessment via DTW
Abstract
1. Introduction
2. Related Works
2.1. Rehabilitation Technologies
2.1.1. Traditional and Hardware-Assisted Rehabilitation
2.1.2. Exergaming for Rehabilitation
2.1.3. Home-Based Rehabilitation
2.1.4. Leveraging Computer Vision
2.1.5. Physical Assessment Integrated with Exergaming
2.1.6. Comparison with Existing Exergaming Systems
- Requires Only Common Webcam: Determines whether the system works with common webcams (RGB cameras) without requiring specialized hardware.
- Independence from Supervision: Evaluates if patients can undergo rehabilitation without constant therapist oversight.
- Remote Monitoring Capability: Assesses whether caregivers can track rehabilitation progress remotely.
- Integration of Standardized Physical Assessments: Examines if the system includes clinically standardized tools for objective movement analysis.
- Movement Data Collection or Analysis During Exergaming: Identifies if the system records or analyzes movement data in real-time while exergaming.
2.2. Standardized Physical Assessments Integrated with Exergaming
2.2.1. Fugl-Mayer Assessment Upper Extremity (FMA-UE)
2.2.2. Dynamic Time Warping (DTW)
3. The Proposed System
3.1. System Overview
3.2. Motion Detection Module (MDM)
3.2.1. Pose Estimation
3.2.2. Feature Extraction for Motion Detection
3.2.3. Data Smoothing for Motion Detection
3.2.4. Motion Detection and Segmentation
3.3. Physical Assessment Module (PAM)
3.3.1. Feature Extraction for Physical Assessment
3.3.2. Data Smoothing for Physical Assessment
3.3.3. Mean Normal Trajectory Calculation
3.3.4. Baseline Comparison
3.3.5. Score Calculation
3.4. Exergame
3.4.1. A Pilot Exergame: Meow Runner
3.4.2. Motion to Game Input
3.5. Report Module
3.6. RehabHub Web Application
- Dashboard: Summarizes the patient’s progress, displaying metrics such as completed exercises and performance scores.
- Task Bar: Lists prescribed activities and exercises assigned by doctors.
- Doctor’s Advice: Features personalized guidance and instructions tailored to the patient’s progress and needs.
- Game Library: Provides access to rehabilitation programs, including exergames that utilize postures for interactive inputs.
- Statistics: Provides detailed visualizations of patient performance, including recorded videos and progress metrics across rehabilitation activities.
- Encyclopedia and FAQ: Offers educational content about physical disability and answers to common questions about rehabilitation and the application.
4. Experiment
- 1.
- Assessing the system’s ability to differentiate between normal and abnormal movements.
- 2.
- Identifying the optimal feature extraction method for representing motion segments, such as using a single-angle versus multiple angles.
- 3.
- Exploring the scoring system, which quantifies motor performance based solely on normal training samples, applied to test samples of both normal and abnormal movements.
4.1. Data Collection
4.1.1. Participants
4.1.2. Apparatus
4.1.3. Procedure
4.1.4. Movement Execution Protocol
4.1.5. Recorded Data
4.2. Analysis and Results
4.2.1. Dataset Preparation
- Baseline Normal Movement (Subset B)—Normal data used for training, forming the mean normal trajectories, and consequently the baseline (referred to as “Sample Normal Subject Data” in Figure 5).
- Test Normal Movement (Subset N)—Normal data used for evaluating the system’s performance.
- Test Abnormal Movement (Subset A)—Abnormal data used for testing movement differentiation.
4.2.2. Analysis of Distance
- Single-angle—Using only the main joint angle, specifically the shoulder for abduction and shoulder flexion, and the elbow for elbow flexion.
- Dual-angle—Using a combination of shoulder and elbow angles for every exercise motion.
- Triple-angle—Using three angles, including an additional wrist angle.
- The single-angle method provides the expected results in all cases under both tests. It can be observed that the shoulder angle effectively distinguishes between normal and abnormal movement for abduction and shoulder flexion, with a p-value less than 0.0001. The elbow angle yields similar results when used for elbow flexion.
- The triple-angle method provides good results only for abduction and elbow flexion. However, for shoulder flexion, it was found that the two normal data subsets, B and N, are significantly different. Since the mean trajectory is calculated from subset B, it is possible that the mean normal trajectories overfit the training data.
- For shoulder flexion, there are no significant differences in elbow angle between all pairs of subsets. Based on the U-test, the p-values between normal (subsets B or N) data and abnormal (subset A) are 0.9745 and 0.0854, respectively. These p-values are notably different, indicating that this feature may be sensitive to sample data and could contribute to the issue mentioned above. We suggest that the elbow angle be omitted when analyzing shoulder flexion.
- For elbow flexion, based on the t-test, the shoulder angle shows no significant difference between subsets B and A, but there is a significant difference between N and A. The p-values are close to the 0.05 threshold. Additionally, in Figure 12e, it can be observed that the shoulder angle is vertically dispersed, lacking a uniform pattern. Therefore, the result appears sensitive to statistical coincidence, and, similarly to the previous case, we believe the shoulder angle should be omitted when analyzing elbow flexion.
- Both single-angle and dual-angle methods provide good results in both the t-test and U-test. However, since it was concluded that the elbow angle is not recommended for shoulder flexion and the shoulder angle is not recommended for elbow flexion, the dual-angle method, which uses both angles for all motions, is less recommended than the single-angle method, which already performs well.
- The wrist angle alone shows good results in all cases except one (the comparison between subsets B and A for shoulder flexion in the t-test). However, we later realized that the wrist angle might be affected because participants simulated abnormal movement data by holding a 5-kg resistance band (cf. Figure 11). Furthermore, the range of motion for the wrist is relatively small compared to the main joint angles, meaning that fluctuations in this angle are minimal; if all angles are equally weighted, the wrist angle could be more sensitive to small noise, potentially impacting the overall accuracy. Therefore, the wrist angle should be excluded if the single-angle method already performs well enough.
4.2.3. Exploration of the Scoring Mechanism
4.2.4. Challenges in Shoulder Flexion Scoring
4.2.5. Limitations and Concerns
4.2.6. Key Findings from Experiment
5. Conclusions
Author Contributions
Funding
Institutional Review Board Statement
Informed Consent Statement
Data Availability Statement
Acknowledgments
Conflicts of Interest
Abbreviations
| DTW | Dynamic Time Warping |
| FMA-UE | Fugl–Meyer Assessment for Upper Extremity |
| MDM | Motion Detection Module |
| PAM | Physical Assessment Module |
| RM | Report Module |
| ROM | Range of Motion |
| WMFT | Wolf Motor Function Test |
| BBT | Box and Block Test |
| DDA | Dynamic Difficulty Adjustment |
References
- World Stroke Organization. Learn About Stroke. 2023. Available online: https://www.world-stroke.org/world-stroke-day-campaign/about-stroke/impact-of-stroke (accessed on 21 February 2023).
- Jacob, L.; Koyanagi, A.; Oh, H.; Smith, L.; Konrad, M.; Shin, J.I.; Haro, J.M.; Kostev, K. Association between adhesive capsulitis and depression: A five-year retrospective cohort study including 58,516 adults from Germany. J. Psychiatr. Res. 2022, 155, 395–400. [Google Scholar] [CrossRef]
- Craig, L.E.; Wu, O.; Bernhardt, J.; Langhorne, P. Approaches to economic evaluations of stroke rehabilitation. Int. J. Stroke 2014, 9, 88–100. [Google Scholar] [CrossRef]
- Weber, L.M.; Stein, J. The use of robots in stroke rehabilitation: A narrative review. NeuroRehabilitation 2018, 43, 99–110. [Google Scholar] [CrossRef]
- Chen, Y.; Abel, K.T.; Janecek, J.T.; Chen, Y.; Zheng, K.; Cramer, S.C. Home-based technologies for stroke rehabilitation: A systematic review. Int. J. Med. Inform. 2019, 123, 11–22. [Google Scholar] [CrossRef]
- Latreche, A.; Kelaiaia, R.; Chemori, A.; Kerboua, A. Reliability and validity analysis of MediaPipe-based measurement system for some human rehabilitation motions. Measurement 2023, 214, 112826. [Google Scholar] [CrossRef]
- Kim, J.W.; Choi, J.Y.; Ha, E.J.; Choi, J.H. Human pose estimation using mediapipe pose and optimization method based on a humanoid model. Appl. Sci. 2023, 13, 2700. [Google Scholar] [CrossRef]
- Kharrazi, H.; Lu, A.S.; Gharghabi, F.; Coleman, W. A scoping review of health game research: Past, present, and future. Games Health Res. Dev. Clin. Appl. 2012, 1, 153–164. [Google Scholar] [CrossRef]
- Burke, J.W.; McNeill, M.; Charles, D.K.; Morrow, P.J.; Crosbie, J.H.; McDonough, S.M. Optimising engagement for stroke rehabilitation using serious games. Vis. Comput. 2009, 25, 1085–1099. [Google Scholar] [CrossRef]
- Fugl-Meyer, A.R.; Jääskö, L.; Leyman, I.; Olsson, S.; Steglind, S. A method for evaluation of physical performance. Scand. J. Rehabil. Med. 1975, 7, 13–31. [Google Scholar] [CrossRef] [PubMed]
- Woodbury, M.L.; Velozo, C.A.; Richards, L.G.; Duncan, P.W.; Studenski, S.; Lai, S.M. Longitudinal stability of the Fugl-Meyer Assessment of the upper extremity. Arch. Phys. Med. Rehabil. 2008, 89, 1563–1569. [Google Scholar] [CrossRef]
- Moncion, K.; Biasin, L.; Jagroop, D.; Bayley, M.; Danells, C.; Mansfield, A.; Salbach, N.M.; Inness, E.; Tang, A. Barriers and facilitators to aerobic exercise implementation in stroke rehabilitation: A scoping review. J. Neurol. Phys. Ther. 2020, 44, 179–187. [Google Scholar] [CrossRef]
- Thimabut, W.; Terachinda, P.; Kitisomprayoonkul, W. Effectiveness of a Soft Robotic Glove to Assist Hand Function in Stroke Patients: A Cross-Sectional Pilot Study. Rehabil. Res. Pract. 2022, 2022, 3738219. [Google Scholar] [CrossRef]
- Celesti, A.; Cimino, V.; Naro, A.; Portaro, S.; Fazio, M.; Villari, M.; Calabró, R.S. Recent considerations on gaming console based training for multiple sclerosis rehabilitation. Med. Sci. 2022, 10, 13. [Google Scholar] [CrossRef]
- Robinson, J.; Dixon, J.; Macsween, A.; Van Schaik, P.; Martin, D. The effects of exergaming on balance, gait, technology acceptance and flow experience in people with multiple sclerosis: A randomized controlled trial. BMC Sports Sci. Med. Rehabil. 2015, 7, 8. [Google Scholar] [CrossRef]
- Trombetta, M.; Henrique, P.P.B.; Brum, M.R.; Colussi, E.L.; De Marchi, A.C.B.; Rieder, R. Motion Rehab AVE 3D: A VR-based exergame for post-stroke rehabilitation. Comput. Methods Programs Biomed. 2017, 151, 15–20. [Google Scholar] [CrossRef] [PubMed]
- Shih, M.C.; Wang, R.Y.; Cheng, S.J.; Yang, Y.R. Effects of a balance-based exergaming intervention using the Kinect sensor on posture stability in individuals with Parkinson’s disease: A single-blinded randomized controlled trial. J. Neuroeng. Rehabil. 2016, 13, 78. [Google Scholar] [CrossRef]
- Pekyavas, N.O.; Ergun, N. Comparison of virtual reality exergaming and home exercise programs in patients with subacromial impingement syndrome and scapular dyskinesis: Short term effect. Acta Orthop. Traumatol. Turc. 2017, 51, 238–242. [Google Scholar] [CrossRef] [PubMed]
- Ferraris, C.; Ronga, I.; Pratola, R.; Coppo, G.; Bosso, T.; Falco, S.; Amprimo, G.; Pettiti, G.; Lo Priore, S.; Priano, L.; et al. Usability of the REHOME solution for the telerehabilitation in neurological diseases: Preliminary results on motor and cognitive platforms. Sensors 2022, 22, 9467. [Google Scholar] [CrossRef]
- Allegue, D.R.; Kairy, D.; Higgins, J.; Archambault, P.S.; Michaud, F.; Miller, W.C.; Sweet, S.N.; Tousignant, M. A personalized home-based rehabilitation program using exergames combined with a telerehabilitation app in a chronic stroke survivor: Mixed methods case study. JMIR Serious Games 2021, 9, e26153. [Google Scholar] [CrossRef]
- Wang, G.; Zhu, B.; Fan, Y.; Wu, M.; Wang, X.; Zhang, H.; Yao, L.; Sun, Y.; Su, B.; Ma, Z. Design and evaluation of an exergame system to assist knee disorders patients’ rehabilitation based on gesture interaction. Health Inf. Sci. Syst. 2022, 10, 20. [Google Scholar] [CrossRef] [PubMed]
- Rosique, F.; Losilla, F.; Navarro, P.J. Applying vision-based pose estimation in a telerehabilitation application. Appl. Sci. 2021, 11, 9132. [Google Scholar] [CrossRef]
- Morris, D.M.; Uswatte, G.; Crago, J.E.; Cook, E.W., III; Taub, E. The reliability of the wolf motor function test for assessing upper extremity function after stroke. Arch. Phys. Med. Rehabil. 2001, 82, 750–755. [Google Scholar] [CrossRef]
- Oliveira, C.S.; Almeida, C.S.; Freias, L.C.; Santana, R.; Fernandes, G.; Fonseca Junior, P.R.; Moura, R.C.F. Use of the Box and Block Test for the evaluation of manual dexterity in individuals with central nervous system disorders: A systematic review. Man. Ther. Posturology Rehabil. J. 2016, 1–7. [Google Scholar] [CrossRef]
- Noveletto, F.; Soares, A.; Mello, B.; Sevegnani, C.; Eichinger, F.; Hounsell, M.D.S.; Bertemes-Filho, P. Biomedical serious game system for balance rehabilitation of hemiparetic stroke patients. IEEE Trans. Neural Syst. Rehabil. Eng. 2018, 26, 2179–2188. [Google Scholar] [CrossRef]
- Sanford, J.; Moreland, J.; Swanson, L.R.; Stratford, P.W.; Gowland, C. Reliability of the Fugl-Meyer assessment for testing motor performance in patients following stroke. Phys. Ther. 1993, 73, 447–454. [Google Scholar] [CrossRef]
- Yu, X.; Xiong, S. A dynamic time warping based algorithm to evaluate kinect-enabled home-based physical rehabilitation exercises for older people. Sensors 2019, 19, 2882. [Google Scholar] [CrossRef]
- Choensawat, W.; Choi, W.; Hachimura, K. Similarity retrieval of motion capture data based on derivative features. J. Adv. Comput. Intell. Intell. Inform. 2012, 16, 13–23. [Google Scholar] [CrossRef]
- Schneider, P.; Memmesheimer, R.; Kramer, I.; Paulus, D. Gesture recognition in RGB videos using human body keypoints and dynamic time warping. In RoboCup 2019: Robot World Cup XXIII 23, Sydney, NSW, Australia, 8 July 2019; Springer: Berlin/Heidelberg, Germany, 2019; pp. 281–293. [Google Scholar]
- Google Developers. ML Kit|Google for Developers. 2024. Available online: https://developers.google.com/ml-kit (accessed on 17 July 2025).
- Jia, W.; Wang, H.; Chen, Q.; Bao, T.; Sun, Y. Analysis of Kinect-Based Human Motion Capture Accuracy Using Skeletal Cosine Similarity Metrics. Sensors 2025, 25, 1047. [Google Scholar] [CrossRef] [PubMed]
- Hen, I.; Sakov, A.; Kafkafi, N.; Golani, I.; Benjamini, Y. The dynamics of spatial behavior: How can robust smoothing techniques help? J. Neurosci. Methods 2004, 133, 161–172. [Google Scholar] [CrossRef] [PubMed]
- Labchurat, N.; Khumthong, A.; Choensawat, W.; Sookhanaphibarn, K. Leveraging Exergaming and Standard Webcams for Stroke Rehabilitation. In 2023 IEEE 12th Global Conference on Consumer Electronics (GCCE), Nara, Japan, 10–13 October 2023; IEEE: Piscataway, NJ, USA, 2023; pp. 942–943. [Google Scholar]
- Labchurat, N. Motion Segmentation Source Code. GitHub Repository. 2025. Available online: https://github.com/ArmNorapat/norapat-motion-segmentation (accessed on 20 October 2025).
- Buehler, C.; Koller, W.; De Comtes, F.; Kainz, H. Quantifying muscle forces and joint loading during hip exercises performed with and without an elastic resistance band. Front. Sports Act. Living 2021, 3, 695383. [Google Scholar] [CrossRef]















| System | Year | A | B | C | D | E |
|---|---|---|---|---|---|---|
| Rabbit Chase [9] | 2009 | O | O | O | X | O |
| Tightrope Walk [15] | 2015 | X | X | X | X | O |
| Obstacle Avoidance [17] | 2016 | X | O | X | O | X |
| Motion Rehab AVE [16] | 2017 | X | X | X | X | O |
| Bowling [18] | 2017 | X | O | X | O | X |
| Crazy Target [22] | 2021 | O | O | O | O | X |
| Fish Frenzy [20] | 2021 | X | O | O | O | X |
| Ski Slalom [14] | 2022 | X | X | X | O | X |
| Airplane [19] | 2022 | X | O | O | X | X |
| Attack the Monster [21] | 2022 | O | O | O | X | O |
| Proposed System | 2025 | O | O | O | O | O |
| Exercise | Compared | Triple-Angle | Dual-Angle | Single-Angle | Shoulder | Elbow | Wrist |
|---|---|---|---|---|---|---|---|
| Abduction | Normal-Baseline | 0.3242 | 0.8874 | 0.5555 | 0.5555 | 0.4563 | 0.6100 |
| Normal-Abnormal | 0.0000 | 0.0000 | 0.0000 | 0.0000 | 0.0000 | 0.0000 | |
| Baseline-Abnormal | 0.0000 | 0.0000 | 0.0000 | 0.0000 | 0.0000 | 0.0000 | |
| Elbow flexion | Normal-Baseline | 0.8606 | 0.8604 | 0.2109 | 0.9391 | 0.2109 | 0.7582 |
| Normal-Abnormal | 0.0000 | 0.0000 | 0.0000 | 0.0540 | 0.0000 | 0.0000 | |
| Baseline-Abnormal | 0.0000 | 0.0000 | 0.0000 | 0.0437 | 0.0000 | 0.0000 | |
| Shoulder flexion | Normal-Baseline | 0.0364 | 0.0672 | 0.6555 | 0.6555 | 0.1215 | 0.0977 |
| Normal-Abnormal | 0.0000 | 0.0000 | 0.0000 | 0.0000 | 0.4608 | 0.0053 | |
| Baseline-Abnormal | 0.0000 | 0.0000 | 0.0000 | 0.0000 | 0.4010 | 0.0000 |
| Exercise | Compared | Triple-Angle | Dual-Angle | Single-Angle | Shoulder | Elbow | Wrist |
|---|---|---|---|---|---|---|---|
| Abduction | Normal-Baseline | 0.3468 | 0.9835 | 0.4619 | 0.4619 | 0.6806 | 0.5420 |
| Normal-Abnormal | 0.0000 | 0.0000 | 0.0000 | 0.0000 | 0.0000 | 0.0000 | |
| Baseline-Abnormal | 0.0000 | 0.0000 | 0.0000 | 0.0000 | 0.0000 | 0.0000 | |
| Elbow flexion | Normal-Baseline | 0.8992 | 0.7461 | 0.6022 | 0.8322 | 0.6022 | 0.9651 |
| Normal-Abnormal | 0.0000 | 0.0000 | 0.0000 | 0.0000 | 0.0000 | 0.0000 | |
| Baseline-Abnormal | 0.0000 | 0.0000 | 0.0000 | 0.0000 | 0.0000 | 0.0000 | |
| Shoulder flexion | Normal-Baseline | 0.0393 | 0.0753 | 0.7843 | 0.7843 | 0.0700 | 0.3451 |
| Normal-Abnormal | 0.0000 | 0.0000 | 0.0000 | 0.0000 | 0.9745 | 0.0000 | |
| Baseline-Abnormal | 0.0000 | 0.0000 | 0.0000 | 0.0000 | 0.0854 | 0.0000 |
| Baseline | Normal | Abnormal | |
|---|---|---|---|
| Abduction | : 0.8348 | : 0.8144 | : 9.2378 |
| s: 0.3862 | s: 0.3735 | s: 3.9171 | |
| Elbow flexion | : 1.4478 | : 1.3737 | : 13.9217 |
| s: 0.6973 | s: 0.5932 | s: 7.2972 | |
| Shoulder flexion | : 2.0120 | : 2.0726 | : 4.5952 |
| s: 1.4640 | s: 1.5109 | s: 3.1200 |
| Mean | SD | |
|---|---|---|
| Distance | 1.9940 | 0.0532 |
| Z-Score | −0.0123 | 0.0363 |
| Score | 100 | 0 |
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2026 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license.
Share and Cite
Labchurat, N.; Sookhanaphibarn, K.; Choensawat, W.; Paliyawan, P. Webcam-Based Exergame for Motor Recovery with Physical Assessment via DTW. Sensors 2026, 26, 1219. https://doi.org/10.3390/s26041219
Labchurat N, Sookhanaphibarn K, Choensawat W, Paliyawan P. Webcam-Based Exergame for Motor Recovery with Physical Assessment via DTW. Sensors. 2026; 26(4):1219. https://doi.org/10.3390/s26041219
Chicago/Turabian StyleLabchurat, Norapat, Kingkarn Sookhanaphibarn, Worawat Choensawat, and Pujana Paliyawan. 2026. "Webcam-Based Exergame for Motor Recovery with Physical Assessment via DTW" Sensors 26, no. 4: 1219. https://doi.org/10.3390/s26041219
APA StyleLabchurat, N., Sookhanaphibarn, K., Choensawat, W., & Paliyawan, P. (2026). Webcam-Based Exergame for Motor Recovery with Physical Assessment via DTW. Sensors, 26(4), 1219. https://doi.org/10.3390/s26041219

