feat: add RAII window class with OpenGL 4.1 context
- Add cbt::window class in cbt/ directory with RAII lifecycle - Add setup_opengl and info_opengl for glad init and GL info - Add Q key to quit the application - Update CMakeLists.txt with glfw3 and glad dependencies - Update AGENTS.md with snake_case naming and shell conventions
This commit is contained in:
@@ -44,6 +44,8 @@ to the custom scripts instead of system-installed packages.
|
||||
- `auto` for obvious types (e.g. `auto main(...) -> int`)
|
||||
- `<>` includes only for system headers (std, OS, etc.)
|
||||
- `""` includes for third-party dependencies (e.g. `fmt`, `nlohmann/json`)
|
||||
- **Naming:** `snake_case` for variables, functions, and classes
|
||||
- **Naming:** `SCREAMING_SNAKE_CASE` only for macros and constants
|
||||
- Include order:
|
||||
1. C++ standard library headers (`<chrono>`, `<vector>`, etc.)
|
||||
2. *(blank line)*
|
||||
@@ -86,6 +88,9 @@ Example:
|
||||
cuber/
|
||||
CMakeLists.txt # Build configuration
|
||||
cuber.cpp # Entry point
|
||||
cbt/ # Project namespace
|
||||
window.hpp # Window RAII wrapper
|
||||
window.cpp # Window implementation
|
||||
deps/ # Custom Find*.cmake scripts
|
||||
Findfmt.cmake # fmt library
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user