In many of my projects I end up including a lot of external figures, like
\begin{figure}[h]
\begin{center}\vspace{1cm}
\includegraphics[width=\linewidth]{something.png}
\caption{An illustration of something.}
\label{fig:foo}
\end{center}
\end{figure}
These figures are often taken from somewhere else and Creative Commons licensed, and some of them require attribution. Either way, I generally include a table of all figures at the end of the document, like
\begin{tabular}{ |c|c|c| }
\hline
Figure & Author & License \\
\hline
1 & John Smith / Wikimedia Commons & CC-BY-SA 3.0 \\
\hline
2 & Jane Doe & CC-BY-NC 3.0 \\
\hline
3 & Own Work & Public Domain \\
\hline
\end{tabular}
The problems with this are:
- I have to do the table markup for every project I make;
- The attribution and license information is far from the figure it applies to in the source code, making it harder to maintain;
- If the figure numbers or relative ordering of the figures were to change, I would need to manually update the table.
I'm aware of the existence of \listoffigures, but it doesn't seem to have the kind of format I want; I don't need the page numbers nor the captions, and I would much rather have the figures listed in a table like the above.
In my ideal use case, I'd prefer to be able to include such information inline when creating the figure, like
\begin{figure}[h]
\begin{center}\vspace{1cm}
\includegraphics[width=\linewidth]{something.png}
\caption{An illustration of something.}
\label{fig:foo}
\author{Jane Doe}
\license{CC-BY-NC 3.0}
\end{center}
\end{figure}
and then put something like \tableoffigures at the end of the project to make the table automatically. I'd also like to be able to put this in a separate package that I could just \usepackage in order to make the necessary changes (I know this is technically a different question, but I wouldn't know how to modify a solution to include this feature).
How could I do this? Other tips are welcome; I'm not too knowledgeable about LaTeX so if this would be easier to accomplish with a different environment than \begin{figure} or a separate package then that would be fine.
