Ultrarelativistic bound states in spinor and scalar QED