Dipole formulation of QCD cascades