zhenyan121 662f10047a feat(renderer): add shadow mapping with PCF soft shadows
Introduce shadow mapping using a dedicated depth framebuffer and shader. The block fragment shader now performs percentage-closer filtering (PCF) with Poisson disk sampling and random rotation for soft shadows. The vertex shader outputs light-space coordinates. A new depth shader pair handles rendering from the light's perspective, discarding transparent fragments. The renderer sets up the light projection based on the camera position and sun direction, and applies the shadow factor to diffuse lighting. Day/night cycle can now be toggled off in the world server thread.
2026-06-16 22:27:08 +08:00
2026-05-28 21:34:36 +08:00
2026-04-21 22:53:34 +08:00
2026-05-28 21:34:36 +08:00
2026-05-28 21:34:36 +08:00
2026-03-05 13:43:34 +08:00
2026-04-14 09:24:10 +08:00
2026-05-28 21:34:36 +08:00
2026-04-19 18:01:09 +08:00
2026-05-28 21:34:36 +08:00

What's it

A cube game like Minecraft, using C++ and OpenGL.

Build Guide

Prerequisites

  • CMake (>= 3.24)
  • C++ 23 compatible compiler

Step

  1. Clone the repository
    git clone https://github.com/zhenyan121/Cubed.git && cd Cubed
    
  2. Configure with CMake
    mkdir build && cd build
    cmake -G "Ninja" ..
    
  3. Build the project
    ninja
    
Description
No description provided
Readme MIT 2.9 MiB
Languages
C++ 92.6%
Python 3.7%
GLSL 1.9%
CMake 1.8%