reAAAq/KrKr2-Next
About
基于 Flutter + ANGLE 重构的 KiriKiri2 跨平台视觉小说模拟器,支持 Metal Vulkan D3D11 现代图形后端
Creative & MediaMeasured star growth
- in 24h
- 0
- in 7 days
- +3
- in 15 days
- +5
- in 1 month
- Collecting history
Net star changes over overlapping periods, not daily totals. Missing measurements are left blank. Stars measure attention, not software quality.
README_EN.md
Original
KrKr2 Next
Next-Generation KiriKiri2 Cross-Platform Emulator Built with Flutter
语言 / Language: 中文 | English
🙏 This project is a refactor based on krkr2. Thanks to the original author for the contribution.
Overview
KrKr2 Next is a modern, cross-platform runtime for the KiriKiri2 visual novel engine. It is fully compatible with original game scripts, uses modern graphics APIs for hardware-accelerated rendering, and includes numerous optimizations for both rendering performance and script execution. Built on Flutter for a unified cross-platform UI, it targets macOS · iOS · Windows · Linux · Android.
The screenshot below shows the current running state on macOS with the Metal backend:
Architecture
Rendering Pipeline: The engine performs offscreen rendering via ANGLE's EGL Pbuffer Surface (OpenGL ES 2.0). Rendered frames are delivered to the Flutter Texture Widget through platform-native texture sharing mechanisms (macOS → IOSurface, Windows → D3D11 Texture, Linux → DMA-BUF) with zero-copy transfer.
Development Progress
⚠️ This project is under active development. No stable release is available yet. macOS is the most advanced platform.
| Module | Status | Notes |
|---|---|---|
| C++ Engine Core Build | ✅ Done | KiriKiri2 core engine compiles on all platforms |
| ANGLE Rendering Migration | ✅ Mostly Done | Replaced legacy Cocos2d-x + GLFW pipeline with EGL/GLES offscreen rendering |
| engine_api Bridge Layer | ✅ Done | Exports engine_create / engine_tick / engine_destroy C APIs |
| Flutter Plugin | ✅ Mostly Done | Platform Channel communication, Texture bridge |
| Zero-Copy Texture Rendering | ✅ Mostly Done | Zero-copy engine render frame sharing to Flutter via platform-native texture mechanisms |
| Flutter Debug UI | ✅ Mostly Done | FPS control, engine lifecycle management, rendering status monitor |
| Input Event Forwarding | ✅ Mostly Done | Mouse / touch event coordinate mapping and forwarding to the engine |
| Engine Performance Optimization | 🔨 In Progress | SIMD pixel blending, GPU compositing pipeline, VM interpreter optimization, etc. |
| Game Compatibility | 🔨 In Progress | Completing the script parser, adding plugins. Current goal: match compatibility with Z's closed-source build |
| Original krkr2 Emulator Feature Porting | 📋 Planned | Gradually port original krkr2 emulator features to the new architecture |
Platform Support
| Platform | Status | Graphics Backend | Texture Sharing |
|---|---|---|---|
| macOS | ✅ Mostly Done | Metal | IOSurface |
| iOS | 🔨 Pipeline Working, Optimizing OpenGL Rendering | Metal | IOSurface |
| Windows | 📋 Planned | Direct3D 11 | D3D11 Texture |
| Linux | 📋 Planned | Vulkan / Desktop GL | DMA-BUF |
| Android | 🔨 Pipeline Working, Optimizing | OpenGL ES / Vulkan | HardwareBuffer |
Engine Performance Optimization
| Priority | Task | Status |
|---|---|---|
| P0 | Pixel Blend SIMD (Highway) | ✅ Done |
| P0 | Full GPU Compositing Pipeline | 🔨 In Progress |
| P0 | TJS2 VM Interpreter (computed goto) | 📋 Planned |
License
This project is licensed under the GNU General Public License v3.0 (GPL-3.0). See LICENSE for details.
Explore related projects
Loading…