Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Image Duplication Sequence Help
#1
I am wondering if it is possible to add text to a single image that reads "Gameplay - Part 01" and generate a duplicate image with the text "Gameplay - Part 02," and so on, using an automatic process to ensure consistent text placement.

Here is a reference on my Google Drive.
https://tinyurl.com/2dn854pz

Thank You.
Reply
#2
(08-02-2023, 10:42 PM)Adore33 Wrote: I am wondering if it is possible to add text to a single image that reads "Gameplay - Part 01" and generate a duplicate image with the text "Gameplay - Part 02," and so on, using an automatic process to ensure consistent text placement.

Here is a reference on my Google Drive.
https://tinyurl.com/2dn854pz

Thank You.

I was able to determine that you can use scripts in GIMP.
I found a script that suits my needs to make my process faster.

You can find some useful scripts here.
Look in each scripts .zip for more information.
https://sourceforge.net/projects/gimp-to...s/scripts/

I had to put the script here to get it to work...
C:\Users\YOURNAME\AppData\Roaming\GIMP\2.10\plug-ins

Restart GIMP and it should work.

Thanks and hope this can help others.
Reply
#3
Vague memory of a Gimp plugin that pastes the layer name into the layer - but I can not find it, so it might not exist.

The usual way is not Gimp but a command line program ImageMagick (IM) http://www.imagemagick.org

For a single image thumb.png where the number space is blank and outputs as a jpeg

Code:
magick thumb.png -font Arial_Bold.ttf -pointsize 22 -fill white -annotate +266+187  "01" 01.jpg

Gives this.

   

Caveates: You need a matching font and put it in the same folder as the base image

For a sequence of numbers then a batch file and a loop is required. If you do a search you will find examples. Often used for lottery tickets etc. I use linux and very rusty with Windows but see https://superuser.com/questions/908476/c...magemagick Scroll down to the end for a Windows example.

You can ask the question on the IM forum: https://github.com/ImageMagick/ImageMagick/discussions Always very helpful there.

edit: just out of interest, how many of these do you need ?
Reply
#4
(08-03-2023, 08:23 AM)rich2005 Wrote: Vague memory of a Gimp plugin that pastes the layer name into the layer - but I can not find it, so it might not exist.

The usual way is not Gimp but a command line program ImageMagick (IM) http://www.imagemagick.org

For a single image thumb.png where the number space is blank and outputs as a jpeg

Code:
magick thumb.png -font Arial_Bold.ttf -pointsize 22 -fill white -annotate +266+187  "01" 01.jpg

Gives this.



Caveates: You need a matching font and put it in the same folder as the base image

For a sequence of numbers then a batch file and a loop is required. If you do a search you will find examples. Often used for lottery tickets etc. I use linux and very rusty with Windows but see https://superuser.com/questions/908476/c...magemagick  Scroll down to the end for a Windows example.

You can ask the question on the IM forum: https://github.com/ImageMagick/ImageMagick/discussions Always very helpful there.

edit: just out of interest, how many of these do you need ?

Thank you for the information I will look into that as well.
It's ok I don't need you to make me any images, but I appreciate it.
I was just using that for a visual example.
Reply
#5
(08-02-2023, 10:42 PM)Adore33 Wrote: I am wondering if it is possible to add text to a single image that reads "Gameplay - Part 01" and generate a duplicate image with the text "Gameplay - Part 02," and so on, using an automatic process to ensure consistent text placement.

Here is a reference on my Google Drive.
https://tinyurl.com/2dn854pz

Thank You.

You can create an image with all your "labels" as text layers i a group, and then use my ofn-export-layer-combinations to export images that are made of one of the text layers from the group and the background image.
Reply
#6
(08-03-2023, 09:03 AM)Adore33 Wrote: Thank you for the information I will look into that as well.
It's ok I don't need you to make me any images, but I appreciate it.
I was just using that for a visual example.  

Just to show that it can work but how you proceed depends on how many.  10 images - one at a time 1000 images - make a batch file.

Edit: Ok, a hunt through my archive.

1. A plugin Text add-number-layers.py Adds layers to a base image, each layer with a sequential number.
Goes in your plugins folder C:\Users\"yourname"\AppData\Roaming\GIMP\2.10\plugins

2. A script-fu export-layers-plus.scm that exports the layers to individual files.
Goes in C:\Users\"yourname"\AppData\Roaming\GIMP\2.10\scripts

A very quick demo, had to trim it to fit into 1 minute. https://i.imgur.com/6zN33dB.mp4

unzip the attached for the two files.


Attached Files
.zip   sequential-numbers.zip (Size: 5.69 KB / Downloads: 229)
Reply
#7
(08-03-2023, 09:48 AM)Ofnuts Wrote:
(08-02-2023, 10:42 PM)Adore33 Wrote: I am wondering if it is possible to add text to a single image that reads "Gameplay - Part 01" and generate a duplicate image with the text "Gameplay - Part 02," and so on, using an automatic process to ensure consistent text placement.

Here is a reference on my Google Drive.
https://tinyurl.com/2dn854pz

Thank You.

You can create an image with all your "labels" as text layers i a group, and then use my ofn-export-layer-combinations to export images that are made of one of the text layers from the group and the background image.

Thank you.

(08-03-2023, 10:52 AM)rich2005 Wrote:
(08-03-2023, 09:03 AM)Adore33 Wrote: Thank you for the information I will look into that as well.
It's ok I don't need you to make me any images, but I appreciate it.
I was just using that for a visual example.  

Just to show that it can work but how you proceed depends on how many.  10 images - one at a time 1000 images - make a batch file.

Edit: Ok, a hunt through my archive.

1. A plugin Text add-number-layers.py Adds layers to a base image, each layer with a sequential number.
Goes in your plugins folder C:\Users\"yourname"\AppData\Roaming\GIMP\2.10\plugins

2. A script-fu export-layers-plus.scm that exports the layers to individual files.
Goes in C:\Users\"yourname"\AppData\Roaming\GIMP\2.10\scripts

A very quick demo, had to trim it to fit into 1 minute. https://i.imgur.com/6zN33dB.mp4

unzip the attached for the two files.

Thank you very much.  I'll have to look into that as well.  I'm not very good with GIMP so it's a learning process.
Reply


Forum Jump: