AVS2PS(1)

πŸ’… avs2ps β€” okay bestie, let's talk

so you know that manual page header that goes like AVS2PS(1) and General Commands Manual? yeah that's this. section 1, general commands, avs2ps, we're here, we're slaying πŸŽ€


✨ NAME ✨

avs2ps β€” it takes an AVS image coming in on stdin and turns it into a monochrome PostScript file going out on stdout. glow up, but make it greyscale πŸ¦‹


🌸 SYNOPSIS 🌸

avs2ps [-b] [-dpi xxx] < infile.avs > outfile.ps

πŸ’– DESCRIPTION πŸ’–

okay so picture this: you've got a 24-bit color image file in AVS format, right? and avs2ps takes that whole thing and converts it into a dithered monochrome PostScript image with the exact same number of pixels as the input file. no shrinkage, no weirdness, same pixel count, periodt πŸ‘‘

and the way it works is so satisfying β€” it takes that input stream, converts it to a grey scale image, and then runs an empirical algorithm for dithering and error propagation to spit out the monochrome output image. iykyk. that's the whole vibe.

but also?? you can literally use avs2ps as a filter for the output of the render program to produce a PostScript file directly. like, no middle steps. just pipe it and go.

and the best part, no cap: avs2ps is machine independent and it does not impose restrictions on the tile size in the original image. it also supersedes the programs molras3d and hdither in the viewtools package β€” so if you were still using those, bestie, it's time to move on, they're the old era πŸ’€


πŸŽ€ EXAMPLES πŸŽ€

1. produce an unbordered black & white image suitable for printing on a 300 dpi PostScript printer:

render < infile.r3d | avs2ps > image.ps

2. add a border, and prep the image for a 400dpi printer:

render < infile.r3d | avs2ps -b -dpi 400 > image.ps

✨ OPTIONS ✨

  • -b β€” draws a border around the figure. by default avs2ps produces a borderless image that sits 0.5 inch in from the bottom left of the page. so if you want that frame, say it with your chest πŸ’…
  • -dpi xxx β€” okay this one matters, listen. by default avs2ps writes header records into the PostScript output file that are correct for a 300dpi printer (think like, an HP IIIsi). and if there's a mis-match between those header records and the actual resolution of the printer, the image quality is substantially degraded 😭 so this option lets you specify a different printer resolution instead. for example -dpi 400 for a Next printer, or -dpi 95 for GhostScript on a 1280x1024 workstation screen. match your dpi to your actual setup, bestie, that's the whole lesson 🫢

πŸ’œ SOURCE πŸ’œ

Ethan A Merritt
University of Washington, Seattle WA 98195
merritt@washington.edu

πŸ¦‹ SEE ALSO πŸ¦‹

  • render(l)
  • raster3d(l)
  • avs

πŸ‘‘ AUTHORS πŸ‘‘

Ethan A Merritt.

and a lil credit where it's due: the dithering algorithm is derived from code by Randy Read and Albert Berghuis. icons supporting icons, we love to see it 🌈


and that's the whole page bestie, no crumbs left. this is from Raster3D, dated 8 May 1999 β€” yeah she's vintage, she's an AVS2PS(1) classic, and she still eats πŸ’–βœ¨