Image Sampler - get file path

Is there any way to get any information out of the image sampler? I would like to get the file path of the image that is loaded to be saved to a text file.

I wish there was a proper parametric version of image sampler, ie. one where I can actually input the settings and not have it set from a UI, but it should still have a preview of the image itself, but that could be separate to the image sampler. Does anybody know if something like that exists?

Never mind manage to build something so I am posting here in case anybody ever needs this. It uses components from the Squid and ShapeDiver plugins.

It has a few pro’s and con’s, but the image preview is actually better since it changes shape so the image isn’t distorted and it always shows you the color image, which I actually prefer to how the normal image sampler will show you only the selected channel as b/w.

sample_image.gh (2.1 MB)