forked from josch/img2pdf
check for minimum pdf page size
This commit is contained in:
parent
4bca045e64
commit
50aff1474f
1 changed files with 3 additions and 0 deletions
|
@ -152,6 +152,9 @@ def main(images, dpi, title=None, author=None, creator=None, producer=None,
|
||||||
|
|
||||||
pdf_x, pdf_y = 72.0*width/dpi_x, 72.0*height/dpi_y # pdf units = 1/72 inch
|
pdf_x, pdf_y = 72.0*width/dpi_x, 72.0*height/dpi_y # pdf units = 1/72 inch
|
||||||
|
|
||||||
|
if pdf_x < 3.00 or pdf_y < 3.00:
|
||||||
|
warning_out("pdf width or height is below 3.00 - decrease the dpi")
|
||||||
|
|
||||||
# either embed the whole jpeg or deflate the bitmap representation
|
# either embed the whole jpeg or deflate the bitmap representation
|
||||||
if imgformat is "JPEG":
|
if imgformat is "JPEG":
|
||||||
ofilter = [ "/DCTDecode" ]
|
ofilter = [ "/DCTDecode" ]
|
||||||
|
|
Loading…
Reference in a new issue