This is also a helpful tip if the room has more than one door.
I can't tell you how often my team knocked at door A to throw out another group that then all left by door B, leaving us waiting outside until we knocked again 5min later.
Which is probably good you didn't have the guts. Being passive-aggressive-impolite to people won't help them to be more polite about running over others' time.
I always did the knock-on-door + tell them my meeting time has started and never had an issue, be assertive and people will move quickly. Escalating impoliteness doesn't help anyone except your own sense of self-justice.
Back in school, I was one of those people who watched the clock so I could just zoom out when it was time. That habit led me to assume others did the same, so when I started my first job I assumed meetings would end on time and I tended to just walk in without checking who is actually in the room (then pause and quietly back out when they all looked at me).
Eventually broke the habit, but for the time I was doing it it did break up the previous meeting pretty quickly.