cadey,
@cadey@pony.social avatar

Cursed TIL of the day: PDF is a vector image format, so you can convert a PDF to SVG with pdf2svg

foone,
@foone@digipres.club avatar

@cadey did I ever tell you about that joke tool we deployed in production at the US government that could turn TIFF files into PDFs, without loading them up as images? It just rewrote the headers!

thomasjwebb,
@thomasjwebb@mastodon.social avatar

@foone @cadey If you told me that some software could open those anyway because of a weird quirk in the pdf specification, I'd have no choice but to believe you.

foone,
@foone@digipres.club avatar

@thomasjwebb @cadey oh its worse than that: they're completely valid pdf files.

foone,
@foone@digipres.club avatar

@thomasjwebb @cadey it's because TIFF supports, among a bunch of other formats, group-4 fax encoding, a black & white image format.
PDF supports a bunch of image formats, including... group-4 fax encoding.

foone,
@foone@digipres.club avatar

@thomasjwebb @cadey so the program just parsed the TIFF to get the size out, then grabbed the binary blob of the g4-encoded image. Then it output a PDF header with that size and a bit of postscript code that says "here comes a g4-encoded image" and then it pastes in the blob. Done. your TIFF is now a PDF.

  • All
  • Subscribed
  • Moderated
  • Favorites
  • random
  • DreamBathrooms
  • ngwrru68w68
  • tester
  • magazineikmin
  • thenastyranch
  • rosin
  • khanakhh
  • InstantRegret
  • Youngstown
  • slotface
  • Durango
  • kavyap
  • mdbf
  • tacticalgear
  • JUstTest
  • osvaldo12
  • normalnudes
  • cubers
  • cisconetworking
  • everett
  • GTA5RPClips
  • ethstaker
  • Leos
  • provamag3
  • anitta
  • modclub
  • megavids
  • lostlight
  • All magazines