Changeset 343 for trunk/src/read_xls.m


Ignore:
Timestamp:
Dec 21, 2011, 10:12:13 AM (12 years ago)
Author:
sommeria
Message:

-bugs repaired in civ
-change in find_file_series to account for possible file index 0
-name2display suppressed in all functions, replaced by fileparts_uvmat (except incorporated in civ_3D)
-open_uvmat introduced to open files from a list

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/read_xls.m

    r19 r343  
    185185                       testrecord=0;%we have an image series without 'record' subdir
    186186                    elseif isequal(Ext,'.png')
    187                        [Path,Root,field_count,str2,str_a,str_b,ext,nom_type,subdir]=name2display(fname{ifile});
     187                       %[Path,Root,field_count,str2,str_a,str_b,ext,nom_type,subdir]=name2display(fname{ifile});
     188                       [~,~,Root]=fileparts_uvmat(fname{ifile});
    188189                       if ~isequal(Root,RootIma)%only one image recorded for each root name
    189190                           [t,ImaDocElement]=add(t,DeviceElement,'element','Image');
     
    194195                       testrecord=0;%we have an image series without 'record' subdir
    195196                    elseif isequal(Ext,'.nc')
    196                        [Path,Root,field_count,str2,str_a,str_b,ext,nom_type,subdir]=name2display(fname{ifile});
     197                       %[Path,Root,field_count,str2,str_a,str_b,ext,nom_type,subdir]=name2display(fname{ifile});
     198                       [~,~,Root]=fileparts_uvmat(fname{ifile});
    197199                       if ~isequal(Root,RootNc)%only one image recorded for each root name
    198200                           [t,ImaDocElement]=add(t,DeviceElement,'element','Ncdata');
     
    240242                               t=attributes(t,'add',ImaDocElement,'source','file');
    241243                            elseif isequal(Ext,'.png')
    242                                [Path,Root,field_count,str2,str_a,str_b,ext,nom_type,subdir]=name2display(fname{ifile});
     244                              % [Path,Root,field_count,str2,str_a,str_b,ext,nom_type,subdir]=name2display(fname{ifile});
     245                                [~,~,Root]=fileparts_uvmat(fname{ifile});
    243246                               if ~isequal(Root,RootIma)
    244247                                   [t,ImaDocElement]=add(t,DeviceElement,'element','Image');
     
    248251                               end
    249252                            elseif isequal(Ext,'.nc')
    250                                [Path,Root,field_count,str2,str_a,str_b,ext,nom_type,subdir]=name2display(fname{ifile});
     253                               %[Path,Root,field_count,str2,str_a,str_b,ext,nom_type,subdir]=name2display(fname{ifile});
     254                               [~,~,Root]=fileparts_uvmat(fname{ifile});
    251255                               if ~isequal(Root,RootNc)%only one image recorded for each root name
    252256                                  [t,ImaDocElement]=add(t,DeviceElement,'element','Ncdata');
     
    290294                            [Path,Name,Ext]=fileparts(fname{ifile});
    291295                            if isequal(Ext,'.xml')
    292                                [Path,Root,field_count,str2,str_a,str_b,ext,nom_type,subdir]=name2display(fname{ifile});
     296                               %[Path,Root,field_count,str2,str_a,str_b,ext,nom_type,subdir]=name2display(fname{ifile});
     297                               [~,~,Root]=fileparts_uvmat(fname{ifile});
    293298                               if ~isequal(Root,RootXml)%only one image recorded for each root name
    294299                                   [t,ImaDocElement]=add(t,RecordElement,'element','CivDoc');
     
    298303                               end
    299304                            elseif isequal(Ext,'.nc')
    300                                [Path,Root,field_count,str2,str_a,str_b,ext,nom_type,subdir]=name2display(fname{ifile});
     305                               %[Path,Root,field_count,str2,str_a,str_b,ext,nom_type,subdir]=name2display(fname{ifile});
     306                               [~,~,Root]=fileparts_uvmat(fname{ifile});
    301307                               if ~isequal(Root,RootNc)%only one image recorded for each root name
    302308                                  [t,ImaDocElement]=add(t,RecordElement,'element','Ncdata');
Note: See TracChangeset for help on using the changeset viewer.