Skip to content
Snippets Groups Projects

Update frameAcquired_Box.m

Merged Dorian Röders requested to merge roededy1-master-patch-81001 into master
1 file
+ 2
2
Compare changes
  • Side-by-side
  • Inline
@@ -22,10 +22,10 @@ ctr(2)=0;
% invert logic for white/ balck background
if strcmp(vTrck.trckCol,'white')
% threshold the frame and check for median x value of tracked object
mat=sum(sum(getdata(vid,1),3)>vTrck.blobThresholdW);
mat=sum(sum(getdata(vid,1),3)>vTrck.blobThresholdW & vTrck.mask);
ctr(1)=round(median(find(mat)));
else
mat=sum(sum(getdata(vid,1),3)<vTrck.blobThresholdB);
mat=sum(sum(getdata(vid,1),3)<vTrck.blobThresholdB & vTrck.mask);
ctr(1)=round(median(find(mat)));
end
Loading