Index: /trunk/src/series/civ_input.m
===================================================================
--- /trunk/src/series/civ_input.m	(revision 832)
+++ /trunk/src/series/civ_input.m	(revision 833)
@@ -66,8 +66,7 @@
 SeriesData=get(hseries,'UserData');% info stored in the GUI series 
 
-%% set visibility options: 
-if strcmp(Param.Action.ActionName,'civ_series')
-    %  set(handles.Program,'String','civ_series')
-    set(handles.num_MaxDiff,'Visible','on')
+%% set visibility options depending on the calling function (Param.Action.ActionName): 
+if strcmp(Param.Action.ActionName,'civ_series')||strcmp(Param.Action.ActionName,'stereo_civ')
+     set(handles.num_MaxDiff,'Visible','on')
     set(handles.num_MaxVel,'Visible','on')
     set(handles.title_MaxVel,'Visible','on')
@@ -84,4 +83,12 @@
     set(handles.CheckDecimal,'Value',0)% desactivate (work in progress)
 end
+switch Param.Action.ActionName
+    case 'stereo_civ'
+        set(handles.ListCompareMode,'Visible','off')
+        set(handles.PairIndices,'Visible','off')
+    case 'civ_series'
+        set(handles.ListCompareMode,'Visible','on')
+        set(handles.PairIndices,'Visible','on')
+end
 
 %% input file info
@@ -140,8 +147,8 @@
         return
 end
-if isfield(SeriesData,'FileType') && numel(SeriesData.FileType)>=2 && strcmp(SeriesData.FileType{end-1},'image') &&   strcmp(SeriesData.FileType{end},'image')
-    set(handles.ListCompareMode,'Value',3)% we compare two image series term to term ('shift')
-    set(handles.PairIndices,'Visible','off')
-end
+% if isfield(SeriesData,'FileType') && numel(SeriesData.FileType)>=2 && strcmp(SeriesData.FileType{end-1},'image') &&   strcmp(SeriesData.FileType{end},'image')
+%     set(handles.ListCompareMode,'Value',3)% we compare two image series term to term ('shift')
+%     set(handles.PairIndices,'Visible','off')
+% end
 
 %% reinitialise menus
@@ -154,5 +161,5 @@
         
 %% prepare the GUI with input parameters 
-set(handles.ListCompareMode,'Visible','on')
+% 
 set(handles.ref_i,'String',num2str(Param.IndexRange.first_i))
 if isfield(Param.IndexRange,'first_j')
@@ -258,5 +265,5 @@
 
 %% introduce the stored Civ parameters  if available (from previous input or ImportConfig in series)
-if isfield(Param,'ActionInput')
+if isfield(Param,'ActionInput')&& strcmp(Param.ActionInput.Program,Param.Action.ActionName)% the program fits with the stored data
     fill_GUI(Param.ActionInput,hObject);%fill the GUI with the parameters retrieved from the input Param
     hcheckgrid=findobj(handles.civ_input,'Tag','CheckGrid');
@@ -439,5 +446,5 @@
 checkbox(6)=get(handles.CheckPatch2,'Value');
 % ind_selected=find(checkbox,1);
-set(handles.PairIndices,'Visible','on')% make the frame PaiIndices visible, choice of the index pairs fo civ
+%set(handles.PairIndices,'Visible','on')% make the frame PaiIndices visible, choice of the index pairs fo civ
 if opening==0
     errormsg=find_netcpair_civ(handles,1); % select the available netcdf files
@@ -622,13 +629,13 @@
     case 'displacement'
         OriginIndex='on';%define a frame origin for displacement
-    case 'shift'
-        if numel(ImageType)==1
-            fileinput=uigetfile_uvmat('pick a second file series for synchronous shift',InputTable{check_nc+1});
-            if ~isempty(fileinput)
-                series( 'display_file_name',hhseries,fileinput,'append')
-            end
-            
-            
-        end
+%     case 'shift'
+%         if numel(ImageType)==1
+%             fileinput=uigetfile_uvmat('pick a second file series for synchronous shift',InputTable{check_nc+1});
+%             if ~isempty(fileinput)
+%                 series( 'display_file_name',hhseries,fileinput,'append')
+%             end
+%             
+%             
+%         end
 end
 set(handles.num_OriginIndex,'Visible',OriginIndex)
Index: /trunk/src/series/civ_series.m
===================================================================
--- /trunk/src/series/civ_series.m	(revision 832)
+++ /trunk/src/series/civ_series.m	(revision 833)
@@ -285,8 +285,8 @@
 %% get timing from the ImaDoc file or input video
 if iview_A~=0
-XmlFileName=find_imadoc(RootPath_A,SubDir_A,RootFile_A,FileExt_A);
-time=[];
-if ~isempty(XmlFileName)
-    XmlData=imadoc2struct(XmlFileName);
+    XmlFileName=find_imadoc(RootPath_A,SubDir_A,RootFile_A,FileExt_A);
+    time=[];
+    if ~isempty(XmlFileName)
+        XmlData=imadoc2struct(XmlFileName);
         if isfield(XmlData,'Time')
             time=XmlData.Time;
@@ -304,26 +304,26 @@
             end
         end
-end
-if isempty(time) && ~isempty(find(strcmp(FileType_A,{'mmreader','video'})))% case of video input
-    time=zeros(FileInfo_A.NumberOfFrames+1,2);
-    time(:,2)=(0:1/FileInfo_A.FrameRate:(FileInfo_A.NumberOfFrames)/FileInfo_A.FrameRate)';
-    TimeSource='video';
-    ColorType='truecolor';
-end
-if isempty(time)% time = index i +0.001 index j by default
-    %MinIndex_i=min(i1_series_Civ1);
-    MaxIndex_i=max(i2_series_Civ1);
-    %MinIndex_j=min(j1_series_Civ1);
-    MaxIndex_j=max(j2_series_Civ1);
-    time=(1:MaxIndex_i)'*ones(1,MaxIndex_j);
-    time=time+0.001*ones(MaxIndex_i,1)*(1:MaxIndex_j);
-    time=[zeros(1,MaxIndex_j);time];% insert a first line of zeros
-    time=[zeros(MaxIndex_i+1,1) time];% insert a first column of zeros
-end
+    end
+    if isempty(time) && ~isempty(find(strcmp(FileType_A,{'mmreader','video'})))% case of video input
+        time=zeros(FileInfo_A.NumberOfFrames+1,2);
+        time(:,2)=(0:1/FileInfo_A.FrameRate:(FileInfo_A.NumberOfFrames)/FileInfo_A.FrameRate)';
+        TimeSource='video';
+        ColorType='truecolor';
+    end
+    if isempty(time)% time = index i +0.001 index j by default
+        %MinIndex_i=min(i1_series_Civ1);
+        MaxIndex_i=max(i2_series_Civ1);
+        %MinIndex_j=min(j1_series_Civ1);
+        MaxIndex_j=max(j2_series_Civ1);
+        time=(1:MaxIndex_i)'*ones(1,MaxIndex_j);
+        time=time+0.001*ones(MaxIndex_i,1)*(1:MaxIndex_j);
+        time=[zeros(1,MaxIndex_j);time];% insert a first line of zeros
+        time=[zeros(MaxIndex_i+1,1) time];% insert a first column of zeros
+    end
     
-if length(FileInfo_A) >1 %case of image with multiple frames
-    nbfield=length(FileInfo_A);
-    nbfield_j=1;
-end
+    if length(FileInfo_A) >1 %case of image with multiple frames
+        nbfield=length(FileInfo_A);
+        nbfield_j=1;
+    end
 end
 
Index: /trunk/src/series/extract_rdvision.m
===================================================================
--- /trunk/src/series/extract_rdvision.m	(revision 832)
+++ /trunk/src/series/extract_rdvision.m	(revision 833)
@@ -367,5 +367,5 @@
 OutputDir=fullfile(PathDir,SeqData.sequencename)
 if exist(OutputDir,'dir')
-    errormsg=[OutpuDir ' already exist, delete it first'];
+    errormsg=[OutputDir ' already exist, delete it first'];
     return
 end
