yes, vertex attach the image ( sprite) to one vertex.
then get the vector direction from vertex 1 to vertex 2, convert that to angles
align the sprite to those angles

then getting the distance from vertex 1 to vertex 2 then scale the image( sprite) ( original hight in pixels /distance)

its no differnt then doing a vertex attachment with a model and aligning the model ( see the script exampls on acknext site) except your just adding in a scale calculation for distance