1

I would like convert a jpg file (a photo taken of two pages of a book) to a pdf file, with the goal of

  • making the pdf file look like pages of a regular ebook file in terms of page size and
  • maintaining the clarity or sharpness of the jpg file in the pdf file

I use the following command:

convert test.jpg  -resize 2500x3080  -units PixelsPerInch -density 300x300 test.pdf

with the -resize, -units and -density options hoped to achieve my goal.

But the pdf file doesn't look as clear or sharp as the original jpg file, when I open the pdf file in evince with 100% zoom factor, and open the jpg file in eog with 1 zoom factor.

I wonder how to choose the options and their arguments to approach my goal as closely as possible? Is there some principle of choosing these arguments and options?

The property of the jpg file is following. The image size is 1024 x 786 in pixels. Do X Resolution and Y Resolution mean the number of pixels per inch, so are there 180 pixels per inch along X and along Y directions?

$ exiftool pg296.jpg
ExifTool Version Number         : 9.46
File Name                       : pg296.jpg
Directory                       : .
File Size                       : 214 kB
File Modification Date/Time     : 2008:02:28 08:40:10-05:00
File Access Date/Time           : 2016:04:01 18:45:28-04:00
File Inode Change Date/Time     : 2016:04:01 13:24:27-04:00
File Permissions                : rw-rw-r--
File Type                       : JPEG
MIME Type                       : image/jpeg
Exif Byte Order                 : Little-endian (Intel, II)
Make                            : Canon
Camera Model Name               : Canon PowerShot A510
Orientation                     : Horizontal (normal)
X Resolution                    : 180
Y Resolution                    : 180
Resolution Unit                 : inches
Modify Date                     : 2008:02:04 11:15:55
Y Cb Cr Positioning             : Centered
Exposure Time                   : 1/40
F Number                        : 2.6
Exif Version                    : 0220
Date/Time Original              : 2008:02:04 11:15:55
Create Date                     : 2008:02:04 11:15:55
Components Configuration        : Y, Cb, Cr, -
Compressed Bits Per Pixel       : 3
Shutter Speed Value             : 1/40
Aperture Value                  : 2.6
Max Aperture Value              : 2.6
Flash                           : Off, Did not fire
Focal Length                    : 5.8 mm
Macro Mode                      : Normal
Self Timer                      : Off
Quality                         : Fine
Canon Flash Mode                : Off
Continuous Drive                : Single
Focus Mode                      : Single
Record Mode                     : JPEG
Canon Image Size                : Medium 2
Easy Mode                       : Full auto
Digital Zoom                    : None
Contrast                        : Normal
Saturation                      : Normal
Sharpness                       : 0
Camera ISO                      : Auto
Metering Mode                   : Evaluative
Focus Range                     : Auto
AF Point                        : Auto AF point selection
Canon Exposure Mode             : Easy
Lens Type                       : Unknown (-1)
Max Focal Length                : 23.1875 mm
Min Focal Length                : 5.8125 mm
Focal Units                     : 32/mm
Max Aperture                    : 2.7
Min Aperture                    : 8
Flash Bits                      : (none)
Focus Continuous                : Single
AE Setting                      : Normal AE
Display Aperture                : 2.6
Zoom Source Width               : 2048
Zoom Target Width               : 2048
Spot Metering Mode              : Center
Photo Effect                    : Off
Manual Flash Output             : n/a
Focal Type                      : Zoom
Focal Plane X Size              : 5.82 mm
Focal Plane Y Size              : 4.37 mm
Auto ISO                        : 100
Base ISO                        : 50
Measured EV                     : 8.97
Target Aperture                 : 2.6
Target Exposure Time            : 1/40
Exposure Compensation           : 0
White Balance                   : Auto
Slow Shutter                    : Off
Shot Number In Continuous Burst : 0
Optical Zoom Code               : 0
Flash Guide Number              : 0
Flash Exposure Compensation     : 0
Auto Exposure Bracketing        : Off
AEB Bracket Value               : 0
Control Mode                    : Camera Local Control
Focus Distance Upper            : 0.53 m
Focus Distance Lower            : 0 m
Bulb Duration                   : 0
Camera Type                     : Compact
Auto Rotate                     : None
ND Filter                       : Off
Self Timer 2                    : 0
Flash Output                    : 0
Num AF Points                   : 9
Valid AF Points                 : 9
Canon Image Width               : 1024
Canon Image Height              : 768
AF Image Width                  : 2048
AF Image Height                 : 256
AF Area Width                   : 369
AF Area Height                  : 46
AF Area X Positions             : -370 0 370 -370 0 370 -370 0 370
AF Area Y Positions             : -49 -49 -49 0 0 0 49 49 49
AF Points In Focus              : 4,7
Primary AF Point                : 4
Thumbnail Image Valid Area      : 0 0 0 0
Canon Image Type                : IMG:PowerShot A510 JPEG
Canon Firmware Version          : Firmware Version 1.00
File Number                     : 111-1152
Owner Name                      :
Canon Model ID                  : PowerShot A510
Date Stamp Mode                 : Off
User Comment                    :
Flashpix Version                : 0100
Color Space                     : sRGB
Exif Image Width                : 1024
Exif Image Height               : 768
Interoperability Index          : R98 - DCF basic file (sRGB)
Interoperability Version        : 0100
Related Image Width             : 1024
Related Image Height            : 768
Focal Plane X Resolution        : 4571.428571
Focal Plane Y Resolution        : 4571.428571
Focal Plane Resolution Unit     : inches
Sensing Method                  : One-chip color area
File Source                     : Digital Camera
Custom Rendered                 : Normal
Exposure Mode                   : Auto
Digital Zoom Ratio              : 1
Scene Capture Type              : Standard
Compression                     : JPEG (old-style)
Thumbnail Offset                : 2560
Thumbnail Length                : 3231
Image Width                     : 1024
Image Height                    : 768
Encoding Process                : Baseline DCT, Huffman coding
Bits Per Sample                 : 8
Color Components                : 3
Y Cb Cr Sub Sampling            : YCbCr4:2:2 (2 1)
Aperture                        : 2.6
Drive Mode                      : Single-frame Shooting
ISO                             : 50
Image Size                      : 1024x768
Lens                            : 5.8 - 23.2 mm
Lens ID                         : Unknown 5-23mm
Scale Factor To 35 mm Equivalent: 6.1
Shooting Mode                   : Full auto
Shutter Speed                   : 1/40
Thumbnail Image                 : (Binary data 3231 bytes, use -b option to extract)
Circle Of Confusion             : 0.005 mm
Field Of View                   : 54.0 deg
Focal Length                    : 5.8 mm (35 mm equivalent: 35.4 mm)
Hyperfocal Distance             : 2.63 m
Lens                            : 5.8 - 23.2 mm (35 mm equivalent: 35.4 - 141.1 mm)
Light Value                     : 9.1

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.