[Proc Gen] BSP - Core class with splitting #202
Labels
No labels
Alpha Release Requirement
Bugfix
Demo Target
Documentation
Major Feature
Minor Feature
priority:tier1-active
priority:tier2-foundation
priority:tier3-future
priority:tier4-deferred
Refactoring & Cleanup
system:animation
system:documentation
system:grid
system:input
system:performance
system:procgen
system:python-binding
system:rendering
system:ui-hierarchy
Tiny Feature
workflow:blocked
workflow:needs-benchmark
workflow:needs-documentation
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Blocks
#203 [Proc Gen] BSPNode - Lightweight node reference
john/McRogueFace
#204 [Proc Gen] BSP - Iteration (leaves, traverse)
john/McRogueFace
#205 [Proc Gen] BSP - Query methods (find, contains)
john/McRogueFace
#206 [Proc Gen] BSP.to_heightmap and BSPMap class
john/McRogueFace
#210 [Proc Gen] BSP.find_path - Room connectivity graph
john/McRogueFace
Reference
john/McRogueFace#202
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Parent Issue: #192
Overview
Implement the core
BSPclass for binary space partitioning of rectangular regions.Specification
Constructor
bounds((x, y), (w, h))Properties
bounds((x, y), (w, h))rootBSPNodeSplitting Methods
Split the root node once at the specified position.
Recursively split to the specified depth.
depthintmin_size(int, int)max_ratiofloatseedintRemove all children, keeping only the root node with original bounds.
Implementation Notes
TCODBspinternallysplit_oncemaps toTCOD_bsp_split_oncesplit_recursivemaps toTCOD_bsp_split_recursiveclearmaps toTCOD_bsp_remove_sonsselffor chainingAcceptance Criteria
BSPcan be constructed with bounds tuplesplit_oncesplits at specified positionsplit_recursivecreates proper tree structureclearremoves all childrenrootproperty returns valid BSPNode