%ì Librarian A09-19ÒBPúŠ™'Û—²Þ™=ˆˆ 15BGGENXV ­'Û—²Þ™1 BGGEN F Generates colored backgrounds on X11 displays. BGGEN is aF program that generates a width-pixel wide by size-pixels highF vertical stripe. The top of the stripe is in color (r1,g1,b1),F and the bottom of the stripe is in color (rn,gn,bn). IntermediateF colors are interpolated between these colors. If you specify moreF than 2 colors, the stripe passes through all the specified colors, in the order specified.iF The '-b' option specifies the number of significant bits inF the (output) color specifications. It must range between 1 and 8,F inclusive. Use values less than 8 (the default) to limit color, use by increasing the color granularity.F Values for 'r', 'g', and 'b' should range between 0 and 255,8 inclusive. 0 means 'off', and 255 means 'fully on'.F BGGEN doesn't actually affect your background directly. BGGENF merely generates a small PPM (Portable Pixma p Format) datafile! that XV can read and display.lF To use BGGEN , you should pipe its output into an XV command,& such as: "xv -root -quit -slow24"F The default 'size' is 1024 pixels, which should be as tall asF your display. If your display is taller than that, you shouldF specify its actual height, otherwise you will get a bizarreF repeating effect, that you probably didn't want. Note: If you@ specify small values of '-s', you can ge t some neat effects.F The '-w' argument has been added to improve the performance ofF various stippling algorithms (as in XV). More information to workF with, and such. Try using '-w 16' on these command lines to see what is meant. Execution format: , BGGEN [-w width] [-s size] [-b bits]. r1 g1 b1 [r2 g2 b2 ... rn gn bn] 2 Examples Light Blue to Dark Blue:9 BGGEN 100 100 255 50 50 150 | xv -ro -q -sl "-"r RGB Rainbow:;  BGGEN 0 0 255 0 255 0 255 0 0 | xv -ro -q -sl "-"  Green Cylinders:> BGGEN 0 0 0 0 255 0 0 0 0 -s 128 | xv -ro -q -sl "-" Blue to Magenta:4 BGGEN 0 0 255 200 0 100 | xv -ro -q -sl "-" Full Rainbow: > BGGEN 0 0 255 0 255 255 0 255 0 255 255 0 255 0 0  | xv -ro -q -sl "-"  Repeating Rainbow:: BGGEN 0 0 255 0 255 255 0 255 0 255 255 0 255 0 0 : 255 0 255 0 0 255 -s 256 | xv -ro -q -sl "-"2 BugsF It'd probably be nice if the program used some X calls toF determine screen size. It'd also probably be nice if the program? could take colors by 'name', and also by hexadecimal value.b2 Author. John Bradley - bradley@cis.upenn.eduww XV supports literally dozens of command line options and X11F resources. Fortunately, it is doubtful that you'll ever need toF use more than a small few. The rest are provided mainly for that, 'one special case' application XVBGGENº«!1y\ø#™ MCCARTHY XVBGGENº«!/¡d]û#™ MCCARTHY XVBGGENº«!íI"C$™ MCCARTHY XVBGGENº«!O!„2$™ MCCARTHY XVBGGENº«!gý¼Ú6$™ MCCARTHY XVBGGENº«!¿,ÀÙ­(™ MCCARTHY XVBGGENº«!¥ÛjÎÓ_™ MCCARTHY XVBGGENº«!7yÎAÜ_™ MCCARTHY XVBGGENº«!¯qMWæ_™ MCCARTHY XVBGGENº«!Ñ0é_™ MCCARTHY XVBGGENº«!‡xQOí_™ MCCARTHY XVBGGENº«! Âøku`™ MCCARTHY XVBGGENº«!–—Vƒ`™ MCCARTHY XVBGGENº«!Ñ þë`™­òó}&p™1 BGGEN F Generates colored backgrounds on X11 displays. BGGEN is aF program that generates a width-pixel wide by size-pixels highF vertical stripe. The top of the stripe is in color (r1,g1,b1),F and the bottom of the stripe is in color (rn,gn,bn). IntermediateF colors are interpolated between these colors. If you specify moreF than 2 colors, the stripe passes through all the specified colors, in the order specified.iF The '-b' option specifies the number of significant bits inF the (output) color specifications. It must range between 1 and 8,F inclusive. Use values less than 8 (the default) to limit color, use by increasing the color granularity.F Values for 'r', 'g', and 'b' should range between 0 and 255,8 inclusive. 0 means 'off', and 255 means 'fully on'.F BGGEN doesn't actually affect your background directly. BGGENF merely generates a small PPM (Portable Pixmap Format) datafile! that XV can read and display.lF To use BGGEN , you should pipe its output into an XV command,& such as: "xv -root -quit -slow24"F The default 'size' is 1024 pixels, which should be as tall asF your display. If your display is taller than that, you shouldF specify its actual height, otherwise you will get a bizarreF repeating effect, that you probably didn't want. Note: If you@ specify small values of '-s', you can get some neat effects.F The '-w' argument has been added to improve the performance ofF various stippling algorithms (as in XV). More information to workF with, and such. Try using '-w 16' on these command lines to see what is meant. Execution format: , BGGEN [-w width] [-s size] [-b bits]. r1 g1 b1 [r2 g2 b2 ... rn gn bn] 2 Examples Light Blue to Dark Blue:9 BGGEN 100 100 255 50 50 150 | xv -ro -q -sl "-"r RGB Rainbow:;  BGGEN 0 0 255 0 255 0 255 0 0 | xv -ro -q -sl "-"  Green Cylinders:> BGGEN 0 0 0 0 255 0 0 0 0 -s 128 | xv -ro -q -sl "-" Blue to Magenta:4 BGGEN 0 0 255 200 0 100 | xv -ro -q -sl "-" Full Rainbow: > BGGEN 0 0 255 0 255 255 0 255 0 255 255 0 255 0 0  | xv -ro -q -sl "-"  Repeating Rainbow:: BGGEN 0 0 255 0 255 255 0 255 0 255 255 0 255 0 0 : 255 0 255 0 0 255 -s 256 | xv -ro -q -sl "-"2 BugsF It'd MCCARTHY XVBGGENº«!²¢“`™ MCCARTHY XVBGGENº«!8eèž`™ MCCARTHY XVBGGENº«!ç=Cz¯`™ MCCARTHY XVBGGENº«!Däaa™ MCCARTHY XVBGGENº«!CŠA{šd™ MCCARTHY XVBGGENº«!j‡}&p™ MCCARTHY XVBGGENº«!Ä”›²Þ™ MCCARTHY XVBGGEN ­T6[²Þ™1 XVF An interactive image display for the X Window System. XV isF an X11 program that displays images in the GIF, PBM, PGM, PPM, X11F bitmap, JPEG, TIFF, Sun Rastefile, RLE, and PM formats on 1-, 4-,F 6-, 8-, 16-, 24-, and 32-bit X displays. xv will also read( compress-ed versions of these files.F NOTE: This man page is merely the text portion of theF (PostScript) XV docs, without the figures, and without theF appendicies. As such, it is highly recommended that you get your& hands on the *real* documentation.; ALSO NOTE: This file documents XV 2.21, *not* XV 3.00.n Execution Format:l2 xv [options] [filename [filename ...]] 2 OVERVIEWF XV lets you do a large number of things (many of them actually: useful), including, but not limited to, the following: 4 o display an image in a window on the screenE o display an image on the root windo w, in a variety of styles E o grab any rectangular portion of the screen and turn it intoe an image3 o arbitrarily stretch or compress the image. o rotate the image in 90--degree steps? o flip the image around the horizontal or vertical axes 1 o crop a rectangular portion of the imagecF o magnify any portion of the image by any amount, up to the size of the screenA o determine pixel values and x,y coordinates in the imag e F o adjust image brightness and contrast with a gamma correction functionF o apply different gamma functions to the Red, Green, and BlueD color components, to correct for non-linear color response( o adjust global image saturation& o perform global hue remapping" o edit an image's colormap1 o reduce the number of colors in an image ! o dither in color and b&w0 o smooth an image-. o crop off solid borders automatically o convert image formatso* o generate Encapsulated PostScriptF Unfortunately the Automatic Checkbook Balancing Module stillF isn't completely debugged, and is not included in this distribution. 2 Starting_XV5F NOTE: Unless explicitly stated otherwise, the term "click"- means "click with the Left mouse button."5F Start the program up by typing 'xv'. After a short delay, aF window will appear with the defaP probably be nice if the program used some X calls toF determine screen size. It'd also probably be nice if the program? could take colors by 'name', and also by hexadecimal value.b2 Author. John Bradley - bradley@cis.upenn.eduww XV supports literally dozens of command line options and X11F resources. Fortunately, it is doubtful that you'll ever need toF use more than a small few. The rest are provided mainly for that, 'one special case' application ult image (the XV logo, creditsF and revision date) displayed in it. If you change the size of theF window (using whatever method your window manager provides), the< image will be automatically stretched to fit the window. 2 OptionseF XV supports literally dozens of command line options and X11F resources. Fortunately, it is doubtful that you'll ever need toF use more than a small few. The rest are provided mainly for that, 'one special case' application  of XV ...F If you start XV with the command 'xv -help', the current list! of options will be displayed:o F xv [-] [-2xlimit] [-aspect w:h] [-best24] [-bg color] [-blackF color] [-browse] [-bw width] [-cecmap] [-cegeometry geom]F [-cemap] [-cgeometry geom] [-clear] [-cmap] [-cursor char#]F [-DEBUG level] [-display disp] [-dither] [-expand exp] [-fgF color] [-fixed] [-geometry geom] [-help] [-hi color] [-hsv]F [-igeome try geom] [-imap] [-keeparound] [-lo color]F [-loadclear] [-max] [-maxpect] [-mono] [-ncols #] [-nglobal]F [-ninstall] [-nolimits] [-nopos] [-noqcheck] [-noresetroot]F [-nostat] [-owncmap] [-perfect] [-quick24] [-quit] [-rbgF color] [-rfg color] [-rgb] [-rmode #] [-root] [-rv] [-rw]F [-slow24] [-smooth] [-visual type] [-wait seconds] [-white( color] [-wloop] [filename ...]3 General_Optionsl -helpF Print  usage instructions, listing the current availableF command-line options. Any unrecognized option will do this as well.h -display dispF Specifies the display that XV should attempt to connect to.F If you don't specify a display, XV will use the environment variable $DISPLAY.6 -fg color (Resource name: foreground string)6 Sets the foreground color used by the windows.8 -bg color (Resource name: backgroun d string)6 Sets the background color used by the windows.6 -hi color (Resource name: highlight string)F Sets the highlight color used for the top-left edges of the control buttons.4 -lo color (Resource name: lowlight string)F Sets the lowlight color used for the bottom-right edges of theA control buttons, and also the background of some windows.a9 -bw bwidth (Resource name: borderWidth integer) F Sets the width of the border on the windows. Your window3 manager may choose to ignore this, however.'3 Image_Sizing_Options7 -geometry geom (Resource name: geometry string)nF Lets you specify the size and placement of the 'image' window.F It's most useful when you only specify a position, and let XVF choose the size. If you specify a size as well, XV willF create a window of that size, unless -fixed is specified. TheF geom argument is in t !he form of a normal X geometry string? (e.g. ``300x240'' or ``+10+10'' or ``400x300+10+10'').a/ -fixed (Resource name: fixed boolean)F Only used in conjunction with the -geometry option. If youF specify a window size with the -geometry option, XV willF normally stretch the picture to exactly that size. This isF not always desirable, as it may seriously distort the aspectF ratio of the picture. Specifying the -fixed optio "n correctsF this behavior by instructing XV to use the specified geometryF size as a maximum window size. It will, however, preserve the- original aspect ratio of the picture.nF For example, if you give a rectangular geometry of '320x240',F and you try to display a square picture with a size ofF '256x256', the window opened will actually be '240x240', whichF is the largest square that still fits in the '320x240'% rect #angle that was specified. = -expand exp (Resource name: expand floating-point)oF Lets you specify an initial expansion or compression factorF for the picture. You can specify floating-point values.F Values larger than zero multiply the picture's dimensions byF the given factor. ( i.e., an expand factor of '3' will make a* 320x200 image display as 960x600).F Factors less than zero are treated as reciprocals. (i.e., anF $ expand factor of '-4' makes the picture 1/4th its normal5 size.). '0' is not a valid expansion factor.n5 -aspect w:h (Resource name: aspect string)F Lets you set an initial aspect ratio, and also sets the valueF used by the Aspect control. The aspect ratio of nearly everyF X display (and, in fact, any civilized graphics display) isF 1:1. What this means is that pixels appear to be 'square'. AF 100 pixel wide by 100 pixel hi%gh box will appear on the screenF as a square. Unfortunately, this is not the case with someF screens and digitizers. The -aspect option lets you stretchF the picture so that the picture appears correctly on yourF display. Unlike the other size-related options, this oneF doesn't care what the size of the overall picture is. ItF operates on a pixel-by-pixel basis, stretching each imageF pixel slightly, in either widt &h or height, depending on the ratio.F Aspect ratios greater than '1:1' (e.g., '4:3') make theF picture wider than normal. Aspect ratios less than '1:1'F (e.g. '2:3') make the picture taller than normal. (UsefulF aspect ratio: A 512x480 image that was supposed to fill aF standard 4x3 video screen (produced by many video digitizers): should be displayed with an aspect ratio of '5:4')3 Color_Allocation_Options2 ' -ncols nc (Resource name: ncols integer)F Sets the maximum number of colors that XV will use. Normally,F this is set to 'as many as it can get'. However, you can setF this to smaller values for interesting effect. Most notably,F if you set it to '0', it will display the picture by ditheringF with 'black' and 'white'. (The actual colors used can be set1 by the -black and -white options, below.)n2 -nglobal (Resource name: nglobal bool(ean)F Adjusts the way the program behaves when it is unable to getF all the colors it requested. Normally, it will search theF display's default colormap, and 'borrow' any colors it deemsF appropriate. These borrowed colors are, however, not owned byF XV, and as such, can changed without xv's permission, orF knowledge. If this happens, the displayed picture willF change, in a less-than-desirable direction. If you speci )fyF the -nglobal option, XV will not use 'global' colors. It willF only use colors that it successfully allocated, which makes it$ immune to any color changes.F It should be noted that 'use global colors' is the defaultF because color changes aren't generally a problem if you areF only using XV to display a picture for a short time. ColorF changes only really become a problem if you use XV to displayF a picture that you wil *l be keeping around for a while, whileF you go and do some other work (such as using XV to display aF background). In such cases you will want to specify -nglobal.F Note: using the -ncols or -root options automatically turn on -nglobal.o. -rw (Resource name: rwColor boolean)F Tells XV to use read/write color cells. Normally, XVF allocates colors read-only, which allows it to share colorsF with other programs. If y +ou use read/write color cells, noF other program can use the colors that XV is using, andF vice-versa. The only reason you'd do such a thing is thatF using read/write color cells allows the Apply function in the6 xv color editor window to operate much faster.3 -perfect (Resource name: perfect boolean),F Makes XV try 'extra hard' to get all the colors it wants. InF particular, when -perfect is specified, XV will allocate a ,ndF install its own colormap if (and only if) it was unable toF allocate all the desired colors. This option is not allowed- in conjunction with the -root option.3 -owncmap (Resource name: ownCmap boolean)mF Like '-perfect', only this option forces XV to always allocateF and install its own colormap, thereby leaving the default colormap untouched.n6 -cecmap (Resource name: ceditColorMap boolean)F Specifies whet -her xv installs the image's colormap in the xvF color editor window, as well as in the image's window. ByF default, the program does install the colormap in the colorF editor window, however this can occasionally make the colorF editor window unreadable. (This option only apples when theE '-perfect' or '-owncmap' options create their own colormaps.)e5 -ninstall (Resource name: ninstall boolean)F Prevents XV from 'installin.g' its own colormap, when theF -perfect or -owncmap options are in effect. Instead ofF installing the colormap, it will merely 'ask the windowF manager, nicely' to take care of it. This is the correct wayF to install a colormap (i.e., ask the WM to do it),F unfortunately, it doesn't actually seem to work in many windowF managers, so the default behavior is for XV to handleF installation itself. However, t /his has been seen to annoy oneF window manager (dxwm), so this option is provided if your WM= doesn't like programs installing their own colormaps.d3 24-bit_Conversion_OptionssF The following options only come into play if you are using XVF to display 24-bit RGB data (PPM files, color PM files, JPEG files,F and the output of bggen). They have no effect whatsoever on how9 GIF pictures or 8-bit greyscale images are displayed.s1 -quick24 (Resource n 0ame: quick24 boolean)vF Forces xv to use the 'quick' 24-bit to 8-bit conversionF algorithm. This algorithm dithers the picture using a fixedF set of colors that span the entire RGB colorspace. InF versions of xv prior to 2.10, this was the default algorithm. It no longer is.1 -slow24 (Resource name: slow24 boolean) F Specifies that the 'slow' 24-bit to 8-bit conversion algorithmF is to be used by the program. T 1his algorithm uses a versionF of Heckbert's median cut algorithm to pick the 'best' colorsF on a per-image basis, and dithers with those. This is the- current default conversion algorithm.eF Advantages: The -slow24 algorithm often produces better5 looking pictures than the -quick24 algorithm.fF Disadvantages: The -slow24 algorithm is about half the speedF of the -quick24 algorithm. Also, since the colors are chosenF 2on a per-image basis, it can't be used to display multipleF images simultaneously, as each image will almost certainlyF want a different set of 256 colors. The -quick24 algorithm,F however, uses the same exact colors for all images, so it canF display many images simultaneously, without running out of colors.r0 -best24 (Resource name: best24 boolean)F Forces xv to use the same algorithm used in the programF ppmq 3uant, written by Jef Poskanzer. This algorithm also usesF a version of Heckbert's median cut algorithm, but is capableF of picking 'better' colors than the -slow24 algorithm, and it doesn't dither.aF Advantages: Generally produces slightly better images thanF the -slow24 algorithm. Also, the images are undithered, so' they look better when expanded. F Disadvantages: Much slower than the -slow24 algorithm. Like,F 5 to 1 40 times slower. The images produced aren't that much< better than those produced by the -slow24 algorithm.5 -noqcheck (Resource name: noqcheck boolean)dF Turns off a 'quick check' that is normally made. Normally,F before running either of the 24-bit to 8-bit conversionF algorithms, XV determines whether the picture to be displayedF has more than 256 unique colors in it. If the pictureF doesn't, it will treat the pic 5ture as an 8-bit colormappedF image (i.e., GIF), and won't run either of the conversion algorithms.sF Advantages: The pictures will be displayed 'perfectly',F whereas if they went through either of the conversion' algorithms, they'd be dithered.iF Disadvantages: Often uses a lot of colors, which limits theF ability to view multiple images at once. (See the -slow24; option above for further info about co 6lor sharing.)i3 Root_Window_Options(F XV has the ability to display images on the root window of anF X display, rather than opening its own window (the defaultF behavior). When using the root window, the program is somewhatF limited, because the program cannot receive input events (keyF press and mouse clicks) from the root window. As a result, youF cannot track pixel values, or crop, nor can you use keyboard3 commands while the mouse is 7in the root window.'' -root (Resource name: ) F Directs XV to display images in the root window, instead ofF opening its own window. Exactly how the images will beF displayed in the root window is determined by the setting of the -rmode option.8 -rmode mode (Resource name: rootMode integer)F Determines how images are to be displayed on the root window,F when -root has been specified. You can find the curren 8t listF of 'modes' by using a mode value of '-1'. XV will complain,F and show a list of valid modes. The current list at of the time of this writing is: 0: tiling" 1: integer tiling# 2: mirrored tilingm+ 3: integer mirrored tilingd# 4: centered tiling 2 5: centered on a solid background3 6: centered on a 'warp' backgroundu4 7: center 9ed on a 'brick' backgroundF The default mode is '0'. See ``Section 3.5: The DisplayF Modes Menu'' for a description of the different display modes./ -noresetroot (Resource name: resetroot)eF Normally, when changing from root to window display mode, theF root is set to the standard X crosshatch pattern. UsingF -noresetroot or setting resetroot to false will force the rootF to remain. This is useful when comparing between dif:ferent tiled images.  < -rfg color (Resource name: rootForeground string)F Sets the 'foreground' color used in some of the root display modes.< -rbg color (Resource name: rootBackground string)F Sets the 'background' color used in some of the root display modes.% -max (Resource name: )F Makes XV automatically stretch the image to the full size ofF the screen. This is mostly useful when ;you want XV to displayF a background. While you could just as well specify theF dimensions of your display ('-geom 1152x900' for example), theF -max option is display-independent. If you suddenly decide toF start working on a 1280x1024 display (ferinstance) the sameF command will still work. Note: If you specify -max when youF aren't using -root, the behavior is slightly different. TheF image will be made as large as possible wh <ile still preserving the normal aspect ratio.) -maxpect (Resource name: ) F Makes the image as large as possible while preserving the aspect ratio.l& -quit (Resource name: )F Makes XV display the (first) specified file and exit, withoutF any user intervention. Since images displayed on the rootF window remain there until explicitly cleared, this is veryF useful for having XV display background = images on the rootF window in some sort of start-up script. Needless to say, this. is only useful if you are using -root.' -clear (Resource name: )oF Clears the root window of any extraneous XV images. Note: itF is not necessary to do an 'xv -clear' before displayingF another picture in the root window. XV will detect thatF there's an old image in the root window and automatically6 clear it out (and free t >he associated colors).3 Window_OptionsF XV currently consists of three main windows, plus one windowF for the actual image. These three windows (the xv controlsF window, the xv info window, and the xv color editor window) may be@ automatically mapped and positioned when the program starts.0 -cmap (Resource name: ctrlMap boolean)$ Maps the xv controls window.; -cgeom geom (Resource name: ctrlGeometry string)eF Sets the initial? geometry of the xv controls window. Note:F only the position information is used. The window is of fixed size.y0 -imap (Resource name: infoMap boolean) Maps the xv info window.9 -igeom geom (Resource name: infoGeomet string)pF Sets the initial geometry of the xv info window. Note: onlyF the position information is used. The window is of fixed size. 2 -cemap (Resource name: ceditMap boolean)( Ma @ps the xv color editor window.= -cegeom geom (Resource name: ceditGeometry string)nF Sets the initial geometry of the xv color editor window.F Note: only the position information is used. The window is of fixed size./ -nopos (Resource name: nopos boolean)oF Turns off the 'default' positioning of the various XV windows.F Every time you open a window, you will be asked to positionF it. (Assuming your window manager a Asks you such things. mwm,* for instance doesn't seem to ask.)3 Miscellaneous_Optionsw- -mono (Resource name: mono boolean)F Forces the image to be displayed as a greyscale. This is mostF useful when you are using certain greyscale X displays. WhileF XV attempts to determine if it's running on a greyscaleF display, many X displays lie, and claim to be able to doF color. (This is often because they have color graphics boards BF hooked up to b/w monitors. The computer, of course, has noF way of knowing what type of monitor is attached.) On theseF displays, if you don't specify -mono, what you will see is aF greyscale representation of one of the RGB outputs of theF system. (For example, you'll see the 'red' output on ourF greyscale Sun 3/60s.) The -mono option corrects this behavior.5 -white color (Resource name: white string) F Specif Cies the 'white' color used when the picture is b/w8 stippled. (When '-ncols 0' has been specified.)5 -black color (Resource name: black string)oF Specifies the 'black' color used when the picture is b/w8 stippled. (When '-ncols 0' has been specified.)F Try something like: 'xv -ncols 0 -bl red -wh yellowF ' for some interesting, late-'60s-style psychodelia effects., -wait secs (Resource name:D )F Turns on a 'slide-show' feature. Normally, if you specifyF multiple input files, XV will display the first one, and waitF for you to give the Next command (or whatever). The -waitF option makes XV wait the specified number of seconds, and thenF go on to the next picture, without any user intervention. TheF program still accepts commands, so it's possible to 'abort'F the current picture without waiting the full specified t Eime by using the Next command.o' -wloop (Resource name: )sF Normally, when running a slide-show with the -wait option, XVF will terminate after displaying the last image. If you alsoF specify the -wloop option, the program will loop back to theF first image and continue the slide-show until the user issues the Quit command. . -rgb (Resource name: hsvMode boolean)F Specifies that, by default, the colormap edit Fing dials in theF xv color editor window should be in RGB mode. This is the normal default behavior./ -hsv (Resource name: hsvMode boolean)tF Specifies that, by default, the colormap editing dials in the5 xv color editor window should be in HSV mode.h4 -dither (Resouce name: autoDither boolean)F When specified, tells XV to automatically issue a DitherF command whenever an image is first displayed. Useful onF G displays with limited color capabilities (4-bit and 6-bit displays.)6 -smooth (Resource name: autoSmooth boolean)F When specified, tells XV to automatically issue a SmoothF command whenever an image is first displayed. This is usefulF when you are using one of the image sizing options (such as '-expand' or '-max').o0 -crop (Resource name: autoCrop boolean)F When specified, tells xv to automatically issue H an AutoCrop5 command whenever an image is first displayed.  9 -visual vistype (Resource name: visual string)tF Normally, XV uses the default visual model provided by your XF server. You can override this by explicitly selecting aF visual to use. Valid types are StaticGray, StaticColor,F TrueColor, GrayScale, PseudoColor, and DirectColor. Not allF of these are necessarily provided on any given X display. RunF xd Ipyinfo on your display to find out what visual types are supported.7 -cursor curs (Resource name: cursor integer)eF Specifies an alternate cursor to use in the image windowF (instead of the normal 'cross' cursor). curs values areF obtained by finding the character number of a cursor you likeF in the 'cursor' font. (Run 'xfd -fn cursor' to display theF cursor font.) For example, a curs value of '56' corresponds to0 J the (singularly useless) 'Gumby' cursor.9 -keeparound (Resource name: keepAround boolean)F By default if you Delete the last file in the XV controlsF list, the program will automatically exit, as a convenience.* If you find this an inconvenience.3 -2xlimit (Resource name: 2xlimit boolean)MF By default, XV prevents the image window from ever gettingF larger than the screen. Unfortunately, because of this, ifF yo Ku load an image that is larger than your screen, the imageF will be shrunk until it fits on your screen. Some folks findF this undesirable behavior. Specifying the -2xlimit optionF doubles the size limitations. The image window will be keptF from getting larger than 2x the width and height of your screen.fF Just in case you're wondering why there's any sizeF limitations: it's fairly easy to accidentally ask for a L hugeF image to be generated. Simply crop a section of the image,F zoom so you can see the individual pixels, and uncrop. IfF there were no size limitations, the (expanded many times)F image could be huge, and might crash your X server. At theF very least, it would take a long period of time, and freezeF your X server during part of it. Generally undesirable behavior.i4 -nolimits (Resource name: nolimites Mboolean)F For the truly daring, this turns off all limitations on theF maximum size of an image window. (Well, there's still anF X-imposed maximum size of 64k by 64k, but that reallyF shouldn't be a problem.) Warning: as mentioned above, it isF fairly easy to accidentally generate a huge image when you doF an UnCrop command, and you may well crash xv, your X server,@ the host machine, or all three. Use At Your Own Risk!!! N% -rv (Resource name: reverse),F Makes xv display a 'negative' of the loaded image. WhiteF becomes black, and black becomes white. Color images willF have 'interesting' effects, as the RGB components areF individually reversed. For example, red (255,0,0) will become= cyan (0,255,255), yellow will become blue, and so on.n/ -DEBUG level (Resource name: ) F Turns on some debugging information. You shouldn' Ot need this.F If everything worked perfectly, I wouldn't need this either.F Specifying '-' all by itself tells XV to take its input fromF stdin, rather then from a file. This lets you put XV on the end of a Un*x pipe.e 2 LimitationsuF XV will NOT work on displays that aren't 1-, 4-, 6-, 8-, 16-F 24-, or 32-bits deep. Luckily, that should still cover nearlyF every display out there. It may not work on certain 6- or 24-bit displays†. F It also only displays the first image in GIF files that have multiple images in them.E As for PM pictures, this program only displays 1-plane PM_I 2 pictures, or 1-, 3-, or 4-plane PM_C pictures. 2 Authorsa. John Bradley - bradley@cis.upenn.eduF GIF reading code based on gif2ras.c, by Patrick J. Naughton (naughton@wind.sun.com)oF GIF writing code essentially unchanged from code written by% Michael Maudlin (mlm@cs.cmu.Q of XV ...F If you start XV with the command 'xv -help', the current list! of options will be displayed: F xv [-] [-2xlimit] [-aspect w:h] [-best24] [-bg color] [-blackF color] [-browse] [-bw width] [-cecmap] [-cegeometry geom]F [-cemap] [-cgeometry geom] [-clear] [-cmap] [-cursor char#]F [-DEBUG level] [-display disp] [-dither] [-expand exp] [-fgF color] [-fixed] [-geometry geom] [-help] [-hi color] [-hsv]F [-igeomeRtry geom] [-imap] [-keeparound] [-lo color]F [-loadclear] [-max] [-maxpect] [-mono] [-ncols #] [-nglobal]F [-ninstall] [-nolimits] [-nopos] [-noqcheck] [-noresetroot]F [-nostat] [-owncmap] [-perfect] [-quick24] [-quit] [-rbgF color] [-rfg color] [-rgb] [-rmode #] [-root] [-rv] [-rw]F [-slow24] [-smooth] [-visual type] [-wait seconds] [-white( color] [-wloop] [filename ...]3 General_Options -helpF Print S usage instructions, listing the current availableF command-line options. Any unrecognized option will do this as well. -display dispF Specifies the display that XV should attempt to connect to.F If you don't specify a display, XV will use the environment variable $DISPLAY.6 -fg color (Resource name: foreground string)6 Sets the foreground color used by the windows.8 -bg color (Resource name: backgrounTd string)6 Sets the background color used by the windows.6 -hi color (Resource name: highlight string)F Sets the highlight color used for the top-left edges of the control buttons.4 -lo color (Resource name: lowlight string)F Sets the lowlight color used for the bottom-right edges of theA control buttons, and also the background of some windows.9 -bw bwidth (Resource name: borderWidth integer)F Sets the widthU of the border on the windows. Your window3 manager may choose to ignore this, however.3 Image_Sizing_Options7 -geometry geom (Resource name: geometry string)F Lets you specify the size and placement of the 'image' window.F It's most useful when you only specify a position, and let XVF choose the size. If you specify a size as well, XV willF create a window of that size, unless -fixed is specified. TheF geom argument is in tVhe form of a normal X geometry string? (e.g. ``300x240'' or ``+10+10'' or ``400x300+10+10'')./ -fixed (Resource name: fixed boolean)F Only used in conjunction with the -geometry option. If youF specify a window size with the -geometry option, XV willF normally stretch the picture to exactly that size. This isF not always desirable, as it may seriously distort the aspectF ratio of the picture. Specifying the -fixed optioWn correctsF this behavior by instructing XV to use the specified geometryF size as a maximum window size. It will, however, preserve the- original aspect ratio of the picture.F For example, if you give a rectangular geometry of '320x240',F and you try to display a square picture with a size ofF '256x256', the window opened will actually be '240x240', whichF is the largest square that still fits in the '320x240'% rectXangle that was specified.= -expand exp (Resource name: expand floating-point)F Lets you specify an initial expansion or compression factorF for the picture. You can specify floating-point values.F Values larger than zero multiply the picture's dimensions byF the given factor. ( i.e., an expand factor of '3' will make a* 320x200 image display as 960x600).F Factors less than zero are treated as reciprocals. (i.e., anF Y expand factor of '-4' makes the picture 1/4th its normal5 size.). '0' is not a valid expansion factor.5 -aspect w:h (Resource name: aspect string)F Lets you set an initial aspect ratio, and also sets the valueF used by the Aspect control. The aspect ratio of nearly everyF X display (and, in fact, any civilized graphics display) isF 1:1. What this means is that pixels appear to be 'square'. AF 100 pixel wide by 100 pixel hiZgh box will appear on the screenF as a square. Unfortunately, this is not the case with someF screens and digitizers. The -aspect option lets you stretchF the picture so that the picture appears correctly on yourF display. Unlike the other size-related options, this oneF doesn't care what the size of the overall picture is. ItF operates on a pixel-by-pixel basis, stretching each imageF pixel slightly, in either widt[h or height, depending on the ratio.F Aspect ratios greater than '1:1' (e.g., '4:3') make theF picture wider than normal. Aspect ratios less than '1:1'F (e.g. '2:3') make the picture taller than normal. (UsefulF aspect ratio: A 512x480 image that was supposed to fill aF standard 4x3 video screen (produced by many video digitizers): should be displayed with an aspect ratio of '5:4')3 Color_Allocation_Options2 \ -ncols nc (Resource name: ncols integer)F Sets the maximum number of colors that XV will use. Normally,F this is set to 'as many as it can get'. However, you can setF this to smaller values for interesting effect. Most notably,F if you set it to '0', it will display the picture by ditheringF with 'black' and 'white'. (The actual colors used can be set1 by the -black and -white options, below.)2 -nglobal (Resource name: nglobal bool]ean)F Adjusts the way the program behaves when it is unable to getF all the colors it requested. Normally, it will search theF display's default colormap, and 'borrow' any colors it deemsF appropriate. These borrowed colors are, however, not owned byF XV, and as such, can changed without xv's permission, orF knowledge. If this happens, the displayed picture willF change, in a less-than-desirable direction. If you speci^fyF the -nglobal option, XV will not use 'global' colors. It willF only use colors that it successfully allocated, which makes it$ immune to any color changes.F It should be noted that 'use global colors' is the defaultF because color changes aren't generally a problem if you areF only using XV to display a picture for a short time. ColorF changes only really become a problem if you use XV to displayF a picture that you wil_l be keeping around for a while, whileF you go and do some other work (such as using XV to display aF background). In such cases you will want to specify -nglobal.F Note: using the -ncols or -root options automatically turn on -nglobal.. -rw (Resource name: rwColor boolean)F Tells XV to use read/write color cells. Normally, XVF allocates colors read-only, which allows it to share colorsF with other programs. If y`ou use read/write color cells, noF other program can use the colors that XV is using, andF vice-versa. The only reason you'd do such a thing is thatF using read/write color cells allows the Apply function in the6 xv color editor window to operate much faster.3 -perfect (Resource name: perfect boolean)F Makes XV try 'extra hard' to get all the colors it wants. InF particular, when -perfect is specified, XV will allocate aandF install its own colormap if (and only if) it was unable toF allocate all the desired colors. This option is not allowed- in conjunction with the -root option.3 -owncmap (Resource name: ownCmap boolean)F Like '-perfect', only this option forces XV to always allocateF and install its own colormap, thereby leaving the default colormap untouched.6 -cecmap (Resource name: ceditColorMap boolean)F Specifies whetbher xv installs the image's colormap in the xvF color editor window, as well as in the image's window. ByF default, the program does install the colormap in the colorF editor window, however this can occasionally make the colorF editor window unreadable. (This option only apples when theE '-perfect' or '-owncmap' options create their own colormaps.)5 -ninstall (Resource name: ninstall boolean)F Prevents XV from 'installincg' its own colormap, when theF -perfect or -owncmap options are in effect. Instead ofF installing the colormap, it will merely 'ask the windowF manager, nicely' to take care of it. This is the correct wayF to install a colormap (i.e., ask the WM to do it),F unfortunately, it doesn't actually seem to work in many windowF managers, so the default behavior is for XV to handleF installation itself. However, tdhis has been seen to annoy oneF window manager (dxwm), so this option is provided if your WM= doesn't like programs installing their own colormaps.3 24-bit_Conversion_OptionsF The following options only come into play if you are using XVF to display 24-bit RGB data (PPM files, color PM files, JPEG files,F and the output of bggen). They have no effect whatsoever on how9 GIF pictures or 8-bit greyscale images are displayed.1 -quick24 (Resource neame: quick24 boolean)F Forces xv to use the 'quick' 24-bit to 8-bit conversionF algorithm. This algorithm dithers the picture using a fixedF set of colors that span the entire RGB colorspace. InF versions of xv prior to 2.10, this was the default algorithm. It no longer is.1 -slow24 (Resource name: slow24 boolean)F Specifies that the 'slow' 24-bit to 8-bit conversion algorithmF is to be used by the program. Tfhis algorithm uses a versionF of Heckbert's median cut algorithm to pick the 'best' colorsF on a per-image basis, and dithers with those. This is the- current default conversion algorithm.F Advantages: The -slow24 algorithm often produces better5 looking pictures than the -quick24 algorithm.F Disadvantages: The -slow24 algorithm is about half the speedF of the -quick24 algorithm. Also, since the colors are chosenF gon a per-image basis, it can't be used to display multipleF images simultaneously, as each image will almost certainlyF want a different set of 256 colors. The -quick24 algorithm,F however, uses the same exact colors for all images, so it canF display many images simultaneously, without running out of colors.0 -best24 (Resource name: best24 boolean)F Forces xv to use the same algorithm used in the programF ppmqhuant, written by Jef Poskanzer. This algorithm also usesF a version of Heckbert's median cut algorithm, but is capableF of picking 'better' colors than the -slow24 algorithm, and it doesn't dither.F Advantages: Generally produces slightly better images thanF the -slow24 algorithm. Also, the images are undithered, so' they look better when expanded.F Disadvantages: Much slower than the -slow24 algorithm. Like,F 5 to 1i0 times slower. The images produced aren't that much< better than those produced by the -slow24 algorithm.5 -noqcheck (Resource name: noqcheck boolean)F Turns off a 'quick check' that is normally made. Normally,F before running either of the 24-bit to 8-bit conversionF algorithms, XV determines whether the picture to be displayedF has more than 256 unique colors in it. If the pictureF doesn't, it will treat the picjture as an 8-bit colormappedF image (i.e., GIF), and won't run either of the conversion algorithms.F Advantages: The pictures will be displayed 'perfectly',F whereas if they went through either of the conversion' algorithms, they'd be dithered.F Disadvantages: Often uses a lot of colors, which limits theF ability to view multiple images at once. (See the -slow24; option above for further info about coklor sharing.)3 Root_Window_OptionsF XV has the ability to display images on the root window of anF X display, rather than opening its own window (the defaultF behavior). When using the root window, the program is somewhatF limited, because the program cannot receive input events (keyF press and mouse clicks) from the root window. As a result, youF cannot track pixel values, or crop, nor can you use keyboard3 commands while the mouse is lin the root window.' -root (Resource name: )F Directs XV to display images in the root window, instead ofF opening its own window. Exactly how the images will beF displayed in the root window is determined by the setting of the -rmode option.8 -rmode mode (Resource name: rootMode integer)F Determines how images are to be displayed on the root window,F when -root has been specified. You can find the currenmt listF of 'modes' by using a mode value of '-1'. XV will complain,F and show a list of valid modes. The current list at of the time of this writing is: 0: tiling" 1: integer tiling# 2: mirrored tiling+ 3: integer mirrored tiling# 4: centered tiling2 5: centered on a solid background3 6: centered on a 'warp' background4 7: centerned on a 'brick' backgroundF The default mode is '0'. See ``Section 3.5: The DisplayF Modes Menu'' for a description of the different display modes./ -noresetroot (Resource name: resetroot)F Normally, when changing from root to window display mode, theF root is set to the standard X crosshatch pattern. UsingF -noresetroot or setting resetroot to false will force the rootF to remain. This is useful when comparing between difoferent tiled images. < -rfg color (Resource name: rootForeground string)F Sets the 'foreground' color used in some of the root display modes.< -rbg color (Resource name: rootBackground string)F Sets the 'background' color used in some of the root display modes.% -max (Resource name: )F Makes XV automatically stretch the image to the full size ofF the screen. This is mostly useful when pyou want XV to displayF a background. While you could just as well specify theF dimensions of your display ('-geom 1152x900' for example), theF -max option is display-independent. If you suddenly decide toF start working on a 1280x1024 display (ferinstance) the sameF command will still work. Note: If you specify -max when youF aren't using -root, the behavior is slightly different. TheF image will be made as large as possible whqile still preserving the normal aspect ratio.) -maxpect (Resource name: )F Makes the image as large as possible while preserving the aspect ratio.& -quit (Resource name: )F Makes XV display the (first) specified file and exit, withoutF any user intervention. Since images displayed on the rootF window remain there until explicitly cleared, this is veryF useful for having XV display background r images on the rootF window in some sort of start-up script. Needless to say, this. is only useful if you are using -root.' -clear (Resource name: )F Clears the root window of any extraneous XV images. Note: itF is not necessary to do an 'xv -clear' before displayingF another picture in the root window. XV will detect thatF there's an old image in the root window and automatically6 clear it out (and free tshe associated colors).3 Window_OptionsF XV currently consists of three main windows, plus one windowF for the actual image. These three windows (the xv controlsF window, the xv info window, and the xv color editor window) may be@ automatically mapped and positioned when the program starts.0 -cmap (Resource name: ctrlMap boolean)$ Maps the xv controls window.; -cgeom geom (Resource name: ctrlGeometry string)F Sets the initialt geometry of the xv controls window. Note:F only the position information is used. The window is of fixed size.0 -imap (Resource name: infoMap boolean) Maps the xv info window.9 -igeom geom (Resource name: infoGeomet string)F Sets the initial geometry of the xv info window. Note: onlyF the position information is used. The window is of fixed size.2 -cemap (Resource name: ceditMap boolean)( Maups the xv color editor window.= -cegeom geom (Resource name: ceditGeometry string)F Sets the initial geometry of the xv color editor window.F Note: only the position information is used. The window is of fixed size./ -nopos (Resource name: nopos boolean)F Turns off the 'default' positioning of the various XV windows.F Every time you open a window, you will be asked to positionF it. (Assuming your window manager avsks you such things. mwm,* for instance doesn't seem to ask.)3 Miscellaneous_Options- -mono (Resource name: mono boolean)F Forces the image to be displayed as a greyscale. This is mostF useful when you are using certain greyscale X displays. WhileF XV attempts to determine if it's running on a greyscaleF display, many X displays lie, and claim to be able to doF color. (This is often because they have color graphics boardswF hooked up to b/w monitors. The computer, of course, has noF way of knowing what type of monitor is attached.) On theseF displays, if you don't specify -mono, what you will see is aF greyscale representation of one of the RGB outputs of theF system. (For example, you'll see the 'red' output on ourF greyscale Sun 3/60s.) The -mono option corrects this behavior.5 -white color (Resource name: white string)F Specifxies the 'white' color used when the picture is b/w8 stippled. (When '-ncols 0' has been specified.)5 -black color (Resource name: black string)F Specifies the 'black' color used when the picture is b/w8 stippled. (When '-ncols 0' has been specified.)F Try something like: 'xv -ncols 0 -bl red -wh yellowF ' for some interesting, late-'60s-style psychodelia effects., -wait secs (Resource name:y )F Turns on a 'slide-show' feature. Normally, if you specifyF multiple input files, XV will display the first one, and waitF for you to give the Next command (or whatever). The -waitF option makes XV wait the specified number of seconds, and thenF go on to the next picture, without any user intervention. TheF program still accepts commands, so it's possible to 'abort'F the current picture without waiting the full specified tzime by using the Next command.' -wloop (Resource name: )F Normally, when running a slide-show with the -wait option, XVF will terminate after displaying the last image. If you alsoF specify the -wloop option, the program will loop back to theF first image and continue the slide-show until the user issues the Quit command.. -rgb (Resource name: hsvMode boolean)F Specifies that, by default, the colormap edit{ing dials in theF xv color editor window should be in RGB mode. This is the normal default behavior./ -hsv (Resource name: hsvMode boolean)F Specifies that, by default, the colormap editing dials in the5 xv color editor window should be in HSV mode.4 -dither (Resouce name: autoDither boolean)F When specified, tells XV to automatically issue a DitherF command whenever an image is first displayed. Useful onF | displays with limited color capabilities (4-bit and 6-bit displays.)6 -smooth (Resource name: autoSmooth boolean)F When specified, tells XV to automatically issue a SmoothF command whenever an image is first displayed. This is usefulF when you are using one of the image sizing options (such as '-expand' or '-max').0 -crop (Resource name: autoCrop boolean)F When specified, tells xv to automatically issue} an AutoCrop5 command whenever an image is first displayed. 9 -visual vistype (Resource name: visual string)F Normally, XV uses the default visual model provided by your XF server. You can override this by explicitly selecting aF visual to use. Valid types are StaticGray, StaticColor,F TrueColor, GrayScale, PseudoColor, and DirectColor. Not allF of these are necessarily provided on any given X display. RunF xd~pyinfo on your display to find out what visual types are supported.7 -cursor curs (Resource name: cursor integer)F Specifies an alternate cursor to use in the image windowF (instead of the normal 'cross' cursor). curs values areF obtained by finding the character number of a cursor you likeF in the 'cursor' font. (Run 'xfd -fn cursor' to display theF cursor font.) For example, a curs value of '56' corresponds to0  the (singularly useless) 'Gumby' cursor.9 -keeparound (Resource name: keepAround boolean)F By default if you Delete the last file in the XV controlsF list, the program will automatically exit, as a convenience.* If you find this an inconvenience.3 -2xlimit (Resource name: 2xlimit boolean)F By default, XV prevents the image window from ever gettingF larger than the screen. Unfortunately, because of this, ifF yo€u load an image that is larger than your screen, the imageF will be shrunk until it fits on your screen. Some folks findF this undesirable behavior. Specifying the -2xlimit optionF doubles the size limitations. The image window will be keptF from getting larger than 2x the width and height of your screen.F Just in case you're wondering why there's any sizeF limitations: it's fairly easy to accidentally ask for a hugeF image to be generated. Simply crop a section of the image,F zoom so you can see the individual pixels, and uncrop. IfF there were no size limitations, the (expanded many times)F image could be huge, and might crash your X server. At theF very least, it would take a long period of time, and freezeF your X server during part of it. Generally undesirable behavior.4 -nolimits (Resource name: nolimites ‚boolean)F For the truly daring, this turns off all limitations on theF maximum size of an image window. (Well, there's still anF X-imposed maximum size of 64k by 64k, but that reallyF shouldn't be a problem.) Warning: as mentioned above, it isF fairly easy to accidentally generate a huge image when you doF an UnCrop command, and you may well crash xv, your X server,@ the host machine, or all three. Use At Your Own Risk!!!ƒ% -rv (Resource name: reverse)F Makes xv display a 'negative' of the loaded image. WhiteF becomes black, and black becomes white. Color images willF have 'interesting' effects, as the RGB components areF individually reversed. For example, red (255,0,0) will become= cyan (0,255,255), yellow will become blue, and so on./ -DEBUG level (Resource name: )F Turns on some debugging information. You shouldn'„t need this.F If everything worked perfectly, I wouldn't need this either.F Specifying '-' all by itself tells XV to take its input fromF stdin, rather then from a file. This lets you put XV on the end of a Un*x pipe. 2 LimitationsF XV will NOT work on displays that aren't 1-, 4-, 6-, 8-, 16-F 24-, or 32-bits deep. Luckily, that should still cover nearlyF every display out there. It may not work on certain 6- or 24-bit displays….F It also only displays the first image in GIF files that have multiple images in them.E As for PM pictures, this program only displays 1-plane PM_I2 pictures, or 1-, 3-, or 4-plane PM_C pictures. 2 Authors. John Bradley - bradley@cis.upenn.eduF GIF reading code based on gif2ras.c, by Patrick J. Naughton (naughton@wind.sun.com)F GIF writing code essentially unchanged from code written by% Michael Maudlin (mlm@cs.cmu.‡edu).H SUN Rasterfile i/o code written by Dave Heath (heath@cs.jhu.edu)2 JPEG interface code written by Markus Baur" (s_baur@iravcl.ira.uka.de)= JPEG i/o code provided by the Independent JPEG Group.B VMS port by David Jones (jonesd@kcgl1.eng.ohio-state.edu),8 and Rick Dyson (Dyson@IowaSP.Physics.UIowa.EDU).ww­Ñ¡™1 BGGENF Generates colored backgrounds on X11 displays. BGGEN is aF program that generates edu).H SUN Rasterfile i/o code written by Dave Heath (heath@cs.jhu.edu)2 JPEG interface code written by Markus Baur" (s_baur@iravcl.ira.uka.de)= JPEG i/o code provided by the Independent JPEG Group. B VMS port by David Jones (jonesd@kcgl1.eng.ohio-state.edu),8 and Rick Dyson (Dyson@IowaSP.Physics.UIowa.EDU).ww (naughton@wind.sun.com)GF GIF writing code essentially unchanged from code written by% Michael Maudlin (mlm@cs.cmu.edu).H SUN Rasterfile i/o code written by Dave Heath (heath@cs.jhu.edu)2 JPEG interface code written by Markus Baur" (s_baur@iravcl.ira.uka.de)= JPEG i/o code provided by the Independent JPEG Group.B VMS port by David Jones (jonesd@kcgl1.eng.ohio-state.edu),8 and Rick Dyson (Dyson@IowaSP.Physics.UIowa.EDU).ww­µ¢“`™1 BGGENF Generates colored backgrounds on X11 displays. BGGEN is aF program that generates