Changeset 343 for trunk/src/find_file_series.m
- Timestamp:
- Dec 21, 2011, 10:12:13 AM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/find_file_series.m
r342 r343 5 5 % OUTPUT: 6 6 % RootPath,RootFile: root path and root name detected in fileinput, possibly modified for movies (indexing is then done on image view, not file) 7 % i1_series(ref_i, ref_j,pair),i2_series,j1_series,j2_series: set of indices (i1,i2,j1,j2) sorted by ref index ref_i, ref_j, and pairindex in case of multiple pairs with the same ref 7 % i1_series(ref_i+1, ref_j+1,pair),i2_series,j1_series,j2_series: set of indices (i1,i2,j1,j2) sorted by ref index ref_i, ref_j, and pairindex in case of multiple pairs with the same ref 8 % (ref_i+1 is used to deal with the image index zero sometimes used) 8 9 % NomType: nomenclature type corrected after checking the first file (problem of 0 before the number string) 9 10 % FileType: type of file, = … … 129 130 for ifile=1:nbpair 130 131 [~,~,~,i1,i2,j1,j2]=fileparts_uvmat(dirpair(ifile).name); 131 % i1_series(ifile)=i1;132 132 ref_i=i1; 133 133 if isempty(i2_input) … … 162 162 nb_pairs=0; 163 163 if ~isempty(i2_input)|| ~isempty(j2_input) %deals with pairs 164 if size(i1_series,1)>=ref_i && size(i1_series,2)>=ref_j165 nb_pairs=numel(find(i1_series(ref_i ,ref_j,:)~=0));166 end 167 end 168 i1_series(ref_i ,ref_j,nb_pairs+1)=i1;164 if size(i1_series,1)>=ref_i+1 && size(i1_series,2)>=ref_j+1 165 nb_pairs=numel(find(i1_series(ref_i+1,ref_j+1,:)~=0)); 166 end 167 end 168 i1_series(ref_i+1,ref_j+1,nb_pairs+1)=i1; 169 169 if ~isempty(i2_input) 170 i2_series(ref_i ,ref_j,nb_pairs+1)=i2;170 i2_series(ref_i+1,ref_j+1,nb_pairs+1)=i2; 171 171 end 172 172 if ~isempty(j1_input) 173 j1_series(ref_i ,ref_j,nb_pairs+1)=j1;173 j1_series(ref_i+1,ref_j+1,nb_pairs+1)=j1; 174 174 end 175 175 if ~isempty(j2_input) 176 j1_series(ref_i ,ref_j,nb_pairs+1)=j1;177 j2_series(ref_i ,ref_j,nb_pairs+1)=j2;176 j1_series(ref_i+1,ref_j+1,nb_pairs+1)=j1; 177 j2_series(ref_i+1,ref_j+1,nb_pairs+1)=j2; 178 178 end 179 179 end
Note: See TracChangeset
for help on using the changeset viewer.