A streamlined OpenGL setup and 3D scene viewer optimized for Apple Silicon Macs. This project eliminates the configuration challenges of OpenGL on modern macOS systems through intelligent scripting and architecture detection.
- Automated OpenGL setup specifically optimized for Apple Silicon
- Architecture detection for correct library installation
- Compatible with multiple C++ compilers (Clang, GCC, system default)
- Interactive 3D scene with camera and object manipulation
- Complete lighting system with configurable parameters
- Coordinate grid and axes visualization
- Real-time position feedback
Setting up OpenGL on modern macOS systems presents several challenges, particularly on Apple Silicon. This project addresses these issues through:
- Automatic architecture detection (Intel vs Apple Silicon)
- Appropriate GLFW library selection based on system architecture
- Comprehensive dependency management
- Simplified build configuration
- OpenGL
- GLFW 3
- CMake (3.0 or higher)
- C++ compiler with C++14 support
git clone https://github.com/kust1011/opengl-quickstart.git && cd opengl-quickstart && ./scripts/install.sh# Clone the repository
git clone https://github.com/kust1011/opengl-quickstart.git
cd opengl-quickstart
# Run the installation script
./scripts/install.shThe installation process:
- Verifies and installs required dependencies
- Detects your Mac's architecture (Intel vs Apple Silicon)
- Downloads and configures the appropriate GLFW version
- Sets up the build environment
- Compiles the application
During installation, you will be prompted to select:
- A C++ compiler if none is found (options for Homebrew Clang or Xcode Command Line Tools)
- GLFW setup method (manual download or automatic installation)
For advanced users who prefer manual configuration, detailed instructions are available in the Installation Guide.
After building, run the application:
cd build
./OpenGLScene-
Camera Movement:
- W - Move forward (−Z)
- S - Move backward (+Z)
- A - Move left (−X)
- D - Move right (+X)
- Space - Move up (+Y)
- Shift - Move down (−Y)
-
Object Movement:
- I - Move forward (−Z)
- K - Move backward (+Z)
- J - Move left (−X)
- L - Move right (+X)
-
Application Control:
- Q - Exit application
OpenGL/
├── CMakeLists.txt
├── Dependencies/ # Auto-generated by setup scripts
├── include/
│ ├── Core/ # Core application components
│ ├── Graphics/ # Rendering components
│ └── Utils/ # Utility functions
└── src/
├── Core/ # Implementation files
└── Graphics/ # Rendering implementation
This project is licensed under the MIT License - see the LICENSE file for details.