On August 6, 1682, the Ottoman Empire, at the height of its power, declared war on the Holy Roman Empire. Muslim domination of Europe extended from the Balkans northward through Hungary and reached into Poland. Westward, only Habsburg Vienna barred the way. Louis XIV, for his own reasons, preferred dealing with the Ottomans rather than with the Habsburgs. Were the Muslims to have been victorious, they might have ruled from the Mediterranean to the Baltic.