An interactive educational tool for learning about the solar system through augmented reality projection. Control a virtual space shuttle using a USB camera to explore planets and learn about celestial bodies!
This is the repository for the TESP 2018 group project at Tohoku University. The project provides an engaging learning experience for children by:
- ๐ฏ Projecting a 2D solar system onto any surface
- ๐น Using a USB camera as a motion controller
- ๐ธ Navigating a virtual space shuttle through space
- ๐ช Landing on planets to discover fascinating information
- ๐ต Enjoying an immersive audio experience
- Camera-based Control: Your USB camera becomes a space shuttle controller
- Interactive Learning: Hover over planets to reveal educational content
- Real-time Tracking: Advanced computer vision using OpenCV ORB feature detection
- Smooth Movement: Interpolated tracking for fluid shuttle motion
- Educational Content: Detailed information about all solar system planets
- Customizable: Multiple command-line options for different setups
The project has been completely modernized for Python 3.10+:
- โ Modern Python syntax with type hints
- โ Comprehensive test suite (9 unit tests)
- โ Improved error handling and stability
- โ Command-line interface with flexible options
- โ Better code organization and maintainability
- โ Full backward compatibility
- ๐ฅ๏ธ Computer with Python 3.10 or later
- ๐น USB camera (external or built-in)
- ๐ฝ๏ธ Projector
- ๐ Audio output (optional)
pip install -r requirements.txtRequired packages:
numpy >= 1.21- Numerical computationsopencv-python >= 4.5- Computer vision and feature detectionPillow >= 8.0- Image processingpygame >= 2.0- Audio playback and multimedia
# Clone the repository
git clone https://github.com/eyildiz-ugoe/tesp2018_projection.git
cd tesp2018_projection
# Create a virtual environment (recommended)
python3 -m venv .venv
source .venv/bin/activate # On Windows: .venv\Scripts\activate
# Install dependencies
pip install -r requirements.txt# Basic usage
python camera_pose.py
# With options
python camera_pose.py --mute --no-debug
# Get help
python camera_pose.py --help- Setup: Position your projector to display the solar system image on a flat surface
- Camera: Point your USB camera at the projected surface
- Control: Move the camera gently to control the space shuttle
- Explore: Navigate to different planets and celestial bodies
- Learn: When the shuttle lands on a planet, information appears automatically!
๐ก Tip: Move the camera slowly and smoothly for best results. Abrupt movements may cause tracking issues.
| Option | Description | Default |
|---|---|---|
--camera-index |
Primary camera device index | 1 |
--fallback-camera-index |
Backup camera if primary fails | 0 |
--mute |
Disable background music | False |
--no-debug |
Hide debug visualization window | False |
--resource-root |
Custom directory for assets | Current directory |
# Use built-in camera (index 0)
python camera_pose.py --camera-index 0
# Silent mode without debug window
python camera_pose.py --mute --no-debug
# Custom resource location
python camera_pose.py --resource-root /path/to/assetsRun the test suite to verify everything works:
# Run all tests
pytest tests/ -v
# Run with coverage
pytest tests/ --cov=camera_pose
# Run specific test
pytest tests/test_camera_pose.py::test_prepare_info_contains_planet_nameTest Results: All 9 tests passing โ
tesp2018_projection/
โโโ camera_pose.py # Main application (modernized)
โโโ camera_pose2.py # Legacy compatibility wrapper
โโโ planet_info.xml # Celestial body data
โโโ requirements.txt # Python dependencies
โโโ solar_system2.png # Projection background image
โโโ shuttleIcon.png # Space shuttle sprite
โโโ spacefont.ttf # Custom font for text display
โโโ markers/ # ArUco-style tracking markers
โโโ sounds/ # Background music and audio
โโโ templates/ # Planet template images for detection
โโโ tests/ # Unit test suite
โโโ test_camera_pose.py
- Feature Detection: Uses OpenCV ORB (Oriented FAST and Rotated BRIEF) to detect keypoints in the projected image
- Homography Calculation: Computes the transformation matrix between camera view and projected image
- Position Tracking: Maps camera center point to virtual position on the projected surface
- Motion Smoothing: Applies velocity-based interpolation for fluid movement
- Collision Detection: Template matching to detect when shuttle enters planet boundaries
- Information Display: Renders educational content from XML data when landing occurs
The application includes detailed information about:
- โ๏ธ Sun - Our star
- โฟ๏ธ Mercury - The swift planet
- โ๏ธ Venus - The morning star
- ๐ Earth - Our home
- โ๏ธ Mars - The red planet
- โ Jupiter - The giant
- โ Saturn - The ringed planet
- โ Uranus - The ice giant
- โ Neptune - The blue planet
Each celestial body displays:
- Distance from Earth
- Relative size and gravity
- Number of moons
- Atmospheric composition
- Orbit and day duration
- Surface temperature
# Try different camera indices
python camera_pose.py --camera-index 0
python camera_pose.py --camera-index 1# Run in mute mode
python camera_pose.py --mute- Ensure good lighting conditions
- Keep the projected image fully visible to the camera
- Move the camera slowly and steadily
- Check that markers are clearly visible
# Reinstall dependencies
pip install --force-reinstall -r requirements.txtThis project was supervised by Professor Kagami at Tohoku University during the TESP 2018 summer school program.
Team Members (equal contribution):
The project is maintained and can be extended by team members. The modernized codebase makes it easier to add new features:
- The file
camera_pose2.pyserves as a compatibility wrapper for legacy documentation - New features should be added to
camera_pose.py - Tests should be added to
tests/test_camera_pose.py - All changes should maintain backward compatibility
This project is open source. Please check the LICENSE file for more information.
- Tohoku University for hosting the TESP 2018 summer school
- Professor Kagami for supervision and guidance
- OpenCV community for the excellent computer vision library
- Python community for the amazing ecosystem
- TESTING_REPORT.md - Comprehensive testing documentation
- PR_STATUS.md - Modernization PR details
- planet_info.xml - Celestial body data structure
Potential enhancements for future development:
- Add more celestial bodies (dwarf planets, asteroids)
- Implement 3D visualization
- Multi-language support
- Mobile app version
- VR/AR integration
- Online multiplayer mode
- Achievement system for students
Made by the TESP 2018 team
Last updated: October 2025