How to add text to an image from a flow variable

Dear All

Is there a way to add text from a flow variable or column value to an image (preferably along the top or bottom.
This post in the forum hints that it might be possible, but without an example it’s very hard to attempt especially with the Labeling to PNG Images node configuration page not able to open unless compatible ImgPlusValue and LabelingValue columns are in spec.

Thanks in advance

John

Hi John,

you might also want to check this post:

Should be pretty easy to wrap, so that you can pass the text from a variable.

Best,
Philipp

4 Likes

Hi Philipp

Thanks for this. It certainly does work but the image resolution is badly degraded in the process.
Is there a way to retain good image resolution in your solution?

BW
John

Hi John,

I just had a look at the workflow: In the “Renderer to Image” node I set the image size to 640 x 640 back then (as this was more a proof of concept this worked fine). In case you have images of different sizes, it would be reasonable to configure this setting dynamically for each image which you process and to set it to the actual images’ sizes.

Does this make sense?

Best,
Philipp

2 Likes

Hi Philipp

Yes that did the trick. My images were coming off the R plot node and it looks like users need to be quite generous with the image size compared to some of the other plotting nodes, and more importantly ensure those dimensions are retained in subsequent nodes like Render to Image to retain good resolution especially with the text.

Many Thanks
John

2 Likes

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.