I know long ago they would have the car stationary and use a projector screen to with moving scenery to make it look like the car was moving. It was obviously staged, but good enough. I've seen "behind the scenes" video clips and still showing some sort of filming rig on an actual car that isn't on a set, but that seems way to dangerous for anything of any complexity.
So I am assuming they have come a long way with the stationary car on a set, and they mix that with a real car with cameras mounted on it. Is this accurate? If not, how do they make it look so real and still keep everyone safe?