High Fidelity 2K / 4K Assets for Classic Infinity Engine Games

End‑to‑end toolchain to extract, AI upscale (NCNN / Vulkan), and assemble enhanced assets for modern displays using GemRB.

  • File Types MOS/BAM/TIS/ARE/... (+ more)
  • GPU Nvidia / AMD / Intel (Vulkan)
  • Pipeline Extract → Upscale → Assemble

Batch Example

./install/bin/pie4k batch complete -c demo-reference.cfg

Creates an x4 override directory (no original files touched).

Current Focus

Improving VRAM-aware tiling, expanding services, and preparing for new AI model integration (e.g., diffusion based workflows).

About Project IE 4K ( PIE4K )

Project IE 4K, or PIE4K, is about taking the classic Infinity Engine games—Baldur’s Gate, Icewind Dale, and others—and pushing them far beyond their original limits.

The goal isn’t just to produce high-quality 2K and 4K assets. It’s to make these worlds feel new again, expand what the engine can do, and explore ideas that simply weren’t possible when the games were originally built.

PIE4K uses a modular service and plugin architecture that makes it easy to add new tools, AI-powered enhancements, and entirely new capabilities while keeping the original games and assets at the core.

And this is only the beginning. More is coming soon.

Current Status

Most image-centric file types are fully processed (extract, upscale, assemble). Some logic-heavy or metadata-centric formats (e.g. BCS scripting, KEY editing) still need refinement. Engine adjustments (GemRB fork) are underway to implement zoom and proper UpScaleFactor scaling for actors, projectiles, overlays, and UI elements.

Engine Modifications

Zoom + scale logic ~70–95% implemented in a dedicated GemRB fork pending upstream PR viability.

Service System

Uniform lifecycle & resource tracking (CPU / RAM / GPU / VRAM) with VRAM-aware tiling for upscaling.

Future

Planned diffusion-based asset generation, multi‑GPU workload distribution, richer configuration semantics.

Usage

  1. Clone and build the project (or download a release once available).
  2. Run the binary to inspect commands: ./install/bin/pie4k
  3. Execute a full pipeline: ./install/bin/pie4k batch complete -c demo-reference.cfg
  4. Launch GemRB with generated override: gemrb -c demo-x4.cfg

All output assets are written to an output/ directory. Original game files and override contents remain untouched.

Supported Platforms & Hardware

OS

  • Linux (primary dev)
  • Windows (tested via MSYS2)
  • macOS (not yet tested)

GPU

Nvidia / AMD / Intel via Vulkan + NCNN. VRAM adaptive tile sizing avoids OOM while maximizing throughput.

System

Recommended: GPU w/ ≥8 GB VRAM, 8+ cores CPU, 32 GB RAM for large full-game batches (swap advisable).

Build Summary

Linux

Install compiler + dependencies (gcc, cmake, vulkan headers, SDL2, gtest, vlc, ninja, etc.). Ensure proper GPU stack (libnvidia-ml, AMD libs, or Intel Level Zero).

./compile.sh

Windows (MSYS2)

Install mingw-w64 toolchain + SDL2, vulkan headers, gtest, vlc, etc. CUDA / ADLX / Level Zero for vendor support.

./compile.sh

Build currently bundles: pie4k core, GemRB fork (modified), and NCNN.

Roadmap Highlights

Rules System

Baseline skipping logic active (≈30%)—expanding for conditional workflows.

Resume Operations

~80% complete; force override supported with --force.

Multi-GPU

Planned: distribute tiles / resource classes across devices.

Config Expansion

More alpha / color / model tuning options forthcoming.

Diffusion / New AI

Future service: model loading (safetensors) + conditional generation flow.

Full File Type Progress
2DA 100%GAM 100%MOS 100%BAM 98%TIS 90%ARE 100%BCS 95%BMP 100%CHU 100%KEY 10%PLT 100%PNG 100%PVRZ 100%WED 100%WMP 90%MVE 100%

Concept Vision

Beyond pure upscaling, the long-term aim is style transformation and artistic reinterpretation—producing cohesive alternative visual themes (e.g. ultra‑realistic, anime, painterly) while preserving mechanical integrity.

Human thief concept example
Concept art inspiration guiding future generative workflows.

Credits & Thanks

License

Project code is under GNU GPLv3 unless otherwise noted. Third‑party model licenses remain their own.