home *** CD-ROM | disk | FTP | other *** search
Text File | 1991-09-06 | 32.4 KB | 846 lines | [TEXT/MPS ] |
-
- {
- Created: Saturday, August 17, 1991 at 10:25 AM
- QuickTimeComponents.p
- Pascal Interface to the Macintosh Libraries
-
- Copyright Apple Computer, Inc. 1991
- All rights reserved
- }
-
-
- {$IFC UNDEFINED UsingIncludes}
- {$SETC UsingIncludes := 0}
- {$ENDC}
-
- {$IFC NOT UsingIncludes}
- UNIT QuickTimeComponents;
- INTERFACE
- {$ENDC}
-
- {$IFC UNDEFINED UsingQuickTimeComponents}
- {$SETC UsingQuickTimeComponents := 1}
-
- {$I+}
- {$SETC QuickTimeComponentsIncludes := UsingIncludes}
- {$SETC UsingIncludes := 1}
- {$IFC UNDEFINED UsingComponents}
- {$I $$Shell(PInterfaces)Components.p}
- {$ENDC}
- {$IFC UNDEFINED UsingImageCompression}
- {$I $$Shell(PInterfaces)ImageCompression.p}
- {$ENDC}
- {$IFC UNDEFINED UsingMovies}
- {$I $$Shell(PInterfaces)Movies.p}
- {$ENDC}
- {$IFC UNDEFINED UsingQuickDraw}
- {$I $$Shell(PInterfaces)QuickDraw.p}
- {$ENDC}
- {$IFC UNDEFINED UsingVideo}
- {$I $$Shell(PInterfaces)Video.p}
- {$ENDC}
- {$SETC UsingIncludes := QuickTimeComponentsIncludes}
-
- CONST
-
- {****
-
- Clock Component
-
- ****}
- clockComponentType = 'clok';
- systemTickClock = 'tick'; { subtype: 60ths since boot }
- systemSecondClock = 'seco'; { subtype: seconds since 1904 }
- systemMillisecondClock = 'mill'; { subtype: 1000ths since boot }
- systemMicrosecondClock = 'micr'; { subtype: 1000000ths since boot }
-
- kClockRateIsLinear = 1;
- kClockImplementsCallBacks = 2;
-
- kClockGetClockTimeSelect = 1;
- kClockSetClockTimeSelect = 2;
- kClockNewCallBackSelect = 3;
- kClockDisposeCallBackSelect = 4;
- kClockCallMeWhenSelect = 5;
- kClockCancelCallBackSelect = 6;
- kClockRateChangedSelect = 7;
- kClockTimeChangedSelect = 8;
- kClockSetTimeBaseSelect = 9;
-
- FUNCTION GetClockTime(aClock: ComponentInstance;VAR out: TimeRecord): ComponentResult;
- INLINE $2F3C,$4,$1,$7000,$A82A;
- FUNCTION ClockNewCallBack(aClock: ComponentInstance;tb: TimeBase;callBackType: INTEGER): QTCallBack;
- INLINE $2F3C,$6,$1,$7000,$A82A;
- FUNCTION ClockDisposeCallBack(aClock: ComponentInstance;cb: QTCallBack): ComponentResult;
- INLINE $2F3C,$4,$1,$7000,$A82A;
- FUNCTION ClockCallMeWhen(clock: ComponentInstance;cb: QTCallBack;param1: LONGINT;
- param2: LONGINT;param3: LONGINT): ComponentResult;
- INLINE $2F3C,$10,$1,$7000,$A82A;
- FUNCTION ClockCancelCallBack(clock: ComponentInstance;cb: QTCallBack): ComponentResult;
- INLINE $2F3C,$4,$1,$7000,$A82A;
- FUNCTION ClockRateChanged(clock: ComponentInstance;cb: QTCallBack): ComponentResult;
- INLINE $2F3C,$4,$1,$7000,$A82A;
- FUNCTION ClockTimeChanged(clock: ComponentInstance;cb: QTCallBack): ComponentResult;
- INLINE $2F3C,$4,$1,$7000,$A82A;
- FUNCTION ClockSetTimeBase(clock: ComponentInstance;tb: TimeBase): ComponentResult;
- INLINE $2F3C,$4,$1,$7000,$A82A;
-
-
- CONST
-
- {
- Video Digitizer Component
-
-
- Standard type for video digitizers }
- videoDigitizerComponentType = 'vdig';
- vdigInterfaceRev = 2;
-
- { Input Format Standards }
- ntscIn = 0; { ntsc input format }
- palIn = 1; { pal input format }
- secamIn = 2; { secam input format }
- autoDetectIn = 3; { auto detect }
-
-
- { Input Formats }
- compositeIn = 0; { input is composite format }
- sVideoIn = 1; { input is sVideo format }
- rgbComponentIn = 2; { input is rgb component format }
-
-
- { Video Digitizer PlayThru States }
- vdPlayThruOff = 0;
- vdPlayThruOn = 1;
-
-
- { Input Color Space Modes }
- vdDigitizerBW = 0; { black and white }
- vdDigitizerRGB = 1; { rgb color }
-
-
- { Phase Lock Loop Modes }
- vdBroadcastMode = 0; { Broadcast / Laser Disk video mode }
- vdVTRMode = 1; { VCR / Magnetic media mode }
-
-
- { vdig types }
- vdTypeBasic = 0; { basic, no clipping }
- vdTypeAlpha = 1; { supports clipping with alpha channel }
- vdTypeMask = 2; { supports clipping with mask plane }
- vdTypeKey = 3; { supports clipping with key color(s) }
-
-
- { Digitizer Error Codes }
- digiUnimpErr = -2201; { feature unimplemented }
- qtParamErr = -2202; { bad input parameter ( out of range, etc ) }
- matrixErr = -2203; { bad matrix, digitizer did nothing }
- notExactMatrix = -2204; { warning of bad matrix, digitizer did its best }
- noMoreKeyColors = -2205; { all key indexes in use }
- notExactSize = -2206; { Can’t do exact size requested }
- badDepth = -2207; { Can’t digitize into this depth }
- noDMA = -2208; { Can’t do DMA digitizing ( i.e. can't go to requested dest }
-
-
- { Digitizer Input Capability/Current Flags }
- digiInDoesNTSC = $1; { digitizer supports NTSC input format }
- digiInDoesPAL = $2; { digitizer supports PAL input format }
- digiInDoesSECAM = $4; { digitizer supports SECAM input format }
- digiInDoesGenLock = $80; { digitizer does genlock }
-
- digiInDoesComposite = $100; { digitizer supports composite input type }
- digiInDoesSVideo = $200; { digitizer supports S-Video input type }
- digiInDoesComponent = $400; { digitizer supports component (rgb) input type }
- digiInVTR_Broadcast = $800; { digitizer can differentiate between the two }
-
- digiInDoesColor = $1000; { digitizer supports color }
- digiInDoesBW = $2000; { digitizer supports black & white }
-
-
- { Digitizer Input Current Flags (these are valid only during active operating conditions) }
- digiInGenLocked = $40000000; { digitizer signal is in genlock mode }
- digiInSignalLock = $80000000; { digitizer detects input signal is locked - this bit = horiz lock || vertical lock }
-
-
- { Digitizer Output Capability/Current Flags }
- digiOutDoes1 = $1; { digitizer supports 1 bit pixels }
- digiOutDoes2 = $2; { digitizer supports 2 bit pixels }
- digiOutDoes4 = $4; { digitizer supports 4 bit pixels }
- digiOutDoes8 = $8; { digitizer supports 8 bit pixels }
- digiOutDoes16 = $10; { digitizer supports 16 bit pixels }
- digiOutDoes32 = $20; { digitizer supports 32 bit pixels }
- digiOutDoesDither = $40; { digitizer dithers in indexed modes }
- digiOutDoesStretch = $80; { digitizer can arbitrarily stretch }
- digiOutDoesShrink = $100; { digitizer can arbitrarily shrink }
- digiOutDoesMask = $200; { digitizer can mask to clipping regions }
-
- digiOutDoesDouble = $800; { digitizer can stretch to exactly double size }
- digiOutDoesQuad = $1000; { digitizer can stretch exactly quadruple size }
- digiOutDoesQuarter = $2000; { digitizer can shrink to exactly quarter size }
- digiOutDoesSixteenth = $4000; { digitizer can shrink to exactly sixteenth size }
-
- digiOutDoesRotate = $8000; { digitizer supports rotate transformations }
- digiOutDoesHorizFlip = $10000; { digitizer supports horizontal flips Sx < 0 }
- digiOutDoesVertFlip = $20000; { digitizer supports vertical flips Sy < 0 }
- digiOutDoesSkew = $40000; { digitizer supports skew (shear, twist) }
- digiOutDoesBlend = $80000;
- digiOutDoesWarp = $100000;
-
- digiOutDoesHW_DMA = $200000; { digitizer not constrained to local device }
- digiOutDoesHWPlayThru = $400000; { digitizer doesn't need time to play thru }
- digiOutDoesILUT = $800000; { digitizer does inverse LUT for index modes }
- digiOutDoesKeyColor = $1000000; { digitizer does key color functions too }
- digiOutDoesAsyncGrabs = $2000000; { digitizer supports async grabs }
-
- TYPE
- VideoDigitizerThing = ComponentInstance;
- VideoDigitizerError = ComponentResult;
-
- { Types }
- DigitizerInfo = RECORD
- vdigType: INTEGER;
- inputCapabilityFlags: LONGINT;
- outputCapabilityFlags: LONGINT;
- inputCurrentFlags: LONGINT;
- outputCurrentFlags: LONGINT;
- slot: INTEGER; { temporary for connection purposes }
- gdh: GDHandle; { temporary for digitizers that have preferred screen }
- maskgdh: GDHandle; { temporary for digitizers that have mask planes }
- minDestHeight: INTEGER; { Smallest resizable height }
- minDestWidth: INTEGER; { Smallest resizable width }
- maxDestHeight: INTEGER; { Largest resizable height }
- maxDestWidth: INTEGER; { Largest resizable height }
- blendLevels: INTEGER; { Number of blend levels supported (2 if 1 bit mask) }
- Private: LONGINT; { reserved }
- END;
-
- VdigType = RECORD
- digType: LONGINT;
- Private: LONGINT;
- END;
-
- VdigTypeListPtr = ^VdigTypeList;
- VdigTypeListHandle = ^VdigTypeListPtr;
- VdigTypeList = RECORD
- count: INTEGER;
- list: ARRAY [0..0] OF VdigType;
- END;
-
- VdigBufferRec = RECORD
- dest: PixMapHandle;
- location: Point;
- reserved: LONGINT;
- END;
-
- VdigBufferRecListPtr = ^VdigBufferRecList;
- VdigBufferRecListHandle = ^VdigBufferRecListPtr;
- VdigBufferRecList = RECORD
- count: INTEGER;
- matrix: MatrixRecordPtr ;
- mask: RgnHandle;
- list: ARRAY [0..0] OF VdigBufferRec;
- END;
-
-
- CONST
-
- { Video Digitizer Interface }
- kSelectVDGetMaxSrcRect = 1;
- kSelectVDGetActiveSrcRect = 2;
- kSelectVDSetDigitizerRect = 3;
- kSelectVDGetDigitizerRect = 4;
- kSelectVDGetVBlankRect = 5;
- kSelectVDGetMaskPixMap = 6;
- kSelectVDDone = 7;
- kSelectVDGetPlayThruDestination = 8;
- kSelectVDUseThisCLUT = 9;
- kSelectVDSetInputGammaValue = 10;
- kSelectVDGetInputGammaValue = 11;
- kSelectVDSetBrightness = 12;
- kSelectVDGetBrightness = 13;
- kSelectVDSetContrast = 14;
- kSelectVDSetHue = 15;
- kSelectVDSetSharpness = 16;
- kSelectVDSetSaturation = 17;
- kSelectVDGetContrast = 18;
- kSelectVDGetHue = 19;
- kSelectVDGetSharpness = 20;
- kSelectVDGetSaturation = 21;
- kSelectVDGrabOneFrame = 22;
- kSelectVDGetMaxAuxBuffer = 23;
- kSelectVDGrabOneFrameAsync = 24;
- kSelectVDGetDigitizerInfo = 25;
- kSelectVDGetCurrentFlags = 26;
- kSelectVDSetKeyColor = 27;
- kSelectVDGetKeyColor = 28;
- kSelectVDAddKeyColor = 29;
- kSelectVDGetNextKeyColor = 30;
- kSelectVDSetKeyColorRange = 31;
- kSelectVDGetKeyColorRange = 32;
- kSelectVDSetDigitizerUserInterrupt = 33;
- kSelectVDSetInputColorSpaceMode = 34;
- kSelectVDGetInputColorSpaceMode = 35;
- kSelectVDSetClipState = 36;
- kSelectVDGetClipState = 37;
- kSelectVDSetClipRgn = 38;
- kSelectVDClearClipRgn = 39;
- kSelectVDGetCLUTInUse = 40;
- kSelectVDSetPLLFilterType = 41;
- kSelectVDGetPLLFilterType = 42;
- kSelectVDGetMaskandValue = 43;
- kSelectVDSetMasterBlendLevel = 44;
- kSelectVDSetPlayThruDestination = 45;
- kSelectVDSetPlayThruOnOff = 46;
- kSelectVDGetAltDataTypes = 47;
- kSelectVDSetAltDataDestination = 48;
- kSelectVDSetAltDataOnOff = 49;
- kSelectVDPreflightDestination = 50;
- kSelectVDPreflightGlobalRect = 51;
- kSelectVDSetPlayThruGlobalRect = 52;
- kSelectVDSetInputGammaRecord = 53;
- kSelectVDGetInputGammaRecord = 54;
- kSelectVDSetBlackLevelValue = 55;
- kSelectVDGetBlackLevelValue = 56;
- kSelectVDSetWhiteLevelValue = 57;
- kSelectVDGetWhiteLevelValue = 58;
- kSelectVDGetVideoDefaults = 59;
- kSelectVDGetNumberOfInputs = 60;
- kSelectVDGetInputFormat = 61;
- kSelectVDSetInput = 62;
- kSelectVDGetInput = 63;
- kSelectVDSetInputStandard = 64;
- kSelectVDSetupBuffers = 65;
- kSelectVDGrabOneFrameAsync2 = 66;
- kSelectVDDone2 = 67;
-
- kvdigSelectors = 67;
-
- FUNCTION VDGetMaxSrcRect(ti: VideoDigitizerThing;inputStd: INTEGER;VAR maxSrcRect: Rect): VideoDigitizerError;
- INLINE $2F3C,$6,$1,$7000,$A82A;
- FUNCTION VDGetActiveSrcRect(ti: VideoDigitizerThing;inputStd: INTEGER;VAR activeSrcRect: Rect): VideoDigitizerError;
- INLINE $2F3C,$6,$2,$7000,$A82A;
- FUNCTION VDSetDigitizerRect(ti: VideoDigitizerThing;VAR digitizerRect: Rect): VideoDigitizerError;
- INLINE $2F3C,$4,$3,$7000,$A82A;
- FUNCTION VDGetDigitizerRect(ti: VideoDigitizerThing;VAR digitizerRect: Rect): VideoDigitizerError;
- INLINE $2F3C,$4,$4,$7000,$A82A;
- FUNCTION VDGetVBlankRect(ti: VideoDigitizerThing;inputStd: INTEGER;VAR vBlankRect: Rect): VideoDigitizerError;
- INLINE $2F3C,$6,$5,$7000,$A82A;
- FUNCTION VDGetMaskPixMap(ti: VideoDigitizerThing;maskPixMap: PixMapHandle): VideoDigitizerError;
- INLINE $2F3C,$4,$6,$7000,$A82A;
- FUNCTION VDGetPlayThruDestination(ti: VideoDigitizerThing;VAR dest: PixMapHandle;
- VAR destRect: Rect;VAR m: MatrixRecord;VAR mask: RgnHandle): VideoDigitizerError;
- INLINE $2F3C,$10,$8,$7000,$A82A;
- FUNCTION VDUseThisCLUT(ti: VideoDigitizerThing;colorTableHandle: CTabHandle): VideoDigitizerError;
- INLINE $2F3C,$4,$9,$7000,$A82A;
- FUNCTION VDSetInputGammaValue(ti: VideoDigitizerThing;channel1: Fixed;channel2: Fixed;
- channel3: Fixed): VideoDigitizerError;
- INLINE $2F3C,$C,$A,$7000,$A82A;
- FUNCTION VDGetInputGammaValue(ti: VideoDigitizerThing;VAR channel1: Fixed;
- VAR channel2: Fixed;VAR channel3: Fixed): VideoDigitizerError;
- INLINE $2F3C,$C,$B,$7000,$A82A;
- FUNCTION VDSetBrightness(ti: VideoDigitizerThing;VAR brightness: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$4,$C,$7000,$A82A;
- FUNCTION VDGetBrightness(ti: VideoDigitizerThing;VAR brightness: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$4,$D,$7000,$A82A;
- FUNCTION VDSetContrast(ti: VideoDigitizerThing;VAR contrast: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$4,$E,$7000,$A82A;
- FUNCTION VDSetHue(ti: VideoDigitizerThing;VAR hue: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$4,$F,$7000,$A82A;
- FUNCTION VDSetSharpness(ti: VideoDigitizerThing;VAR sharpness: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$4,$10,$7000,$A82A;
- FUNCTION VDSetSaturation(ti: VideoDigitizerThing;VAR saturation: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$4,$11,$7000,$A82A;
- FUNCTION VDGetContrast(ti: VideoDigitizerThing;VAR contrast: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$4,$12,$7000,$A82A;
- FUNCTION VDGetHue(ti: VideoDigitizerThing;VAR hue: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$4,$13,$7000,$A82A;
- FUNCTION VDGetSharpness(ti: VideoDigitizerThing;VAR sharpness: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$4,$14,$7000,$A82A;
- FUNCTION VDGetSaturation(ti: VideoDigitizerThing;VAR saturation: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$4,$15,$7000,$A82A;
- FUNCTION VDGrabOneFrame(ti: VideoDigitizerThing): VideoDigitizerError;
- INLINE $2F3C,$0,$16,$7000,$A82A;
- FUNCTION VDGetMaxAuxBuffer(ti: VideoDigitizerThing;VAR pm: PixMapHandle;
- VAR r: Rect): VideoDigitizerError;
- INLINE $2F3C,$8,$17,$7000,$A82A;
- FUNCTION VDGetDigitizerInfo(ti: VideoDigitizerThing;VAR info: DigitizerInfo): VideoDigitizerError;
- INLINE $2F3C,$4,$19,$7000,$A82A;
- FUNCTION VDGetCurrentFlags(ti: VideoDigitizerThing;VAR inputCurrentFlag: LONGINT;
- VAR outputCurrentFlag: LONGINT): VideoDigitizerError;
- INLINE $2F3C,$8,$1A,$7000,$A82A;
- FUNCTION VDSetKeyColor(ti: VideoDigitizerThing;index: LONGINT): VideoDigitizerError;
- INLINE $2F3C,$4,$1B,$7000,$A82A;
- FUNCTION VDGetKeyColor(ti: VideoDigitizerThing;VAR index: LONGINT): VideoDigitizerError;
- INLINE $2F3C,$4,$1C,$7000,$A82A;
- FUNCTION VDAddKeyColor(ti: VideoDigitizerThing;VAR index: LONGINT): VideoDigitizerError;
- INLINE $2F3C,$4,$1D,$7000,$A82A;
- FUNCTION VDGetNextKeyColor(ti: VideoDigitizerThing;index: LONGINT): VideoDigitizerError;
- INLINE $2F3C,$4,$1E,$7000,$A82A;
- FUNCTION VDSetKeyColorRange(ti: VideoDigitizerThing;VAR minRGB: RGBColor;
- VAR maxRGB: RGBColor): VideoDigitizerError;
- INLINE $2F3C,$8,$1F,$7000,$A82A;
- FUNCTION VDGetKeyColorRange(ti: VideoDigitizerThing;VAR minRGB: RGBColor;
- VAR maxRGB: RGBColor): VideoDigitizerError;
- INLINE $2F3C,$8,$20,$7000,$A82A;
- FUNCTION VDSetDigitizerUserInterrupt(ti: VideoDigitizerThing;whichOne: INTEGER;
- userInterruptProc: ProcPtr;params: Ptr): VideoDigitizerError;
- INLINE $2F3C,$A,$21,$7000,$A82A;
- FUNCTION VDSetInputColorSpaceMode(ti: VideoDigitizerThing;colorSpaceMode: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$2,$22,$7000,$A82A;
- FUNCTION VDGetInputColorSpaceMode(ti: VideoDigitizerThing;VAR colorSpaceMode: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$4,$23,$7000,$A82A;
- FUNCTION VDSetClipState(ti: VideoDigitizerThing;clipEnable: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$2,$24,$7000,$A82A;
- FUNCTION VDGetClipState(ti: VideoDigitizerThing;VAR clipEnable: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$4,$25,$7000,$A82A;
- FUNCTION VDSetClipRgn(ti: VideoDigitizerThing;clipRegion: RgnHandle): VideoDigitizerError;
- INLINE $2F3C,$4,$26,$7000,$A82A;
- FUNCTION VDClearClipRgn(ti: VideoDigitizerThing;clipRegion: RgnHandle): VideoDigitizerError;
- INLINE $2F3C,$4,$27,$7000,$A82A;
- FUNCTION VDGetCLUTInUse(ti: VideoDigitizerThing;VAR colorTableHandle: CTabHandle): VideoDigitizerError;
- INLINE $2F3C,$4,$28,$7000,$A82A;
- FUNCTION VDSetPLLFilterType(ti: VideoDigitizerThing;pllType: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$2,$29,$7000,$A82A;
- FUNCTION VDGetPLLFilterType(ti: VideoDigitizerThing;VAR pllType: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$4,$2A,$7000,$A82A;
- FUNCTION VDGetMaskandValue(ti: VideoDigitizerThing;blendLevel: INTEGER;
- VAR mask: LONGINT;VAR value: LONGINT): VideoDigitizerError;
- INLINE $2F3C,$A,$2B,$7000,$A82A;
- FUNCTION VDSetMasterBlendLevel(ti: VideoDigitizerThing;VAR blendLevel: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$4,$2C,$7000,$A82A;
- FUNCTION VDSetPlayThruDestination(ti: VideoDigitizerThing;dest: PixMapHandle;
- VAR destRect: Rect;VAR m: MatrixRecord;mask: RgnHandle): VideoDigitizerError;
- INLINE $2F3C,$10,$2D,$7000,$A82A;
- FUNCTION VDSetPlayThruOnOff(ti: VideoDigitizerThing;state: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$2,$2E,$7000,$A82A;
- FUNCTION VDGetAltDataTypes(ti: VideoDigitizerThing;list: VdigTypeListHandle): VideoDigitizerError;
- INLINE $2F3C,$4,$2F,$7000,$A82A;
- FUNCTION VDSetAltDataDestination(ti: VideoDigitizerThing;dstType: LONGINT;
- startAddr: Ptr;rowBytes: INTEGER;PixelSize: INTEGER;bufferSize: LONGINT;
- VAR destRect: Rect;VAR m: MatrixRecord;frameDonePtr: ProcPtr): VideoDigitizerError;
- INLINE $2F3C,$1C,$30,$7000,$A82A;
- FUNCTION VDSetAltDataOnOff(ti: VideoDigitizerThing;state: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$2,$31,$7000,$A82A;
- FUNCTION VDPreflightDestination(ti: VideoDigitizerThing;VAR digitizerRect: Rect;
- dest: PixMapHandle;VAR destRect: Rect;VAR m: MatrixRecord): VideoDigitizerError;
- INLINE $2F3C,$10,$32,$7000,$A82A;
- FUNCTION VDPreflightGlobalRect(ti: VideoDigitizerThing;theWindow: GrafPtr;
- VAR globalRect: Rect): VideoDigitizerError;
- INLINE $2F3C,$8,$33,$7000,$A82A;
- FUNCTION VDSetPlayThruGlobalRect(ti: VideoDigitizerThing;theWindow: GrafPtr;
- VAR globalRect: Rect): VideoDigitizerError;
- INLINE $2F3C,$8,$34,$7000,$A82A;
- FUNCTION VDSetInputGammaRecord(ti: VideoDigitizerThing;inputGammaPtr: VDGamRecPtr): VideoDigitizerError;
- INLINE $2F3C,$4,$35,$7000,$A82A;
- FUNCTION VDGetInputGammaRecord(ti: VideoDigitizerThing;VAR inputGammaPtr: VDGamRecPtr): VideoDigitizerError;
- INLINE $2F3C,$4,$36,$7000,$A82A;
- FUNCTION VDSetBlackLevelValue(ti: VideoDigitizerThing;VAR blackLevel: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$4,$37,$7000,$A82A;
- FUNCTION VDGetBlackLevelValue(ti: VideoDigitizerThing;VAR blackLevel: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$4,$38,$7000,$A82A;
- FUNCTION VDSetWhiteLevelValue(ti: VideoDigitizerThing;VAR whiteLevel: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$4,$39,$7000,$A82A;
- FUNCTION VDGetWhiteLevelValue(ti: VideoDigitizerThing;VAR whiteLevel: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$4,$3A,$7000,$A82A;
- FUNCTION VDGetVideoDefaults(ti: VideoDigitizerThing;VAR blackLevel: INTEGER;
- VAR whiteLevel: INTEGER;VAR brightness: INTEGER;VAR hue: INTEGER;VAR saturation: INTEGER;
- VAR contrast: INTEGER;VAR sharpness: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$1C,$3B,$7000,$A82A;
- FUNCTION VDGrabOneFrameAsync(ti: VideoDigitizerThing;bufferingOn: BOOLEAN;
- nextDest: PixMapHandle;nextPt: Point): VideoDigitizerError;
- INLINE $2F3C,$A,$18,$7000,$A82A;
- FUNCTION VDDone(ti: VideoDigitizerThing): LONGINT;
- INLINE $2F3C,$0,$7,$7000,$A82A;
- FUNCTION VDGetNumberOfInputs(ti: VideoDigitizerThing;VAR inputs: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$4,$3C,$7000,$A82A;
- FUNCTION VDGetInputFormat(ti: VideoDigitizerThing;input: INTEGER;VAR format: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$6,$3D,$7000,$A82A;
- FUNCTION VDSetInput(ti: VideoDigitizerThing;input: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$2,$3E,$7000,$A82A;
- FUNCTION VDGetInput(ti: VideoDigitizerThing;VAR input: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$4,$3F,$7000,$A82A;
- FUNCTION VDSetInputStandard(ti: VideoDigitizerThing;inputStandard: INTEGER): VideoDigitizerError;
- INLINE $2F3C,$2,$40,$7000,$A82A;
- FUNCTION VDSetupBuffers(ti: VideoDigitizerThing; bufferList: VdigBufferRecListHandle ) : VideoDigitizerError;
- INLINE $2F3C,$4,$41,$7000,$A82A;
- FUNCTION VDGrabOneFrameAsync2(ti: VideoDigitizerThing; buffer : INTEGER) : VideoDigitizerError;
- INLINE $2F3C,$2,$42,$7000,$A82A;
- FUNCTION VDDone2(ti: VideoDigitizerThing; buffer : INTEGER) : LONGINT;
- INLINE $2F3C,$2,$43,$7000,$A82A;
-
- TYPE
- { Sequence Grab Component }
- SeqGrabComponent = ComponentInstance;
- SGChannel = ComponentInstance;
-
- CONST
- SeqGrabComponentType = 'barg';
- SeqGrabChannelType = 'sgch';
- grabPictOffScreen = 1;
- sgFlagControlledGrab = 1;
-
- channelPlayNormal = 0;
- channelPlayFast = 1;
- channelPlayHighQuality = 2;
- channelPlayAllData = 4;
-
- seqGrabToDisk = 1;
- seqGrabToMemory = 2;
- seqGrabUseTempMemory = 4;
- seqGrabAppendToFile = 8;
- seqGrabDontAddMovieResource = 16;
- seqGrabRecord = 1;
- seqGrabPreview = 2;
- seqGrabPlayDuringRecord = 4;
- seqGrabHasBounds = 1;
- seqGrabHasVolume = 2;
- seqGrabHasDiscreteSamples = 4;
-
- noDeviceForChannel = -9400;
- grabTimeComplete = -9401;
- cantDoThatInCurrentMode = -9402;
- notEnoughMemoryToGrab = -9403;
- notEnoughDiskSpaceToGrab = -9404;
- couldntGetRequiredComponent = -9405;
- badSGChannel = -9406;
- seqGrabInfoNotAvailable = -9407;
- deviceCantMeetRequest = -9408;
-
- TYPE
- SeqGrabFrameInfo = RECORD
- frameOffset: LONGINT;
- frameTime: LONGINT;
- frameSize: LONGINT;
- frameChannel: SGChannel;
- frameRefCon: LONGINT;
- END;
-
-
-
- FUNCTION SGInitialize(s: SeqGrabComponent): ComponentResult;
- INLINE $2F3C,$0,$1,$7000,$A82A;
-
- FUNCTION SGSetDataOutput(s: SeqGrabComponent;VAR movieFile: FSSpec;whereFlags: LONGINT): ComponentResult;
- INLINE $2F3C,$8,$2,$7000,$A82A;
- FUNCTION SGGetDataOutput(s: SeqGrabComponent;VAR movieFile: FSSpec;VAR whereFlags: LONGINT): ComponentResult;
- INLINE $2F3C,$8,$3,$7000,$A82A;
-
- FUNCTION SGSetGWorld(s: SeqGrabComponent;gp: CGrafPtr;gd: GDHandle): ComponentResult;
- INLINE $2F3C,$8,$4,$7000,$A82A;
- FUNCTION SGGetGWorld(s: SeqGrabComponent;VAR gp: CGrafPtr;VAR gd: GDHandle): ComponentResult;
- INLINE $2F3C,$8,$5,$7000,$A82A;
-
- FUNCTION SGNewChannel(s: SeqGrabComponent;channelType: OSType;VAR ref: SGChannel): ComponentResult;
- INLINE $2F3C,$8,$6,$7000,$A82A;
- FUNCTION SGDisposeChannel(s: SeqGrabComponent;c: SGChannel): ComponentResult;
- INLINE $2F3C,$4,$7,$7000,$A82A;
-
- FUNCTION SGStartPreview(s: SeqGrabComponent): ComponentResult;
- INLINE $2F3C,$0,$10,$7000,$A82A;
- FUNCTION SGStartRecord(s: SeqGrabComponent): ComponentResult;
- INLINE $2F3C,$0,$11,$7000,$A82A;
- FUNCTION SGIdle(s: SeqGrabComponent): ComponentResult;
- INLINE $2F3C,$0,$12,$7000,$A82A;
- FUNCTION SGStop(s: SeqGrabComponent): ComponentResult;
- INLINE $2F3C,$0,$13,$7000,$A82A;
-
- FUNCTION SGPause(s: SeqGrabComponent;pause: BOOLEAN): ComponentResult;
- INLINE $2F3C,$2,$14,$7000,$A82A;
-
- FUNCTION SGPrepare(s: SeqGrabComponent;prepareForPreview: BOOLEAN;prepareForRecord: BOOLEAN): ComponentResult;
- INLINE $2F3C,$4,$15,$7000,$A82A;
- FUNCTION SGRelease(s: SeqGrabComponent): ComponentResult;
- INLINE $2F3C,$0,$16,$7000,$A82A;
-
- FUNCTION SGGetMovie(s: SeqGrabComponent): Movie;
- INLINE $2F3C,$0,$17,$7000,$A82A;
-
- FUNCTION SGSetMaximumRecordTime(s: SeqGrabComponent;ticks: LONGINT): ComponentResult;
- INLINE $2F3C,$4,$18,$7000,$A82A;
- FUNCTION SGGetMaximumRecordTime(s: SeqGrabComponent;VAR ticks: LONGINT): ComponentResult;
- INLINE $2F3C,$4,$19,$7000,$A82A;
-
- FUNCTION SGGetStorageSpaceRemaining(s: SeqGrabComponent;VAR bytes: LONGINT): ComponentResult;
- INLINE $2F3C,$4,$1A,$7000,$A82A;
- FUNCTION SGGetTimeRemaining(s: SeqGrabComponent;VAR ticksLeft: LONGINT): ComponentResult;
- INLINE $2F3C,$4,$1B,$7000,$A82A;
-
-
- FUNCTION SGGrabPict(s: SeqGrabComponent; VAR p: PicHandle; bounds: Rect;
- offscreenDepth: INTEGER; grabPictFlags: LONGINT): ComponentResult;
- INLINE $2F3C,$E,$1C,$7000,$A82A;
-
- FUNCTION SGGetLastMovieResID(s: SeqGrabComponent; VAR resID: INTEGER): ComponentResult;
- INLINE $2F3C,$4,$1D,$7000,$A82A;
-
- FUNCTION SGSetFlags(s: SeqGrabComponent; sgFlags: LONGINT): ComponentResult;
- INLINE $2F3C,$4,$1E,$7000,$A82A;
-
- FUNCTION SGGetFlags(s: SeqGrabComponent; VAR sgFlags: LONGINT): ComponentResult;
- INLINE $2F3C,$4,$1F,$7000,$A82A;
-
- { General Channel Routines }
- FUNCTION SGSetChannelUsage(c: SGChannel;usage: LONGINT): ComponentResult;
- INLINE $2F3C,$4,$80,$7000,$A82A;
- FUNCTION SGGetChannelUsage(c: SGChannel;VAR usage: LONGINT): ComponentResult;
- INLINE $2F3C,$4,$81,$7000,$A82A;
-
- FUNCTION SGSetChannelBounds(c: SGChannel;bounds: Rect): ComponentResult;
- INLINE $2F3C,$4,$82,$7000,$A82A;
- FUNCTION SGGetChannelBounds(c: SGChannel;VAR bounds: Rect): ComponentResult;
- INLINE $2F3C,$4,$83,$7000,$A82A;
-
- FUNCTION SGSetChannelVolume(c: SGChannel;volume: INTEGER): ComponentResult;
- INLINE $2F3C,$2,$84,$7000,$A82A;
- FUNCTION SGGetChannelVolume(c: SGChannel;VAR volume: INTEGER): ComponentResult;
- INLINE $2F3C,$4,$85,$7000,$A82A;
-
- FUNCTION SGGetChannelInfo(c: SGChannel;VAR channelInfo: LONGINT): ComponentResult;
- INLINE $2F3C,$4,$86,$7000,$A82A;
-
- FUNCTION SGSetChannelPlayFlags(c: SGChannel;playFlags: LONGINT): ComponentResult;
- INLINE $2F3C,$4,$87,$7000,$A82A;
- FUNCTION SGGetChannelPlayFlags(c: SGChannel;VAR playFlags: LONGINT): ComponentResult;
- INLINE $2F3C,$4,$88,$7000,$A82A;
-
- FUNCTION SGSetChannelMaxFrames(c: SGChannel;frameCount: LONGINT): ComponentResult;
- INLINE $2F3C,$4,$89,$7000,$A82A;
- FUNCTION SGGetChannelMaxFrames(c: SGChannel;VAR frameCount: LONGINT): ComponentResult;
- INLINE $2F3C,$4,$8A,$7000,$A82A;
-
- FUNCTION SGSetChannelRefCon(c: SGChannel;refCon: LONGINT): ComponentResult;
- INLINE $2F3C,$4,$8B,$7000,$A82A;
-
-
- TYPE
- { Video Routines }
-
- GrabProc = ComponentResult;
- GrabCompleteProc = ComponentResult;
- DisplayProc = ComponentResult;
- CompressProc = ComponentResult;
- CompressCompleteProc = ComponentResult;
- AddFrameProc = ComponentResult;
- TransferFrameProc = ComponentResult;
-
- VideoBottles = RECORD
- procCount: INTEGER;
- grabProc: GrabProc;
- grabCompleteProc: GrabCompleteProc;
- displayProc: DisplayProc;
- compressProc: CompressProc;
- addFrameProc: AddFrameProc;
- transferFrameProc: TransferFrameProc;
- END;
-
- SGCompressInfo = RECORD
- buffer: Ptr;
- bufferSize: LONGINT;
- similarity: CHAR;
- reserved: CHAR;
- END;
-
-
-
- FUNCTION SGGetSrcVideoBounds(c: SGChannel;VAR r: Rect): ComponentResult;
- INLINE $2F3C,$4,$100,$7000,$A82A;
- FUNCTION SGSetVideoRect(c: SGChannel;VAR r: Rect): ComponentResult;
- INLINE $2F3C,$4,$101,$7000,$A82A;
- FUNCTION SGGetVideoRect(c: SGChannel;VAR r: Rect): ComponentResult;
- INLINE $2F3C,$4,$102,$7000,$A82A;
-
- FUNCTION SGGetVideoCompressorType(c: SGChannel;VAR compressorType: OSType): ComponentResult;
- INLINE $2F3C,$4,$103,$7000,$A82A;
- FUNCTION SGSetVideoCompressorType(c: SGChannel;compressorType: OSType): ComponentResult;
- INLINE $2F3C,$4,$104,$7000,$A82A;
-
- FUNCTION SGSetVideoCompressor(c: SGChannel;depth: INTEGER;compressor: CompressorComponent;
- spatialQuality: CodecQ;temporalQuality: CodecQ;keyFrameRate: LONGINT): ComponentResult;
- INLINE $2F3C,$12,$105,$7000,$A82A;
- FUNCTION SGGetVideoCompressor(c: SGChannel;VAR depth: INTEGER;VAR compressor: CompressorComponent;
- VAR spatialQuality: CodecQ;VAR temporalQuality: CodecQ;VAR keyFrameRate: LONGINT): ComponentResult;
- INLINE $2F3C,$14,$106,$7000,$A82A;
-
- FUNCTION SGGetVideoDigitizerComponent(c: SGChannel): ComponentInstance;
- INLINE $2F3C,$0,$107,$7000,$A82A;
- FUNCTION SGSetVideoDigitizerComponent(c: SGChannel;vdig: ComponentInstance): ComponentResult;
- INLINE $2F3C,$4,$108,$7000,$A82A;
- FUNCTION SGVideoDigitizerChanged(c: SGChannel): ComponentResult;
- INLINE $2F3C,$0,$109,$7000,$A82A;
-
- FUNCTION SGSetVideoBottlenecks(c: SGChannel;VAR vb: VideoBottles): ComponentResult;
- INLINE $2F3C,$4,$10A,$7000,$A82A;
- FUNCTION SGGetVideoBottlenecks(c: SGChannel;VAR vb: VideoBottles): ComponentResult;
- INLINE $2F3C,$4,$10B,$7000,$A82A;
-
- FUNCTION SGGrabFrame(c: SGChannel;bufferNum: INTEGER): ComponentResult;
- INLINE $2F3C,$2,$10C,$7000,$A82A;
- FUNCTION SGGrabFrameComplete(c: SGChannel;bufferNum:INTEGER;VAR done:Boolean): ComponentResult;
- INLINE $2F3C,$6,$10D,$7000,$A82A;
-
- FUNCTION SGDisplayFrame(c: SGChannel;bufferNum: INTEGER;VAR mp: MatrixRecord;
- clipRgn: RgnHandle): ComponentResult;
- INLINE $2F3C,$A,$10E,$7000,$A82A;
- FUNCTION SGCompressFrame(c: SGChannel;bufferNum:INTEGER): ComponentResult;
- INLINE $2F3C,$2,$10F,$7000,$A82A;
- FUNCTION SGCompressFrameComplete(c: SGChannel;bufferNum:INTEGER;VAR done:Boolean;
- VAR ci:SGCompressInfo): ComponentResult;
- INLINE $2F3C,$A,$110,$7000,$A82A;
- FUNCTION SGAddFrame(c: SGChannel;bufferNum:INTEGER;atTime: TimeValue;scale: TimeScale;
- ci: SGCompressInfo): ComponentResult;
- INLINE $2F3C,$E,$111,$7000,$A82A;
-
- FUNCTION SGTransferFrameForCompress(c: SGChannel;bufferNum:INTEGER;mp: MatrixRecord;
- clipRgn: RgnHandle): ComponentResult;
- INLINE $2F3C,$A,$112,$7000,$A82A;
-
- FUNCTION SGSetCompressBuffer(c: SGChannel;depth: INTEGER;compressSize: Rect): ComponentResult;
- INLINE $2F3C,$6,$113,$7000,$A82A;
-
- FUNCTION SGGetCompressBuffer(c: SGChannel;VAR depth: INTEGER; VAR compressSize: Rect): ComponentResult;
- INLINE $2F3C,$8,$114,$7000,$A82A;
-
- FUNCTION SGGetBufferInfo(c: SGChannel;bufferNum: INTEGER; VAR bufferPM: PixMapHandle;
- VAR bufferRect: Rect;VAR compressBuffer: GWorldPtr;
- VAR compressBufferRect: Rect): ComponentResult;
- INLINE $2F3C,$12,$115,$7000,$A82A;
-
-
- { Sound Routines }
- FUNCTION SGSetSoundInputDriver(c: SGChannel;driverName: Str255): ComponentResult;
- INLINE $2F3C,$4,$100,$7000,$A82A;
- FUNCTION SGGetSoundInputDriver(c: SGChannel): LONGINT;
- INLINE $2F3C,$0,$101,$7000,$A82A;
- FUNCTION SGSoundInputDriverChanged(c: SGChannel): ComponentResult;
- INLINE $2F3C,$0,$102,$7000,$A82A;
-
- FUNCTION SGSetSoundRecordChunkSize(c: SGChannel;seconds: LONGINT): ComponentResult;
- INLINE $2F3C,$4,$103,$7000,$A82A;
- FUNCTION SGGetSoundRecordChunkSize(c: SGChannel): LONGINT;
- INLINE $2F3C,$0,$104,$7000,$A82A;
-
- FUNCTION SGSetSoundInputRate(c: SGChannel;rate: Fixed): ComponentResult;
- INLINE $2F3C,$4,$105,$7000,$A82A;
- FUNCTION SGGetSoundInputRate(c: SGChannel): Fixed;
- INLINE $2F3C,$0,$106,$7000,$A82A;
-
-
- { calls from seqGrab to Channel }
- FUNCTION SGInitChannel(c: SGChannel;owner: SeqGrabComponent): ComponentResult;
- INLINE $2F3C,$4,$C8,$7000,$A82A;
- FUNCTION SGWriteSamples(c: SGChannel;m: Movie;theFile: AliasHandle): ComponentResult;
- INLINE $2F3C,$8,$C9,$7000,$A82A;
- FUNCTION SGGetDataRate(c: SGChannel;VAR bytesPerSecond: LONGINT): ComponentResult;
- INLINE $2F3C,$4,$CA,$7000,$A82A;
-
-
- { calls from Channel to seqGrab }
- FUNCTION SGWriteMovieData(s: SeqGrabComponent;c: SGChannel;p: Ptr;len: LONGINT;
- VAR offset: LONGINT): ComponentResult;
- INLINE $2F3C,$10,$80,$7000,$A82A;
- FUNCTION SGAddFrameReference(s: SeqGrabComponent;VAR frameInfo: SeqGrabFrameInfo): ComponentResult;
- INLINE $2F3C,$4,$81,$7000,$A82A;
- FUNCTION SGGetNextFrameReference(s: SeqGrabComponent;VAR frameInfo: SeqGrabFrameInfo;
- VAR frameDuration: TimeValue;VAR frameNumber: LONGINT): ComponentResult;
- INLINE $2F3C,$C,$82,$7000,$A82A;
- FUNCTION SGGetTimeBase(s: SeqGrabComponent;VAR tb: TimeBase): ComponentResult;
- INLINE $2F3C,$4,$83,$7000,$A82A;
-
-
- {****
-
- Clock Component
-
- ****}
-
- CONST
-
- PreviewComponentType = 'prvt';
- { The subtypes of the preview components provided by Apple }
- FileInfoPrevCompSubType = 'finf';
- PICTPrevCompSubType = 'PICT';
- MoviePrevCompSubType = 'MooV';
-
- prevComponentCreatePreviewRefNum = 2;
- prevComponentGetPreviewData = 3;
- prevComponentAddPreviewRefNum = 5;
- prevComponentStartPreviewing = 11;
- prevComponentDoDraw = 12;
- prevComponentTimeSlice = 13;
- prevComponentDoMouseDown = 14;
- prevComponentLastCall = 15;
-
- prevComponentCantPreviewThisFile = -9999;
- prevComponentCouldGeneratePreviewForThisFile = -9998;
- prevComponentDontNeedTimeSlice = -9993;
-
- TYPE
- Previewer = ComponentInstance;
- ResourceDesc = RECORD
- resourceType: ResType;
- resourceId: INTEGER;
- END;
-
- ThumbnailList = RECORD
- date: LONGINT;
- version: INTEGER;
- prevComponentType: ResType;
- fileTypeDesc: Str31;
- fileTypeDescScript: INTEGER;
- count: INTEGER;
- resources: ARRAY [0..0] OF ResourceDesc;
- END;
- ThumbnailListPtr = ^ThumbnailList;
- ThumbnailListHandle = ^ThumbnailListPtr;
-
- Str31WithScript = RECORD
- theString: Str31;
- scriptCode: INTEGER;
- END;
- Str31WithScriptPtr = ^Str31WithScript;
- Str31WithScriptHandle = ^Str31WithScriptPtr;
-
- PreviewStatusRec = RECORD
- fileInfo: StandardFileReply;
- fileSize: LONGINT;
- resRefNum: INTEGER;
- PRVLHandle: ThumbnailListHandle;
- END;
- PreviewStatusPtr = ^PreviewStatusRec;
- PreviewStatusHandle = ^PreviewStatusPtr;
-
- FUNCTION PreviewCreatePreviewForResRefNum(p: Previewer; resRefNum: INTEGER;
- theFile: FSSpecPtr; removieOldPreviews: Boolean; fileTypeDescription: Str31WithScriptPtr;
- progressProc: ProgressProcRecordPtr): ComponentResult;
- INLINE $2F3C,$10,$2,$7000,$A82A;
-
- FUNCTION PreviewerGetPreviewData(p: Previewer; theFile: FSSpecPtr;
- previewData, auxData: Handle; progressProc: ProgressProcRecordPtr): ComponentResult;
- INLINE $2F3C,$10,$3,$7000,$A82A;
-
- FUNCTION PreviewerAddPreviewDataRefNum(p: Previewer; resRefNum: INTEGER;
- theFile: FSSpecPtr; removieOldPreviews: Boolean; fileTypeDescription: Str31WithScriptPtr;
- previewData, auxData: Handle): ComponentResult;
- INLINE $2F3C,$14,$5,$7000,$A82A;
-
- FUNCTION PreviewerStartPreviewing(p: Previewer; status: PreviewStatusPtr; window: WindowPtr;
- VAR boundsRect: Rect; VAR NeedInitialUpdate: Boolean): ComponentResult;
- INLINE $2F3C,$10,$B,$7000,$A82A;
-
- FUNCTION PreviewerDoDraw(p: Previewer; status: PreviewStatusPtr): ComponentResult;
- INLINE $2F3C,$4,$C,$7000,$A82A;
-
- FUNCTION PreviewerTimeSlice(p: Previewer; status: PreviewStatusPtr): ComponentResult;
- INLINE $2F3C,$4,$D,$7000,$A82A;
-
- FUNCTION PreviewerLastCall(p: Previewer; status: PreviewStatusPtr): ComponentResult;
- INLINE $2F3C,$4,$F,$7000,$A82A;
-
-
- {$ENDC} { UsingQuickTimeComponents }
-
- {$IFC NOT UsingIncludes}
- END.
- {$ENDC}
-
-