Changeset 128 for trunk/src/read_geometry_calib.m
- Timestamp:
- Nov 21, 2010, 10:06:11 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/read_geometry_calib.m
r71 r128 9 9 k=findstr('|',coord_str);%find separators '|' 10 10 if length(k)>=4 % test for separators '|' 11 data1=str2 num(coord_str(1:k(1)-5));12 data2=str2 num(coord_str(k(1)+5:k(2)-5));13 data3=str2 num(coord_str(k(2)+5:k(3)-5));14 data4=str2 num(coord_str(k(3)+5:k(4)-5));15 data5=str2 num(coord_str(k(4)+5:end));16 if ~is empty(data1)||~isempty(data2)||~isempty(data3)||~isempty(data4)||~isempty(data5)11 data1=str2double(coord_str(1:k(1)-2)); 12 data2=str2double(coord_str(k(1)+2:k(2)-2)); 13 data3=str2double(coord_str(k(2)+2:k(3)-2)); 14 data4=str2double(coord_str(k(3)+2:k(4)-2)); 15 data5=str2double(coord_str(k(4)+2:end)); 16 if ~isnan(data1)||~isnan(data2)||~isnan(data3)||~isnan(data4)||~isnan(data5) 17 17 iline=iline+1; 18 if ~is empty(data1)18 if ~isnan(data1) 19 19 data.Coord(iline,1)=data1; 20 20 end 21 if ~is empty(data2)21 if ~isnan(data2) 22 22 data.Coord(iline,2)=data2; 23 23 end 24 if ~is empty(data3)24 if ~isnan(data3) 25 25 data.Coord(iline,3)=data3; 26 26 end 27 if ~is empty(data4)27 if ~isnan(data4) 28 28 data.Coord(iline,4)=data4; 29 29 end 30 if is empty(data5)30 if isnan(data5) 31 31 data.Coord(iline,5)=0; 32 32 else
Note: See TracChangeset
for help on using the changeset viewer.