The properties of lignocellulosic biomass, such as bulk physical, thermal, and mechanical properties, as well as the mobility of enzymes or catalysts, are largely affected by porosity, pore structures, and pore size distribution. While X-ray computed tomography (CT) has been introduced to effectively produce 3D volumetric images of material microstructure, a quantitative porosity analysis from the 3D images has never been done. This work introduces a first-of-its-kind X-ray CT-based quantitative porosity analysis method and applies the developed toolkit to characterize the internal porosity distribution of loblolly pine. A sample loblolly pine chip was scanned by a nano-resolution X-ray CT system and digitally reconstructed after a sequence of image processing operations. A comprehensive porosity analysis was then performed to quantify the envelope porosity, the spatial distribution of local porosity, and the directional porosity. Solutions to the various challenges in image processing, porosity calculation, and large data handling are provided.