← Back to selected work

cub3D

A Wolfenstein-inspired renderer that converts a 2D map into a textured first-person scene using raycasting.

Role
Graphics Engine Developer
Access
1337 / 42 validated project
[01]

Context

A Wolfenstein-inspired renderer that converts a 2D map into a textured first-person scene using raycasting. The project includes map validation, player movement, collision detection, wall projection, textures, and a minimap.

[02]

My responsibility

Built and validated through the 1337 / 42 project curriculum, with direct responsibility for implementation, debugging, testing, and evaluation requirements.

[03]

System scheme

Engineering scheme

2D map to raycast frame

Input → Processing → Output

Every screen column traces a ray through the grid, resolves the nearest wall, and samples a texture at the projected height.

  1. 01

    Map parser

    Validate scene directives, textures, colors, and enclosed geometry.

  2. 02

    Player camera

    Track position, direction vector, and camera plane.

  3. 03

    Ray generation

    Create one world-space ray for each screen column.

  4. 04

    DDA traversal

    Advance through grid cells until a wall is intersected.

  5. 05

    Wall projection

    Correct distance, calculate slice height, and select texture data.

  6. 06

    Frame buffer

    Draw walls and minimap, then present the completed image.

Linear algebra
Collision detection
Texture sampling
Frame performance
[04]

Implementation breakdown

  1. 01

    System design

    Digital Differential Analysis (DDA) finds wall intersections for each screen column, then projection math determines texture sampling and rendered wall height.

[05]

Technical scope

C01
MiniLibX02
Raycasting Algorithms03
Linear Algebra04
[07]

Implementation details

  • Fully textured wall mapping spanning distinct geographic compass orientations.
  • Fluid first-person camera rotational controls mitigating visual tearing.
  • Dynamic minimap array generation parsing real-time object coordinates.
[08]

Engineering focus

  • Linear algebra remained an explicit concern across the implementation.
  • Collision detection remained an explicit concern across the implementation.
  • Texture sampling remained an explicit concern across the implementation.
  • Frame performance remained an explicit concern across the implementation.
[10]

Project gallery

cub3D project view 1
cub3D project view 2
cub3D project view 3

Need a system like this?

Tell me about the workflow, integration, or backend problem.

Discuss a project