encodeStateTree

Encodes a state tree one module at a time with the encoder the capture uses for its deltas.