You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
25 lines
607 B
Matlab
25 lines
607 B
Matlab
function [I,xcent,ycent]=image_feature_sub(gridsize,len,wid,spacing,angle,contrast,backgnd)
|
|
%create a search array with odd target defined by missing element
|
|
|
|
if nargin<6, contrast=0.5; end
|
|
if nargin<7, backgnd=0.5; end
|
|
|
|
bar=define_bar(len,wid);
|
|
[I,gridsize,xlocations,ylocations]=define_blank_image(gridsize,len,spacing,backgnd);
|
|
|
|
a=0;
|
|
for x=xlocations
|
|
a=a+1;
|
|
b=0;
|
|
for y=ylocations
|
|
b=b+1;
|
|
I=draw_bar(I,x,y,bar,angle,contrast,backgnd);
|
|
if a~=ceil(length(xlocations)/2) | b~=ceil(length(ylocations)/2)
|
|
I=draw_bar(I,x,y,bar,angle-90,contrast,backgnd);
|
|
else
|
|
xcent=x;
|
|
ycent=y;
|
|
end
|
|
end
|
|
end
|