Hard, but doable. I think it would require a civil war(s), a king getting support not only from noblemen/knights, but also some other social group (burghers?), possibly also some overhelming external threat to give king absolute power, initially only temporarily, but later perpetually.
I think that Władysław III might be a good candidate. Perhaps king of Hungary Albrecht II Habsburg lives longer, but in 1441 Murad II manages to capture Belgrad, and John Hunyady dies during the campaign in a skirmish? Hungary can not offer Władysław Hungarian throne as long as Albrecht is alive. Eventually the Ottomans conquer most of Hungary closing to Polish borders. Meanwhile Ulugh Muhammad keeps control of most of the Golden Horde and, as revenge for Lithuanian support for his rivals, allies with the Ottomans and starts raiding Ruthenia and Lithuania. First Polish and Lithuanian armies (levee en masse) gather slowly and are more interested in policy, than fighting, so when they enter the action, there are quickly defeated. King Władysław manages to convince his knights to agree to higher taxes in exchange of their personal service, so he can hire professional soldiers (like IOTL during Polish-Teutonic War 1454-1466). That smaller, but mich more competent army is much more successful - and loyal to the king.
After temporarily stabilizing situation on southern border (peace treaties with the Ottomans and Tatars). King Władysław III is expected to disband most of his professional army. However, at the same time, Prussian Union raises against the Order (as they did IOTL) and ask for incorporation into Poland. The Polish-Teutonic war lasts much shorter than IOTL and most of the Prussian Union get their wish.
King Władysław III now has hardened in battle, professional army; support of the very wealthy towns of the Prussian Union. He sees no reason to relinquish his power, especially after his son, John, is born (it doesn't matter who is the wife). The noblemen raise against them and ask Władysław's brother, Casimir, for help. The civil/fratricide war ends with Władysław's vctory and Casimir's surender (or death). King's position is now very strong and Władysław's successor will do their best to streghten it even more.
Pure improvisation, not very likely, but possible.