189
189
normxcorr_hw(hwid, 3, base_points_x, base_points_y);
190
190
normxcorr_hw(hwid, 4, base);
192
normxcorr_hw(hwid, 5);
194
192
base_points_for(:,1)=reshape(base_points_x,[],1);
195
193
base_points_for(:,2)=reshape(base_points_y,[],1);
271
269
input_correl(:,2)=reshape(input_points_y,[],1);
272
input = uint8(mean(double(imread([imagedir, filenamelist((firstimage+1),:)])),3)); % read in the image which has to be correlated
274
273
for i=firstimage:(r-1) % run through all images
275
274
tic % start the timer
277
input = uint8(mean(double(imread([imagedir, filenamelist((i+1),:)])),3)); % read in the image which has to be correlated
276
% input = uint8(mean(double(imread([imagedir, filenamelist((i+1),:)])),3)); % read in the image which has to be correlated
280
279
%Validate findpeak
281
280
%dic_cpcorr3(CORRSIZE, PRECISION, OPTIMIZE, hwid, ncp, input);
283
281
normxcorr_hw(hwid, 13, input)
283
input = uint8(mean(double(imread([imagedir, filenamelist((i+2),:)])),3)); % read in the image which has to be correlated
284
285
input_correl = normxcorr_hw(hwid, 14);
285
286
elseif OPTIMIZE > 0
286
287
input_correl(:,:)=dic_cpcorr(CORRSIZE, PRECISION, OPTIMIZE, hwid, data_base, input_correl, input);
288
289
input_correl(:,:)=cpcorr(input_correl, base_points_for, input, base);
292
293
validx(:,i)=double(input_correl(:,1)); % the results we get from cpcorr for the x-direction
293
294
validy(:,i)=double(input_correl(:,2)); % the results we get from cpcorr for the y-direction