Breathing motion is a significant source of error in radiotherapy treatment planning for the thorax and upper abdomen. Accounting for breathing motion has a profound effect on the size of conformal radiation portals employed in these sites. Breathing motion also causes artifacts and distortions in treatment planning computed tomography (CT) scans acquired during free breathing and also causes a breakdown of the assumption of the superposition of radiation portals in intensity-modulated radiation therapy, possibly leading to significant dose delivery errors. Proposed voluntary and involuntary breath-hold techniques have the potential for reducing or eliminating the effects of breathing motion, however, they are limited in practice, by the fact that many lung cancer patients cannot tolerate holding their breath. We present an alternative solution to accounting for breathing motion in radiotherapy treatment planning, where multislice CT scans are collected simultaneously with digital spirometry over many free breathing cycles to create a four-dimensional (4-D) image set, where tidal lung volume is the additional dimension. An analysis of this 4-D data leads to methods for digital-spirometry, based elimination or accounting of breathing motion artifacts in radiotherapy treatment planning for free breathing patients. The 4-D image set is generated by sorting free-breathing multislice CT scans according to user-defined tidal-volume bins. A multislice CT scanner is operated in the ciné mode, acquiring 15 scans per couch position, while the patient undergoes simultaneous digital-spirometry measurements. The spirometry is used to retrospectively sort the CT scans by their correlated tidal lung volume within the patient's normal breathing cycle. This method has been prototyped using data from three lung cancer patients. The actual tidal lung volumes agreed with the specified bin volumes within standard deviations ranging between 22 and 33 cm3. An analysis of sagittal and coronal images demonstrated relatively small (<1 cm) motion artifacts along the diaphragm, even for tidal volumes where the rate of breathing motion is greatest. While still under development, this technology has the potential for revolutionizing the radiotherapy treatment planning for the thorax and upper abdomen.