CT scans did (and still do) this by sending x-ray beams through the head at various angles and collecting the x-ray beams on the opposite side that were not absorbed by the head. Then magic occurs. A series of images appear on a computer monitor or on x-ray film as if the head had been run through a giant salami-cutter and the slices were laid out flat and in sequence.