A comprehensive 3D medical imaging and visualization platform for anatomical education and learning. This system provides advanced rendering techniques and interactive navigation tools for multiple organ systems.
![]() |
|
![]() |
|
- Overview
- Demo
- Features
- System Architecture
- Supported Medical Systems
- Installation
- Data
- Usage Guide
- Technical Stack
- Requirements
- Contributing
- License
- Contact
This 3D Medical Visualization System is a powerful educational tool designed to provide realistic, interactive visualization of human anatomy. Built with VTK and PyQt5, it supports multiple organ systems with advanced rendering capabilities, real-time data integration, and intuitive navigation controls.
- Multi-System Support: Cardiovascular, Nervous, Musculoskeletal, and Dental systems
- Real-Time Data Integration: ECG/EEG signal visualization synchronized with 3D models
- Advanced Rendering: Surface rendering, clipping planes, curved MPR, and orthogonal slicing
- Interactive Navigation: Focus mode, fly-through, and real-time manipulation
- Anatomically Accurate: Realistic colors and proportions based on medical literature
Cardiovascular System
Surface rendering of heart anatomy with realistic coloring and ECG-synchronized heart contraction with blood flow
Heart.mp4
Nervous System
3D brain model with cortical surface detail, Real-time EEG electrical signal propagation and Curved MPR for neural tract visualization
Brain.mp4
Dental
High-detail dental and jaw anatomy and Curved MPR along dental arch
Dental.mp4
Musculoskeletal System
Complete leg musculoskeletal visualization and Cross-sectional view with clipping planes
Skeleton.mp4
- Surface Rendering: High-quality 3D surface visualization with realistic lighting
- Clipping Planes: Cross-sectional views with adjustable X/Y axis slicing
- Curved MPR: Multi-planar reconstruction along curved paths
- Volume Rendering: Direct volume visualization from DICOM data
- Focus Navigation: Zoom and highlight specific anatomical components
- Fly-Through Mode: Cinematic camera paths through 3D models
- Interactive Rotation: Mouse-controlled model manipulation
- Auto-Flythrough: Automated camera movement with customizable endpoints
- ECG Visualization: Real-time cardiac electrical activity mapped to heart chambers
- EEG Mapping: Brain electrical signals displayed on cortical surface
- DICOM Support: Load medical imaging data from CT/MRI scans
- NIfTI Support: Neuroimaging data format compatibility
- Batch Import: Load multiple OBJ files simultaneously
- Opacity Adjustment: Fine-tune transparency for layered viewing
- Component Toggle: Show/hide individual anatomical parts
- Speed Control: Adjust animation playback speed
- Color Coding: Anatomically accurate tissue coloring
┌─────────────────────────────────────────────────────────┐
│ Main GUI (gui.py) │
│ Medical Systems Selection Hub │
└───────────┬─────────────────────────────────┬───────────┘
│ │
┌───────▼────────┐ ┌──────▼─────────┐
│ System GUIs │ │ Visualization │
│ - heart_gui │ │ Modules │
│ - brain_gui │ │ - flyThrough │
│ - legs_gui │ │ - clipping │
│ - teeth_gui │ │ - curvedMPR │
└───────┬────────┘ └──────┬─────────┘
│ │
┌───────▼─────────────────────────────────▼───────┐
│ VTK Rendering Engine │
│ (3D Graphics & Interaction) │
└─────────────────────────────────────────────────┘
- Components: Ventricles, atria, valves, coronary arteries, veins
- Special Features:
- ECG-synchronized heart pumping animation
- Realistic blood flow visualization
- Chamber-specific contraction sequences
- Separate phase timing for each chamber
- Components: Cerebral cortex, white matter, cerebellum, brainstem, blood vessels
- Special Features:
- EEG electrode mapping (10-20 system)
- Real-time electrical signal propagation
- Surface-based signal paths
- Curved MPR for tract visualization
- Components: Bones, muscles, tendons, ligaments, cartilage
- Special Features:
- Smart color detection (bone vs. muscle vs. tendon)
- Regional anatomy display
- Clipping planes for internal structure viewing
- Components: Teeth, gums, alveolar bone, pulp, jaw
- Special Features:
- High-specular tooth surface rendering
- Curved MPR for dental arch analysis
- Detailed intraoral anatomy
Python 3.8+
pip (Python package manager)- Clone the repository:
git clone https://github.com/RadwaHa/3D-Medical-Visualization.git
cd 3D-Medical-Visualization- Install dependencies:
pip install -r requirements.txt- Run the main application:
python src/gui.pyYou can access the used data here: Data
-
Launch the main GUI:
python src/gui.py
-
Select your desired medical system (Cardio, Skeleton, Nervous, or Dental)
-
Choose a visualization mode or navigation technique
- Single File: Click "Load Single OBJ File" and select a .obj file
- Batch Import: Click "Load Folder (Batch Import)" to load multiple files at once
- DICOM: For CT/MRI data, use the clipping planes or orthogonal viewer
- NIfTI: Brain imaging data loads automatically in curved MPR mode
- EDF/EEG: Electrical signal data integrates with brain models
- Rotate: Left-click and drag
- Zoom: Scroll wheel or +/- keys
- Pan: Middle-click and drag
- Reset: Click "Reset" button to restore default view
Displays the outer surface of anatomical structures with realistic lighting and shading.
Usage:
- Load your 3D models
- Click "Surface Rendering" button
- Adjust opacity slider for transparency
Best For: General anatomy overview, external structure examination
Creates cross-sectional views by slicing through the model along X or Y axes.
Usage:
- Click "Clipping Planes" button
- Enable X-axis or Y-axis clipping
- Adjust slider to move the cutting plane
- Use "Invert" to reverse the cutting direction
Best For: Internal structure examination, layer-by-layer analysis
Generates curved cross-sections following user-defined paths.
Supported Systems: Nervous, Dental
Usage:
- Draw a curved path on the 2D slice view
- Select viewing side (concave/convex)
- Adjust thickness slider
- Click "Generate Curved MPR"
Best For: Dental arch analysis, nerve tract following, curved anatomical pathways
Isolates and zooms into specific anatomical components.
Usage:
- Click "Focus Navigation"
- Select component from dropdown
- Click "Focus" - camera smoothly animates to target
- Click "Reset Focus" to restore full view
Features:
- Smooth camera animation (800ms transition)
- Other parts fade to 25% opacity
- Maintains spatial context
Provides cinematic navigation through 3D models with automatic or manual control.
Usage:
- Click "Fly-through Mode"
- Navigate manually using keyboard:
Space: Move forwardCtrl: Move backwardArrow Keys: Rotate view+/-: Zoom in/out
- Set endpoint for automatic flythrough:
- Position camera at desired start
- Click "Set End Point (Current View)"
- Click "Start Auto Flythrough"
Features:
- Real-time 3D rendering
- Customizable speed (10-200%)
- Smooth interpolation between waypoints
- Interactive and automatic modes
Real-time cardiac animation synchronized with ECG data.
Components:
- Automatic ECG extraction from PNG images
- Synthetic ECG generation as fallback
- Per-chamber contraction timing
- Realistic blood flow particles
Technical Details:
- Detects P-waves, QRS complexes, T-waves
- Right atrium contracts 30ms before left atrium
- Right ventricle contracts 10ms before left ventricle
- Smooth deformation using wall-thickening algorithm
Usage:
- From Heart System, click "ECG Heart Pumping"
- Provide ECG folder path or use synthetic data
- Adjust playback speed
- Observe phase-accurate contractions
Surface-based electrical signal propagation across the brain.
Components:
- 10-20 EEG electrode system mapping
- 60+ electrode positions supported
- Real-time signal amplitude visualization
- Flowing gradient textures
Technical Details:
- Electrodes projected onto brain surface using spherical coordinates
- Cell locator ensures paths follow cortical surface
- Region-specific activity thresholds (frontal/central/posterior)
- Bright, animated flow textures
Usage:
- From Brain System, click "EEG Brain Signals"
- Load EEG data (.edf format)
- Watch electrical signals flow across brain surface
- Active paths indicate strong electrode coupling
- Python 3.8+: Main programming language
- VTK 9.x: 3D visualization and rendering engine
- PyQt5: GUI framework
- NumPy: Numerical computations
- SciPy: Signal processing and interpolation
- MNE: EEG/MEG data processing
- PyDICOM: DICOM medical imaging
- NiBabel: NIfTI neuroimaging format
- OpenCV: Image processing for ECG extraction
- Matplotlib: 2D plotting (ECG signals)
- VisPy: High-performance 3D graphics (fly-through mode)
-
Minimum:
- CPU: Dual-core 2.0 GHz
- RAM: 4 GB
- GPU: Integrated graphics with OpenGL 3.3+
- Storage: 2 GB free space
-
Recommended:
- CPU: Quad-core 3.0 GHz+
- RAM: 8 GB+
- GPU: Dedicated graphics with 2GB VRAM
- Storage: 10 GB free space (for medical datasets)
- Operating System: Windows 10/11, macOS 10.14+, or Linux (Ubuntu 18.04+)
- Python: 3.8 or higher
- OpenGL: 3.3 or higher
We welcome contributions! Please follow these steps:
- Fork the repository
- Create a feature branch
git checkout -b feature/amazing-feature
- Commit your changes
git commit -m 'Add amazing feature' - Push to the branch
git push origin feature/amazing-feature
- Open a Pull Request
This project is provided as-is for educational purposes. Not intended for clinical diagnostic use.
- VTK Community: For the powerful 3D visualization library
- MNE Developers: For EEG/MEG processing tools
- Medical Dataset Providers: Open-source anatomical models
- Research Contributors: Dr. [Name], Dr. [Name] for validation
Project Contributer:Ahd Ahmed
Project Contributer: Radwa Hamdy
Project Contributer:Habiba Ibrahem
Project Contributer:David Bahaa
⭐ If you find this project helpful, please consider giving it a star!



