Replace references with actual storage
Make pretty-printing functions public
Store frame_state (except for rasters) in a vector