Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Contact Us
Online Help
Domain Status
Man Pages

Virtual Servers

Topology Map

Server Agreement
Year 2038

USA Flag



Man Pages

Manual Reference Pages  -  FBSTRETCH (1)

.ds Aq ’


fbstretch - stretch a frame buffer image



fbstretch [-h] [-f input image name] [-s input square size] [-w input width]
  [-n input height] [-a] [-x horizontal scale factor] [-y vertical scale factor]
[-v] [-S output square size] [-W output width] [-N output height]
[[-F ] output frame buffer name]


¬ fbstretch expands or compresses a frame buffer image, in either or both the horizontal and vertical directions. The image scaling origin (fixed point) is the lower left-hand corner of the display. When expanding (scale factor greater than 1), pixels are simply replicated; when compressing (scale factor less than 1), pixel averaging is performed unless sampling is explicitly requested by the ¬ -a option.


¬ -h

(‚Äúhigh resolution‚ÄĚ)Assumes 1024 by 1024 pixels for default input image size instead of 512 by 512. Explicitly specified sizes override the default, and if actual input image size is smaller than requested, the actual size will be used. If not specified, requested output frame buffer size will be the stretched revised input size. If there are margins within the requested output beyond the stretched image, they will be cleared to background; if the stretched image would extend beyond the requested output size, it will be clipped to fit, even if there is room for it in the actual frame buffer. Actual sizes depend on details of specific frame buffers.

-f input image name

Inputs the image to be displayed from the specified frame buffer or pix(5) file, instead of modifying the output frame buffer in place. This option may not work if input and output frame buffers are the same device.

-s input square size

Specifies input image width and height.

-w input width

Specifies input image width.

-n input height

Specifies input image height.

¬ -a

(‚Äúno averaging‚ÄĚ)Specifies that output pixels will be sampled from the input, instead of being computed by averaging RGB values.

¬ -v

(‚Äúverbose‚ÄĚ)Causes actual sizes and scale factors used to be printed on the standard error output.

-x horizontal scale factor

Scales the image by the specified factor in the horizontal direction; the default is the ratio of requested output to input widths, if specified, otherwise 1.

-y vertical scale factor

Scales the image by the specified factor in the vertical direction; the default is the ratio of requested output to input heights, if specified, otherwise 1.

-S output square size

Specifies output frame buffer width and height.

-W output width

Specifies output frame buffer width.

-N output height

Specifies output frame buffer height.

-F output frame buffer name

Outputs to the specified frame buffer instead of the one specified by the ¬ FB_FILE environment variable (or the default, if ¬ FB_FILE is not set). If this is the last option specified, the ¬ -F is optional.


Pixel averaging may be meaningless for some images or color maps, in which case sampling should be specified. Images of the Mandelbrot set (see mandel(1)) are a good example of this.


The following procedure enlarges an image, obtained from a personal computer via the ¬ gif-fb utility, to fill a 1280-by-1024 frame buffer.

$ ‚ÄČgif-fb ‚ÄČimage.gif # displays the 320x200 PC image

$ ‚ÄČfbstretch ‚ÄČ-w 320 ‚ÄČ-n 200 ‚ÄČ-W 1280 ‚ÄČ-N 1024


gif-fb(1), mandel(1), pixscale(1), libfb(3), pix(5).


Error messages are intended to be self-explanatory.


Douglas A. Gwyn, BRL/VLD-VMB


This software is Copyright (c) 1989-2013 by the United States Government as represented by U.S. Army Research Laboratory.


Reports of bugs or problems should be submitted via electronic mail to <>.

Search for    or go to Top of page |  Section 1 |  Main Index

BRL-CAD FBSTRETCH (1) 04/04/2016

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.