Rendering library/engine built on top of Vulkan
				
			
		| cmake | ||
| examples | ||
| REFERENCE | ||
| src | ||
| .clangd | ||
| .gitignore | ||
| build.sh | ||
| CLAUDE.md | ||
| CMakeLists.txt | ||
| README.md | ||
LemonFX
A batteries-included Vulkan renderer library for C++. LemonFX provides a simple, Raylib-inspired API while leveraging modern C++17 and Vulkan features for high performance.
Features
- Single-header library - Just include lemonfx.hppand you're ready to go
- RAII wrappers - Automatic resource management with move semantics
- Simple API - Clean, intuitive interface inspired by Raylib
- Modern C++17 - Uses std::optional, move semantics, and modern patterns
- Validation layers - Built-in debug support for development
- Window management - Integrated GLFW for cross-platform windowing
- Swapchain handling - Automatic resize and recreation
Requirements
- C++17 compatible compiler
- Vulkan SDK (1.2+)
- GLFW3
- CMake 3.15+
Quick Start
#include <lemonfx.hpp>
int main() {
	// Initialize context
	lfx::Context ctx;
	// Create window
	lfx::WindowConfig config;
	config.title = "My App";
	config.width = 1280;
	config.height = 720;
	lfx::Window window(ctx, config);
	// Main loop
	while (!window.shouldClose()) {
		window.pollEvents();
		if (window.beginFrame()) {
			window.clearColor(lfx::Color::Blue());
			window.endFrame();
		}
	}
	return 0;
}
Building
mkdir build && cd build
cmake ..
cmake --build .
Examples
See the examples/ directory for sample programs:
- hello_window.cpp - Basic window with color clearing
Architecture
LemonFX is structured around a few key classes:
- Context - Manages Vulkan instance, device, and queues
- Window - Handles window creation, swapchain, and frame rendering
- Shader - SPIR-V shader module wrapper
- Color - Simple color representation with preset colors
License
MIT License - See LICENSE file for details