Not sure about Bavaria. The Hohenzollerns saw a need to reach an agreement with the Wittelsbachs BEFORE Wilhelm assumed the imperial crown, although Ludwig II still absented himself from the coronation since...well...it's Ludwig being Ludwig.
Not to mention that in 1848 Bavarian princesses are the queens of Prussia and Saxony, as well as mother to the soon-to-be emperor of Austria; the crown princess of Hannover is a cousin/niece. Really, marry Max II to Olga Nikolaïevna as was originally considered and the Bavarian candidature will probably have Russian backing (plus then they'll be related to the Württemberger royal family). Could be fun
Bavaria is powerful enough, that you need to make concessions to them and negotiate if you want to achieve some German Unification. An alliance between Bavaria and various middle-sized German states (like Saxony, Hannover ...) could prevent German Unification. But I doubt that Bavaria is powerful enough and has on its on the interest to start a project to gain German Unification.
It is important for any German unification that Russia isn't angered and won't do anything (or even better) support you. Maybe Bavaria has here good chances.
But if Bavaria tries to start adventures on its own, it is likely that this will provoke Prussia and Austria. If Prussia and Austria are against you, it seems unlikely that other German States will support you, since they would also fear the risk involved with such an adventure.
Also to start such adventures we need a government which want to support German Nationalism and cooperate with revolutionaries. In OTL several liberal reforms happened in Bavaria during the 1848-1849 revolutions and the king abdicated because of a scandal. But the new king Maximilian II. Joseph didn't accepted the constitution created in Frankfurt. Maximilians foreign policy centered on forging cooperation between the medium sized German states to create a third force next to Austria and Prussia in Germany. It seems as if he wasn't an adventurer or a great soldier (which seems necessary to throw the kingdom of Bavaria into such a great adventure which likely leads to war) but a more cautious ruler. Another reason, why Bavaria could be opposed to the revolutionaries, is that the Pfalz (an exclave of Bavaria) rebelled against Bavaria and had a short time revolutionary government between Mai and June 1849 (therefore the revolution endangered the territorial integrity of Bavaria).
In OTL later in 1850 Bavaria cooperated with Austria against Prussia (Bavaria shortly occupied the electorate of Hesse to support Austria against the Erfurt Union by Prussia).
If we have an hypothetical small Germany without Austria and without Prussia, Bavaria wouldn't dominate it. This construct would be more likely a confederacy of various middle sized countries. Such a construct would give the various monarchs far more power and lead to a really weak central government. I doubt that German Nationalists would be happy with that.
Bavaria is also weaker because the industrialization started stronger and earlier in the Rhineland compared to Bavaria.
According to this graphic (
https://de.wikipedia.org/wiki/Datei:Staaten_im_Deutschen_Bund_1848_Einwohner.svg ) Bavaria had a population of 4,5 million in 1848, while Prussia had 16 million. (This graphic probably only depicts the population inside the German confederacy).
As a result, I conclude that it is highly unlikely that Bavaria would accept the crown.
I also conclude that Bavaria wouldn't start own initiatives for German Unification as long as Prussian and Austrian opposition is likely.
But Bavaria would try to cooperate with neighboring middle sized countries to balance and maintain some power compared to Prussia and Austria.