externalize-image gp image &key maximum-colors important-colors type quality &allow-other-keys => external-image
A CAPI pane.
An image.
An integer or nil
. The default is nil
.
An integer or nil
One of the keywords :bmp
, :jpg
, :jpeg
, :png
and :tiff
. Other keywords may be supported, depending on the platform.
An integer in the range [0,100].
The function externalize-image
returns an external-image containing color information from
image
.
If
maximum-colors
is nil
or if the screen has no palette, an external-image using all the colors in
image
is created.
If maximum-colors is an integer, the external-image containing image will be created using no more than that number of colors. If the image contains more than maximum-colors colors, the maximum-colors most frequently used colors will be accurately stored; the remainder will be approximated by nearest colors out of the accurate ones, using internal Color System parameters as the weighting factors for the color distance.
The value of important-color is recorded in the external-image for later use, and specifies the number of colors required to draw a good likeness of the image. The default value is the number of colors in the image.
If
type
is supplied, it must be a keyword which specifies a known type, as returned by list-known-image-formats with
for-writing-too
t
. The types :bmp
, :jpg
, :png
and :tiff
are known on all platforms (except Motif). Additionally, :jpeg
is an as alias for :jpg
.
quality is used for writing a JPG image on GTK+. It must be an integer in the inclusive range [0,100]. High values generate better images and larger files.
CAPI User Guide and Reference Manual (Unix version) - 3 Aug 2017