About this Blog

This Blog has English posts and Japanese posts. About Mac, iOS, Objective-C, and so on.


xcf.txtの日本語訳 8. GENERIC PROPERTIES

This post is a personal translation of Henning Makholm's xcf.txt to Japanese. : Index here



This section lists the formats of the defined property records that
can appear in more than one context in an XCF file.
  uint32  0   The type number for PROP_END is 0
  uint32  0   PROP_END has no payload
  This pseudo-property marks the end of a property list in the XCF


PROP_OPACITY (essential)
  uint32  6   The type number for PROP_OPACITY is 6
  uint32  4   Four bytes of payload
  uint32  x   The opacity on a scale from 0 (fully transparent) to 255
              (fully opaque)
  Appears in the property list of layers and channels, and records the
  overall opacity setting for the layer/channel. Note that though the
  Gimp's user interface displays the opacity as a percentage, it is
  actually stored on a 0-255 scale. Also note that this opacity value
  is stored as a 32-bit quantity even though it has been scaled to
  fit exactly in a single byte.


  When reading old XCF files that lack this property, full opacity
  should be assumed.


PROP_VISIBLE (essential)
  uint32  8   The type number for PROP_VISIBLE is 8
  uint32  4   Four bytes of payload
  uint32  b   1 if the layer/channel is visible; 0 if not
  Appears in the property list for layers and channels.
  When reading old XCF files that lack this property, assume that
  layers are visible and channels are not.

>古いXCFファイルで、このpropertyが存在しない場合layerについては PROP_VISIBLE=1、channelについては PROP_VISIBLE=0とします。

PROP_LINKED (editing state)
  uint32  9   The type number for PROP_LINKED is 9
  uint32  4   Four bytes of payload
  uint32  b   1 if the layer is linked; 0 if not
  Appears in the property list for layers and channels.  "Linked" is a
  UI property: if the Move tool is used to move a linked layer, all
  other linked layers will be moved in parallel.


PROP_TATTOO (internal Gimp state)
  uint32  20  The type number for PROP_TATTOO is 20
  uint32  4   Four bytes of payload
  uint32  4   The tattoo, a nonzero unsigned integer
  Appears in the property list of layers, channels, and entire images.
  A tattoo is a unique and permanent identifier attached to a drawable
  (or vector element) that can be used to uniquely identify a drawable
  within an image even between sessions.


  The PROP_TATTOO property of the entire image stores a "high-water
  mark" for the entire image; it is greater than OR EQUAL TO any
  tattoo for an element of the image. It allows efficient generation
  of new unused tattoo values and also prevents old tattoo numbers
  from being reused within a single image, lest plug-ins that use
  the tattoos for bookkeeping get confused.


  An XCF file must either provide tattoo values for all its elements
  or for none of them. GIMP will invent fresh tattoos when it
  reads in tattoo-less elements, but it does not attempt to keep them
  different from ones specified explicitly in the file. 


  uint32    21      The type number for PROP_PARASITES is 21
  uint32    length  Total length of the following payload data
  ,---------------- Repeat for each parasite:
  | string  name    Name of the parasite
  | uint32  flags   ?????
  | uint32  n       Size of the payload data
  | byte[n] ...     Parasite-specific payload
  This property can appear in any property list. It can contain
  multiple "parasites" which are named extension records. See "Basic
  concepts and datatypes" above. The number of parasites is not
  directly encoded; the list ends when the total length of the
  parasite data read equals the property payload length.
  GIMP's XCF reader checks that the combined size of all parasites
  in the property precisely equals the length word, so it is safe for
  a reader to use the length word to skip the property without parsing
  the individual parasites.
  The parasite contents may be binary, but often a textual encoding is
  chosen in order to free the creator/consumer code of having to deal
  with byte ordering.
  There can only be one parasite with a given name attached to
  each element of the image. Some versions of GIMP will
  erroneously write some parasites twice in the same property list;
  XCF readers must be prepared to gracefully ignore all but the
  last instance of a parasite name in each property list.


0 件のコメント: