Open glassmansam opened 2 years ago
Made progress at identifying render slowdown bottleneck: There are two main causes:
Intruder A* -- The more intruders there are the worse it gets -- As intruders discover more of the map, the worse the frontier target performs on maps with large open areas -- Counter-intuitive shortest paths give a performance hit -- Implementation has room for optimizations and augmentations with data structures, pre-calculated heuristics, etc -- flame graph indicates that much time is spent on ArrayList operations, e.g. creation, allocation, removal, additions
Canvas draw operations -- Draws all static components every frame. Should just draw them once and store as a background canvas -- Time spent calculating colors for displaying unexplored areas -- Canvas does not need to be drawn to ~60x per second
The AnimationTimer framerate drops after some time