It is currently Wed Jul 22, 2026 7:01 am


All times are UTC - 5 hours [ DST ]



Post new topic Reply to topic  [ 23 posts ]  Go to page Previous  1, 2
Author Message
 Post subject: Re: Batch export all opened images script for GIMP [Update]
PostPosted: Tue Jul 16, 2024 1:12 pm  (#21) 
Offline
GimpChat Member

Joined: Jul 15, 2024
Posts: 5
rich2005 wrote:
The compression curve. As you can see it is a curve not a straight line. You can not use a linear interpolation. For example the amount of compression for quality=50 is not half of quality=100 (yes a 100 jpeg is still compressed).

rich2005 wrote:
It says use quality 40 to 60 for posting images on the internet. Smaller file sizes = saving on band with / site storage...

Thanks for your explanation and clarification.
rich2005 wrote:
BIMP. Using Debian so that might not be available unless you compile it yourself. A flatpak Gimp does have it as a special flatpak BIMP version. No limit of the number of files but it might be slow. So lets forget BIMP

OK, I won't use BIMP then, per your recommendation.
rich2005 wrote:
Go to the folder containing the jpegs and if you want a size of about say, 400 kb (your quality=50 requirement) the command in a terminal is:
mogrify -define jpeg:extent=400kb *.jpg

I genuinely thank you for the above command line.
rich2005 wrote:
Beware mogrify will overwrite the original sized image.

Thanks for your warning.
rich2005 wrote:
It might slow down where there are many images.

Oh...I'm quite disappointed to learn about it.

Patrice (a.k.a. PixLab) found that XnConvert is able to process tons of JPG files very quickly. Perhaps I should try XnConvert.
rich2005 wrote:
XnConvert - yes there is a linux version.

Based on what I learned after going to XnConvert's official website, the software is available as a native app for Microsoft Windows OS.

I shall use XnConvert for Microsoft Windows because:

(1) XnConvert's latest version is available unlike XnConvert for Debian/Linux where I need to install AppImage or Flatpak first on said Linux distro.
(2) XnConvert has a GUI compared to ImageMagick. I've been using Microsoft Windows OS all my life and only dabbled in Debian, Fedora and OpenBSD some years ago.

rich2005 wrote:
I often use the larger XnViewMP - I use the linux appimage.

Sorry, would you like to clarify what you meant by "larger XnViewMP"?

I did notice that the software developer for XnConvert and XnViewMP is the same person/organization.
Moreover, I noticed that XnViewMP is available as a native app for Microsoft Windows; therefore I won't use XnViewMP on a Linux distro because I'll have to install AppImage or Flatpak first.

Last but not least, I wish to ask you for advice about the size of a JPG file.

According to your graph that you provided in one of your earlier posts, quality=80 is good for archival of personal JPG images.

Again, based on your graph, a quality=80 setting would produce a JPG file of size 200KB. That's why I'm a bit confused as to how you obtained a value of 400KB for a quality=50 setting.


Top
 Post subject: Re: Batch export all opened images script for GIMP [Update]
PostPosted: Tue Jul 16, 2024 2:06 pm  (#22) 
Offline
GimpChat Member

Joined: Mar 04, 2011
Posts: 2610
Well if you go here: https://www.xnview.com/en/xnconvert/ there are various linux packages available. I have used a "portable" version before. Unpack and run.

There is also a flatpak version and it seems you do not like those.

What do I mean a larger XnViewMP - It is a viewer / cataloger that also has all the functions of XnConvert

Several linux options here: https://newsgroup.xnview.com/viewtopic.php?f=82&t=47317 I happen to prefer the appimage, but it is just a choice.

No need to go anywhere near Windows.

[/quote]According to your graph that you provided in one of your earlier posts, quality=80 is good for archival of personal JPG images.

Again, based on your graph, a quality=80 setting would produce a JPG file of size 200KB. That's why I'm a bit confused as to how you obtained a value of 400KB for a quality=50 setting. [/quote]

I do not know how you arrived at that conclusion. Look, you can determine a value by using a sample image and adjusting the compression in Gimp (this is a Gimp forum) from the Export dialogue.

Attachment:
comparison.jpg
comparison.jpg [ 132.99 KiB | Viewed 788 times ]


Enable Show preview in image window and just above that is an estimate of file size for that image. Of course jpeg compression is a lossy format so you can not lay down hard and fast rule, it does depend on the image. A landscape photograph versus a line drawing.


Top
 Post subject: Re: Batch export all opened images script for GIMP [Update]
PostPosted: Tue Jul 16, 2024 4:30 pm  (#23) 
Offline
GimpChat Member

Joined: Jul 15, 2024
Posts: 5
rich2005 wrote:
Well if you go here: ....... there are various linux packages available. I have used a "portable" version before. Unpack and run.

Thanks for your recommendation.
rich2005 wrote:
There is also a flatpak version and it seems you do not like those.

There's a reason I don't install AppImage and/or Flatpak on my Debian distro.

My Debian distro is used for online banking, cryptocurrency trading, in particular XMR, Zcash, Dash and of course BTC.

Both AppImage and Flatpak do have security vulnerabilities (which software doesn't have them?) and they may not be fixed in time before hackers hack into my crypto wallets and steal my funds.
rich2005 wrote:
What do I mean a larger XnViewMP - It is a viewer / cataloger that also has all the functions of XnConvert

Thanks for your clarification.
rich2005 wrote:
Several linux options here: ......... I happen to prefer the appimage, but it is just a choice.

Thanks for your sharing your experience.
rich2005 wrote:
No need to go anywhere near Windows.

I happen to be a Windows guy since the days of Windows 3.1 and only dabbled in Linux distros and OpenBSD some years ago.

Anyway I don't mind Microsoft sending telemetry about my use of XnConvert on my personal JPG files.
rich2005 wrote:
I do not know how you arrived at that conclusion.

Sorry, I apologize for the misunderstanding.

You have been a great guy and I genuinely appreciate your help and very useful tips.

Cheers!


Top
Post new topic Reply to topic  [ 23 posts ]  Go to page Previous  1, 2

All times are UTC - 5 hours [ DST ]



* Login  



Powered by phpBB3 © phpBB Group