What events helped consolidate the Ottoman Empire in the East, to the extent that they emerge as a rival to Western Europe?