Daily Shaarli

All links of one day in a single page.

July 29, 2021

Convertir un PDF 1.6 -> 1.4

Pour une raison encore inconnue, pas moyen d'ouvrir un PDF 1.6 sur ma Debian 11 (sid).

$ file problematic-1.6..pdf
problematic-1.6.pdf: PDF document, version 1.6

$ pdfinfo problematic-1.6.pdf
Syntax Error: Gen inside xref table too large (bigger than INT_MAX)
Syntax Error: Invalid XRef entry 3
Syntax Error: Top-level pages object is wrong type (null)
Command Line Error: Wrong page range given: the first page (1) can not be after the last page (0).

Tant pis, pas le temps de regarder en détail d'où vient le problème. Convertissons-le en PDF 1.4.

$ gs -q -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -o good-1.4.pdf problematic-1.6.pdf
**** Error: /BBox has zero width or height, which is not allowed.
Output may be incorrect.

$ file good-1.4.pdf
good-1.4.pdf: PDF document, version 1.4

Worlds Beyond Our Senses_Monster Hunter Soundtrack (by Paul Haslinger) - YouTube
thumbnail

Épique !

Paul Haslinger - Worlds Beyond Our Senses