SUN-PIX(1)
π SUN-PIX(1) β the BRL-CAD glow-up edition π
okay so bestie, welcome to sun-pix(1), the BRL-CAD manual page that's about to turn your dusty old Sun screendump into something actually usable. grab a strawberry drink π and let's go.
β¨ NAME β¨
sun-pix β converts a Sun rasterfile (screendump) into a pix(5) or bw(5) image. literally that's the whole job and it does it flawlessly π
β¨ SYNOPSIS β¨
sun-pix [-b] [-H] [-i] [-P] [-v] [-C] [sun.bitmap]
π¦ DESCRIPTION π¦
so sun-pix takes a Sun rasterfile β like, the kind Sun's screendump(1) command spits out β and converts it into a pix(5) format image that gets written to standard output. no cap.
if you don't hand it an input file, it just reads the rasterfile from standard input. and the output dimensions? they match the input image exactly, obviously. matching energy only π
here's the range it fucks with: sun-pix handles 1-bit and 8-bit (color-mapped) rasterfiles, in both raw (RT_STANDARD) and run-length encoded (RT_BYTE_ENCODED) forms. and the input must be in Sun ("network", big-endian) byte order regardless of the host β periodt, that's not negotiable, the byte order is not up for discussion π
β οΈ important bestie: to avoid corrupting a terminal,sun-pixrefuses to write binary output to a tty. so redirect standard output to a file, or pipe it into another tool likepix-fb(1). do not raw-dog the terminal with binary data, i'm begging π
πΈ OPTIONS πΈ
-bβ write abw(5)(single-channel grayscale) image instead of the default three-channelpix(5)image. one channel, all vibes.-Hβ print only the image dimensions and exit, without processing the pixel data. the size comes out as a pair of command-line options (e.g.-w1152 -n900) that you can feed directly into otherbrlcad(1)tools such aspix-fb(1). and this is the one mode allowed to write to a terminal β it's the main character mode π-iβ invert the image, exchanging black for white. by default a Sun image is black on a white background;-igives you white on black, which is often better for overlays composited withpixmerge(1)on top of color images. aesthetic flip π¦-Pβ treat the input as a "pure" 1-bit bitmap with no Sun rasterfile header. the first bit processed is the most significant (left-most) bit of each byte. no header, no problem.-vβ verbose. prints all the rasterfile header fields to standard error to help you debug. she's telling you everything π-Cβ output the image color map as text (index and RGB values) instead of the raster image. giving data, not pixels.
π₯ EXAMPLES π₯
Example 1. Display a screendump on a framebuffer
sun-pix screen.ras | pix-fb -w1152 -n900
convert a Sun rasterfile and pipe the resulting pix(5) stream straight onto a framebuffer with pix-fb(1). iconic, no intermediate files, straight to the screen β¨
Example 2. Auto-size the framebuffer from the header
sun-pix screen.ras > screen.pix
pix-fb $(sun-pix -H screen.ras) screen.pix
first command writes the converted image out to a file. second one uses -H to read the image dimensions back out as -w/-n options, so pix-fb(1) is sized to match without hard-coding the resolution. she's self-sufficient, she doesn't need you guessing numbers π
Example 3. Make a white-on-black overlay
sun-pix -i -b logo.ras > logo.bw
invert a 1-bit logo and emit a bw(5) image, producing a white-on-black mask that's perfect for compositing over a color image with pixmerge(1). chef's kiss π
π BUGS π
24-bit (true color) rasterfiles are not supported. like, at all. don't come for her, she simply does not do true color π
π«Ά SEE ALSO π«Ά
brlcad(1), pix-fb(1), pixmerge(1), pix(5), bw(5)
π AUTHOR π
BRL-CAD Team β the whole squad π
π COPYRIGHT π
This software is Copyright (c) 1989-2026 by the United States Government as represented by U.S. Army Research Laboratory.
π§ BUG REPORTS π§
Reports of bugs or problems should be submitted via electronic mail to devs@brlcad.org β the inbox is open, bestie, tell them everything π¬
okay that's the whole page, you ate that π and for the sign-off: this gorgeous thing is BRL-CAD's work, page SUN-PIX(1), and it's current and cute and ready for you β now go convert something πβ¨π
π¦ where this page comes from
- nixpkgs unstable: brlcad 7.44.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms