NAME
jpg, gif, png, ppm, bmp, v210, yuv, ico, togif, toppm, topng,
toico – view and convert pictures |
SYNOPSIS
jpg [ –39cdefFkJrtv ] [ file ... ] gif [ –39cdektv ] [ file ... ] png [ –39cdektv ] [ file ... ] ppm [ –39cdektv ] [ file ... ] bmp [ file ] v210 [ –39cdektv ] [ file ... ] yuv [ file ]
togif [ –c comment ] [ –l loopcount ] [ –d msec ] [ –t transindex
] [ file ... [ –d msec ] file ... ]
ico [ file ] |
DESCRIPTION
These programs read, display, and write image files in public
formats. Jpg, gif, png, ppm, bmp, v210, and yuv read files in
the corresponding formats and, by default, display them in the
current window; options cause them instead to convert the images
to Plan 9 image format and write them to standard output.
Togif, Toppm, and topng read Plan 9 images files, convert them
to GIF, PPM, or PNG, and write them to standard output. The default behavior of jpg, gif, and ppm is to display the file, or standard input if no file is named. Once a file is displayed, typing a character causes the program to display the next image. Typing a q, DEL, or control–D exits the program. For a more user–friendly interface, use page(1), which invokes these programs to convert the images to standard format, displays them, and offers scrolling, panning, and menu–driven navigation among the files.
These programs share many options:
Jpg has two extra options used to process the output of the LML
video card:
The togif and toppm programs go the other way: they convert from
Plan 9 images to GIF and PPM, and have no display capability.
Both accept an option –c to set the comment field of the resulting
file. If there is only one input picture, togif converts the image
to GIF format. If there are many files, though, it will
assemble them into an animated GIF file. The options control this
process:
Ico displays a Windows icon (.ico) file. If no file is specified, ico reads from standard input. Icon files contain sets of icons represented by an image and a mask. Clicking the right button pops up a menu that lets you write any icon's image as a Plan 9 image (widthxheight.image), write any icon's mask as a Plan 9 image (widthxheight.mask), or exit. Selecting one of the write menu items yields a sight cursor. Move the sight over the icon and right click again to write.
Toico takes a list of Plan 9 image files (or standard input) and
creates a single icon file. The masks in the icon file will be
the white space in the image. The icon file is written to standard
output. |
SOURCE
/sys/src/cmd/jpg |
SEE ALSO
page(1), image(6). http://www.w3.org/Graphics/JPEG/itu–t81.pdf http://www.w3.org/Graphics/GIF/spec–gif89a.txt http://www.w3.org/TR/2003/REC–PNG–20031110 http://netpbm.sourceforge.net/doc/ppm.html http://en.wikipedia.org/wiki/Windows_bitmap http://en.wikipedia.org/wiki/Yuv |
BUGS
Writing an animated GIF using togif is a clumsy undertaking. |