It is currently Tue Sep 22, 2026 8:20 pm


All times are UTC - 5 hours [ DST ]



Post new topic Reply to topic  [ 9 posts ] 
Author Message
 Post subject: Export as png
PostPosted: Mon Jan 02, 2017 3:52 pm  (#1) 
Offline
New Member

Joined: Jan 02, 2017
Posts: 2
GIMP Version: 2.8.14
Operating System: Windows
GIMP Experience: New User



My camera saves files in jpg and when I process them in Gimp, I prefer saving them in png format. I set the export type to png for the first save and change filename extension to .png from .jpg, and it exports fine. However, it seems each succeeding export, I have to change each extension to .png even though the export type stays at png. Is there a way to have the extension automatically set to .png?

The "Select file type by extension" would work but it doesn't retain my choice between images.


Share on Facebook Share on Twitter Share on Orkut Share on Digg Share on MySpace Share on Delicious Share on Technorati
Top
 Post subject: Re: Export as png
PostPosted: Tue Jan 03, 2017 9:23 pm  (#2) 
Offline
Global Moderator
User avatar

Joined: Apr 01, 2012
Posts: 8471
Location: On the other side of your screen
As far as I am aware you have to put in the file type each time when exporting unless you use the same one quite a lot.
Because your photos are opening up as .jpg's they want to export as .jpg's. I have found they even want to use the same name. (Gotta be careful of overwriting unless you want to)
It will stay the same (save the same each time) if you are creating an image from scratch.
Anyway , if there is a way to do it automatically someone else will let us know.

_________________
Image
Free Fun Photo Editing & resources
Poems from the Lord
Gimp Newby
Gimp version 3.2.4 and GMIC-Qt 4.0.2 OS :- Windows 10 Home 64


Top
 Post subject: Re: Export as png
PostPosted: Tue Jan 03, 2017 11:13 pm  (#3) 
Offline
GimpChat Member
User avatar

Joined: Sep 24, 2010
Posts: 12845
If you open a jpg, it will want to save as jpg. A tif a tif and a png a png and so forth and so on. Don't think there is a setting for GIMP to save to a default setting (nor do I actually ever need one, but that's just me). :)

_________________
Lyle

Psalm 109:8

Image


Top
 Post subject: Re: Export as png
PostPosted: Tue Jan 03, 2017 11:42 pm  (#4) 
Offline
New Member

Joined: Jan 02, 2017
Posts: 2
That seems a bit odd. I may have a few hundred files from a trip that will be in jpg format. When I process them, I wish to save in png, so I select the export png option. But for each and every file I export, I have to type a new extension because even though I set the export to png, it doesn't update the extension (and anyway, there's a Overwrite *.jpg if I wanted it to save a jpg.)


Top
 Post subject: Re: Export as png
PostPosted: Wed Jan 04, 2017 12:12 am  (#5) 
Offline
GimpChat Member
User avatar

Joined: Sep 24, 2010
Posts: 12845
One way to overcome this issue is to save all of your jpgs as PNG using a batch processor; Irfanview has such a feature. Then open the PNG from the get-go and save the result (leaving your jpgs intact). :)

_________________
Lyle

Psalm 109:8

Image


Top
 Post subject: Re: Export as png
PostPosted: Wed Jan 04, 2017 4:08 am  (#6) 
Offline
Script Coder
User avatar

Joined: Jun 22, 2010
Posts: 1171
Location: Here and there
Sounds like you could do with someone writing a GIMP script to take your existing file name, change the extension and export as a .png (in the same directory?)

Kevin


Top
 Post subject: Re: Export as png
PostPosted: Wed Jan 04, 2017 4:10 am  (#7) 
Offline
GimpChat Member

Joined: Mar 04, 2011
Posts: 2615
One option, is a script that will export the active image to a png. Not 100% suitable, but works for photographs where there is essentially a single layer, is http://registry.gimp.org/node/18440 export_layers-0.6.py.txt (note the .txt to remove)

snags
- The exported file is named filename.jpg.png which might be an annoyance. I use a home made script the other way; png -> jpeg and a quick rename (lose the extension) of the layer name before using the script tidies this up.
- Come to close the active image and there is the annoying 'save warning' Use the saver plugin http://www.shallowsky.com/software/gimp-save/ which writes the file and marks as 'clean' for a quick close.

Maybe one of the clever people could combine these functions into one. ( see Kevin has suggested that)

Batch conversion. Although good, no need for XnView. BIMP will do that from within Gimp. http://www.alessandrofrancesconi.it/projects/bimp/


Top
 Post subject: Re: Export as png
PostPosted: Wed Jan 04, 2017 5:05 am  (#8) 
Offline
Script Coder
User avatar

Joined: Jun 22, 2010
Posts: 1171
Location: Here and there
Just because I thought it could be done simply, I've created a Python plug-in to export the current image to a PNG.

Extract the .py file from the attached archive and put it into your personal plug-ins folder (also make it executable if you are using a Linux operating system)

It adds an entry on the File menu:
Attachment:
Untitled.png
Untitled.png [ 39.31 KiB | Viewed 4382 times ]


And will save the .png in the same directory as the source image.

Hope it helps

Kevin


Attachments:
jaftwo_001.zip [771 Bytes]
Downloaded 221 times
Top
 Post subject: Re: Export as png
PostPosted: Wed Jan 04, 2017 8:18 am  (#9) 
Offline
Script Coder
User avatar

Joined: Oct 25, 2010
Posts: 4812
jaftwo wrote:
GIMP Version: 2.8.14
Operating System: Windows
GIMP Experience: New User



My camera saves files in jpg and when I process them in Gimp, I prefer saving them in png format.


Is there a good reason for that? The difference between PNG and good quality JPG (quality 97+, no subsampling) would be less than the chroma noise of your picture and the round-off errors of any color processing in Gimp. If you are that picky with your pictures, you should be working from RAW. The PNG you create are likely bigger that the RAW files from your camera (at least they are with mine, 33MB vs 20MB). And RAW processors never alter your source, they usually keep the processing parameters in a side file.

TL;DR: pixel wise, picture foolish :)

_________________
Image


Top
Post new topic Reply to topic  [ 9 posts ] 

All times are UTC - 5 hours [ DST ]



* Login  



Powered by phpBB3 © phpBB Group