github.com/kaydxh/golang@v0.0.131/pkg/gocv/cgo/third_path/graphics-magick/share/man/man4/miff.4 (about)

     1  .ad l
     2  .nh
     3  .TH MIFF 4 "$Date$" "ImageMagick"
     4  .SH NAME
     5  MIFF - Magick Image File Format
     6  .SH SYNOPSIS
     7  .B #include <image.h>
     8  .SH DESCRIPTION
     9  The Magick Image File Format (MIFF) is a platform-independent format for
    10  storing bitmap images.  MIFF is a part of the ImageMagick toolkit of
    11  image manipulation utilities for the X Window System.  ImageMagick is
    12  capable of converting many different image file formats to and from MIFF
    13  (e.g. JPEG, XPM, TIFF, etc.).
    14  
    15  A MIFF image file consist of two sections.  The first section is a
    16  header composed of keys describing the image in text form.  The
    17  next section is the binary image data.  The header is separated from
    18  the image data by a \fB:\fP character immediately followed by a
    19  \fBnewline\fP.
    20  
    21  The MIFF header is composed entirely of LATIN-1 characters.  The fields
    22  in the header are key and value combination in the
    23  \fIkey=value\fP format, with each key and value separated by an
    24  equal sign (=).  Each \fIkey=value\fP combination is delimited by
    25  at least one control or whitespace character.  Comments may appear in
    26  the header section and are always delimited by braces.  The MIFF header
    27  always ends with a colon (:) character, followed by a \fBctrl-Z\fP
    28  character.  It is also common to proceed the colon with a \fBformfeed\fP
    29  and a \fBnewline\fP character.  The \fBformfeed\fP prevents the listing
    30  of binary data when using \fBmore(1)\fP under Unix where the \fBctrl-Z\fP
    31  has the same effect with the \fBtype\fP command on the Win32 command line.
    32  
    33  The following is a list of \fIkey=value\fP combinations that may be
    34  found in a MIFF file:
    35  .TP
    36  .B "background-color=\fIcolor\fP"
    37  .B "border-color=\fIcolor\fP"
    38  .B "matte-color=\fIcolor\fP"
    39  these optional keys reflects the image background, border, and matte
    40  colors respectively. A color can be a name (e.g. white) or a
    41  hex value (e.g. #ccc).
    42  .TP
    43  .B "class=\fIDirectClass\fP"
    44  .B "class=\fBPseudoClass\fP"
    45  the type of binary image data stored in the MIFF file.  If
    46  this key is not present, \fBDirectClass\fP image data is assumed.
    47  .TP
    48  .B "colors=\fIvalue\fP"
    49  the number of colors in a \fBDirectClass\fP image. For a
    50  \fBPseudoClass\fP image, this key specifies the size of the
    51  colormap.  If this key is not present in the header, and the image
    52  is \fBPseudoClass\fP, a linear 256 color grayscale colormap is used
    53  with the image data.  The maximum number of colormap entries is 65535. 
    54  .B "colorspace=\fBCMYK\fP"
    55  the colorspace of the pixel data.  The default is RGB.
    56  .TP
    57  .B "columns=\fIvalue\fP"
    58  the width of the image in pixels.  This is a required key and
    59  has no default.
    60  .TP
    61  .B "compression=\fBBZip\fP"
    62  .B "compression=\fBFax\fP"
    63  .B "compression=\fBJPEG\fP"
    64  .B "compression=\fBLZW\fP"
    65  .B "compression=\fBRLE\fP"
    66  .B "compression=\fBZip\fP"
    67  the type of algorithm used to compress the image data.  If this
    68  key is not present, the image data is assumed to be uncompressed.
    69  .TP
    70  .B "delay \fI<1/100ths of a second>\fP"
    71  the interframe delay in an image sequence.  The maximum delay is 65535.
    72  .TP
    73  .B "depth=\fB8\fP"
    74  .B "depth=\fB16\fP"
    75  the depth of a single color value representing values from 0 to 255
    76  (depth 8) or 65535 (depth 16).  If this key is absent, a depth of 8 is
    77  assumed.
    78  .TP
    79  .B "dispose \fIvalue\fP"
    80  GIF disposal method.
    81  
    82  Here are the valid methods:
    83  
    84  .nf
    85       0  No disposal specified.
    86       1  Do not dispose between frames.
    87       2  Overwrite frame with background color from header.
    88       3  Overwrite with previous frame.
    89  .fi
    90  .TP
    91  .B "gamma=\fIvalue\fP"
    92  the gamma of the image.  If it is not specified, a gamma of 1.0
    93  (linear brightness response) is assumed,
    94  .TP
    95  .B "id=\fBImageMagick\fP"
    96  identifies the file as a MIFF-format image file.  This key
    97  is required and has no default.  Although this key can appear anywhere
    98  in the header, it should start as the first key of the header in column
    99  1.  This will allow programs like \fBfile\fP(1) to easily identify the file
   100  as MIFF.
   101  .TP
   102  .B "iterations \fIvalue\fP"
   103  the number of times an image sequence loops before stopping.
   104  .TP
   105  .B "label=\fI{value}\fP"
   106  defines a short title or caption for the image.  If
   107  any whitespace appears in the label, it must be enclosed within braces.
   108  .TP
   109  .B "matte=\fBTrue\fP"
   110  .B "matte=\fBFalse\fP"
   111  specifies whether a \fBDirectClass\fP image has matte data.  Matte data
   112  is generally useful for image compositing.  This key has no meaning
   113  for pseudo-color images.
   114  .TP
   115  .B "montage=\fI<width>x<height>{\+-}<x offset>{\+-}<y offset>\fP
   116  size and location of the individual tiles of a composite image.  See
   117  \fBX(1)\fP for details about the geometry specification.
   118  
   119  Use this key when the image is a composite of a number of different
   120  tiles.  A tile consists of an image and optionally a border and a
   121  label.  \fI<width>\fP is the size in pixels of each individual tile in
   122  the horizontal direction and \fI<height>\fP is the size in the vertical
   123  direction.  Each tile must have an equal number of pixels in width and
   124  equal in height.  However, the width can differ from the height.  \fI<x
   125  offset>\fP is the offset in number of pixels from the vertical edge of
   126  the composite image where the first tile of a row begins and \fI<y
   127  offset>\fP is the offset from the horizontal edge where the first tile
   128  of a column begins.
   129  
   130  If this key is specified, a directory of tile names must follow the
   131  image header.  The format of the directory is explained below.
   132  .TP
   133  .B "page=\fIvalue\fP"
   134  preferred size and location of an image canvas.
   135  .TP
   136  .B "profile-icc=\fIvalue\fP"
   137  the number of bytes in the International Color Consortium color profile.
   138  The profile is defined by the ICC profile specification located at
   139  ftp://sgigate.sgi.com/pub/icc/icc34.ps.
   140  .TP
   141  .B "colorspace=\fBRGB\fP"
   142  .TP
   143  .B "red-primary=\fIx,y\fP"
   144  .B "green-primary=\fIx,y\fP"
   145  .B "blue-primary=\fIx,y\fP"
   146  .B "white-point=\fIx,y\fP"
   147  this optional key reflects the chromaticity primaries and white point.
   148  .TP
   149  .B "rendering-intent=\fBsaturation\fP"
   150  .B "rendering-intent=\fBperceptual\fP"
   151  .B "rendering-intent=\fBabsolute\fP"
   152  .B "rendering-intent=\fBrelative\fP"
   153  Rendering intent is the CSS-1 property that has been defined by the
   154  International Color Consortium (http://www.color.org).
   155  .TP
   156  .B "resolution=\fI<x-resolution>x<y-resolution>\fP"
   157  vertical and horizontal resolution of the image.  See \fBunits\fP
   158  for the specific resolution units (e.g. pixels per inch).
   159  .TP
   160  .B "rows=\fIvalue\fP"
   161  the height of the image in pixels.  This is a required key
   162  and has no default.
   163  .TP
   164  .B "scene=\fIvalue\fP"
   165  the sequence number for this MIFF image file.  This optional
   166  key is used when a MIFF image file is one in a sequence of files
   167  used in an animation.
   168  .TP
   169  .B "signature=\fIvalue\fP"
   170  this optional key contains a string that uniquely identifies
   171  the image pixel contents.  NIST's SHA-256 message digest algorithm is
   172  recommended.
   173  .TP
   174  .B "units=\fBpixels-per-inch\fP"
   175  .B "units=\fBpixels-per-centimeter\fP"
   176  image resolution units.
   177  
   178  Other key value pairs are permitted.  If a value contains whitespace it
   179  must be enclosed with braces as illustrated here:
   180  
   181      id=ImageMagick
   182      class=PseudoClass  colors=256
   183      compression=RunlengthEncoded  packets=27601
   184      columns=1280  rows=1024
   185      signature=d79e1c308aa5bbcdeea8ed63df412da9
   186      copyright={Copyright (c) 2001 ImageMagick Studio}
   187      <FF>
   188      :
   189  
   190  .PP
   191  Note that \fIkey=value\fP combinations may be separated by newlines or
   192  spaces and may occur in any order within the header.  Comments (within
   193  braces) may appear anywhere before the colon.
   194  
   195  If you specify the \fBmontage\fP key in the header, follow
   196  the header with a directory of image tiles.  This directory consists of
   197  a name for each tile of the composite image separated by a
   198  \fBnewline\fP character.  The list is terminated with a NULL character.
   199  
   200  If you specify the \fBcolor-profile\fP key in the header, follow
   201  the header (or montage directory if the \fBmontage\fP key is in the
   202  header) with the binary color profile.
   203  
   204  Next comes the binary image data itself.  How the image
   205  data is formatted depends upon the class of the image as specified (or
   206  not specified) by the value of the \fBclass\fP key in the header.
   207  
   208  DirectClass images (class=DirectClass) are continuous-tone, images
   209  stored as RGB (red, green, blue), RGBA (red, green, blue, alpha), or
   210  CMYK (cyan, yellow, magenta, black) intensity values as defined by the
   211  colorspace key. Each intensity value is one byte in length for
   212  images of depth 8 (0..255), whereas, images of depth 16 (0..65535)
   213  require two bytes in most significant byte first order.
   214  
   215  PseudoClass images (class=PseudoClass) are colormapped RGB images. The
   216  colormap is stored as a series of red, green, and blue pixel values,
   217  each value being a byte in size. If the image depth is 16, each
   218  colormap entry consumes two bytes with the most significant byte being
   219  first. The number of colormap entries is defined by the colors key.
   220  The colormap data occurs immediately following the header (or image
   221  directory if the montage key is in the header). PseudoClass image
   222  data is an array of index values into the color map. If there are 256
   223  or fewer colors in the image, each byte of image data contains an index
   224  value. If the image contains more than 256 colors or the image depth is
   225  16, the index value is stored as two contiguous bytes with the most
   226  significant byte being first. If matte is true, each
   227  colormap index is followed by a 1 or 2-byte alpha value.
   228  
   229  The image data in a MIFF file may be uncompressed, runlength encoded,
   230  Zip compressed, or BZip compressed. The compression key in the
   231  header defines how the image data is compressed. Uncompressed pixels
   232  are just stored one scanline at a time in row order. Runlength encoded
   233  compression counts runs of identical adjacent pixels and stores the
   234  pixels followed by a length byte (the number of identical pixels minus
   235  1). Zip and BZip compression compresses each row of an image and
   236  preceeds the compressed row with the length of compressed pixel bytes
   237  as a word in most significant byte first order.
   238  
   239  MIFF files may contain more than one image.  Simply concatenate each
   240  individual image (composed of a header and image data) into one file.
   241  .SH SEE ALSO
   242  .B
   243  display(1), animate(1), import(1), montage(1), mogrify(1), convert(1), more(1), compress(1)
   244  .SH COPYRIGHT
   245  Copyright (C) 2000 ImageMagick Studio, a non-profit organization dedicated
   246  to making software imaging solutions freely available.
   247  
   248  Permission is hereby granted, free of charge, to any person obtaining a
   249  copy of this software and associated documentation files ("ImageMagick"),
   250  to deal in ImageMagick without restriction, including without limitation
   251  the rights to use, copy, modify, merge, publish, distribute, sublicense,
   252  and/or sell copies of ImageMagick, and to permit persons to whom the
   253  ImageMagick is furnished to do so, subject to the following conditions:
   254  
   255  The above copyright notice and this permission notice shall be included in
   256  all copies or substantial portions of ImageMagick.
   257  
   258  The software is provided "as is", without warranty of any kind, express or
   259  implied, including but not limited to the warranties of merchantability,
   260  fitness for a particular purpose and noninfringement.  In no event shall
   261  ImageMagick Studio be liable for any claim, damages or other liability,
   262  whether in an action of contract, tort or otherwise, arising from, out of
   263  or in connection with ImageMagick or the use or other dealings in
   264  ImageMagick.
   265  
   266  Except as contained in this notice, the name of the ImageMagick Studio
   267  shall not be used in advertising or otherwise to promote the sale, use or
   268  other dealings in ImageMagick without prior written authorization from the
   269  ImageMagick Studio.
   270  .SH AUTHORS
   271  John Cristy, ImageMagick Studio