In this paper, an automatic block-by-block pattern generator is proposed for multi-leaf nonperiodic masonries. The outcome is then directly employed in block-based computational analysis of full-scale historical masonry structures. Given the 3D volume of the structure (obtainable also from point clouds) and the 3D block definition of a sample, both in terms of voxels, the volume of the structure is automatically filled with blocks by keeping the blocks statistics of the sample, as well as accounting for through-thickness blocks and structural details, such as lintels and edges. A meaningful benchmark is used to assess the efficiency of the filling algorithm, as well as its capability to generate statistically-consistent patterns. The benchmark is then employed in full-scale computational analyses by using an available block-based model. Various multi-leaf patterns are considered and critically compared in structural analysis, highlighting the influence of through-thickness blocks and intralayer mechanical properties on the overall structural response.