Changeset 548
- Timestamp:
- Oct 10, 2012, 11:25:35 PM (12 years ago)
- Location:
- trunk/src
- Files:
-
- 1 deleted
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/check_files.m
r530 r548 85 85 'read_civdata';... reads new civ data from netcdf files 86 86 'read_field';...% read the fields from files in different formats (netcdf files, images, video) 87 'read_get_field';... read the list of selected variables from the GUI get_field (TODO: use read_GUI)87 % 'read_get_field';... read the list of selected variables from the GUI get_field (TODO: use read_GUI) 88 88 'read_GUI';... %read a GUI and provide the data as a Matlab structure 89 89 'read_image';...%read images or video objects -
trunk/src/civ.m
r547 r548 3776 3776 set(0,'CurrentFigure',hview_field) 3777 3777 hhview_field=guihandles(hview_field); 3778 set(hview_field,'CurrentAxes',hhview_field. axes3)3778 set(hview_field,'CurrentAxes',hhview_field.PlotAxes) 3779 3779 ViewData=get(hview_field,'UserData'); 3780 3780 ViewData.CivHandle=handles.civ;% indicate the handle of the civ GUI in view_field 3781 ViewData. axes3.B=imread(filecell.ima2.civ1{1});%store the second image in the UserData of the GUI view_field3782 ViewData. axes3.X=Grid.Civ1_X; %keep the set of points in memeory3783 ViewData. axes3.Y=Grid.Civ1_Y;3781 ViewData.PlotAxes.B=imread(filecell.ima2.civ1{1});%store the second image in the UserData of the GUI view_field 3782 ViewData.PlotAxes.X=Grid.Civ1_X; %keep the set of points in memeory 3783 ViewData.PlotAxes.Y=Grid.Civ1_Y; 3784 3784 set(hview_field,'UserData',ViewData) 3785 3785 corrfig=findobj(allchild(0),'tag','corrfig');% look for a current figure for image correlation display -
trunk/src/civ_matlab.m
r497 r548 100 100 end 101 101 else 102 if isfield(Param.Civ1,'ImageA') %&&...102 if isfield(Param.Civ1,'ImageA') && ischar(Param.Civ1.ImageA) 103 103 Param.Civ1.ImageA=regexprep(Param.Civ1.ImageA,'''','\'); 104 104 [par_civ1.ImageA,VideoObject] = read_image(Param.Civ1.ImageA,par_civ1.FileTypeA,[],par_civ1.FrameIndexA); 105 105 end 106 if isfield(Param.Civ1,'ImageB') %&& ...106 if isfield(Param.Civ1,'ImageB')&& ischar(Param.Civ1.ImageB) 107 107 Param.Civ1.ImageB=regexprep(Param.Civ1.ImageB,'''','\'); 108 108 if strcmp(Param.Civ1.ImageA,Param.Civ1.ImageB)% use the same movie object -
trunk/src/sub_field.m
r520 r548 45 45 end 46 46 if ~isfield(Field,AttrName) || ~isequal(Field_1.(AttrName),Field.(AttrName)) 47 SubData.ListGlobalAttribute=[SubData.ListGlobalAttribute {AttrNameNew}];48 SubData.(AttrNameNew)=Field_1.(AttrName);47 SubData.ListGlobalAttribute=[SubData.ListGlobalAttribute {AttrNameNew}]; 48 SubData.(AttrNameNew)=Field_1.(AttrName); 49 49 end 50 50 end … … 149 149 150 150 %% substrat fields when possible 151 [CellVarIndex,NbDim,CellVarType,errormsg]=find_field_cells(SubData); 151 %[CellVarIndex,NbDim,CellVarType,errormsg]=find_field_cells(SubData); 152 [CellInfo,NbDim,errormsg]=find_field_cells(SubData) 152 153 ind_remove=zeros(size(SubData.ListVarName)); 153 154 ivar=[]; 154 155 ivar_1=[]; 155 for icell=1:numel(Cell VarIndex)156 if ~isempty(Cell VarIndex{icell})157 if isfield(Cell VarType{icell},'scalar') && numel(CellVarType{icell}.scalar)==2 && SubData.VarAttribute{CellVarType{icell}.scalar(2)}.CheckSub;158 ivar=[ivar Cell VarType{icell}.scalar(1)];159 ivar_1=[ivar_1 Cell VarType{icell}.scalar(2)];156 for icell=1:numel(CellInfo) 157 if ~isempty(CellInfo{icell}) 158 if isfield(CellInfo{icell},'VarIndex_scalar') && numel(CellInfo{icell}.VarIndex_scalar)==2 && SubData.VarAttribute{CellInfo{icell}.VarIndex_scalar(2)}.CheckSub; 159 ivar=[ivar CellInfo{icell}.VarIndex_scalar(1)]; 160 ivar_1=[ivar_1 CellInfo{icell}.VarIndex_scalar(2)]; 160 161 end 161 if isfield(Cell VarType{icell},'vector_x') && numel(CellVarType{icell}.vector_x)==2 && SubData.VarAttribute{CellVarType{icell}.vector_x(2)}.CheckSub;162 ivar=[ivar Cell VarType{icell}.vector_x(1)];163 ivar_1=[ivar_1 Cell VarType{icell}.vector_x(2)];162 if isfield(CellInfo{icell},'VarIndex_vector_x') && numel(CellInfo{icell}.VarIndex_vector_x)==2 && SubData.VarAttribute{CellInfo{icell}.VarIndex_vector_x(2)}.CheckSub; 163 ivar=[ivar CellInfo{icell}.VarIndex_vector_x(1)]; 164 ivar_1=[ivar_1 CellInfo{icell}.VarIndex_vector_x(2)]; 164 165 end 165 if isfield(Cell VarType{icell},'vector_y') && numel(CellVarType{icell}.vector_y)==2 && SubData.VarAttribute{CellVarType{icell}.vector_y(2)}.CheckSub;166 ivar=[ivar Cell VarType{icell}.vector_y(1)];167 ivar_1=[ivar_1 Cell VarType{icell}.vector_y(2)];166 if isfield(CellInfo{icell},'VarIndex_vector_y') && numel(CellInfo{icell}.VarIndex_vector_y)==2 && SubData.VarAttribute{CellInfo{icell}.VarIndex_vector_y(2)}.CheckSub; 167 ivar=[ivar CellInfo{icell}.VarIndex_vector_y(1)]; 168 ivar_1=[ivar_1 CellInfo{icell}.VarIndex_vector_y(2)]; 168 169 end 169 170 end … … 172 173 VarName=SubData.ListVarName{ivar(imod)}; 173 174 VarName_1=SubData.ListVarName{ivar_1(imod)}; 174 SubData.(VarName)= SubData.(VarName)-SubData.(VarName_1);175 SubData.(VarName)=double(SubData.(VarName))-double(SubData.(VarName_1)); 175 176 ind_remove(ivar_1(imod))=1; 176 177 end -
trunk/src/uvmat.m
r546 r548 791 791 TimeUnit='';%default 792 792 Time=[]; 793 testima=0; %test for image input793 % testima=0; %test for image input 794 794 imainfo=[]; 795 795 ColorType='falsecolor'; %default 796 hhh=[];796 % hhh=[]; 797 797 UvData.MovieObject{index}=VideoObject; 798 798 if ~isempty(VideoObject) 799 799 imainfo=get(VideoObject); 800 testima=1;800 % testima=1; 801 801 TimeUnit='s'; 802 802 if isempty(j1_series); %frame index along i 803 803 Time=(0:1/imainfo.FrameRate:(imainfo.NumberOfFrames)/imainfo.FrameRate)'; 804 804 else 805 Time=ones(size(i1_series,1),1)*(0:1/imainfo.FrameRate:(imainfo.NumberOfFrames)/imainfo.FrameRate); 806 end 807 %nbfield=imainfo.NumberOfFrames; 805 Time=ones(size(i1_series,1),1)*(0:1/imainfo.FrameRate:(imainfo.NumberOfFrames)/imainfo.FrameRate); 806 end 808 807 set(handles.Dt_txt,'String',['Dt=' num2str(1000/imainfo.FrameRate) 'ms']);%display the elementary time interval in millisec 809 808 ColorType='truecolor'; 810 809 elseif ~isempty(FileExt(2:end))&&(~isempty(imformats(FileExt(2:end))) || isequal(FileExt,'.vol'))%&& isequal(NomType,'*')% multi-frame image 811 testima=1;810 % testima=1; 812 811 if ~isequal(SubDir,'') 813 RootFile=get(handles.RootFile,'String');814 812 imainfo=imfinfo([fullfile(RootPath,SubDir,RootFile) FileIndices FileExt]); 815 813 else … … 817 815 end 818 816 ColorType=imainfo.ColorType;%='truecolor' for color images 819 if length(imainfo) >1 %case of image with multiple frames820 % nbfield=length(imainfo);821 % nbfield_j=1;822 end823 817 end 824 818 if isfield(imainfo,'Width') && isfield(imainfo,'Height')
Note: See TracChangeset
for help on using the changeset viewer.