C++ implementation of the transport framework, including subhorizon effects