sff2g3(1)

πŸ’– sff2g3 β€” the glow-up your fax files deserve πŸ’–

okay bestie, so this lil icon lives in the mgetty+sendfax manual, and its whole thing is turning crusty old CAPI fax files into the shiny G3 format everyone else in the fam actually speaks. let's get into it 🫢


✨ NAME ✨

sff2g3 β€” convert CAPI SFF fax files into G3 fax files πŸ’…


🌸 SYNOPSIS 🌸

sff2g3 [-r] [-d] [-v] input.SFF output.%03d.g3

πŸ¦‹ DESCRIPTION πŸ¦‹

so here's the vibe: sff2g3 reads a Common ISDN API (CAPI) structured file format (SFF) input file, and converts every single fax page tucked inside it into a raw G3 fax file. every page. no pages left behind. periodt. ✨

where do these SFF files even come from, you ask? they typically come from fax reception programs using CAPI on active ISDN cards β€” think isdn4linux, AVM or DIVA cards β€” or similar setups. and the output G3 files? they're in the ``native'' format that all the other G3 utilities in the mgetty+sendfax package use. so like, they'll actually play nice with the rest of the crew. no cap. πŸ’–

fun fact: if the input file name is -, sff2g3 will read from stdin instead. very demure, very stdin. 🌈

now the output file name β€” listen up, this part matters. it should contain a %d or %03d part, and that lil placeholder gets replaced with the current page number. so every page lands in its own file, cute and numbered. BUT 😭 if there's no page number field in there? then only the last page in the SFF file will be saved. just the last one. the others simply do not survive. so don't do that unless you mean it, bestie. πŸ’€


πŸŽ€ OPTIONS πŸŽ€

  • -r β€” reverses the bit order in the bytes of the output G3 file. note that the input bit order is fixed β€” you don't get to touch that one, only the output. πŸ¦‹
  • -d β€” will one day make sff2g3 prepend a digifax header to the page. one day. not today. we'll get to it (see BUGS, bestie, we keep it real here). πŸ™ˆ
  • -v β€” verbose mode, aka show what's going on πŸ‘€. and the more -v arguments you stack, the more debug output level you get. go off, add like four of them, live your truth.

⭐ REFERENCES ⭐

  • the standard for Group 3 fax is defined in CCITT Recommendation T.4 πŸ“œ
  • the SFF file format is specified in the CAPI specs β€” http://www.capi.org 🌐

πŸ’€ BUGS πŸ’€

  • the -d option isn't implemented yet. it's giving "coming soon" but it's been coming for a while, ngl. 🫠
  • the output file name is not yet robust against format string attacks. yes that's a real thing to be worried about. protect your format strings, friends. πŸ”₯

🌈 SEE ALSO 🌈


πŸ‘‘ AUTHOR πŸ‘‘

sff2g3 is Copyright (C) 2004 by Gert Doering, <gert@greenie.muc.de>. πŸ’œ


and that's the whole thing, bestie!! this page came to you courtesy of greenie, dated 17 Jul 04, for sff2g3(1) in the mgetty+sendfax manual. slay, go convert some faxes, and drink water πŸ’–βœ¨πŸŽ€πŸ¦‹πŸŒΈ