QuickTimeComponents.h
上传用户:xjjlds
上传日期:2015-12-05
资源大小:22823k
文件大小:297k
源码类别:

多媒体编程

开发平台:

Visual C++

  1. EXTERN_API( ComponentResult )
  2. DataHSetFileSize64              (DataHandler            dh,
  3.                                  const wide *           fileSize)                           FIVEWORDINLINE(0x2F3C, 0x0004, 0x0032, 0x7000, 0xA82A);
  4. EXTERN_API( ComponentResult )
  5. DataHGetFreeSpace64             (DataHandler            dh,
  6.                                  wide *                 freeSize)                           FIVEWORDINLINE(0x2F3C, 0x0004, 0x0033, 0x7000, 0xA82A);
  7. EXTERN_API( ComponentResult )
  8. DataHAppend64                   (DataHandler            dh,
  9.                                  void *                 data,
  10.                                  wide *                 fileOffset,
  11.                                  unsigned long          size)                               FIVEWORDINLINE(0x2F3C, 0x000C, 0x0034, 0x7000, 0xA82A);
  12. EXTERN_API( ComponentResult )
  13. DataHReadAsync                  (DataHandler            dh,
  14.                                  void *                 dataPtr,
  15.                                  UInt32                 dataSize,
  16.                                  const wide *           dataOffset,
  17.                                  DataHCompletionUPP     completion,
  18.                                  long                   refCon)                             FIVEWORDINLINE(0x2F3C, 0x0014, 0x0035, 0x7000, 0xA82A);
  19. EXTERN_API( ComponentResult )
  20. DataHPollRead                   (DataHandler            dh,
  21.                                  void *                 dataPtr,
  22.                                  UInt32 *               dataSizeSoFar)                      FIVEWORDINLINE(0x2F3C, 0x0008, 0x0036, 0x7000, 0xA82A);
  23. EXTERN_API( ComponentResult )
  24. DataHGetDataAvailability        (DataHandler            dh,
  25.                                  long                   offset,
  26.                                  long                   len,
  27.                                  long *                 missing_offset,
  28.                                  long *                 missing_len)                        FIVEWORDINLINE(0x2F3C, 0x0010, 0x0037, 0x7000, 0xA82A);
  29. EXTERN_API( ComponentResult )
  30. DataHGetFileSizeAsync           (DataHandler            dh,
  31.                                  wide *                 fileSize,
  32.                                  DataHCompletionUPP     completionRtn,
  33.                                  long                   refCon)                             FIVEWORDINLINE(0x2F3C, 0x000C, 0x003A, 0x7000, 0xA82A);
  34. EXTERN_API( ComponentResult )
  35. DataHGetDataRefAsType           (DataHandler            dh,
  36.                                  OSType                 requestedType,
  37.                                  Handle *               dataRef)                            FIVEWORDINLINE(0x2F3C, 0x0008, 0x003B, 0x7000, 0xA82A);
  38. EXTERN_API( ComponentResult )
  39. DataHSetDataRefExtension        (DataHandler            dh,
  40.                                  Handle                 extension,
  41.                                  OSType                 idType)                             FIVEWORDINLINE(0x2F3C, 0x0008, 0x003C, 0x7000, 0xA82A);
  42. EXTERN_API( ComponentResult )
  43. DataHGetDataRefExtension        (DataHandler            dh,
  44.                                  Handle *               extension,
  45.                                  OSType                 idType)                             FIVEWORDINLINE(0x2F3C, 0x0008, 0x003D, 0x7000, 0xA82A);
  46. EXTERN_API( ComponentResult )
  47. DataHGetMovieWithFlags          (DataHandler            dh,
  48.                                  Movie *                theMovie,
  49.                                  short *                id,
  50.                                  short                  flags)                              FIVEWORDINLINE(0x2F3C, 0x000A, 0x003E, 0x7000, 0xA82A);
  51. EXTERN_API( ComponentResult )
  52. DataHGetFileTypeOrdering        (DataHandler            dh,
  53.                                  DataHFileTypeOrderingHandle * orderingListHandle)          FIVEWORDINLINE(0x2F3C, 0x0004, 0x0040, 0x7000, 0xA82A);
  54. /* flags for DataHCreateFileWithFlags*/
  55. enum {
  56.     kDataHCreateFileButDontCreateResFile = (1L << 0)
  57. };
  58. EXTERN_API( ComponentResult )
  59. DataHCreateFileWithFlags        (DataHandler            dh,
  60.                                  OSType                 creator,
  61.                                  Boolean                deleteExisting,
  62.                                  UInt32                 flags)                              FIVEWORDINLINE(0x2F3C, 0x000A, 0x0041, 0x7000, 0xA82A);
  63. EXTERN_API( ComponentResult )
  64. DataHGetMIMETypeAsync           (DataHandler            dh,
  65.                                  Str255                 mimeType,
  66.                                  DataHCompletionUPP     completionRtn,
  67.                                  long                   refCon)                             FIVEWORDINLINE(0x2F3C, 0x000C, 0x0042, 0x7000, 0xA82A);
  68. EXTERN_API( ComponentResult )
  69. DataHGetInfo                    (DataHandler            dh,
  70.                                  OSType                 what,
  71.                                  void *                 info)                               FIVEWORDINLINE(0x2F3C, 0x0008, 0x0043, 0x7000, 0xA82A);
  72. EXTERN_API( ComponentResult )
  73. DataHSetIdleManager             (DataHandler            dh,
  74.                                  IdleManager            im)                                 FIVEWORDINLINE(0x2F3C, 0x0004, 0x0044, 0x7000, 0xA82A);
  75. EXTERN_API( ComponentResult )
  76. DataHDeleteFile                 (DataHandler            dh)                                 FIVEWORDINLINE(0x2F3C, 0x0000, 0x0045, 0x7000, 0xA82A);
  77. enum {
  78.     kDataHMovieUsageDoAppendMDAT = 1L << 0                      /* if set, datahandler should append wide and mdat atoms in append call*/
  79. };
  80. EXTERN_API( ComponentResult )
  81. DataHSetMovieUsageFlags         (DataHandler            dh,
  82.                                  long                   flags)                              FIVEWORDINLINE(0x2F3C, 0x0004, 0x0046, 0x7000, 0xA82A);
  83. enum {
  84.     kDataHTempUseSameDirectory  = 1L << 0,                      /* temp data ref should be in same directory as current data ref (vs. in temporary directory)*/
  85.     kDataHTempUseSameVolume     = 1L << 1,                      /* temp data ref should be on same volume as current data ref (vs. find "best" volume)*/
  86.     kDataHTempCreateFile        = 1L << 2,                      /* create the file*/
  87.     kDataHTempOpenFile          = 1L << 3                       /* open temporary file for write (kDataHTempCreateFile must be passed, too)*/
  88. };
  89. EXTERN_API( ComponentResult )
  90. DataHUseTemporaryDataRef        (DataHandler            dh,
  91.                                  long                   inFlags)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0047, 0x7000, 0xA82A);
  92. EXTERN_API( ComponentResult )
  93. DataHGetTemporaryDataRefCapabilities (DataHandler       dh,
  94.                                  long *                 outUnderstoodFlags)                 FIVEWORDINLINE(0x2F3C, 0x0004, 0x0048, 0x7000, 0xA82A);
  95. EXTERN_API( ComponentResult )
  96. DataHRenameFile                 (DataHandler            dh,
  97.                                  Handle                 newDataRef)                         FIVEWORDINLINE(0x2F3C, 0x0004, 0x0049, 0x7000, 0xA82A);
  98. EXTERN_API( ComponentResult )
  99. DataHPlaybackHints              (DataHandler            dh,
  100.                                  long                   flags,
  101.                                  unsigned long          minFileOffset,
  102.                                  unsigned long          maxFileOffset,
  103.                                  long                   bytesPerSecond)                     FIVEWORDINLINE(0x2F3C, 0x0010, 0x0103, 0x7000, 0xA82A);
  104. EXTERN_API( ComponentResult )
  105. DataHPlaybackHints64            (DataHandler            dh,
  106.                                  long                   flags,
  107.                                  const wide *           minFileOffset,
  108.                                  const wide *           maxFileOffset,
  109.                                  long                   bytesPerSecond)                     FIVEWORDINLINE(0x2F3C, 0x0010, 0x010E, 0x7000, 0xA82A);
  110. /* Symbolic constants for DataHGetDataRate*/
  111. enum {
  112.     kDataHGetDataRateInfiniteRate = 0x7FFFFFFF                  /* all the data arrived instantaneously*/
  113. };
  114. EXTERN_API( ComponentResult )
  115. DataHGetDataRate                (DataHandler            dh,
  116.                                  long                   flags,
  117.                                  long *                 bytesPerSecond)                     FIVEWORDINLINE(0x2F3C, 0x0008, 0x0110, 0x7000, 0xA82A);
  118. /* Flags for DataHSetTimeHints*/
  119. enum {
  120.     kDataHSetTimeHintsSkipBandwidthRequest = 1 << 0             /* set if this data handler should use the network without requesting bandwidth*/
  121. };
  122. EXTERN_API( ComponentResult )
  123. DataHSetTimeHints               (DataHandler            dh,
  124.                                  long                   flags,
  125.                                  long                   bandwidthPriority,
  126.                                  TimeScale              scale,
  127.                                  TimeValue              minTime,
  128.                                  TimeValue              maxTime)                            FIVEWORDINLINE(0x2F3C, 0x0014, 0x0111, 0x7000, 0xA82A);
  129. /* Standard type for video digitizers */
  130. enum {
  131.     videoDigitizerComponentType = FOUR_CHAR_CODE('vdig'),
  132.     vdigInterfaceRev            = 2
  133. };
  134. /* Input Format Standards */
  135. enum {
  136.     ntscIn                      = 0,                            /* current input format */
  137.     currentIn                   = 0,                            /* ntsc input format */
  138.     palIn                       = 1,                            /* pal input format */
  139.     secamIn                     = 2,                            /* secam input format */
  140.     ntscReallyIn                = 3                             /* ntsc input format */
  141. };
  142. /* Input Formats */
  143. enum {
  144.     compositeIn                 = 0,                            /* input is composite format */
  145.     sVideoIn                    = 1,                            /* input is sVideo format */
  146.     rgbComponentIn              = 2,                            /* input is rgb component format */
  147.     rgbComponentSyncIn          = 3,                            /* input is rgb component format (sync on green?)*/
  148.     yuvComponentIn              = 4,                            /* input is yuv component format */
  149.     yuvComponentSyncIn          = 5,                            /* input is yuv component format (sync on green?) */
  150.     tvTunerIn                   = 6,
  151.     sdiIn                       = 7
  152. };
  153. /* Video Digitizer PlayThru States */
  154. enum {
  155.     vdPlayThruOff               = 0,
  156.     vdPlayThruOn                = 1
  157. };
  158. /* Input Color Space Modes */
  159. enum {
  160.     vdDigitizerBW               = 0,                            /* black and white */
  161.     vdDigitizerRGB              = 1                             /* rgb color */
  162. };
  163. /* Phase Lock Loop Modes */
  164. enum {
  165.     vdBroadcastMode             = 0,                            /* Broadcast / Laser Disk video mode */
  166.     vdVTRMode                   = 1                             /* VCR / Magnetic media mode */
  167. };
  168. /* Field Select Options */
  169. enum {
  170.     vdUseAnyField               = 0,                            /* Digitizers choice on field use */
  171.     vdUseOddField               = 1,                            /* Use odd field for half size vert and smaller */
  172.     vdUseEvenField              = 2                             /* Use even field for half size vert and smaller */
  173. };
  174. /* vdig types */
  175. enum {
  176.     vdTypeBasic                 = 0,                            /* basic, no clipping */
  177.     vdTypeAlpha                 = 1,                            /* supports clipping with alpha channel */
  178.     vdTypeMask                  = 2,                            /* supports clipping with mask plane */
  179.     vdTypeKey                   = 3                             /* supports clipping with key color(s) */
  180. };
  181. /* Digitizer Input Capability/Current Flags */
  182. enum {
  183.     digiInDoesNTSC              = 1L << 0,                      /* digitizer supports NTSC input format */
  184.     digiInDoesPAL               = 1L << 1,                      /* digitizer supports PAL input format */
  185.     digiInDoesSECAM             = 1L << 2,                      /* digitizer supports SECAM input format */
  186.     digiInDoesGenLock           = 1L << 7,                      /* digitizer does genlock */
  187.     digiInDoesComposite         = 1L << 8,                      /* digitizer supports composite input type */
  188.     digiInDoesSVideo            = 1L << 9,                      /* digitizer supports S-Video input type */
  189.     digiInDoesComponent         = 1L << 10,                     /* digitizer supports component = rgb, input type */
  190.     digiInVTR_Broadcast         = 1L << 11,                     /* digitizer can differentiate between the two */
  191.     digiInDoesColor             = 1L << 12,                     /* digitizer supports color */
  192.     digiInDoesBW                = 1L << 13,                     /* digitizer supports black & white */
  193.                                                                 /* Digitizer Input Current Flags = these are valid only during active operating conditions,   */
  194.     digiInSignalLock            = 1L << 31                      /* digitizer detects input signal is locked, this bit = horiz lock || vertical lock */
  195. };
  196. /* Digitizer Output Capability/Current Flags */
  197. enum {
  198.     digiOutDoes1                = 1L << 0,                      /* digitizer supports 1 bit pixels */
  199.     digiOutDoes2                = 1L << 1,                      /* digitizer supports 2 bit pixels */
  200.     digiOutDoes4                = 1L << 2,                      /* digitizer supports 4 bit pixels */
  201.     digiOutDoes8                = 1L << 3,                      /* digitizer supports 8 bit pixels */
  202.     digiOutDoes16               = 1L << 4,                      /* digitizer supports 16 bit pixels */
  203.     digiOutDoes32               = 1L << 5,                      /* digitizer supports 32 bit pixels */
  204.     digiOutDoesDither           = 1L << 6,                      /* digitizer dithers in indexed modes */
  205.     digiOutDoesStretch          = 1L << 7,                      /* digitizer can arbitrarily stretch */
  206.     digiOutDoesShrink           = 1L << 8,                      /* digitizer can arbitrarily shrink */
  207.     digiOutDoesMask             = 1L << 9,                      /* digitizer can mask to clipping regions */
  208.     digiOutDoesDouble           = 1L << 11,                     /* digitizer can stretch to exactly double size */
  209.     digiOutDoesQuad             = 1L << 12,                     /* digitizer can stretch exactly quadruple size */
  210.     digiOutDoesQuarter          = 1L << 13,                     /* digitizer can shrink to exactly quarter size */
  211.     digiOutDoesSixteenth        = 1L << 14,                     /* digitizer can shrink to exactly sixteenth size */
  212.     digiOutDoesRotate           = 1L << 15,                     /* digitizer supports rotate transformations */
  213.     digiOutDoesHorizFlip        = 1L << 16,                     /* digitizer supports horizontal flips Sx < 0 */
  214.     digiOutDoesVertFlip         = 1L << 17,                     /* digitizer supports vertical flips Sy < 0 */
  215.     digiOutDoesSkew             = 1L << 18,                     /* digitizer supports skew = shear,twist, */
  216.     digiOutDoesBlend            = 1L << 19,
  217.     digiOutDoesWarp             = 1L << 20,
  218.     digiOutDoesHW_DMA           = 1L << 21,                     /* digitizer not constrained to local device */
  219.     digiOutDoesHWPlayThru       = 1L << 22,                     /* digitizer doesn't need time to play thru */
  220.     digiOutDoesILUT             = 1L << 23,                     /* digitizer does inverse LUT for index modes */
  221.     digiOutDoesKeyColor         = 1L << 24,                     /* digitizer does key color functions too */
  222.     digiOutDoesAsyncGrabs       = 1L << 25,                     /* digitizer supports async grabs */
  223.     digiOutDoesUnreadableScreenBits = 1L << 26,                 /* playthru doesn't generate readable bits on screen*/
  224.     digiOutDoesCompress         = 1L << 27,                     /* supports alternate output data types */
  225.     digiOutDoesCompressOnly     = 1L << 28,                     /* can't provide raw frames anywhere */
  226.     digiOutDoesPlayThruDuringCompress = 1L << 29,               /* digi can do playthru while providing compressed data */
  227.     digiOutDoesCompressPartiallyVisible = 1L << 30,             /* digi doesn't need all bits visible on screen to do hardware compress */
  228.     digiOutDoesNotNeedCopyOfCompressData = 1L << 31             /* digi doesn't need any bufferization when providing compressed data */
  229. };
  230. /* Types */
  231. typedef ComponentInstance               VideoDigitizerComponent;
  232. typedef ComponentResult                 VideoDigitizerError;
  233. struct DigitizerInfo {
  234.     short                           vdigType;
  235.     long                            inputCapabilityFlags;
  236.     long                            outputCapabilityFlags;
  237.     long                            inputCurrentFlags;
  238.     long                            outputCurrentFlags;
  239.     short                           slot;                       /* temporary for connection purposes */
  240.     GDHandle                        gdh;                        /* temporary for digitizers that have preferred screen */
  241.     GDHandle                        maskgdh;                    /* temporary for digitizers that have mask planes */
  242.     short                           minDestHeight;              /* Smallest resizable height */
  243.     short                           minDestWidth;               /* Smallest resizable width */
  244.     short                           maxDestHeight;              /* Largest resizable height */
  245.     short                           maxDestWidth;               /* Largest resizable width */
  246.     short                           blendLevels;                /* Number of blend levels supported (2 if 1 bit mask) */
  247.     long                            reserved;                   /* reserved */
  248. };
  249. typedef struct DigitizerInfo            DigitizerInfo;
  250. struct VdigType {
  251.     long                            digType;
  252.     long                            reserved;
  253. };
  254. typedef struct VdigType                 VdigType;
  255. struct VdigTypeList {
  256.     short                           count;
  257.     VdigType                        list[1];
  258. };
  259. typedef struct VdigTypeList             VdigTypeList;
  260. struct VdigBufferRec {
  261.     PixMapHandle                    dest;
  262.     Point                           location;
  263.     long                            reserved;
  264. };
  265. typedef struct VdigBufferRec            VdigBufferRec;
  266. struct VdigBufferRecList {
  267.     short                           count;
  268.     MatrixRecordPtr                 matrix;
  269.     RgnHandle                       mask;
  270.     VdigBufferRec                   list[1];
  271. };
  272. typedef struct VdigBufferRecList        VdigBufferRecList;
  273. typedef VdigBufferRecList *             VdigBufferRecListPtr;
  274. typedef VdigBufferRecListPtr *          VdigBufferRecListHandle;
  275. typedef CALLBACK_API( void , VdigIntProcPtr )(long flags, long refcon);
  276. typedef STACK_UPP_TYPE(VdigIntProcPtr)                          VdigIntUPP;
  277. struct VDCompressionList {
  278.     CodecComponent                  codec;
  279.     CodecType                       cType;
  280.     Str63                           typeName;
  281.     Str63                           name;
  282.     long                            formatFlags;
  283.     long                            compressFlags;
  284.     long                            reserved;
  285. };
  286. typedef struct VDCompressionList        VDCompressionList;
  287. typedef VDCompressionList *             VDCompressionListPtr;
  288. typedef VDCompressionListPtr *          VDCompressionListHandle;
  289. enum {
  290.     dmaDepth1                   = 1,
  291.     dmaDepth2                   = 2,
  292.     dmaDepth4                   = 4,
  293.     dmaDepth8                   = 8,
  294.     dmaDepth16                  = 16,
  295.     dmaDepth32                  = 32,
  296.     dmaDepth2Gray               = 64,
  297.     dmaDepth4Gray               = 128,
  298.     dmaDepth8Gray               = 256
  299. };
  300. enum {
  301.     kVDIGControlledFrameRate    = -1
  302. };
  303. EXTERN_API( VideoDigitizerError )
  304. VDGetMaxSrcRect                 (VideoDigitizerComponent  ci,
  305.                                  short                  inputStd,
  306.                                  Rect *                 maxSrcRect)                         FIVEWORDINLINE(0x2F3C, 0x0006, 0x0001, 0x7000, 0xA82A);
  307. EXTERN_API( VideoDigitizerError )
  308. VDGetActiveSrcRect              (VideoDigitizerComponent  ci,
  309.                                  short                  inputStd,
  310.                                  Rect *                 activeSrcRect)                      FIVEWORDINLINE(0x2F3C, 0x0006, 0x0002, 0x7000, 0xA82A);
  311. EXTERN_API( VideoDigitizerError )
  312. VDSetDigitizerRect              (VideoDigitizerComponent  ci,
  313.                                  Rect *                 digitizerRect)                      FIVEWORDINLINE(0x2F3C, 0x0004, 0x0003, 0x7000, 0xA82A);
  314. EXTERN_API( VideoDigitizerError )
  315. VDGetDigitizerRect              (VideoDigitizerComponent  ci,
  316.                                  Rect *                 digitizerRect)                      FIVEWORDINLINE(0x2F3C, 0x0004, 0x0004, 0x7000, 0xA82A);
  317. EXTERN_API( VideoDigitizerError )
  318. VDGetVBlankRect                 (VideoDigitizerComponent  ci,
  319.                                  short                  inputStd,
  320.                                  Rect *                 vBlankRect)                         FIVEWORDINLINE(0x2F3C, 0x0006, 0x0005, 0x7000, 0xA82A);
  321. EXTERN_API( VideoDigitizerError )
  322. VDGetMaskPixMap                 (VideoDigitizerComponent  ci,
  323.                                  PixMapHandle           maskPixMap)                         FIVEWORDINLINE(0x2F3C, 0x0004, 0x0006, 0x7000, 0xA82A);
  324. EXTERN_API( VideoDigitizerError )
  325. VDGetPlayThruDestination        (VideoDigitizerComponent  ci,
  326.                                  PixMapHandle *         dest,
  327.                                  Rect *                 destRect,
  328.                                  MatrixRecord *         m,
  329.                                  RgnHandle *            mask)                               FIVEWORDINLINE(0x2F3C, 0x0010, 0x0008, 0x7000, 0xA82A);
  330. EXTERN_API( VideoDigitizerError )
  331. VDUseThisCLUT                   (VideoDigitizerComponent  ci,
  332.                                  CTabHandle             colorTableHandle)                   FIVEWORDINLINE(0x2F3C, 0x0004, 0x0009, 0x7000, 0xA82A);
  333. EXTERN_API( VideoDigitizerError )
  334. VDSetInputGammaValue            (VideoDigitizerComponent  ci,
  335.                                  Fixed                  channel1,
  336.                                  Fixed                  channel2,
  337.                                  Fixed                  channel3)                           FIVEWORDINLINE(0x2F3C, 0x000C, 0x000A, 0x7000, 0xA82A);
  338. EXTERN_API( VideoDigitizerError )
  339. VDGetInputGammaValue            (VideoDigitizerComponent  ci,
  340.                                  Fixed *                channel1,
  341.                                  Fixed *                channel2,
  342.                                  Fixed *                channel3)                           FIVEWORDINLINE(0x2F3C, 0x000C, 0x000B, 0x7000, 0xA82A);
  343. EXTERN_API( VideoDigitizerError )
  344. VDSetBrightness                 (VideoDigitizerComponent  ci,
  345.                                  unsigned short *       brightness)                         FIVEWORDINLINE(0x2F3C, 0x0004, 0x000C, 0x7000, 0xA82A);
  346. EXTERN_API( VideoDigitizerError )
  347. VDGetBrightness                 (VideoDigitizerComponent  ci,
  348.                                  unsigned short *       brightness)                         FIVEWORDINLINE(0x2F3C, 0x0004, 0x000D, 0x7000, 0xA82A);
  349. EXTERN_API( VideoDigitizerError )
  350. VDSetContrast                   (VideoDigitizerComponent  ci,
  351.                                  unsigned short *       contrast)                           FIVEWORDINLINE(0x2F3C, 0x0004, 0x000E, 0x7000, 0xA82A);
  352. EXTERN_API( VideoDigitizerError )
  353. VDSetHue                        (VideoDigitizerComponent  ci,
  354.                                  unsigned short *       hue)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x000F, 0x7000, 0xA82A);
  355. EXTERN_API( VideoDigitizerError )
  356. VDSetSharpness                  (VideoDigitizerComponent  ci,
  357.                                  unsigned short *       sharpness)                          FIVEWORDINLINE(0x2F3C, 0x0004, 0x0010, 0x7000, 0xA82A);
  358. EXTERN_API( VideoDigitizerError )
  359. VDSetSaturation                 (VideoDigitizerComponent  ci,
  360.                                  unsigned short *       saturation)                         FIVEWORDINLINE(0x2F3C, 0x0004, 0x0011, 0x7000, 0xA82A);
  361. EXTERN_API( VideoDigitizerError )
  362. VDGetContrast                   (VideoDigitizerComponent  ci,
  363.                                  unsigned short *       contrast)                           FIVEWORDINLINE(0x2F3C, 0x0004, 0x0012, 0x7000, 0xA82A);
  364. EXTERN_API( VideoDigitizerError )
  365. VDGetHue                        (VideoDigitizerComponent  ci,
  366.                                  unsigned short *       hue)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x0013, 0x7000, 0xA82A);
  367. EXTERN_API( VideoDigitizerError )
  368. VDGetSharpness                  (VideoDigitizerComponent  ci,
  369.                                  unsigned short *       sharpness)                          FIVEWORDINLINE(0x2F3C, 0x0004, 0x0014, 0x7000, 0xA82A);
  370. EXTERN_API( VideoDigitizerError )
  371. VDGetSaturation                 (VideoDigitizerComponent  ci,
  372.                                  unsigned short *       saturation)                         FIVEWORDINLINE(0x2F3C, 0x0004, 0x0015, 0x7000, 0xA82A);
  373. EXTERN_API( VideoDigitizerError )
  374. VDGrabOneFrame                  (VideoDigitizerComponent  ci)                               FIVEWORDINLINE(0x2F3C, 0x0000, 0x0016, 0x7000, 0xA82A);
  375. EXTERN_API( VideoDigitizerError )
  376. VDGetMaxAuxBuffer               (VideoDigitizerComponent  ci,
  377.                                  PixMapHandle *         pm,
  378.                                  Rect *                 r)                                  FIVEWORDINLINE(0x2F3C, 0x0008, 0x0017, 0x7000, 0xA82A);
  379. EXTERN_API( VideoDigitizerError )
  380. VDGetDigitizerInfo              (VideoDigitizerComponent  ci,
  381.                                  DigitizerInfo *        info)                               FIVEWORDINLINE(0x2F3C, 0x0004, 0x0019, 0x7000, 0xA82A);
  382. EXTERN_API( VideoDigitizerError )
  383. VDGetCurrentFlags               (VideoDigitizerComponent  ci,
  384.                                  long *                 inputCurrentFlag,
  385.                                  long *                 outputCurrentFlag)                  FIVEWORDINLINE(0x2F3C, 0x0008, 0x001A, 0x7000, 0xA82A);
  386. EXTERN_API( VideoDigitizerError )
  387. VDSetKeyColor                   (VideoDigitizerComponent  ci,
  388.                                  long                   index)                              FIVEWORDINLINE(0x2F3C, 0x0004, 0x001B, 0x7000, 0xA82A);
  389. EXTERN_API( VideoDigitizerError )
  390. VDGetKeyColor                   (VideoDigitizerComponent  ci,
  391.                                  long *                 index)                              FIVEWORDINLINE(0x2F3C, 0x0004, 0x001C, 0x7000, 0xA82A);
  392. EXTERN_API( VideoDigitizerError )
  393. VDAddKeyColor                   (VideoDigitizerComponent  ci,
  394.                                  long *                 index)                              FIVEWORDINLINE(0x2F3C, 0x0004, 0x001D, 0x7000, 0xA82A);
  395. EXTERN_API( VideoDigitizerError )
  396. VDGetNextKeyColor               (VideoDigitizerComponent  ci,
  397.                                  long                   index)                              FIVEWORDINLINE(0x2F3C, 0x0004, 0x001E, 0x7000, 0xA82A);
  398. EXTERN_API( VideoDigitizerError )
  399. VDSetKeyColorRange              (VideoDigitizerComponent  ci,
  400.                                  RGBColor *             minRGB,
  401.                                  RGBColor *             maxRGB)                             FIVEWORDINLINE(0x2F3C, 0x0008, 0x001F, 0x7000, 0xA82A);
  402. EXTERN_API( VideoDigitizerError )
  403. VDGetKeyColorRange              (VideoDigitizerComponent  ci,
  404.                                  RGBColor *             minRGB,
  405.                                  RGBColor *             maxRGB)                             FIVEWORDINLINE(0x2F3C, 0x0008, 0x0020, 0x7000, 0xA82A);
  406. EXTERN_API( VideoDigitizerError )
  407. VDSetDigitizerUserInterrupt     (VideoDigitizerComponent  ci,
  408.                                  long                   flags,
  409.                                  VdigIntUPP             userInterruptProc,
  410.                                  long                   refcon)                             FIVEWORDINLINE(0x2F3C, 0x000C, 0x0021, 0x7000, 0xA82A);
  411. EXTERN_API( VideoDigitizerError )
  412. VDSetInputColorSpaceMode        (VideoDigitizerComponent  ci,
  413.                                  short                  colorSpaceMode)                     FIVEWORDINLINE(0x2F3C, 0x0002, 0x0022, 0x7000, 0xA82A);
  414. EXTERN_API( VideoDigitizerError )
  415. VDGetInputColorSpaceMode        (VideoDigitizerComponent  ci,
  416.                                  short *                colorSpaceMode)                     FIVEWORDINLINE(0x2F3C, 0x0004, 0x0023, 0x7000, 0xA82A);
  417. EXTERN_API( VideoDigitizerError )
  418. VDSetClipState                  (VideoDigitizerComponent  ci,
  419.                                  short                  clipEnable)                         FIVEWORDINLINE(0x2F3C, 0x0002, 0x0024, 0x7000, 0xA82A);
  420. EXTERN_API( VideoDigitizerError )
  421. VDGetClipState                  (VideoDigitizerComponent  ci,
  422.                                  short *                clipEnable)                         FIVEWORDINLINE(0x2F3C, 0x0004, 0x0025, 0x7000, 0xA82A);
  423. EXTERN_API( VideoDigitizerError )
  424. VDSetClipRgn                    (VideoDigitizerComponent  ci,
  425.                                  RgnHandle              clipRegion)                         FIVEWORDINLINE(0x2F3C, 0x0004, 0x0026, 0x7000, 0xA82A);
  426. EXTERN_API( VideoDigitizerError )
  427. VDClearClipRgn                  (VideoDigitizerComponent  ci,
  428.                                  RgnHandle              clipRegion)                         FIVEWORDINLINE(0x2F3C, 0x0004, 0x0027, 0x7000, 0xA82A);
  429. EXTERN_API( VideoDigitizerError )
  430. VDGetCLUTInUse                  (VideoDigitizerComponent  ci,
  431.                                  CTabHandle *           colorTableHandle)                   FIVEWORDINLINE(0x2F3C, 0x0004, 0x0028, 0x7000, 0xA82A);
  432. EXTERN_API( VideoDigitizerError )
  433. VDSetPLLFilterType              (VideoDigitizerComponent  ci,
  434.                                  short                  pllType)                            FIVEWORDINLINE(0x2F3C, 0x0002, 0x0029, 0x7000, 0xA82A);
  435. EXTERN_API( VideoDigitizerError )
  436. VDGetPLLFilterType              (VideoDigitizerComponent  ci,
  437.                                  short *                pllType)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x002A, 0x7000, 0xA82A);
  438. EXTERN_API( VideoDigitizerError )
  439. VDGetMaskandValue               (VideoDigitizerComponent  ci,
  440.                                  unsigned short         blendLevel,
  441.                                  long *                 mask,
  442.                                  long *                 value)                              FIVEWORDINLINE(0x2F3C, 0x000A, 0x002B, 0x7000, 0xA82A);
  443. EXTERN_API( VideoDigitizerError )
  444. VDSetMasterBlendLevel           (VideoDigitizerComponent  ci,
  445.                                  unsigned short *       blendLevel)                         FIVEWORDINLINE(0x2F3C, 0x0004, 0x002C, 0x7000, 0xA82A);
  446. EXTERN_API( VideoDigitizerError )
  447. VDSetPlayThruDestination        (VideoDigitizerComponent  ci,
  448.                                  PixMapHandle           dest,
  449.                                  RectPtr                destRect,
  450.                                  MatrixRecordPtr        m,
  451.                                  RgnHandle              mask)                               FIVEWORDINLINE(0x2F3C, 0x0010, 0x002D, 0x7000, 0xA82A);
  452. EXTERN_API( VideoDigitizerError )
  453. VDSetPlayThruOnOff              (VideoDigitizerComponent  ci,
  454.                                  short                  state)                              FIVEWORDINLINE(0x2F3C, 0x0002, 0x002E, 0x7000, 0xA82A);
  455. EXTERN_API( VideoDigitizerError )
  456. VDSetFieldPreference            (VideoDigitizerComponent  ci,
  457.                                  short                  fieldFlag)                          FIVEWORDINLINE(0x2F3C, 0x0002, 0x002F, 0x7000, 0xA82A);
  458. EXTERN_API( VideoDigitizerError )
  459. VDGetFieldPreference            (VideoDigitizerComponent  ci,
  460.                                  short *                fieldFlag)                          FIVEWORDINLINE(0x2F3C, 0x0004, 0x0030, 0x7000, 0xA82A);
  461. EXTERN_API( VideoDigitizerError )
  462. VDPreflightDestination          (VideoDigitizerComponent  ci,
  463.                                  Rect *                 digitizerRect,
  464.                                  PixMap **              dest,
  465.                                  RectPtr                destRect,
  466.                                  MatrixRecordPtr        m)                                  FIVEWORDINLINE(0x2F3C, 0x0010, 0x0032, 0x7000, 0xA82A);
  467. EXTERN_API( VideoDigitizerError )
  468. VDPreflightGlobalRect           (VideoDigitizerComponent  ci,
  469.                                  GrafPtr                theWindow,
  470.                                  Rect *                 globalRect)                         FIVEWORDINLINE(0x2F3C, 0x0008, 0x0033, 0x7000, 0xA82A);
  471. EXTERN_API( VideoDigitizerError )
  472. VDSetPlayThruGlobalRect         (VideoDigitizerComponent  ci,
  473.                                  GrafPtr                theWindow,
  474.                                  Rect *                 globalRect)                         FIVEWORDINLINE(0x2F3C, 0x0008, 0x0034, 0x7000, 0xA82A);
  475. EXTERN_API( VideoDigitizerError )
  476. VDSetInputGammaRecord           (VideoDigitizerComponent  ci,
  477.                                  VDGamRecPtr            inputGammaPtr)                      FIVEWORDINLINE(0x2F3C, 0x0004, 0x0035, 0x7000, 0xA82A);
  478. EXTERN_API( VideoDigitizerError )
  479. VDGetInputGammaRecord           (VideoDigitizerComponent  ci,
  480.                                  VDGamRecPtr *          inputGammaPtr)                      FIVEWORDINLINE(0x2F3C, 0x0004, 0x0036, 0x7000, 0xA82A);
  481. EXTERN_API( VideoDigitizerError )
  482. VDSetBlackLevelValue            (VideoDigitizerComponent  ci,
  483.                                  unsigned short *       blackLevel)                         FIVEWORDINLINE(0x2F3C, 0x0004, 0x0037, 0x7000, 0xA82A);
  484. EXTERN_API( VideoDigitizerError )
  485. VDGetBlackLevelValue            (VideoDigitizerComponent  ci,
  486.                                  unsigned short *       blackLevel)                         FIVEWORDINLINE(0x2F3C, 0x0004, 0x0038, 0x7000, 0xA82A);
  487. EXTERN_API( VideoDigitizerError )
  488. VDSetWhiteLevelValue            (VideoDigitizerComponent  ci,
  489.                                  unsigned short *       whiteLevel)                         FIVEWORDINLINE(0x2F3C, 0x0004, 0x0039, 0x7000, 0xA82A);
  490. EXTERN_API( VideoDigitizerError )
  491. VDGetWhiteLevelValue            (VideoDigitizerComponent  ci,
  492.                                  unsigned short *       whiteLevel)                         FIVEWORDINLINE(0x2F3C, 0x0004, 0x003A, 0x7000, 0xA82A);
  493. EXTERN_API( VideoDigitizerError )
  494. VDGetVideoDefaults              (VideoDigitizerComponent  ci,
  495.                                  unsigned short *       blackLevel,
  496.                                  unsigned short *       whiteLevel,
  497.                                  unsigned short *       brightness,
  498.                                  unsigned short *       hue,
  499.                                  unsigned short *       saturation,
  500.                                  unsigned short *       contrast,
  501.                                  unsigned short *       sharpness)                          FIVEWORDINLINE(0x2F3C, 0x001C, 0x003B, 0x7000, 0xA82A);
  502. EXTERN_API( VideoDigitizerError )
  503. VDGetNumberOfInputs             (VideoDigitizerComponent  ci,
  504.                                  short *                inputs)                             FIVEWORDINLINE(0x2F3C, 0x0004, 0x003C, 0x7000, 0xA82A);
  505. EXTERN_API( VideoDigitizerError )
  506. VDGetInputFormat                (VideoDigitizerComponent  ci,
  507.                                  short                  input,
  508.                                  short *                format)                             FIVEWORDINLINE(0x2F3C, 0x0006, 0x003D, 0x7000, 0xA82A);
  509. EXTERN_API( VideoDigitizerError )
  510. VDSetInput                      (VideoDigitizerComponent  ci,
  511.                                  short                  input)                              FIVEWORDINLINE(0x2F3C, 0x0002, 0x003E, 0x7000, 0xA82A);
  512. EXTERN_API( VideoDigitizerError )
  513. VDGetInput                      (VideoDigitizerComponent  ci,
  514.                                  short *                input)                              FIVEWORDINLINE(0x2F3C, 0x0004, 0x003F, 0x7000, 0xA82A);
  515. EXTERN_API( VideoDigitizerError )
  516. VDSetInputStandard              (VideoDigitizerComponent  ci,
  517.                                  short                  inputStandard)                      FIVEWORDINLINE(0x2F3C, 0x0002, 0x0040, 0x7000, 0xA82A);
  518. EXTERN_API( VideoDigitizerError )
  519. VDSetupBuffers                  (VideoDigitizerComponent  ci,
  520.                                  VdigBufferRecListHandle  bufferList)                       FIVEWORDINLINE(0x2F3C, 0x0004, 0x0041, 0x7000, 0xA82A);
  521. EXTERN_API( VideoDigitizerError )
  522. VDGrabOneFrameAsync             (VideoDigitizerComponent  ci,
  523.                                  short                  buffer)                             FIVEWORDINLINE(0x2F3C, 0x0002, 0x0042, 0x7000, 0xA82A);
  524. EXTERN_API( VideoDigitizerError )
  525. VDDone                          (VideoDigitizerComponent  ci,
  526.                                  short                  buffer)                             FIVEWORDINLINE(0x2F3C, 0x0002, 0x0043, 0x7000, 0xA82A);
  527. EXTERN_API( VideoDigitizerError )
  528. VDSetCompression                (VideoDigitizerComponent  ci,
  529.                                  OSType                 compressType,
  530.                                  short                  depth,
  531.                                  Rect *                 bounds,
  532.                                  CodecQ                 spatialQuality,
  533.                                  CodecQ                 temporalQuality,
  534.                                  long                   keyFrameRate)                       FIVEWORDINLINE(0x2F3C, 0x0016, 0x0044, 0x7000, 0xA82A);
  535. EXTERN_API( VideoDigitizerError )
  536. VDCompressOneFrameAsync         (VideoDigitizerComponent  ci)                               FIVEWORDINLINE(0x2F3C, 0x0000, 0x0045, 0x7000, 0xA82A);
  537. /*    Note that UInt8* queuedFrameCount replaces Boolean* done. 0(==false) still means no frames, and 1(==true) one, 
  538.     but if more than one are available the number should be returned here. The value 2 previously meant more than one frame,
  539.     so some VDIGs may return 2 even if more than 2 are available, and some will still return 1 as they are using the original definition */
  540. EXTERN_API( VideoDigitizerError )
  541. VDCompressDone                  (VideoDigitizerComponent  ci,
  542.                                  UInt8 *                queuedFrameCount,
  543.                                  Ptr *                  theData,
  544.                                  long *                 dataSize,
  545.                                  UInt8 *                similarity,
  546.                                  TimeRecord *           t)                                  FIVEWORDINLINE(0x2F3C, 0x0014, 0x0046, 0x7000, 0xA82A);
  547. EXTERN_API( VideoDigitizerError )
  548. VDReleaseCompressBuffer         (VideoDigitizerComponent  ci,
  549.                                  Ptr                    bufferAddr)                         FIVEWORDINLINE(0x2F3C, 0x0004, 0x0047, 0x7000, 0xA82A);
  550. EXTERN_API( VideoDigitizerError )
  551. VDGetImageDescription           (VideoDigitizerComponent  ci,
  552.                                  ImageDescriptionHandle  desc)                              FIVEWORDINLINE(0x2F3C, 0x0004, 0x0048, 0x7000, 0xA82A);
  553. EXTERN_API( VideoDigitizerError )
  554. VDResetCompressSequence         (VideoDigitizerComponent  ci)                               FIVEWORDINLINE(0x2F3C, 0x0000, 0x0049, 0x7000, 0xA82A);
  555. EXTERN_API( VideoDigitizerError )
  556. VDSetCompressionOnOff           (VideoDigitizerComponent  ci,
  557.                                  Boolean                state)                              FIVEWORDINLINE(0x2F3C, 0x0002, 0x004A, 0x7000, 0xA82A);
  558. EXTERN_API( VideoDigitizerError )
  559. VDGetCompressionTypes           (VideoDigitizerComponent  ci,
  560.                                  VDCompressionListHandle  h)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x004B, 0x7000, 0xA82A);
  561. EXTERN_API( VideoDigitizerError )
  562. VDSetTimeBase                   (VideoDigitizerComponent  ci,
  563.                                  TimeBase               t)                                  FIVEWORDINLINE(0x2F3C, 0x0004, 0x004C, 0x7000, 0xA82A);
  564. EXTERN_API( VideoDigitizerError )
  565. VDSetFrameRate                  (VideoDigitizerComponent  ci,
  566.                                  Fixed                  framesPerSecond)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x004D, 0x7000, 0xA82A);
  567. EXTERN_API( VideoDigitizerError )
  568. VDGetDataRate                   (VideoDigitizerComponent  ci,
  569.                                  long *                 milliSecPerFrame,
  570.                                  Fixed *                framesPerSecond,
  571.                                  long *                 bytesPerSecond)                     FIVEWORDINLINE(0x2F3C, 0x000C, 0x004E, 0x7000, 0xA82A);
  572. EXTERN_API( VideoDigitizerError )
  573. VDGetSoundInputDriver           (VideoDigitizerComponent  ci,
  574.                                  Str255                 soundDriverName)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x004F, 0x7000, 0xA82A);
  575. EXTERN_API( VideoDigitizerError )
  576. VDGetDMADepths                  (VideoDigitizerComponent  ci,
  577.                                  long *                 depthArray,
  578.                                  long *                 preferredDepth)                     FIVEWORDINLINE(0x2F3C, 0x0008, 0x0050, 0x7000, 0xA82A);
  579. EXTERN_API( VideoDigitizerError )
  580. VDGetPreferredTimeScale         (VideoDigitizerComponent  ci,
  581.                                  TimeScale *            preferred)                          FIVEWORDINLINE(0x2F3C, 0x0004, 0x0051, 0x7000, 0xA82A);
  582. EXTERN_API( VideoDigitizerError )
  583. VDReleaseAsyncBuffers           (VideoDigitizerComponent  ci)                               FIVEWORDINLINE(0x2F3C, 0x0000, 0x0052, 0x7000, 0xA82A);
  584. /* 83 is reserved for compatibility reasons */
  585. EXTERN_API( VideoDigitizerError )
  586. VDSetDataRate                   (VideoDigitizerComponent  ci,
  587.                                  long                   bytesPerSecond)                     FIVEWORDINLINE(0x2F3C, 0x0004, 0x0054, 0x7000, 0xA82A);
  588. EXTERN_API( VideoDigitizerError )
  589. VDGetTimeCode                   (VideoDigitizerComponent  ci,
  590.                                  TimeRecord *           atTime,
  591.                                  void *                 timeCodeFormat,
  592.                                  void *                 timeCodeTime)                       FIVEWORDINLINE(0x2F3C, 0x000C, 0x0055, 0x7000, 0xA82A);
  593. EXTERN_API( VideoDigitizerError )
  594. VDUseSafeBuffers                (VideoDigitizerComponent  ci,
  595.                                  Boolean                useSafeBuffers)                     FIVEWORDINLINE(0x2F3C, 0x0002, 0x0056, 0x7000, 0xA82A);
  596. EXTERN_API( VideoDigitizerError )
  597. VDGetSoundInputSource           (VideoDigitizerComponent  ci,
  598.                                  long                   videoInput,
  599.                                  long *                 soundInput)                         FIVEWORDINLINE(0x2F3C, 0x0008, 0x0057, 0x7000, 0xA82A);
  600. EXTERN_API( VideoDigitizerError )
  601. VDGetCompressionTime            (VideoDigitizerComponent  ci,
  602.                                  OSType                 compressionType,
  603.                                  short                  depth,
  604.                                  Rect *                 srcRect,
  605.                                  CodecQ *               spatialQuality,
  606.                                  CodecQ *               temporalQuality,
  607.                                  unsigned long *        compressTime)                       FIVEWORDINLINE(0x2F3C, 0x0016, 0x0058, 0x7000, 0xA82A);
  608. EXTERN_API( VideoDigitizerError )
  609. VDSetPreferredPacketSize        (VideoDigitizerComponent  ci,
  610.                                  long                   preferredPacketSizeInBytes)         FIVEWORDINLINE(0x2F3C, 0x0004, 0x0059, 0x7000, 0xA82A);
  611. EXTERN_API( VideoDigitizerError )
  612. VDSetPreferredImageDimensions   (VideoDigitizerComponent  ci,
  613.                                  long                   width,
  614.                                  long                   height)                             FIVEWORDINLINE(0x2F3C, 0x0008, 0x005A, 0x7000, 0xA82A);
  615. EXTERN_API( VideoDigitizerError )
  616. VDGetPreferredImageDimensions   (VideoDigitizerComponent  ci,
  617.                                  long *                 width,
  618.                                  long *                 height)                             FIVEWORDINLINE(0x2F3C, 0x0008, 0x005B, 0x7000, 0xA82A);
  619. EXTERN_API( VideoDigitizerError )
  620. VDGetInputName                  (VideoDigitizerComponent  ci,
  621.                                  long                   videoInput,
  622.                                  Str255                 name)                               FIVEWORDINLINE(0x2F3C, 0x0008, 0x005C, 0x7000, 0xA82A);
  623. EXTERN_API( VideoDigitizerError )
  624. VDSetDestinationPort            (VideoDigitizerComponent  ci,
  625.                                  CGrafPtr               destPort)                           FIVEWORDINLINE(0x2F3C, 0x0004, 0x005D, 0x7000, 0xA82A);
  626. /*
  627.    The following call is designed to give the VDIG a little more control over how it is presented to the User, to clarify the 
  628.    distinction between Devices and Inputs. Historically, the assumption has been that there is one component registered per device
  629.    and the component name is displayed. This change lets a component choose its name after registration.
  630.    vdDeviceFlagShowInputsAsDevices is meant for components that register once and support multiple devices 
  631.    The UI is clearer if these are presented as device rather than inputs, 
  632.    and this allows a VDIG to present itself this way without huge restructuring
  633.    vdDeviceFlagHideDevice is for the kind of VDIG that registers itself, and then can register a further VDIG for each device. 
  634.    If no hardware is available, returning this flag will omit it from the list. 
  635.    This call being made is also a good time to check for hardware and register further VDIG components if needed, 
  636.    allowing for lazy initialization when the Application needs to find a VDIG rather than on every launch or replug.
  637. */
  638. enum {
  639.     vdDeviceFlagShowInputsAsDevices = (1 << 0),                 /* Tell the Panel to promote Inputs to Devices*/
  640.     vdDeviceFlagHideDevice      = (1 << 1)                      /* Omit this Device entirely from the list*/
  641. };
  642. EXTERN_API( VideoDigitizerError )
  643. VDGetDeviceNameAndFlags         (VideoDigitizerComponent  ci,
  644.                                  Str255                 outName,
  645.                                  UInt32 *               outNameFlags)                       FIVEWORDINLINE(0x2F3C, 0x0008, 0x005E, 0x7000, 0xA82A);
  646. enum {
  647.     vdFlagCaptureStarting       = (1 << 0),                     /* Capture is about to start; allocate bandwidth */
  648.     vdFlagCaptureStopping       = (1 << 1),                     /* Capture is about to stop; stop queuing frames*/
  649.     vdFlagCaptureIsForPreview   = (1 << 2),                     /* Capture is just to screen for preview purposes*/
  650.     vdFlagCaptureIsForRecord    = (1 << 3),                     /* Capture is going to be recorded*/
  651.     vdFlagCaptureLowLatency     = (1 << 4),                     /* Fresh frames are more important than delivering every frame - don't queue too much*/
  652.     vdFlagCaptureAlwaysUseTimeBase = (1 << 5),                  /* Use the timebase for every frame; don't worry about making durations uniform*/
  653.     vdFlagCaptureSetSettingsBegin = (1 << 6),                   /* A series of calls are about to be made to restore settings.*/
  654.     vdFlagCaptureSetSettingsEnd = (1 << 7)                      /* Finished restoring settings; any set calls after this are from the app or UI*/
  655. };
  656. EXTERN_API( VideoDigitizerError )
  657. VDCaptureStateChanging          (VideoDigitizerComponent  ci,
  658.                                  UInt32                 inStateFlags)                       FIVEWORDINLINE(0x2F3C, 0x0004, 0x005F, 0x7000, 0xA82A);
  659. /*
  660.    These UniqueID calls are so that the VDIG can give the SG information enabling it to restore a particular
  661.    configuration - choose a particular device and input from those available.
  662.    For example, restoring the specific camera for a set of several hot-plugged FireWire cameras 
  663.    the caller can pass nil if it is not interested in one of the IDs
  664.    returning 0 in an ID means you don't have one
  665. */
  666. EXTERN_API( VideoDigitizerError )
  667. VDGetUniqueIDs                  (VideoDigitizerComponent  ci,
  668.                                  UInt64 *               outDeviceID,
  669.                                  UInt64 *               outInputID)                         FIVEWORDINLINE(0x2F3C, 0x0008, 0x0060, 0x7000, 0xA82A);
  670. /*
  671.    Note this is a 'Select' not a 'Set' - the assumption is that the Unique ID is a function of the hardware
  672.    and not modifiable by the calling application. Either a nil pointer or 0 an the ID means don't care.
  673.    return vdDontHaveThatUniqueIDErr if your device doesn't have a match.
  674. */
  675. EXTERN_API( VideoDigitizerError )
  676. VDSelectUniqueIDs               (VideoDigitizerComponent  ci,
  677.                                  const UInt64 *         inDeviceID,
  678.                                  const UInt64 *         inInputID)                          FIVEWORDINLINE(0x2F3C, 0x0008, 0x0061, 0x7000, 0xA82A);
  679. /*
  680.    IIDC (Instrumentation & Industrial Digital Camera) Video Digitizers
  681.    Video Digitizers of subtype vdSubtypeIIDC support FireWire cameras which conform to the
  682.    "IIDC 1394-based Digital Camera Specification." 
  683. */
  684. enum {
  685.     vdSubtypeIIDC               = FOUR_CHAR_CODE('iidc')        /* Subtype for IIDC 1394-Digital Camera video digitizer*/
  686. };
  687. /*
  688.    vdIIDCAtomTypeFeature
  689.    Parent node for the QTAtoms which describe a given feature.  
  690. */
  691. enum {
  692.     vdIIDCAtomTypeFeature       = FOUR_CHAR_CODE('feat')
  693. };
  694. /*
  695.    vdIIDCAtomTypeFeatureAtomTypeAndID
  696.    This atom describes the feature's OSType/group/name and QTAtomType & QTAtomID needed to retrieve its settings.
  697.    The contents of this atom is a VDIIDCFeatureAtomTypeAndID structure.  
  698. */
  699. enum {
  700.     vdIIDCAtomTypeFeatureAtomTypeAndID = FOUR_CHAR_CODE('t&id'),
  701.     vdIIDCAtomIDFeatureAtomTypeAndID = 1
  702. };
  703. struct VDIIDCFeatureAtomTypeAndID {
  704.     OSType                          feature;                    /* OSType of feature*/
  705.     OSType                          group;                      /* OSType of group that feature is categorized into*/
  706.     Str255                          name;                       /* Name of this feature*/
  707.     QTAtomType                      atomType;                   /* Atom type which contains feature's settings*/
  708.     QTAtomID                        atomID;                     /* Atom ID which contains feature's settings*/
  709. };
  710. typedef struct VDIIDCFeatureAtomTypeAndID VDIIDCFeatureAtomTypeAndID;
  711. /* IIDC Feature OSTypes*/
  712. enum {
  713.     vdIIDCFeatureHue            = FOUR_CHAR_CODE('hue '),       /* Feature's settings handled by VDIIDCFeatureSettings*/
  714.     vdIIDCFeatureSaturation     = FOUR_CHAR_CODE('satu'),       /* Feature's settings handled by VDIIDCFeatureSettings*/
  715.     vdIIDCFeatureContrast       = FOUR_CHAR_CODE('ctst'),       /* Feature's settings handled by VDIIDCFeatureSettings*/
  716.     vdIIDCFeatureSharpness      = FOUR_CHAR_CODE('shrp'),       /* Feature's settings handled by VDIIDCFeatureSettings*/
  717.     vdIIDCFeatureBlackLevel     = FOUR_CHAR_CODE('blvl'),       /* Feature's settings handled by VDIIDCFeatureSettings*/
  718.     vdIIDCFeatureGain           = FOUR_CHAR_CODE('gain'),       /* Feature's settings handled by VDIIDCFeatureSettings*/
  719.     vdIIDCFeatureIris           = FOUR_CHAR_CODE('iris'),       /* Feature's settings handled by VDIIDCFeatureSettings*/
  720.     vdIIDCFeatureShutter        = FOUR_CHAR_CODE('shtr'),       /* Feature's settings handled by VDIIDCFeatureSettings*/
  721.     vdIIDCFeatureExposure       = FOUR_CHAR_CODE('xpsr'),       /* Feature's settings handled by VDIIDCFeatureSettings*/
  722.     vdIIDCFeatureWhiteBalanceU  = FOUR_CHAR_CODE('whbu'),       /* Feature's settings handled by VDIIDCFeatureSettings*/
  723.     vdIIDCFeatureWhiteBalanceV  = FOUR_CHAR_CODE('whbv'),       /* Feature's settings handled by VDIIDCFeatureSettings*/
  724.     vdIIDCFeatureGamma          = FOUR_CHAR_CODE('gmma'),       /* Feature's settings handled by VDIIDCFeatureSettings*/
  725.     vdIIDCFeatureTemperature    = FOUR_CHAR_CODE('temp'),       /* Feature's settings handled by VDIIDCFeatureSettings*/
  726.     vdIIDCFeatureZoom           = FOUR_CHAR_CODE('zoom'),       /* Feature's settings handled by VDIIDCFeatureSettings*/
  727.     vdIIDCFeatureFocus          = FOUR_CHAR_CODE('fcus'),       /* Feature's settings handled by VDIIDCFeatureSettings*/
  728.     vdIIDCFeaturePan            = FOUR_CHAR_CODE('pan '),       /* Feature's settings handled by VDIIDCFeatureSettings*/
  729.     vdIIDCFeatureTilt           = FOUR_CHAR_CODE('tilt'),       /* Feature's settings handled by VDIIDCFeatureSettings*/
  730.     vdIIDCFeatureOpticalFilter  = FOUR_CHAR_CODE('opft'),       /* Feature's settings handled by VDIIDCFeatureSettings*/
  731.     vdIIDCFeatureTrigger        = FOUR_CHAR_CODE('trgr'),       /* Trigger's setttings handled by VDIIDCTriggerSettings*/
  732.     vdIIDCFeatureCaptureSize    = FOUR_CHAR_CODE('cpsz'),       /* Feature's settings is not defined*/
  733.     vdIIDCFeatureCaptureQuality = FOUR_CHAR_CODE('cpql')        /* Feature's settings is not defined*/
  734. };
  735. /* IIDC Group OSTypes that features are categorized into*/
  736. enum {
  737.     vdIIDCGroupImage            = FOUR_CHAR_CODE('imag'),       /* Feature related to camera's image*/
  738.     vdIIDCGroupColor            = FOUR_CHAR_CODE('colr'),       /* Feature related to camera's color control*/
  739.     vdIIDCGroupMechanics        = FOUR_CHAR_CODE('mech'),       /* Feature related to camera's mechanics*/
  740.     vdIIDCGroupTrigger          = FOUR_CHAR_CODE('trig')        /* Feature related to camera's trigger*/
  741. };
  742. /*
  743.    vdIIDCAtomTypeFeatureSettings
  744.    This atom describes the settings for the majority of features.
  745.    The contents of this atom is a VDIIDCFeatureSettings structure.
  746. */
  747. enum {
  748.     vdIIDCAtomTypeFeatureSettings = FOUR_CHAR_CODE('fstg'),
  749.     vdIIDCAtomIDFeatureSettings = 1
  750. };
  751. struct VDIIDCFeatureCapabilities {
  752.     UInt32                          flags;
  753.     UInt16                          rawMinimum;
  754.     UInt16                          rawMaximum;
  755.     QTFloatSingle                   absoluteMinimum;
  756.     QTFloatSingle                   absoluteMaximum;
  757. };
  758. typedef struct VDIIDCFeatureCapabilities VDIIDCFeatureCapabilities;
  759. struct VDIIDCFeatureState {
  760.     UInt32                          flags;
  761.     QTFloatSingle                   value;
  762. };
  763. typedef struct VDIIDCFeatureState       VDIIDCFeatureState;
  764. struct VDIIDCFeatureSettings {
  765.     VDIIDCFeatureCapabilities       capabilities;
  766.     VDIIDCFeatureState              state;
  767. };
  768. typedef struct VDIIDCFeatureSettings    VDIIDCFeatureSettings;
  769. /*
  770.    Flags for use in VDIIDCFeatureCapabilities.flags & VDIIDCFeatureState.flags
  771.    When indicating capabilities, the flag being set indicates that the feature can be put into the given state.
  772.    When indicating/setting state, the flag represents the current/desired state.
  773.    Note that certain combinations of flags are valid for cababilities (i.e. vdIIDCFeatureFlagOn | vdIIDCFeatureFlagOff)
  774.    but are mutally exclusive for state.
  775. */
  776. enum {
  777.     vdIIDCFeatureFlagOn         = (1 << 0),
  778.     vdIIDCFeatureFlagOff        = (1 << 1),
  779.     vdIIDCFeatureFlagManual     = (1 << 2),
  780.     vdIIDCFeatureFlagAuto       = (1 << 3),
  781.     vdIIDCFeatureFlagTune       = (1 << 4),
  782.     vdIIDCFeatureFlagRawControl = (1 << 5),
  783.     vdIIDCFeatureFlagAbsoluteControl = (1 << 6)
  784. };
  785. /*
  786.    vdIIDCAtomTypeTriggerSettings
  787.    This atom describes the settings for the trigger feature.
  788.    The contents of this atom is a VDIIDCTriggerSettings structure.
  789. */
  790. enum {
  791.     vdIIDCAtomTypeTriggerSettings = FOUR_CHAR_CODE('tstg'),
  792.     vdIIDCAtomIDTriggerSettings = 1
  793. };
  794. struct VDIIDCTriggerCapabilities {
  795.     UInt32                          flags;
  796.     QTFloatSingle                   absoluteMinimum;
  797.     QTFloatSingle                   absoluteMaximum;
  798. };
  799. typedef struct VDIIDCTriggerCapabilities VDIIDCTriggerCapabilities;
  800. struct VDIIDCTriggerState {
  801.     UInt32                          flags;
  802.     UInt16                          mode2TransitionCount;
  803.     UInt16                          mode3FrameRateMultiplier;
  804.     QTFloatSingle                   absoluteValue;
  805. };
  806. typedef struct VDIIDCTriggerState       VDIIDCTriggerState;
  807. struct VDIIDCTriggerSettings {
  808.     VDIIDCTriggerCapabilities       capabilities;
  809.     VDIIDCTriggerState              state;
  810. };
  811. typedef struct VDIIDCTriggerSettings    VDIIDCTriggerSettings;
  812. /*
  813.    Flags for use in VDIIDCTriggerCapabilities.flags & VDIIDCTriggerState.flags
  814.    When indicating capabilities, the flag being set indicates that the trigger can be put into the given state.
  815.    When indicating/setting state, the flag represents the current/desired state.
  816.    Note that certain combinations of flags are valid for cababilities (i.e. vdIIDCTriggerFlagOn | vdIIDCTriggerFlagOff)
  817.    but are mutally exclusive for state.
  818. */
  819. enum {
  820.     vdIIDCTriggerFlagOn         = (1 << 0),
  821.     vdIIDCTriggerFlagOff        = (1 << 1),
  822.     vdIIDCTriggerFlagActiveHigh = (1 << 2),
  823.     vdIIDCTriggerFlagActiveLow  = (1 << 3),
  824.     vdIIDCTriggerFlagMode0      = (1 << 4),
  825.     vdIIDCTriggerFlagMode1      = (1 << 5),
  826.     vdIIDCTriggerFlagMode2      = (1 << 6),
  827.     vdIIDCTriggerFlagMode3      = (1 << 7),
  828.     vdIIDCTriggerFlagRawControl = (1 << 8),
  829.     vdIIDCTriggerFlagAbsoluteControl = (1 << 9)
  830. };
  831. /*
  832.    VDIIDC calls are additional calls for IIDC digitizers (vdSubtypeIIDC)
  833.    These calls are only valid for video digitizers of subtype vdSubtypeIIDC.
  834. */
  835. EXTERN_API( VideoDigitizerError )
  836. VDIIDCGetFeatures               (VideoDigitizerComponent  ci,
  837.                                  QTAtomContainer *      container)                          FIVEWORDINLINE(0x2F3C, 0x0004, 0x0200, 0x7000, 0xA82A);
  838. EXTERN_API( VideoDigitizerError )
  839. VDIIDCSetFeatures               (VideoDigitizerComponent  ci,
  840.                                  QTAtomContainer        container)                          FIVEWORDINLINE(0x2F3C, 0x0004, 0x0201, 0x7000, 0xA82A);
  841. EXTERN_API( VideoDigitizerError )
  842. VDIIDCGetDefaultFeatures        (VideoDigitizerComponent  ci,
  843.                                  QTAtomContainer *      container)                          FIVEWORDINLINE(0x2F3C, 0x0004, 0x0202, 0x7000, 0xA82A);
  844. EXTERN_API( VideoDigitizerError )
  845. VDIIDCGetCSRData                (VideoDigitizerComponent  ci,
  846.                                  Boolean                offsetFromRegisterBase,
  847.                                  UInt32                 offset,
  848.                                  UInt32 *               data)                               FIVEWORDINLINE(0x2F3C, 0x000A, 0x0203, 0x7000, 0xA82A);
  849. EXTERN_API( VideoDigitizerError )
  850. VDIIDCSetCSRData                (VideoDigitizerComponent  ci,
  851.                                  Boolean                offsetFromRegisterBase,
  852.                                  UInt32                 offset,
  853.                                  UInt32                 data)                               FIVEWORDINLINE(0x2F3C, 0x000A, 0x0204, 0x7000, 0xA82A);
  854. enum {
  855.     xmlParseComponentType       = FOUR_CHAR_CODE('pars'),
  856.     xmlParseComponentSubType    = FOUR_CHAR_CODE('xml ')
  857. };
  858. enum {
  859.     xmlIdentifierInvalid        = 0,
  860.     xmlIdentifierUnrecognized   = (long)0xFFFFFFFF,
  861.     xmlContentTypeInvalid       = 0,
  862.     xmlContentTypeElement       = 1,
  863.     xmlContentTypeCharData      = 2
  864. };
  865. enum {
  866.     elementFlagAlwaysSelfContained = 1L << 0,                   /*    Element doesn't have contents or closing tag even if it doesn't end with />, as in the HTML <img> tag*/
  867.     elementFlagPreserveWhiteSpace = 1L << 1,                    /*  Preserve whitespace in content, default is to remove it */
  868.     xmlParseFlagAllowUppercase  = 1L << 0,                      /*    Entities and attributes do not have to be lowercase (strict XML), but can be upper or mixed case as in HTML*/
  869.     xmlParseFlagAllowUnquotedAttributeValues = 1L << 1,         /*    Attributes values do not have to be enclosed in quotes (strict XML), but can be left unquoted if they contain no spaces*/
  870.     xmlParseFlagEventParseOnly  = 1L << 2                       /*    Do event parsing only*/
  871. };
  872. enum {
  873.     attributeValueKindCharString = 0,
  874.     attributeValueKindInteger   = 1L << 0,                      /*    Number*/
  875.     attributeValueKindPercent   = 1L << 1,                      /*    Number or percent*/
  876.     attributeValueKindBoolean   = 1L << 2,                      /*    "true" or "false"*/
  877.     attributeValueKindOnOff     = 1L << 3,                      /*    "on" or "off"*/
  878.     attributeValueKindColor     = 1L << 4,                      /*    Either "#rrggbb" or a color name*/
  879.     attributeValueKindEnum      = 1L << 5,                      /*    one of a number of strings; the enum strings are passed as a zero-separated, double-zero-terminated C string in the attributeKindValueInfo param*/
  880.     attributeValueKindCaseSensEnum = 1L << 6,                   /*    one of a number of strings; the enum strings are passed as for attributeValueKindEnum, but the values are case-sensitive*/
  881.     MAX_ATTRIBUTE_VALUE_KIND    = attributeValueKindCaseSensEnum
  882. };
  883. enum {
  884.     nameSpaceIDNone             = 0
  885. };
  886. /*  A Parsed XML attribute value, one of number/percent, boolean/on-off, color, or enumerated type*/
  887. union XMLAttributeValue {
  888.     SInt32                          number;                     /*    The value when valueKind is attributeValueKindInteger or attributeValueKindPercent*/
  889.     Boolean                         boolean;                    /*    The value when valueKind is attributeValueKindBoolean or attributeValueKindOnOff*/
  890.     RGBColor                        color;                      /*    The value when valueKind is attributeValueKindColor*/
  891.     UInt32                          enumType;                   /*    The value when valueKind is attributeValueKindEnum*/
  892. };
  893. typedef union XMLAttributeValue         XMLAttributeValue;
  894. /*  An XML attribute-value pair*/
  895. struct XMLAttribute {
  896.     UInt32                          identifier;                 /*    Tokenized identifier, if the attribute name was recognized by the parser*/
  897.     char *                          name;                       /*    Attribute name, Only present if identifier == xmlIdentifierUnrecognized*/
  898.     long                            valueKind;                  /*    Type of parsed value, if the value was recognized and parsed; otherwise, attributeValueKindCharString*/
  899.     XMLAttributeValue               value;                      /*    Parsed attribute value*/
  900.     char *                          valueStr;                   /*    Always present*/
  901. };
  902. typedef struct XMLAttribute             XMLAttribute;
  903. typedef XMLAttribute *                  XMLAttributePtr;
  904. /*  Forward struct declarations for recursively-defined tree structure*/
  905. typedef struct XMLContent               XMLContent;
  906. typedef XMLContent *                    XMLContentPtr;
  907. /*
  908.     An XML Element, i.e.
  909.         <element attr="value" attr="value" ...> [contents] </element>
  910.     or
  911.         <element attr="value" attr="value" .../>
  912. */
  913. struct XMLElement {
  914.     UInt32                          identifier;                 /*    Tokenized identifier, if the element name was recognized by the parser*/
  915.     char *                          name;                       /*    Element name, only present if identifier == xmlIdentifierUnrecognized*/
  916.     XMLAttributePtr                 attributes;                 /*    Array of attributes, terminated with an attribute with identifier == xmlIdentifierInvalid*/
  917.     XMLContentPtr                   contents;                   /*    Array of contents, terminated with a content with kind == xmlIdentifierInvalid*/
  918. };
  919. typedef struct XMLElement               XMLElement;
  920. typedef XMLElement *                    XMLElementPtr;
  921. /*
  922.     The content of an XML element is a series of parts, each of which may be either another element
  923.     or simply character data.
  924. */
  925. union XMLElementContent {
  926.     XMLElement                      element;                    /*    The contents when the content kind is xmlContentTypeElement*/
  927.     char *                          charData;                   /*    The contents when the content kind is xmlContentTypeCharData*/
  928. };
  929. typedef union XMLElementContent         XMLElementContent;
  930. struct XMLContent {
  931.     UInt32                          kind;
  932.     XMLElementContent               actualContent;
  933. };
  934. struct XMLDocRecord {
  935.     void *                          xmlDataStorage;             /*    opaque storage*/
  936.     XMLElement                      rootElement;
  937. };
  938. typedef struct XMLDocRecord             XMLDocRecord;
  939. typedef XMLDocRecord *                  XMLDoc;
  940. /*callback routines for event parsing*/
  941. typedef CALLBACK_API( ComponentResult , StartDocumentHandler )(long refcon);
  942. typedef CALLBACK_API( ComponentResult , EndDocumentHandler )(long refcon);
  943. typedef CALLBACK_API( ComponentResult , StartElementHandler )(const char *name, const char *const atts[], long refcon);
  944. typedef CALLBACK_API( ComponentResult , EndElementHandler )(const char *name, long refcon);
  945. typedef CALLBACK_API( ComponentResult , CharDataHandler )(const char *charData, long refcon);
  946. typedef CALLBACK_API( ComponentResult , PreprocessInstructionHandler )(const char *name, const char *const atts[], long refcon);
  947. typedef CALLBACK_API( ComponentResult , CommentHandler )(const char *comment, long refcon);
  948. typedef CALLBACK_API( ComponentResult , CDataHandler )(const char *cdata, long refcon);
  949. typedef STACK_UPP_TYPE(StartDocumentHandler)                    StartDocumentHandlerUPP;
  950. typedef STACK_UPP_TYPE(EndDocumentHandler)                      EndDocumentHandlerUPP;
  951. typedef STACK_UPP_TYPE(StartElementHandler)                     StartElementHandlerUPP;
  952. typedef STACK_UPP_TYPE(EndElementHandler)                       EndElementHandlerUPP;
  953. typedef STACK_UPP_TYPE(CharDataHandler)                         CharDataHandlerUPP;
  954. typedef STACK_UPP_TYPE(PreprocessInstructionHandler)            PreprocessInstructionHandlerUPP;
  955. typedef STACK_UPP_TYPE(CommentHandler)                          CommentHandlerUPP;
  956. typedef STACK_UPP_TYPE(CDataHandler)                            CDataHandlerUPP;
  957. /*  Parses the XML file pointed to by dataRef, returning a XMLDoc parse tree*/
  958. EXTERN_API( ComponentResult )
  959. XMLParseDataRef                 (ComponentInstance      aParser,
  960.                                  Handle                 dataRef,
  961.                                  OSType                 dataRefType,
  962.                                  long                   parseFlags,
  963.                                  XMLDoc *               document)                           FIVEWORDINLINE(0x2F3C, 0x0010, 0x0001, 0x7000, 0xA82A);
  964. /*  Parses the XML file pointed to by fileSpec, returning a XMLDoc parse tree*/
  965. EXTERN_API( ComponentResult )
  966. XMLParseFile                    (ComponentInstance      aParser,
  967.                                  ConstFSSpecPtr         fileSpec,
  968.                                  long                   parseFlags,
  969.                                  XMLDoc *               document)                           FIVEWORDINLINE(0x2F3C, 0x000C, 0x0002, 0x7000, 0xA82A);
  970. /*  Disposes of a XMLDoc parse tree*/
  971. EXTERN_API( ComponentResult )
  972. XMLParseDisposeXMLDoc           (ComponentInstance      aParser,
  973.                                  XMLDoc                 document)                           FIVEWORDINLINE(0x2F3C, 0x0004, 0x0003, 0x7000, 0xA82A);
  974. /*
  975.     Returns a more detailed description of the error and the line in which it occurred, if a
  976.     file failed to parse properly.
  977. */
  978. EXTERN_API( ComponentResult )
  979. XMLParseGetDetailedParseError   (ComponentInstance      aParser,
  980.                                  long *                 errorLine,
  981.                                  StringPtr              errDesc)                            FIVEWORDINLINE(0x2F3C, 0x0008, 0x0004, 0x7000, 0xA82A);
  982. /*
  983.     Tell the parser of an element to be recognized. The tokenized element unique identifier is
  984.     passed in *elementID, unless *elementID is zero, whereupon a unique ID is generated and returned.
  985.     Thus, a valid element identifier can never be zero.
  986. */
  987. EXTERN_API( ComponentResult )
  988. XMLParseAddElement              (ComponentInstance      aParser,
  989.                                  char *                 elementName,
  990.                                  UInt32                 nameSpaceID,
  991.                                  UInt32 *               elementID,
  992.                                  long                   elementFlags)                       FIVEWORDINLINE(0x2F3C, 0x0010, 0x0005, 0x7000, 0xA82A);
  993. /*
  994.     Tells the parser of an attribute for the specified element. The tokenized attribute unique
  995.     ID is passed in *attributeID, unless *attributeID is zero, whereupon a unique ID is generated and
  996.     returned. Thus, a valid attribute identifier can never be zero.
  997. */
  998. EXTERN_API( ComponentResult )
  999. XMLParseAddAttribute            (ComponentInstance      aParser,
  1000.                                  UInt32                 elementID,
  1001.                                  UInt32                 nameSpaceID,
  1002.                                  char *                 attributeName,
  1003.                                  UInt32 *               attributeID)                        FIVEWORDINLINE(0x2F3C, 0x0010, 0x0006, 0x7000, 0xA82A);
  1004. /*
  1005.     Tells the parser of several attributes for the specified element. The attributes are passed
  1006.     as a zero-delimited, double-zero-terminated C string in attributeNames, and the attribute
  1007.     IDs are passed in on attributeIDs as an array; if any attributeIDs are zero, unique IDs
  1008.     are generated for those and returned
  1009. */
  1010. EXTERN_API( ComponentResult )
  1011. XMLParseAddMultipleAttributes   (ComponentInstance      aParser,
  1012.                                  UInt32                 elementID,
  1013.                                  UInt32 *               nameSpaceIDs,
  1014.                                  char *                 attributeNames,
  1015.                                  UInt32 *               attributeIDs)                       FIVEWORDINLINE(0x2F3C, 0x0010, 0x0007, 0x7000, 0xA82A);
  1016. /*
  1017.     Tells the parser of an attribute, which may have a particular type of value, for the
  1018.     specified element. Params are as in XMLParseAddAttribute, plus all the kinds of values
  1019.     the attribute may have are passed in attributeValueKind, and optional additional information
  1020.     required to tokenize the particular kind of attribute is passed in attributeValueKindInfo
  1021. */
  1022. EXTERN_API( ComponentResult )
  1023. XMLParseAddAttributeAndValue    (ComponentInstance      aParser,
  1024.                                  UInt32                 elementID,
  1025.                                  UInt32                 nameSpaceID,
  1026.                                  char *                 attributeName,
  1027.                                  UInt32 *               attributeID,
  1028.                                  UInt32                 attributeValueKind,
  1029.                                  void *                 attributeValueKindInfo)             FIVEWORDINLINE(0x2F3C, 0x0018, 0x0008, 0x7000, 0xA82A);
  1030. /*
  1031.     Tells the parser of several attributes, which may have a particular type of value, for the
  1032.     specified element. Params are as in XMLParseAddMultipleAttributes, plus all the kinds of values
  1033.     the attributes may have are passed in attributeValueKinds, and optional additional information
  1034.     required to tokenize the particular kind of attributes is passed in attributeValueKindInfos
  1035. */
  1036. EXTERN_API( ComponentResult )
  1037. XMLParseAddMultipleAttributesAndValues (ComponentInstance  aParser,
  1038.                                  UInt32                 elementID,
  1039.                                  UInt32 *               nameSpaceIDs,
  1040.                                  char *                 attributeNames,
  1041.                                  UInt32 *               attributeIDs,
  1042.                                  UInt32 *               attributeValueKinds,
  1043.                                  void **                attributeValueKindInfos)            FIVEWORDINLINE(0x2F3C, 0x0018, 0x0009, 0x7000, 0xA82A);
  1044. /*
  1045.     Tells the parser that the particular attribute may have an additional kind of
  1046.     value, as specified by attributeValueKind and attributeValueKindInfo
  1047. */
  1048. EXTERN_API( ComponentResult )
  1049. XMLParseAddAttributeValueKind   (ComponentInstance      aParser,
  1050.                                  UInt32                 elementID,
  1051.                                  UInt32                 attributeID,
  1052.                                  UInt32                 attributeValueKind,
  1053.                                  void *                 attributeValueKindInfo)             FIVEWORDINLINE(0x2F3C, 0x0010, 0x000A, 0x7000, 0xA82A);
  1054. /*
  1055.     Tell the parser of a namespace to be recognized. The tokenized namespace unique identifier is
  1056.     passed in *nameSpaceID, unless *nameSpaceID is zero, whereupon a unique ID is generated and returned.
  1057.     Thus, a valid nameSpaceID identifier can never be zero.
  1058. */
  1059. EXTERN_API( ComponentResult )
  1060. XMLParseAddNameSpace            (ComponentInstance      aParser,
  1061.                                  char *                 nameSpaceURL,
  1062.                                  UInt32 *               nameSpaceID)                        FIVEWORDINLINE(0x2F3C, 0x0008, 0x000B, 0x7000, 0xA82A);
  1063. /*  Specifies the offset and limit for reading from the dataref to be used when parsing*/
  1064. EXTERN_API( ComponentResult )
  1065. XMLParseSetOffsetAndLimit       (ComponentInstance      aParser,
  1066.                                  UInt32                 offset,
  1067.                                  UInt32                 limit)                              FIVEWORDINLINE(0x2F3C, 0x0008, 0x000C, 0x7000, 0xA82A);
  1068. /*  Set the event parse refcon*/
  1069. EXTERN_API( ComponentResult )
  1070. XMLParseSetEventParseRefCon     (ComponentInstance      aParser,
  1071.                                  long                   refcon)                             FIVEWORDINLINE(0x2F3C, 0x0004, 0x000D, 0x7000, 0xA82A);
  1072. /*  Set the start document handler UPP for event parsing*/
  1073. EXTERN_API( ComponentResult )
  1074. XMLParseSetStartDocumentHandler (ComponentInstance      aParser,
  1075.                                  StartDocumentHandlerUPP  startDocument)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x000E, 0x7000, 0xA82A);
  1076. /*  Set the end document handler UPP for event parsing*/
  1077. EXTERN_API( ComponentResult )
  1078. XMLParseSetEndDocumentHandler   (ComponentInstance      aParser,
  1079.                                  EndDocumentHandlerUPP  endDocument)                        FIVEWORDINLINE(0x2F3C, 0x0004, 0x000F, 0x7000, 0xA82A);
  1080. /*  Set the start element handler UPP for event parsing*/
  1081. EXTERN_API( ComponentResult )
  1082. XMLParseSetStartElementHandler  (ComponentInstance      aParser,
  1083.                                  StartElementHandlerUPP  startElement)                      FIVEWORDINLINE(0x2F3C, 0x0004, 0x0010, 0x7000, 0xA82A);
  1084. /*  Set the end element handler UPP for event parsing*/
  1085. EXTERN_API( ComponentResult )
  1086. XMLParseSetEndElementHandler    (ComponentInstance      aParser,
  1087.                                  EndElementHandlerUPP   endElement)                         FIVEWORDINLINE(0x2F3C, 0x0004, 0x0011, 0x7000, 0xA82A);
  1088. /*  Set the character data handler UPP for event parsing*/
  1089. EXTERN_API( ComponentResult )
  1090. XMLParseSetCharDataHandler      (ComponentInstance      aParser,
  1091.                                  CharDataHandlerUPP     charData)                           FIVEWORDINLINE(0x2F3C, 0x0004, 0x0012, 0x7000, 0xA82A);
  1092. /*  Set the preprocess instruction handler UPP for event parsing*/
  1093. EXTERN_API( ComponentResult )
  1094. XMLParseSetPreprocessInstructionHandler (ComponentInstance  aParser,
  1095.                                  PreprocessInstructionHandlerUPP  preprocessInstruction)    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0013, 0x7000, 0xA82A);
  1096. /*  Set the comment handler UPP for event parsing*/
  1097. EXTERN_API( ComponentResult )
  1098. XMLParseSetCommentHandler       (ComponentInstance      aParser,
  1099.                                  CommentHandlerUPP      comment)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0014, 0x7000, 0xA82A);
  1100. /*  Set the cdata handler UPP for event parsing*/
  1101. EXTERN_API( ComponentResult )
  1102. XMLParseSetCDataHandler         (ComponentInstance      aParser,
  1103.                                  CDataHandlerUPP        cdata)                              FIVEWORDINLINE(0x2F3C, 0x0004, 0x0015, 0x7000, 0xA82A);
  1104. /*
  1105.     Helper Macros
  1106.     
  1107.         These macros allow you to easily add entities and attributes to the parser
  1108.         in an error free manner when the identifiers are defined in a particular manner.
  1109.         For these to work, you must define the identifiers as follows:
  1110.         
  1111.         For entities, they must be defined as element_elementName, as in:
  1112.         
  1113.             enum
  1114.             {
  1115.                 element_xml =   1,      //  "xml"
  1116.                 element_head,           //  "head"
  1117.                 element_body            //  "body"
  1118.             };
  1119.             
  1120.         If the element name has characters that are illegal in an identifier,
  1121.         some of the macros support that, but the identifier must not contain
  1122.         the illegal characters:
  1123.         
  1124.             enum
  1125.             {
  1126.                 element_rootlayout      //  "root-layout"
  1127.             }
  1128.             
  1129.         For attribute names, similar rules apply except that they must be defined
  1130.         as attr_attributeName, as in:
  1131.             
  1132.             enum
  1133.             {
  1134.                 attr_src    =   1,      //  "src"
  1135.                 attr_href,
  1136.                 attr_width,
  1137.                 attr_height
  1138.             }
  1139.             
  1140.         Finally, the existence of local variables elementID and attributeID is required.
  1141. */
  1142. /*
  1143.     Adds the specified element to the parser, i.e. XML_ADD_ELEMENT(head) adds the element "head" with
  1144.     a unique identifier of element_head
  1145. */
  1146. #define XML_ADD_ELEMENT_NS(elementName,nameSpaceID)        elementID   =   GLUE2(element_,elementName);    XMLParseAddElement(xmlParser, #elementName, nameSpaceID, &elementID, 0)
  1147. #define XML_ADD_ELEMENT(elementName)                    XML_ADD_ELEMENT_NS(elementName,nameSpaceIDNone)
  1148. /*
  1149.     Adds the specified element to the parser, not using the same string to generate the identifier and
  1150.     the element name. Use for element names that contain characters which are illegal in identifiers,
  1151.     i.e XML_ADD_COMPLEX_ELEMENT("root-layout",rootlayout) adds the element "root-layout" with a unique
  1152.     identifier of element_rootlayout
  1153. */
  1154. #define XML_ADD_COMPLEX_ELEMENT_NS(elementName,elemID,nameSpaceID)     elementID   =   GLUE2(element_,elemID);     XMLParseAddElement(xmlParser, #elementName, nameSpaceID, &elementID, 0)
  1155. #define XML_ADD_COMPLEX_ELEMENT(elementName,elemID)                     XML_ADD_COMPLEX_ELEMENT_NS(elementName,elemID,nameSpaceIDNone)
  1156. /*
  1157.     Adds the specified attribute to the current element in the parser, i.e. XML_ADD_ATTRIBUTE(src)
  1158.     adds the attribute "src" to the current element, and identifies it by attr_src
  1159. */
  1160. #define XML_ADD_ATTRIBUTE_NS(attrName,nameSpaceID)     attributeID =   GLUE2(attr_,attrName);      XMLParseAddAttribute(xmlParser, elementID, nameSpaceID, #attrName, &attributeID);
  1161. #define XML_ADD_ATTRIBUTE(attrName)                       XML_ADD_ATTRIBUTE_NS(attrName,nameSpaceIDNone)
  1162. /*
  1163.     Adds the specified attribute to the current element in the parser, i.e. XML_ADD_ATTRIBUTE(element_img, src)
  1164.     adds the attribute "src" to the element_img element, and identifies it by attr_src
  1165.     Adds the specified attribute to the current element in the parser, not using the same string to
  1166.     generate the identifier and the element name. Use for attribute names that contain characters which
  1167.     are illegal in identifiers, i.e XML_ADD_COMPLEX_ATTRIBUTE("http-equiv",httpequiv) adds the element
  1168.     "http-equiv" with a unique identifier of attr_httpequiv
  1169. */
  1170. #define XML_ADD_COMPLEX_ATTRIBUTE_NS(attrName,attrID,nameSpaceID)  attributeID =   GLUE2(attr_,attrID);        XMLParseAddAttribute(xmlParser, elementID, nameSpaceID, #attrName, &attributeID);
  1171. #define XML_ADD_COMPLEX_ATTRIBUTE(attrName,attrID)                    XML_ADD_COMPLEX_ATTRIBUTE_NS(attrName,attrID,nameSpaceIDNone)
  1172. #define XML_ADD_ATTRIBUTE_AND_VALUE_NS(attrName,valueKind,valueKindInfo,nameSpaceID)   attributeID =   GLUE2(attr_,attrName);      XMLParseAddAttributeAndValue(xmlParser, elementID, nameSpaceID, #attrName, &attributeID, valueKind, valueKindInfo);
  1173. #define XML_ADD_ATTRIBUTE_AND_VALUE(attrName,valueKind,valueKindInfo)                   XML_ADD_ATTRIBUTE_AND_VALUE_NS(attrName,valueKind,valueKindInfo,nameSpaceIDNone)
  1174. #define XML_ADD_COMPLEX_ATTRIBUTE_AND_VALUE_NS(attrName,attrID,valueKind,valueKindInfo,nameSpaceID)        attributeID =   GLUE2(attr_,attrID);        XMLParseAddAttributeAndValue(xmlParser, elementID, nameSpaceID, #attrName, &attributeID, valueKind, valueKindInfo);
  1175. #define XML_ADD_COMPLEX_ATTRIBUTE_AND_VALUE(attrName,attrID,valueKind,valueKindInfo)                    XML_ADD_COMPLEX_ATTRIBUTE_AND_VALUE_NS(attrName,attrID,valueKind,valueKindInfo,nameSpaceIDNone)
  1176. /*
  1177.     General Sequence Grab stuff
  1178. */
  1179. typedef ComponentInstance               SeqGrabComponent;
  1180. typedef ComponentInstance               SGChannel;
  1181. enum {
  1182.     SeqGrabComponentType        = FOUR_CHAR_CODE('barg'),
  1183.     SeqGrabChannelType          = FOUR_CHAR_CODE('sgch'),
  1184.     SeqGrabPanelType            = FOUR_CHAR_CODE('sgpn'),
  1185.     SeqGrabCompressionPanelType = FOUR_CHAR_CODE('cmpr'),
  1186.     SeqGrabSourcePanelType      = FOUR_CHAR_CODE('sour')
  1187. };
  1188. enum {
  1189.     seqGrabToDisk               = 1,
  1190.     seqGrabToMemory             = 2,
  1191.     seqGrabDontUseTempMemory    = 4,
  1192.     seqGrabAppendToFile         = 8,
  1193.     seqGrabDontAddMovieResource = 16,
  1194.     seqGrabDontMakeMovie        = 32,
  1195.     seqGrabPreExtendFile        = 64,
  1196.     seqGrabDataProcIsInterruptSafe = 128,
  1197.     seqGrabDataProcDoesOverlappingReads = 256
  1198. };
  1199. typedef unsigned long                   SeqGrabDataOutputEnum;
  1200. enum {
  1201.     seqGrabRecord               = 1,
  1202.     seqGrabPreview              = 2,
  1203.     seqGrabPlayDuringRecord     = 4,
  1204.     seqGrabLowLatencyCapture    = 8,                            /* return the freshest frame possible, for live work (videoconferencing, live broadcast, live image processing) */
  1205.     seqGrabAlwaysUseTimeBase    = 16                            /* Tell VDIGs to use TimebaseTime always, rather than creating uniform frame durations, for more accurate live sync with audio */
  1206. };
  1207. typedef unsigned long                   SeqGrabUsageEnum;
  1208. enum {
  1209.     seqGrabHasBounds            = 1,
  1210.     seqGrabHasVolume            = 2,
  1211.     seqGrabHasDiscreteSamples   = 4,
  1212.     seqGrabDoNotBufferizeData   = 8,
  1213.     seqGrabCanMoveWindowWhileRecording = 16
  1214. };
  1215. typedef unsigned long                   SeqGrabChannelInfoEnum;
  1216. struct SGOutputRecord {
  1217.     long                            data[1];
  1218. };
  1219. typedef struct SGOutputRecord           SGOutputRecord;
  1220. typedef SGOutputRecord *                SGOutput;
  1221. struct SeqGrabFrameInfo {
  1222.     long                            frameOffset;
  1223.     long                            frameTime;
  1224.     long                            frameSize;
  1225.     SGChannel                       frameChannel;
  1226.     long                            frameRefCon;
  1227. };
  1228. typedef struct SeqGrabFrameInfo         SeqGrabFrameInfo;
  1229. typedef SeqGrabFrameInfo *              SeqGrabFrameInfoPtr;
  1230. struct SeqGrabExtendedFrameInfo {
  1231.     wide                            frameOffset;
  1232.     long                            frameTime;
  1233.     long                            frameSize;
  1234.     SGChannel                       frameChannel;
  1235.     long                            frameRefCon;
  1236.     SGOutput                        frameOutput;
  1237. };
  1238. typedef struct SeqGrabExtendedFrameInfo SeqGrabExtendedFrameInfo;
  1239. typedef SeqGrabExtendedFrameInfo *      SeqGrabExtendedFrameInfoPtr;
  1240. enum {
  1241.     grabPictOffScreen           = 1,
  1242.     grabPictIgnoreClip          = 2,
  1243.     grabPictCurrentImage        = 4
  1244. };
  1245. enum {
  1246.     sgFlagControlledGrab        = (1 << 0),
  1247.     sgFlagAllowNonRGBPixMaps    = (1 << 1)
  1248. };
  1249. typedef CALLBACK_API( OSErr , SGDataProcPtr )(SGChannel c, Ptr p, long len, long *offset, long chRefCon, TimeValue time, short writeType, long refCon);
  1250. typedef STACK_UPP_TYPE(SGDataProcPtr)                           SGDataUPP;
  1251. struct SGDeviceInputName {
  1252.     Str63                           name;
  1253.     Handle                          icon;
  1254.     long                            flags;
  1255.     long                            reserved;                   /* zero*/
  1256. };
  1257. typedef struct SGDeviceInputName        SGDeviceInputName;
  1258. enum {
  1259.     sgDeviceInputNameFlagInputUnavailable = (1 << 0)
  1260. };
  1261. struct SGDeviceInputListRecord {
  1262.     short                           count;
  1263.     short                           selectedIndex;
  1264.     long                            reserved;                   /* zero*/
  1265.     SGDeviceInputName               entry[1];
  1266. };
  1267. typedef struct SGDeviceInputListRecord  SGDeviceInputListRecord;
  1268. typedef SGDeviceInputListRecord *       SGDeviceInputListPtr;
  1269. typedef SGDeviceInputListPtr *          SGDeviceInputList;
  1270. struct SGDeviceName {
  1271.     Str63                           name;
  1272.     Handle                          icon;
  1273.     long                            flags;
  1274.     long                            refCon;
  1275.     SGDeviceInputList               inputs;                     /* list of inputs; formerly reserved to 0*/
  1276. };
  1277. typedef struct SGDeviceName             SGDeviceName;
  1278. enum {
  1279.     sgDeviceNameFlagDeviceUnavailable = (1 << 0),
  1280.     sgDeviceNameFlagShowInputsAsDevices = (1 << 1)
  1281. };
  1282. struct SGDeviceListRecord {
  1283.     short                           count;
  1284.     short                           selectedIndex;
  1285.     long                            reserved;                   /* zero*/
  1286.     SGDeviceName                    entry[1];
  1287. };
  1288. typedef struct SGDeviceListRecord       SGDeviceListRecord;
  1289. typedef SGDeviceListRecord *            SGDeviceListPtr;
  1290. typedef SGDeviceListPtr *               SGDeviceList;
  1291. enum {
  1292.     sgDeviceListWithIcons       = (1 << 0),
  1293.     sgDeviceListDontCheckAvailability = (1 << 1),
  1294.     sgDeviceListIncludeInputs   = (1 << 2)
  1295. };
  1296. enum {
  1297.     seqGrabWriteAppend          = 0,
  1298.     seqGrabWriteReserve         = 1,
  1299.     seqGrabWriteFill            = 2
  1300. };
  1301. enum {
  1302.     seqGrabUnpause              = 0,
  1303.     seqGrabPause                = 1,
  1304.     seqGrabPauseForMenu         = 3
  1305. };
  1306. enum {
  1307.     channelFlagDontOpenResFile  = 2,
  1308.     channelFlagHasDependency    = 4
  1309. };
  1310. typedef CALLBACK_API( Boolean , SGModalFilterProcPtr )(DialogRef theDialog, const EventRecord *theEvent, short *itemHit, long refCon);
  1311. typedef STACK_UPP_TYPE(SGModalFilterProcPtr)                    SGModalFilterUPP;
  1312. enum {
  1313.     sgPanelFlagForPanel         = 1
  1314. };
  1315. enum {
  1316.     seqGrabSettingsPreviewOnly  = 1
  1317. };
  1318. enum {
  1319.     channelPlayNormal           = 0,
  1320.     channelPlayFast             = 1,
  1321.     channelPlayHighQuality      = 2,
  1322.     channelPlayAllData          = 4
  1323. };
  1324. EXTERN_API( ComponentResult )
  1325. SGInitialize                    (SeqGrabComponent       s)                                  FIVEWORDINLINE(0x2F3C, 0x0000, 0x0001, 0x7000, 0xA82A);
  1326. EXTERN_API( ComponentResult )
  1327. SGSetDataOutput                 (SeqGrabComponent       s,
  1328.                                  const FSSpec *         movieFile,
  1329.                                  long                   whereFlags)                         FIVEWORDINLINE(0x2F3C, 0x0008, 0x0002, 0x7000, 0xA82A);
  1330. EXTERN_API( ComponentResult )
  1331. SGGetDataOutput                 (SeqGrabComponent       s,
  1332.                                  FSSpec *               movieFile,
  1333.                                  long *                 whereFlags)                         FIVEWORDINLINE(0x2F3C, 0x0008, 0x0003, 0x7000, 0xA82A);
  1334. EXTERN_API( ComponentResult )
  1335. SGSetGWorld                     (SeqGrabComponent       s,
  1336.                                  CGrafPtr               gp,
  1337.                                  GDHandle               gd)                                 FIVEWORDINLINE(0x2F3C, 0x0008, 0x0004, 0x7000, 0xA82A);
  1338. EXTERN_API( ComponentResult )
  1339. SGGetGWorld                     (SeqGrabComponent       s,
  1340.                                  CGrafPtr *             gp,
  1341.                                  GDHandle *             gd)                                 FIVEWORDINLINE(0x2F3C, 0x0008, 0x0005, 0x7000, 0xA82A);
  1342. EXTERN_API( ComponentResult )
  1343. SGNewChannel                    (SeqGrabComponent       s,
  1344.                                  OSType                 channelType,
  1345.                                  SGChannel *            ref)                                FIVEWORDINLINE(0x2F3C, 0x0008, 0x0006, 0x7000, 0xA82A);
  1346. EXTERN_API( ComponentResult )
  1347. SGDisposeChannel                (SeqGrabComponent       s,
  1348.                                  SGChannel              c)                                  FIVEWORDINLINE(0x2F3C, 0x0004, 0x0007, 0x7000, 0xA82A);
  1349. EXTERN_API( ComponentResult )
  1350. SGStartPreview                  (SeqGrabComponent       s)                                  FIVEWORDINLINE(0x2F3C, 0x0000, 0x0010, 0x7000, 0xA82A);
  1351. EXTERN_API( ComponentResult )
  1352. SGStartRecord                   (SeqGrabComponent       s)                                  FIVEWORDINLINE(0x2F3C, 0x0000, 0x0011, 0x7000, 0xA82A);
  1353. EXTERN_API( ComponentResult )
  1354. SGIdle                          (SeqGrabComponent       s)                                  FIVEWORDINLINE(0x2F3C, 0x0000, 0x0012, 0x7000, 0xA82A);
  1355. EXTERN_API( ComponentResult )
  1356. SGStop                          (SeqGrabComponent       s)                                  FIVEWORDINLINE(0x2F3C, 0x0000, 0x0013, 0x7000, 0xA82A);
  1357. EXTERN_API( ComponentResult )
  1358. SGPause                         (SeqGrabComponent       s,
  1359.                                  Byte                   pause)                              FIVEWORDINLINE(0x2F3C, 0x0002, 0x0014, 0x7000, 0xA82A);
  1360. EXTERN_API( ComponentResult )
  1361. SGPrepare                       (SeqGrabComponent       s,
  1362.                                  Boolean                prepareForPreview,
  1363.                                  Boolean                prepareForRecord)                   FIVEWORDINLINE(0x2F3C, 0x0004, 0x0015, 0x7000, 0xA82A);
  1364. EXTERN_API( ComponentResult )
  1365. SGRelease                       (SeqGrabComponent       s)                                  FIVEWORDINLINE(0x2F3C, 0x0000, 0x0016, 0x7000, 0xA82A);
  1366. EXTERN_API( Movie )
  1367. SGGetMovie                      (SeqGrabComponent       s)                                  FIVEWORDINLINE(0x2F3C, 0x0000, 0x0017, 0x7000, 0xA82A);
  1368. EXTERN_API( ComponentResult )
  1369. SGSetMaximumRecordTime          (SeqGrabComponent       s,
  1370.                                  unsigned long          ticks)                              FIVEWORDINLINE(0x2F3C, 0x0004, 0x0018, 0x7000, 0xA82A);
  1371. EXTERN_API( ComponentResult )
  1372. SGGetMaximumRecordTime          (SeqGrabComponent       s,
  1373.                                  unsigned long *        ticks)                              FIVEWORDINLINE(0x2F3C, 0x0004, 0x0019, 0x7000, 0xA82A);
  1374. EXTERN_API( ComponentResult )
  1375. SGGetStorageSpaceRemaining      (SeqGrabComponent       s,
  1376.                                  unsigned long *        bytes)                              FIVEWORDINLINE(0x2F3C, 0x0004, 0x001A, 0x7000, 0xA82A);
  1377. EXTERN_API( ComponentResult )
  1378. SGGetTimeRemaining              (SeqGrabComponent       s,
  1379.                                  long *                 ticksLeft)                          FIVEWORDINLINE(0x2F3C, 0x0004, 0x001B, 0x7000, 0xA82A);
  1380. EXTERN_API( ComponentResult )
  1381. SGGrabPict                      (SeqGrabComponent       s,
  1382.                                  PicHandle *            p,
  1383.                                  const Rect *           bounds,
  1384.                                  short                  offscreenDepth,
  1385.                                  long                   grabPictFlags)                      FIVEWORDINLINE(0x2F3C, 0x000E, 0x001C, 0x7000, 0xA82A);
  1386. EXTERN_API( ComponentResult )
  1387. SGGetLastMovieResID             (SeqGrabComponent       s,
  1388.                                  short *                resID)                              FIVEWORDINLINE(0x2F3C, 0x0004, 0x001D, 0x7000, 0xA82A);
  1389. EXTERN_API( ComponentResult )
  1390. SGSetFlags                      (SeqGrabComponent       s,
  1391.                                  long                   sgFlags)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x001E, 0x7000, 0xA82A);
  1392. EXTERN_API( ComponentResult )
  1393. SGGetFlags                      (SeqGrabComponent       s,
  1394.                                  long *                 sgFlags)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x001F, 0x7000, 0xA82A);
  1395. EXTERN_API( ComponentResult )
  1396. SGSetDataProc                   (SeqGrabComponent       s,
  1397.                                  SGDataUPP              proc,
  1398.                                  long                   refCon)                             FIVEWORDINLINE(0x2F3C, 0x0008, 0x0020, 0x7000, 0xA82A);
  1399. EXTERN_API( ComponentResult )
  1400. SGNewChannelFromComponent       (SeqGrabComponent       s,
  1401.                                  SGChannel *            newChannel,
  1402.                                  Component              sgChannelComponent)                 FIVEWORDINLINE(0x2F3C, 0x0008, 0x0021, 0x7000, 0xA82A);
  1403. EXTERN_API( ComponentResult )
  1404. SGDisposeDeviceList             (SeqGrabComponent       s,
  1405.                                  SGDeviceList           list)                               FIVEWORDINLINE(0x2F3C, 0x0004, 0x0022, 0x7000, 0xA82A);
  1406. EXTERN_API( ComponentResult )
  1407. SGAppendDeviceListToMenu        (SeqGrabComponent       s,
  1408.                                  SGDeviceList           list,
  1409.                                  MenuRef                mh)                                 FIVEWORDINLINE(0x2F3C, 0x0008, 0x0023, 0x7000, 0xA82A);
  1410. EXTERN_API( ComponentResult )
  1411. SGSetSettings                   (SeqGrabComponent       s,
  1412.                                  UserData               ud,
  1413.                                  long                   flags)                              FIVEWORDINLINE(0x2F3C, 0x0008, 0x0024, 0x7000, 0xA82A);
  1414. EXTERN_API( ComponentResult )
  1415. SGGetSettings                   (SeqGrabComponent       s,
  1416.                                  UserData *             ud,
  1417.                                  long                   flags)                              FIVEWORDINLINE(0x2F3C, 0x0008, 0x0025, 0x7000, 0xA82A);
  1418. EXTERN_API( ComponentResult )
  1419. SGGetIndChannel                 (SeqGrabComponent       s,
  1420.                                  short                  index,
  1421.                                  SGChannel *            ref,
  1422.                                  OSType *               chanType)                           FIVEWORDINLINE(0x2F3C, 0x000A, 0x0026, 0x7000, 0xA82A);
  1423. EXTERN_API( ComponentResult )
  1424. SGUpdate                        (SeqGrabComponent       s,
  1425.                                  RgnHandle              updateRgn)                          FIVEWORDINLINE(0x2F3C, 0x0004, 0x0027, 0x7000, 0xA82A);
  1426. EXTERN_API( ComponentResult )
  1427. SGGetPause                      (SeqGrabComponent       s,
  1428.                                  Byte *                 paused)                             FIVEWORDINLINE(0x2F3C, 0x0004, 0x0028, 0x7000, 0xA82A);
  1429. typedef const Component *               ConstComponentListPtr;
  1430. EXTERN_API( ComponentResult )
  1431. SGSettingsDialog                (SeqGrabComponent       s,
  1432.                                  SGChannel              c,
  1433.                                  short                  numPanels,
  1434.                                  ConstComponentListPtr  panelList,
  1435.                                  long                   flags,
  1436.                                  SGModalFilterUPP       proc,
  1437.                                  long                   procRefNum)                         FIVEWORDINLINE(0x2F3C, 0x0016, 0x0029, 0x7000, 0xA82A);
  1438. EXTERN_API( ComponentResult )
  1439. SGGetAlignmentProc              (SeqGrabComponent       s,
  1440.                                  ICMAlignmentProcRecordPtr  alignmentProc)                  FIVEWORDINLINE(0x2F3C, 0x0004, 0x002A, 0x7000, 0xA82A);
  1441. EXTERN_API( ComponentResult )
  1442. SGSetChannelSettings            (SeqGrabComponent       s,
  1443.                                  SGChannel              c,
  1444.                                  UserData               ud,
  1445.                                  long                   flags)                              FIVEWORDINLINE(0x2F3C, 0x000C, 0x002B, 0x7000, 0xA82A);
  1446. EXTERN_API( ComponentResult )
  1447. SGGetChannelSettings            (SeqGrabComponent       s,
  1448.                                  SGChannel              c,
  1449.                                  UserData *             ud,
  1450.                                  long                   flags)                              FIVEWORDINLINE(0x2F3C, 0x000C, 0x002C, 0x7000, 0xA82A);
  1451. EXTERN_API( ComponentResult )
  1452. SGGetMode                       (SeqGrabComponent       s,
  1453.                                  Boolean *              previewMode,
  1454.                                  Boolean *              recordMode)                         FIVEWORDINLINE(0x2F3C, 0x0008, 0x002D, 0x7000, 0xA82A);
  1455. EXTERN_API( ComponentResult )
  1456. SGSetDataRef                    (SeqGrabComponent       s,
  1457.                                  Handle                 dataRef,
  1458.                                  OSType                 dataRefType,
  1459.                                  long                   whereFlags)                         FIVEWORDINLINE(0x2F3C, 0x000C, 0x002E, 0x7000, 0xA82A);
  1460. EXTERN_API( ComponentResult )
  1461. SGGetDataRef                    (SeqGrabComponent       s,
  1462.                                  Handle *               dataRef,
  1463.                                  OSType *               dataRefType,
  1464.                                  long *                 whereFlags)                         FIVEWORDINLINE(0x2F3C, 0x000C, 0x002F, 0x7000, 0xA82A);
  1465. EXTERN_API( ComponentResult )
  1466. SGNewOutput                     (SeqGrabComponent       s,
  1467.                                  Handle                 dataRef,
  1468.                                  OSType                 dataRefType,
  1469.                                  long                   whereFlags,
  1470.                                  SGOutput *             sgOut)                              FIVEWORDINLINE(0x2F3C, 0x0010, 0x0030, 0x7000, 0xA82A);
  1471. EXTERN_API( ComponentResult )