JBIG2ENC(1)

πŸ“¦
version 0.32 Β· 4 versions
, in ubuntu stonking

✨ NAME ✨

okay so bestie, welcome to jbig2enc β€” the encoder for JBIG2 πŸ’… (yes it's in section 1 of the manual, iykyk). it takes your images and turns them into lil JBIG2 bitstreams and honestly? iconic behavior.


🌸 SYNOPSIS 🌸

jbig2 [options] <input filenames...>

like. you run jbig2, you throw some options at it, you hand it a pile of input filenames, and it does its thing. the way that this is literally the whole interface. 🫢


πŸŽ€ OPTIONS πŸŽ€

the full menu, no skips, no cap, every single one of them:

  • -b <basename> β€” sets the output file root name, and this one only matters when you're doing symbol coding, so keep that in mind bestie πŸ’–
  • -d, --duplicate-line-removal β€” uses TPGD in the generic region coder. bye bye duplicate lines ✨
  • -p, --pdf β€” produces PDF ready data. lowkey the reason half of y'all are even here fr fr πŸ“„
  • -s, --symbol-mode β€” uses a text region instead of the generic coder. main character mode for text πŸ¦‹
  • -t <threshold> β€” sets the classification threshold for the symbol coder. default is 0.92 ⭐
  • -w <weight> β€” sets the classification weight for the symbol coder. default is 0.50 πŸ’œ
  • -T <bw threshold> β€” sets the 1 bpp threshold. default is 200 🌸
  • -G, --global β€” uses the global BW threshold on 8 bpp images. heads up: the default is to use local (adaptive) thresholding, so this flips you to the other vibe entirely πŸ‘‘
  • -r, --refine β€” uses refinement. ⚠️ it requires -s, and it's lossless, so don't be out here pairing it with anything else and then acting surprised πŸ™ˆ
  • -O <outfile> β€” dumps the thresholded image as a PNG. lil preview moment, obsessed πŸŽ€
  • -2 β€” upsamples 2x before thresholding 🌈
  • -4 β€” upsamples 4x before thresholding πŸ”₯
  • -S β€” removes images from mixed input and saves them separately πŸ“
  • -j, --jpeg-output β€” writes images from mixed input as JPEG πŸ’…
  • -a, --auto-thresh β€” uses automatic thresholding in the symbol encoder ✨
  • -D, --dpi β€” forces dpi πŸ“
  • --no-hash β€” disables use of the hash function for automatic thresholding. literally just turns the hashing off, that's it πŸ’€
  • -V, --version β€” version info ⭐
  • -v β€” be verbose. it says more stuff. slay πŸ—£οΈ

and when -v does its little version thing, the info it's working with looks a whole lot like this:

leptonica-1.86.0

libgif 5.2.2 : libjpeg 8d (libjpeg-turbo 2.1.5) : libpng 1.6.58 :
libtiff 4.7.0 : zlib 1.3.1 : libwebp 1.5.0 : libopenjp2 2.5.4

look at all those libraries holding hands 🫢🧚


and that's the whole page bestie, no filler, no gatekeeping πŸ’– this was jbig2enc 0.32, dated June 2026, and it ate. periodt. πŸ‘‘

πŸ“¦ where this page comes from