I'm playing a song that goes Dm to Dm9. Moving from either open Dm or fifth-string bar Dm to the pictured Dm9 shape feel pretty awkward. Is there a better shape or fingering? I imagine Dm->Dm9 in any key can't be too uncommon.
It's towards the dusty end, but barre 10th fret, and finger 12th fret 5th string, and 12th fret top string gives the 9th part of the chord. So Dm barre there,(with 12th fret 4th string if you want, otherwise it's Dm7) and Dm9 follows easily.
EDIT: an alternative - similar to the chord window in the question, but maybe not easy fo you, would be very much like D9 where evrything is in 5th fret, except 4th fret 4th string (quite an easy chord to finger), but move the 4th string from F♯ down to 3rd fret, giving the m3 of F♮. But getting to it from where? Maybe 5th fret barre Am shape?
That depends on a few factors. Like whether or not you want all notes in the voicing, whether the style of the song is folk or rock versus Jazz.
I personally have no problems with the fingering
(x, 5, 7, 7, 6, x) to (x, 5, 3, 5, 5, x)
which would require a shift back. Another option is.
(x, x, 3, 2, 3, x) or (x, 0, 3, 2, 3, x) to (x, 5, 3, 5, 5, x)
You could even use (x, 5, 3, 2, 3, x) if you can grab it.
Lastly if you want an open string tone and feel.
(x, x, 0, 2, 3, 1) to (x, x, 3, 2, 3, 0) or (x, x, 0, 2, 3, 0) if you don't mind the ambiguity of not having the 3rd.
An more obtuse voicing might be,
(x, x, 0, 2, 3, 1) to (x, x, 2, 2, 3, 1)
It really depends on the style you are playing, e.g. full strums vs fingerpicking.
On top of existing answers, you can play
Dm7 either ways:
x5356x, with the minor 3rd on top;
x5353x, with the root on top. You bar on the 3rd fret with the 1st finger, so you are basically playing a
G7sus4on 3rd position.
Drive by Incubus makes exactly that (but in Em) by the way!