procedure ExtractEvenField(NewWindow:boolean); { Replaces odd scan lines with average of neighboring even lines. Can be used to improve the quality of images that have even and odd fields that are out of sync as the result of subject movement during capture. } var i,width,height,row1,row2:integer; begin SaveState; if NewWindow then Duplicate('Even Field'); GetPicSize(width,height); row1:=0; row2:=0; for i:=1 to height/2 do begin GetRow(0,row1,width); PutRow(0,row2,width); row1:=row1+2; row2:=row2+1; end; MakeRoi(0,0,width,height/2); Copy; MakeRoi(0,height/4-1,width,height/2); Paste; RestoreRoi; SetScaling('Bilinear; Same Window'); ScaleAndRotate(1,2,0); RestoreState; end; macro 'Extract Even Field->New Window'; begin ExtractEvenField(true); end; macro 'Extract Even Field->Same Window'; begin ExtractEvenField(false); end; macro 'Make Movie to DiskÉ'; { Captures a specified number of images at a specified rate and saves them to disk. Select an area of interest within the Camera window before starting. Can be aborted with cmd-period. } var nFrames,n,Left,Top,Width,Height:integer; IntervalTicks,EndTicks,secs:integer; begin RequiresVersion(1.49); GetRoi(Left,Top,Width,Height); if width=0 then begin PutMessage('First select the area of interest in the Camera window.'); exit; end; nFrames:=GetNumber('Number of Frames?',10); IntervalTicks:=round(GetNumber('Delay Between Frames(seconds)?',60)*60); EndTicks:=TickCount+IntervalTicks; for n:=1 to nFrames do begin StopCapturing; MakeRoi(Left,Top,Width,Height); SaveAs('Frame ',n); StartCapturing; while TickCount