In joint work with A. Eskin and A. Zorich, we study the asymptotics of the number of closed trajectories for billiards in polygons with right-angles. We will show how this leads to the calculation of volumes of moduli spaces of meromorphic quadratic differentials on the Riemann sphere.