Changeset 621
- Timestamp:
- Apr 26, 2013, 8:12:29 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/civ.m
r611 r621 512 512 set(handles.ListPairMode,'String',{'series(Di)'}) 513 513 MaxIndex_i=get(MovieObject,'NumberOfFrames'); 514 time=(dt*(0:MaxIndex_i-1))';%list of image times 514 %time=(dt*(0:MaxIndex_i-1))';%list of image times 515 time=zeros(MaxIndex_i+1,2); 516 time(:,2)=dt*(0:MaxIndex_i)'; 515 517 else 516 518 set(handles.ListPairMode,'String',[{'series(Dj)'};{'series(Di)'}]) 517 519 MaxIndex_i=max(i1_series(i1_series>0)); 518 520 MaxIndex_j=get(MovieObject,'NumberOfFrames'); 519 time=ones(MaxIndex_i,1)*(dt*(0:MaxIndex_j-1));%list of image times 521 %time=ones(MaxIndex_i,1)*(dt*(0:MaxIndex_j-1));%list of image times 522 time=[0;dt*ones(MaxIndex_j,1)]*(0:MaxIndex_j); 520 523 enable_j(handles,'on') 521 524 end … … 527 530 %show the reference image edit box if relevant (not needed for movies or in the absence of time information 528 531 if numel(time)>=2 % if there are at least two time values to define dt 529 if size(time,1)<MaxIndex_i ;532 if size(time,1)<MaxIndex_i+1; 530 533 msgbox_uvmat('WARNING','maximum i index restricted by the timing of the xml file'); 531 elseif size(time,2)<MaxIndex_j 534 elseif size(time,2)<MaxIndex_j+1 532 535 msgbox_uvmat('WARNING','maximum j index restricted by the timing of the xml file'); 533 536 end 534 MaxIndex_i=min(size(time,1) ,MaxIndex_i);%possibly adjust the max index according to time data535 MaxIndex_j=min(size(time,2) ,MaxIndex_j);537 MaxIndex_i=min(size(time,1)-1,MaxIndex_i);%possibly adjust the max index according to time data 538 MaxIndex_j=min(size(time,2)-1,MaxIndex_j); 536 539 % time=[zeros(size(time,1),1) time]; %insert a vertical line of zeros (to deal with zero file indices) 537 540 % time=[zeros(1,size(time,2)); time]; %insert a horizontal line of zeros 538 541 else 539 542 set(handles.ImaDoc,'String',''); %xml file not used for timing 540 time=(i1_series(:,1)+0:size(i1_series,3) -1);% time=index i541 time=time'*ones(1,size(i1_series,2) ,1); %makes a time matrix with the same time for all j indices543 time=(i1_series(:,1)+0:size(i1_series,3));% time=index i 544 time=time'*ones(1,size(i1_series,2)+1,1); %makes a time matrix with the same time for all j indices 542 545 TimeUnit='frame'; 543 546 end
Note: See TracChangeset
for help on using the changeset viewer.