hedgewars/uVideoRec.pas
changeset 14900 002f7d41f5ce
parent 14482 9844450389a4
child 14908 a414d37278df
equal deleted inserted replaced
14899:4e3d81af71bf 14900:002f7d41f5ce
    66                   CamX, CamY: LongInt;
    66                   CamX, CamY: LongInt;
    67                   zoom: single;
    67                   zoom: single;
    68               end;
    68               end;
    69 
    69 
    70 var RGB_Buffer: PByte;
    70 var RGB_Buffer: PByte;
    71     cameraFile: File of TFrame;
    71     cameraFile: File;
    72     audioFile: File;
    72     audioFile: File;
    73     numPixels: LongWord;
    73     numPixels: LongWord;
    74     startTime, numFrames, curTime, progress, maxProgress: LongWord;
    74     startTime, numFrames, curTime, progress, maxProgress: LongWord;
    75     soundFilePath: shortstring;
    75     soundFilePath: shortstring;
    76     thumbnailSaved: boolean;
    76     thumbnailSaved: boolean;
    83 
    83 
    84 {$IOCHECKS OFF}
    84 {$IOCHECKS OFF}
    85     // open file with prerecorded camera positions
    85     // open file with prerecorded camera positions
    86     filename:= UserPathPrefix + '/VideoTemp/' + RecPrefix + '.txtin';
    86     filename:= UserPathPrefix + '/VideoTemp/' + RecPrefix + '.txtin';
    87     Assign(cameraFile, filename);
    87     Assign(cameraFile, filename);
    88     Reset(cameraFile);
    88     Reset(cameraFile, SizeOf(TFrame));
    89     maxProgress:= FileSize(cameraFile);
    89     maxProgress:= FileSize(cameraFile);
    90     if IOResult <> 0 then
    90     if IOResult <> 0 then
    91     begin
    91     begin
    92         AddFileLog('Error: Could not read from ' + filename);
    92         AddFileLog('Error: Could not read from ' + filename);
    93         exit(false);
    93         exit(false);
   312         end;
   312         end;
   313 
   313 
   314     // create file with camera positions
   314     // create file with camera positions
   315     filename:= UserPathPrefix + '/VideoTemp/' + RecPrefix + '.txtout';
   315     filename:= UserPathPrefix + '/VideoTemp/' + RecPrefix + '.txtout';
   316     Assign(cameraFile, filename);
   316     Assign(cameraFile, filename);
   317     Rewrite(cameraFile);
   317     Rewrite(cameraFile, SizeOf(TFrame));
   318     if IOResult <> 0 then
   318     if IOResult <> 0 then
   319         begin
   319         begin
   320         AddFileLog('Error: Could not write to ' + filename);
   320         AddFileLog('Error: Could not write to ' + filename);
   321         exit;
   321         exit;
   322         end;
   322         end;