-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathSector_Drawing.m
More file actions
33 lines (27 loc) · 1.6 KB
/
Sector_Drawing.m
File metadata and controls
33 lines (27 loc) · 1.6 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
function I=Sector_Drawing(str,I,x_center, y_center)
[M,~,~]=size(I);
M = floor(M);
c_Unit = M/12;
switch str
case 7
I = insertShape(I,'circle',[x_center y_center c_Unit],'LineWidth',2,'color','green');
I = insertShape(I,'circle',[x_center y_center 3*c_Unit],'LineWidth',2,'color','green');
I = insertShape(I,'circle',[x_center y_center 5*c_Unit],'LineWidth',2,'color','green');
case 6
I = insertShape(I,'circle',[x_center y_center 2*c_Unit],'LineWidth',2,'color','green');
I = insertShape(I,'circle',[x_center y_center 4*c_Unit],'LineWidth',2,'color','green');
I = insertShape(I,'circle',[x_center y_center 6*c_Unit],'LineWidth',2,'color','green');
case 5
I = insertShape(I,'circle',[x_center y_center 3*c_Unit],'LineWidth',2,'color','green');
I = insertShape(I,'circle',[x_center y_center 5*c_Unit],'LineWidth',2,'color','green');
I = insertShape(I,'circle',[x_center y_center 7*c_Unit],'LineWidth',2,'color','green');
case 4
I = insertShape(I,'circle',[x_center y_center 4*c_Unit],'LineWidth',2,'color','green');
I = insertShape(I,'circle',[x_center y_center 6*c_Unit],'LineWidth',2,'color','green');
I = insertShape(I,'circle',[x_center y_center 8*c_Unit],'LineWidth',2,'color','green');
case 3
I = insertShape(I,'circle',[x_center y_center 5*c_Unit],'LineWidth',2,'color','green');
I = insertShape(I,'circle',[x_center y_center 7*c_Unit],'LineWidth',2,'color','green');
I = insertShape(I,'circle',[x_center y_center 9*c_Unit],'LineWidth',2,'color','green');
end
end