Religion in Europe was not simply a spiritual pursuit, but a source of power. On the one hand was the pope who exercised his authority primarily from Rome. On the other, kings were loathe to cede power. Therefore, starting with Emperor Charlemagne (Karl der Große), they established the Holy Roman Empire as a balancing power. Resultantly, the Emperor was to be both King of Germany and Italy, but only the pope could crown him. In practice, it created a dynamic where political maneuvering and military strength reigned supreme.
Throughout history, there were 3 Holy Roman Emperors from the House of Wittelsbach - Ludwig IV (known as the Bavarian), Ruprecht III, and Charles VII (Karl Albrecht). Another Bavarian also held the title, and this was Henry II (aka Sankt Heinrich).
Swabia produced a number of Holy Roman Emperors, starting with Frederick I Barbarossa (Kaiser Rotbart) but going on to include Philip, Conrads II, III and IV, and Henry III.
There were also several Franks on the list, including Louis the Pious I, Lothars I and II, and the aforementioned Charlemagne.
One point worth mentioning is that Bavaria was an electorate starting in 1623. This meant that it could vote for the emperor (as the position was officially an elected monarch). As such, the coats of arms from this time included the imperial orb in the very center. However, this ended in 1806 at the hands of Napoleon.