Hi,
Would someone be able to tell how how the conversion from TIFF to PNG, and TIFF to JPG is done in ImageMagick?
I tried looking in the documents but could not find how it is implemented.
Regards
Minary
Conversion TIFF to PNG, TIFF to JPG
-
- Posts: 12159
- Joined: 2010-01-23T23:01:33-07:00
- Authentication code: 1151
- Location: England, UK
Re: Conversion TIFF to PNG, TIFF to JPG
Your question is vague. Perhaps you mean, "What is the command to convert from TIFF to PNG, etc?" Then the answer is:
Or perhaps you want to know how the magick works? It is open source, so you can see all the internals.
Code: Select all
convert in.tiff out.png
snibgo's IM pages: im.snibgo.com
Re: Conversion TIFF to PNG, TIFF to JPG
Thank you for the reply!
It is how the magick works I would like to know. I will try to find the right place in the code, but have limited experience with coding so might come back asking you or someone else to point me to the right direction.
Thank you again!
It is how the magick works I would like to know. I will try to find the right place in the code, but have limited experience with coding so might come back asking you or someone else to point me to the right direction.
Thank you again!
-
- Posts: 12159
- Joined: 2010-01-23T23:01:33-07:00
- Authentication code: 1151
- Location: England, UK
Re: Conversion TIFF to PNG, TIFF to JPG
In a nutshell: it reads each image in the input file, storing pixel data in a pixel cache, and metadata in a structure. It does that for all the formats that it can read internally, such as png, jpg, tiff etc. The source code for reading is in the "coders" directory.
It does the inverse for writing. The writing functions are also there, so for example coders\png.c contains the code to both read and write PNG files.
For formats that IM can't directly read or write, it delegates the work to external programs, going via a format it can understand.
It does the inverse for writing. The writing functions are also there, so for example coders\png.c contains the code to both read and write PNG files.
For formats that IM can't directly read or write, it delegates the work to external programs, going via a format it can understand.
snibgo's IM pages: im.snibgo.com
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: Conversion TIFF to PNG, TIFF to JPG
What is the point of the question? Is there some bug you are encountering or some feature that is missing? Are you trying to make some enhancement? What is the motivation for the question.
Re: Conversion TIFF to PNG, TIFF to JPG
Thank you snibgo! I really appreciate it!
I will have a look tonight (haven't had time yet).
@fmw42 The point of the question is that I am using this for a university project and want to understand what's happening under the hood.
I will have a look tonight (haven't had time yet).
@fmw42 The point of the question is that I am using this for a university project and want to understand what's happening under the hood.