In pandoc you can even do:

![This is the caption\label{mylabel}](/url/of/image.png)
See figure \ref{mylabel}.