A .pdf file has 100 pages of images.
The goal is to enumerate pages 81-90 in the upper left hand corner. I have been able to enumerate .jpg (Raster) images with imagemagick
top=/Users/user/Desktop/AITH_USB_Hope_Submitted_MyCloud/Photographs_ForLoopCaseInsesntive
n=100
echo $top
cp /dev/null forLooplog.txt
echo `date` | tee -a $top/forLooplog.txt
for file in $top/**/*.[jJ][pP]([eE]|)[gG](NDn.); do https://unix.stackexchange.com/a/678469/182280
mogrify -auto-orient \
-gravity northWest \
-font "Arial-Bold-Italic" \
-pointsize 175 \
-fill red \
-annotate +30+30 $n \
-- $file &&
echo $file "was watermarked with" $n | tee -a $top/forLooplog.txt
(( n++ ))
done
echo `date` | tee -a forLooplog.txt
It is my understanding the pdf is a Vector format and suspect that it may be necessary to convert the pdf page to a matrix (Raster).
GOAL: loop through pages of the pdf file and enumerate the page in a similar manner. I have had difficulty finding examples that could be cobbled together to reproduce results similar to the script above.
How would one script a similar algorithm that would enable Imagemagick to loop through each page of a pdf fileand label / stamp as shown in the above example?
Guidance are appreciated / examples are preferred. Thank you