From 28610bce4cbb0c7a4a5959856767783075d8d2fc Mon Sep 17 00:00:00 2001 From: Shihaam Abdul Rahman Date: Sat, 11 Nov 2023 23:45:57 +0500 Subject: [PATCH] experimental support for editing image with caption --- bot.sh | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/bot.sh b/bot.sh index 9b9cf04..cbba69f 100755 --- a/bot.sh +++ b/bot.sh @@ -5,6 +5,7 @@ date=$(date "+%Y%m%d_%H%M%S") image=data/image_$date.png speedtest_result=data/speedtest_$date.txt weather_file=data/weather_$date.json +edited_image=data/edited_image_$date.png ################################################################################# # Capture a frame from RTSP stream @@ -50,6 +51,15 @@ $current_weather " ################################################################################# +################################################################################# +#convert "$image" \ +# -gravity South \ +# -font $PWD/JoyPixels.ttf \ +# -pointsize 20 \ +# -annotate +0+10 "$caption" \ +# $edited_image +################################################################################# + ################################################################################# curl -X POST https://api.telegram.org/bot$TG_BOT_API_KEY/sendPhoto \ -F chat_id=$TG_CHANNEL_ID \