home *** CD-ROM | disk | FTP | other *** search
/ HyperLib 1997 Winter - Disc 1 / HYPERLIB-1997-Winter-CD1.ISO.7z / HYPERLIB-1997-Winter-CD1.ISO / 第1特集Plug-in / Photoshop / Plug-in_Kit_2.5.1.sit / Plug-in_Kit_2.5.1 / Code / PIGeneral.r < prev    next >
Text File  |  1993-04-28  |  4KB  |  154 lines

  1. /* Copyright 1992.  Adobe Systems, Inc.. All rights reserved. */
  2. /*
  3.     File: PIGeneral.r
  4.  
  5.     Copyright 1991, 1992 by Adobe Systems Inc..
  6.     
  7.     Written by    Marc Kaufman
  8.                 Kaufman Research
  9.                 17 Mountain Meadow
  10.                 Woodside, CA  94062
  11.                 (415) 851-5777
  12. */
  13.  
  14. #ifndef __PIGeneral.r__
  15. #define __PIGeneral.r__
  16.  
  17.  
  18. type 'PiMI'
  19. {
  20. Start:                /* The following is common to all Photoshop 2.5 Plugin modules      */
  21.     integer;                        /* The version number of the interface supported. */
  22.     integer;                        /* The sub-version number.                          */
  23.     integer;                        /* The plug-in's priority.                        */
  24.     integer = (General-Start)/8;    /* The size of the general info.                  */
  25.     integer = (TypeInfo-General)/8;    /* The size of the type specific info.              */
  26.     integer;                        /* A bit mask indicating supported image modes.   */
  27.     literal longint;                /* A required host if any.                          */
  28. General:
  29.  
  30.     array {            /* The following is used only for Format Plugin modules              */
  31.         integer = $$Countof(TypeArray);                /* type count */
  32.         integer = $$Countof(ExtensionArray);        /* extension count */
  33.         byte  cannotRead, canRead;                    /* Can we read using this format?                  */
  34.         byte  cannotReadAll, canReadAll;            /* Can this plug-in read from all files?          */
  35.         byte  cannotWrite, canWrite;                /* Can we write using this format?                  */
  36.         byte  cannotWriteIfRead, canWriteIfRead;    /* Can we write if we read using this format?      */
  37.         byte  doesntSaveResources, savesResources;    /* Does this file format save the resource data?  */
  38.         fill byte;                    /* Padding */
  39.         wide array [16]
  40.             { integer; };            /* Maximum # of channels with each plug-in mode.  */
  41.         integer;                    /* Maximum rows allowed in document.              */
  42.         integer;                    /* Maximum columns allowed in document.              */
  43.         literal longint;            /* The file type if we create a file.              */
  44.         literal longint;            /* The creator type if we create a file.          */
  45.         array TypeArray
  46.         {
  47.             literal longint;        /* The type-creator pairs supported.              */
  48.             literal longint;
  49.         };
  50.         array ExtensionArray
  51.         {
  52.             literal longint;        /* The extensions supported.                      */
  53.         };
  54.     };
  55.     
  56.     array {        /* The following is used only for filter plug-in modules.              */
  57.         byte    dontCopySourceToDestination, copySourceToDestination;
  58.     };
  59.  
  60. TypeInfo:
  61.  
  62. };
  63.     
  64. #define supportsBitmap             1
  65. #define supportsGrayScale        2
  66. #define supportsIndexedColor    4
  67. #define supportsRGBColor        8
  68. #define supportsCMYKColor       16
  69. #define supportsHSLColor       32
  70. #define supportsHSBColor       64
  71. #define supportsMultichannel  128
  72. #define supportsDuotone          256
  73. #define supportsLABColor      512
  74.  
  75. #define latestAcquireVersion        4
  76. #define latestAcquireSubVersion        0
  77. #define latestExportVersion            4
  78. #define latestExportSubVersion        0
  79. #define latestExtensionVersion        1
  80. #define latestExtensionSubVersion    0
  81. #define latestFilterVersion            4
  82. #define latestFilterSubVersion        0
  83. #define latestFormatVersion            1
  84. #define latestFormatSubVersion        0
  85.  
  86.  
  87. #if 0
  88.  
  89. /* Example of Format plugin resource */
  90.  
  91. resource 'PiMI' (16000, purgeable)
  92. {
  93.     latestFormatVersion,     /* Version, subVersion, and priority of the interface */
  94.     latestFormatSubVersion,
  95.     0,
  96.     supportsGrayScale+supportsRGBColor+supportsCMYKColor,
  97.     '    ',
  98.     
  99.     {
  100.         canRead,
  101.         cannotReadAll,
  102.         canWrite,
  103.         canWriteIfRead,
  104.         doesntSaveResources,
  105.         { 0, 1, 0, 3,
  106.           4, 0, 0, 0,
  107.           0, 0, 0, 0,
  108.           0, 0, 0, 0 },
  109.         32767,
  110.         32767,
  111.         'JPEG',
  112.         '    ',
  113.         {
  114.             'JPEG', '8BIM'
  115.         },
  116.         {
  117.             'JPG '
  118.         }
  119.     }
  120.     
  121.     {}
  122.  
  123. };
  124.  
  125. /* Example of Acquire/Export resource */
  126.  
  127. resource 'PiMI' (16001, purgeable)
  128. {
  129.     latestAcquireVersion,     /* Version, subVersion, and priority of the interface */ 
  130.     latestAcquireSubVersion, 
  131.     0,
  132.     supportsGrayScale+supportsRGBColor+supportsCMYKColor,
  133.     '    ',
  134.     {}            /* Null Format extension field */
  135.     {}            /* Null Filter extension field */
  136. };
  137.  
  138. /* Example of Filter resource */
  139.  
  140. resource 'PiMI' (16001, purgeable)
  141. {
  142.     latestAcquireVersion,     /* Version, subVersion, and priority of the interface */ 
  143.     latestAcquireSubVersion, 
  144.     0,
  145.     supportsGrayScale+supportsRGBColor+supportsCMYKColor,
  146.     '    ',
  147.     {}            /* Null Format extension field */
  148.     { dontCopySourceToDestination }
  149. };
  150.  
  151. #endif
  152.  
  153. #endif
  154.