- Timestamp:
- Mar 30, 2010, 11:50:35 PM (15 years ago)
- Location:
- trunk/src
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/civ.m
r71 r73 51 51 % handles structure with handles and user data (see GUIDATA) 52 52 % varargin command line arguments to civ (see VARARGIN) 53 global test_batch patch_newBin %=1 if patch processing available53 global test_batch patch_newBin CivBin%=1 if patch processing available 54 54 %filebase: root name 55 55 %nom_type: nomencalture used ('png_old','_i_j'...) … … 295 295 end 296 296 end 297 [RootPath,RootFile,str1,str2,str_a,str_b,ext,nom_type,subdir]=name2display(fileinput) ;297 [RootPath,RootFile,str1,str2,str_a,str_b,ext,nom_type,subdir]=name2display(fileinput) 298 298 filebase=fullfile(RootPath,RootFile); 299 299 % if isequal(nom_type,'*')% all fields in a single file ( movie files) … … 303 303 if isempty(num_i1),num_i1=1;end 304 304 num_i2=stra2num(str2); 305 if isempty(num_i2),num_i2= 1;end305 if isempty(num_i2),num_i2=num_i1;end 306 306 num_j1=stra2num(str_a); 307 307 if isempty(num_j1),num_j1=1;end 308 308 num_j2=stra2num(str_b); 309 if isempty(num_j2),num_j2= 1;end309 if isempty(num_j2),num_j2=num_j1;end 310 310 if isequal(get(handles.compare,'Value'),1) 311 311 browse=[];%initialisation … … 355 355 set(handles.ImaDoc,'String',ext); 356 356 if ~isempty(num_i1) 357 ref_i=num_i1; 357 ref_i=num_i1 358 'TEStbrowse' 359 num_i2 358 360 if ~isempty(num_i2) 359 361 ref_i=floor((ref_i+num_i2)/2);% reference image number corresponding to the file … … 537 539 end 538 540 elseif isequal(ext,'.xml') 539 [XmlData,warntext]=imadoc2struct([filebase '.xml']) 541 [XmlData,warntext]=imadoc2struct([filebase '.xml']); 540 542 if isfield(XmlData,'Time') 541 543 time=XmlData.Time; … … 1047 1049 if isequal(mode,'series(Di)') %| isequal(mode,'st_series(Di)') 1048 1050 if testpair 1049 displ_pair{1}=['Di= ' num2str(-floor(browse.incr_pair(1)/2)) '|' num2str(ceil(browse.incr_pair(1)/2))];1050 % elseif ~isequal(get(handles.root_txt,'String'),'dt(ms)=') 1051 % for ipair=1:nbpair1052 % if select(ipair) 1053 % if size(time,1)>=ref_i+displ_num(4,ipair) && size(time,2)>=ref_j+displ_num(2,ipair)1054 % dt=time(ref_i+displ_num(4,ipair),ref_j+displ_num(2,ipair))-time(ref_i+displ_num(3,ipair),ref_j+displ_num(1,ipair));%time interval dt1055 % displ_pair{ipair}=['Di= ' num2str(-floor(ipair/2)) '|' num2str(ceil(ipair/2)) ' :dt= ' num2str(dt*1000)];1056 % end1057 % else 1058 % displ_pair{ipair}='...'; %pair not displayed in the menu1059 % end1060 % end1051 displ_pair{1}=['Di= ' num2str(-floor(browse.incr_pair(1)/2)) '|' num2str(ceil(browse.incr_pair(1)/2))]; 1052 % elseif ~isequal(get(handles.root_txt,'String'),'dt(ms)=') 1053 % for ipair=1:nbpair 1054 % if select(ipair) 1055 % if size(time,1)>=ref_i+displ_num(4,ipair) && size(time,2)>=ref_j+displ_num(2,ipair) 1056 % dt=time(ref_i+displ_num(4,ipair),ref_j+displ_num(2,ipair))-time(ref_i+displ_num(3,ipair),ref_j+displ_num(1,ipair));%time interval dt 1057 % displ_pair{ipair}=['Di= ' num2str(-floor(ipair/2)) '|' num2str(ceil(ipair/2)) ' :dt= ' num2str(dt*1000)]; 1058 % end 1059 % else 1060 % displ_pair{ipair}='...'; %pair not displayed in the menu 1061 % end 1062 % end 1061 1063 else 1062 for ipair=1:nbpair 1063 if select(ipair) 1064 displ_pair{ipair}=['Di= ' num2str(-floor(ipair/2)) '|' num2str(ceil(ipair/2)) ' :dt= ' num2str(dt_unit*ipair)]; 1065 else 1066 displ_pair{ipair}='...'; %pair not displayed in the menu 1067 end 1068 end 1064 for ipair=1:nbpair 1065 if select(ipair) 1066 if size(time,1)>=ref_i+displ_num(4,ipair) && size(time,2)>=ref_j+displ_num(2,ipair) 1067 dt=time(ref_i+displ_num(4,ipair),ref_j+displ_num(2,ipair))-time(ref_i+displ_num(3,ipair),ref_j+displ_num(1,ipair));%time interval dt 1068 displ_pair{ipair}=['Di= ' num2str(-floor(ipair/2)) '|' num2str(ceil(ipair/2)) ' :dt= ' num2str(dt*1000)]; 1069 else 1070 displ_pair{ipair}='...'; %pair not displayed in the menu 1071 end 1072 end 1073 end 1069 1074 end 1070 1075 elseif isequal(mode,'series(Dj)')%|isequal(mode,'st_series(Dj)')% series on the j index … … 1190 1195 end 1191 1196 %dt_unit=str2num(get(handles.dt,'String'));% used when there is no image documentation file 1192 dt_unit=1000;1197 %dt_unit=1000; 1193 1198 displ_num=get(handles.list_pair_civ1,'UserData'); 1194 1199 … … 2001 2006 %------------------------------------------------------------------------ 2002 2007 % global civ1_exe civ2_exe patch_exe patch_new_exe sge 2003 2008 set(handles.RUN, 'Enable','Off') 2009 set(handles.RUN,'BackgroundColor',[0.831 0.816 0.784]) 2004 2010 batch=0; 2005 2011 launch_jobs(hObject, eventdata, handles,batch); 2006 2012 set(handles.RUN, 'Enable','On') 2013 set(handles.RUN,'BackgroundColor',[1 0 0]) 2007 2014 2008 2015 %------------------------------------------------------------------------ … … 2011 2018 %------------------------------------------------------------------------ 2012 2019 %global civ1_exe civ2_exe patch_exe patch_new_exe fix_exe todo_path sge Civ_exe % probabely to remove 2020 set(handles.BATCH, 'Enable','Off') 2021 set(handles.BATCH,'BackgroundColor',[0.831 0.816 0.784]) 2013 2022 batch=1; 2014 2023 launch_jobs(hObject, eventdata, handles, batch) 2024 set(handles.BATCH, 'Enable','On') 2025 set(handles.BATCH,'BackgroundColor',[1 0 0]) 2015 2026 2016 2027 %------------------------------------------------------------------------ … … 2086 2097 s=convert(t); 2087 2098 end 2088 % else2089 % xmlfile=fullfile(path_UVMAT,'PARAM_WIN.xml');2090 % if exist(xmlfile,'file')2091 % t=xmltree(xmlfile);2092 % sparam=convert(t);2093 % end2094 % end2095 % batch=0;2096 2099 if batch 2097 2100 if isfield(s,'BatchParam') … … 2113 2116 end 2114 2117 if isfield(sparam,'CivBin') 2115 CivBin=sparam.CivBin ;2118 CivBin=sparam.CivBin 2116 2119 end 2117 2120 if isfield(sparam,'Civ1Bin') … … 2121 2124 civ2Bin=sparam.Civ2Bin; 2122 2125 end 2123 if isfield(sparam,'PatchBin') 2124 patchBin=sparam.PatchBin; 2125 end 2126 if isfield(sparam,'PatchNewBin') 2127 patch_newBin=sparam.PatchNewBin; 2128 end 2129 if isfield(sparam,'FixBin') 2126 test_interp=get(handles.test_interp,'Value'); 2127 if ~test_interp && isfield(sparam,'PatchBin') 2128 PatchBin=sparam.PatchBin; 2129 end 2130 if test_interp && isfield(sparam,'PatchNewBin') 2131 PatchBin=sparam.PatchNewBin; 2132 end 2133 if isfield(sparam,'FixBin') 2130 2134 fixBin=sparam.FixBin; 2131 end 2132 % if isfield(sparam,'Todo_path') 2133 % todo_path=sparam.Todo_path; 2134 % end 2135 end 2135 2136 if batch 2136 2137 if isfield(sparam,'BatchMode') … … 2149 2150 set(handles.waitbar_civ2,'Position',[0.946 0.219 0.03 0.001]) 2150 2151 set(handles.waitbar_patch2,'Position',[0.946 0.0 0.03 0.001]) 2151 set(handles.BATCH, 'Enable','Off') 2152 set(handles.BATCH,'BackgroundColor',[0.831 0.816 0.784]) 2152 2153 2153 drawnow 2154 2154 %get the filename root, nomenclature and numbers … … 2266 2266 subdomain_patch1=get(handles.subdomain_patch1,'String'); 2267 2267 thresh_patch1=get(handles.thresh_patch1,'String'); 2268 test_interp=get(handles.test_interp,'Value');2269 2268 end 2270 2269 … … 2291 2290 2292 2291 2292 2293 2293 %get patch2 parameters 2294 2294 if box_test(6)==1 … … 2312 2312 subdomain_patch2=get(handles.subdomain_patch2,'String'); 2313 2313 thresh_patch2=get(handles.thresh_patch2,'String'); 2314 test_interp=get(handles.test_interp,'Value'); 2315 end 2316 2317 % if ~sge 2318 % 2319 % %OPEN THE WAIT LIST FOR BATCH PROCESSES 2320 % name_lock=fullfile(todo_path,'lock'); %lock file 2321 % iwait=0; 2322 % while(exist(name_lock) & iwait<15) 2323 % pause(1); %wait 1 second 2324 % iwait=iwait+1; 2325 % end 2326 % if iwait==15 2327 % msgbox_uvmat('ERROR',['I''m tired to wait for the lock file, please delete it then click again on BATCH' name_lock ]) 2328 % set(handles.BATCH, 'Enable','On') 2329 % set(handles.BATCH,'BackgroundColor',[1 0 0]) 2330 % return 2331 % end 2332 % p0=fopen(name_lock,'w'); %create the file name_lock: prevents other users to interfere 2333 % name_todo=fullfile(todo_path,'TODO.txt'); 2334 % p1=fopen(name_todo,'a'); 2335 % if (p1<0) 2336 % msgbox_uvmat('ERROR',['error in opening ' name_todo]) 2337 % set(handles.BATCH, 'Enable','On') 2338 % set(handles.BATCH,'BackgroundColor',[1 0 0]) 2339 % return; 2340 % end 2341 % end 2314 % test_interp=get(handles.test_interp,'Value'); 2315 end 2342 2316 2343 2317 %MAIN LOOP … … 2350 2324 i_cmd=0; 2351 2325 cmd=''; 2352 if batch2326 if isunix % check: necessaire aussi en RUN? 2353 2327 %fid=fopen([filename '.cmx'],'w') 2354 2328 cmd='#!/bin/bash'; … … 2358 2332 if civAll 2359 2333 civAllxml=xmltree;% xml contents, all parameters 2360 civAllCmd= [];2334 civAllCmd=''; 2361 2335 civAllxml=set(civAllxml,1,'name','CivDoc'); 2362 2336 end 2363 % filecell.nc.civ1 2364 filename_cmx=filecell.nc.civ1{ifile,j}%output netcdf file 2337 filename_cmx=filecell.nc.civ1{ifile,j};%output netcdf file 2365 2338 filename_cmx(end-1:end)='cm';%name of cmx file 2366 2339 filename_cmx=[filename_cmx 'x']; … … 2369 2342 if box_test(1)==1 2370 2343 par_civ1.filename_ima_a=filecell.ima1.civ1{ifile,j}; 2371 % par_civ1.filename_ima_a([end-3:end])=[];%remove .png extension 2372 par_civ1.filename_ima_b=filecell.ima2.civ1{ifile,j}; 2373 % par_civ1.filename_ima_b([end-3:end])=[];%remove .png extension 2374 2344 par_civ1.filename_ima_b=filecell.ima2.civ1{ifile,j}; 2375 2345 namelog=[filename_cmx([1:end-3]) 'log']; 2376 2346 par_civ1.Dt=num2str(time(num2_civ1(ifile),num_b_civ1(j))-time(num1_civ1(ifile),num_a_civ1(j))); … … 2482 2452 if box_test(3)==1 2483 2453 if isequal(civAll,0) 2484 cmd_PATCH=RUN_PATCH(filecell.nc.civ1{ifile,j},nx_patch1,ny_patch1,rho_patch1,subdomain_patch1,thresh_patch1,test_interp );2454 cmd_PATCH=RUN_PATCH(filecell.nc.civ1{ifile,j},nx_patch1,ny_patch1,rho_patch1,subdomain_patch1,thresh_patch1,test_interp,PatchBin); 2485 2455 cmd=[cmd '\n' cmd_PATCH]; 2486 2456 else … … 2601 2571 else 2602 2572 civAllCmd=[civAllCmd ' civ2 ']; 2603 str=BATCH_CIV2_Unified(filename_cmx([1:end-4]),namelog,par_civ2 ,sparam);2573 str=BATCH_CIV2_Unified(filename_cmx([1:end-4]),namelog,par_civ2); 2604 2574 fieldnames=fields(str); 2605 2575 [civAllxml,uid_civ2]=add(civAllxml,1,'element','civ2'); … … 2654 2624 if box_test(6)==1 2655 2625 if isequal(civAll,0) 2656 cmd_PATCH=RUN_PATCH(filecell.nc.civ2{ifile,j},nx_patch2,ny_patch2,rho_patch2,subdomain_patch2,thresh_patch2,test_interp );2626 cmd_PATCH=RUN_PATCH(filecell.nc.civ2{ifile,j},nx_patch2,ny_patch2,rho_patch2,subdomain_patch2,thresh_patch2,test_interp,PatchBin); 2657 2627 cmd=[cmd '\n' cmd_PATCH]; 2658 2628 else … … 2700 2670 if isequal(civAll,1) 2701 2671 save(civAllxml,[filename_cmx([1:end-4]) '.xml']); 2702 cmd=char({cmd;[CivBin ' -f ' [filename_cmx([1:end-4]) '.xml'] ' ' civAllCmd]}); 2672 %cmd=char({cmd;[CivBin ' -f ' [filename_cmx([1:end-4]) '.xml'] ' ' civAllCmd]}); 2673 cmd=[cmd '\n' CivBin ' -f ' filename_cmx(1:end-4) '.xml ' civAllCmd] 2703 2674 end 2704 2675 % create the .bat file: … … 2719 2690 pvalue=num2str((1-ind_answer)*500); 2720 2691 namelog=[filename_bat '.patch.log']; 2721 ['!qsub -p ' pvalue ' -q civ.q -e ' filename_cmx(1:end-4) '.errors -o ' filename_cmx(1:end-4) '.log' ' ' filename_bat];2692 display(['!qsub -p ' pvalue ' -q civ.q -e ' filename_cmx(1:end-4) '.errors -o ' filename_cmx(1:end-4) '.log' ' ' filename_bat]); 2722 2693 eval( ['!qsub -p ' pvalue ' -q civ.q -e ' filename_cmx(1:end-4) '.errors -o ' filename_cmx(1:end-4) '.log' ' ' filename_bat]); 2723 2694 end 2724 2725 2726 2727 2695 else 2728 2696 %% to lauch the jobs locally : 2729 2697 if(isunix) 2730 2698 eval(['!. ' filename_bat ' &']); 2699 display(['!. ' filename_bat ' &']) 2731 2700 else 2732 2701 eval(['!' filename_bat ' &']); 2702 display(['!' filename_bat ' &']) 2733 2703 end 2734 2704 % if(isunix) … … 3430 3400 3431 3401 %------------------------------------------------------------------------ 3432 %CIV1 CIV1 CIV1 CIV1 3402 %CIV1 CIV1 CIV1 CIV1 NOT USED: replaced by RUN_BATCH 3433 3403 function RUN_CIV1(handles,filecell,filecell_1,filecell_nc1,num1,num2,num_a,num_b,nom_type_nc) 3434 3404 %------------------------------------------------------------------------ … … 3807 3777 %------------------------------------------------------------------------ 3808 3778 % --- PATCH 3809 function cmd_PATCH=RUN_PATCH(filename_nc,nx_patch,ny_patch,rho_patch,subdomain_patch,thresh_value,test_interp) 3810 %------------------------------------------------------------------------ 3811 global patchBin patch_newBin 3779 function cmd_PATCH=RUN_PATCH(filename_nc,nx_patch,ny_patch,rho_patch,subdomain_patch,thresh_value,test_interp,PatchBin) 3780 %------------------------------------------------------------------------ 3781 %global patchBin patch_newBin 3782 3783 3812 3784 namelog=[filename_nc([1:end-3]) '_patch.log']; 3813 3785 if test_interp==0 3814 cmd_PATCH=[ patchBin ' -f ' filename_nc ' -m ' nx_patch ' -n ' ny_patch ' -ro ' rho_patch ' -nopt ' subdomain_patch ...3786 cmd_PATCH=[PatchBin ' -f ' filename_nc ' -m ' nx_patch ' -n ' ny_patch ' -ro ' rho_patch ' -nopt ' subdomain_patch ... 3815 3787 ' > ' namelog ' 2>&1']; % redirect standard output to the log file 3816 3788 else %nouveau programme patch 3817 cmd_PATCH=[ patch_newBin ' -f ' filename_nc ' -m ' nx_patch ' -n ' ny_patch ' -ro ' rho_patch ...3789 cmd_PATCH=[PatchBin ' -f ' filename_nc ' -m ' nx_patch ' -n ' ny_patch ' -ro ' rho_patch ... 3818 3790 ' -max ' thresh_value ' -nopt ' subdomain_patch ' > ' namelog ' 2>&1']; % redirect standard output to the log file 3819 3791 end … … 4895 4867 fclose(fid); 4896 4868 4897 % if sge 4898 cmd_CIV1=[sparam.Civ1Bin ' -f ' filename '.cmx' ]; % redirect standard output to the log file 4899 % else 4900 % cmd_CIV1=[civ1Bin ' -f ' filename_cmx ' > ' namelog ' 2>&1']; % redirect standard output to the log file 4901 % end 4869 cmd_CIV1=[sparam.Civ1Bin ' -f ' filename '.cmx' ]; % redirect standard output to the log file 4902 4870 if(isunix) 4903 4871 [Rootbat,Filebat,extbat]=fileparts(namelog); … … 4913 4881 %------------------------------------------------------------------------ 4914 4882 %pixels per cm and matrix of the image times, read from the .civ file by uvmat 4915 global civ1BinCivBin%name of the executable for civ1 calculation4883 %global CivBin%name of the executable for civ1 calculation 4916 4884 4917 4885 civ1.image1=par.filename_ima_a; … … 4952 4920 %------------------------------------------------------------------------ 4953 4921 %pixels per cm and matrix of the image times, read from the .civ file by uvmat 4954 global civ2BinCivBin%name of the executable for civ1 calculation4922 %global CivBin%name of the executable for civ1 calculation 4955 4923 4956 4924 civ2.image1=par.filename_ima_a; -
trunk/src/plot_field.m
r72 r73 455 455 end 456 456 if test_newplot && ~isequal(plotstr,'plot(') 457 plotstr=[plotstr '''tag'',''plot_line'') ']457 plotstr=[plotstr '''tag'',''plot_line'');']; 458 458 %execute plot (instruction plotstr) 459 459 eval(plotstr) … … 914 914 vec_U=reshape(vec_U,1,numel(vec_U)); 915 915 vec_V=reshape(vec_V,1,numel(vec_V)); 916 MinMaxX=max(vec_X)-min(vec_X) 917 MinMaxY=max(vec_Y)-min(vec_Y) 916 MinMaxX=max(vec_X)-min(vec_X); 917 MinMaxY=max(vec_Y)-min(vec_Y); 918 918 AxeData.Mesh=sqrt((MinMaxX*MinMaxY)/length(vec_X)); 919 919 if ~isfield(PlotParam.Vectors,'AutoVec') || isequal(PlotParam.Vectors.AutoVec,0)|| ~isfield(PlotParam.Vectors,'VecScale')... -
trunk/src/series/ima2vol.m
r72 r73 60 60 %main loop 61 61 vol=[]; 62 for ifile=1:nbfield1*nbfield2 63 update_waitbar(hseries.waitbar,WaitbarPos,ifile/(nbfield1*nbfield2)) 64 filename=name_generator(basename,ifile-1,1,Series.FileExt,Series.NomType); 65 num_j=mod(ifile-1,nbfield2)+1; 66 num_i=floor((ifile-1)/nbfield2)+1; 67 A=imread(filename); 68 if test_level 69 A=levels(A); 70 end 71 vol=[vol;A];%concacene along y 72 if num_j==nbfield2 73 filename_new=name_generator(basename_new,num_i,1,'.vol','_i'); 74 imwrite(vol,filename_new,'png','BitDepth',16)% WRITE IN 16 bits 75 vol=[]; 76 end 77 end 62 for ifile=1:nbfield1*nbfield2 63 update_waitbar(hseries.waitbar,WaitbarPos,ifile/(nbfield1*nbfield2)) 64 stopstate=get(hseries.RUN,'BusyAction'); 65 if isequal(stopstate,'queue') % enable STOP command 66 filename=name_generator(basename,ifile-1,1,Series.FileExt,Series.NomType); 67 num_j=mod(ifile-1,nbfield2)+1; 68 num_i=floor((ifile-1)/nbfield2)+1; 69 A=imread(filename); 70 Atype=class(A); 71 if test_level 72 A=levels(A,16); 73 display(num2str(num_i)) 74 end 75 vol=[vol;A];%concacene along y 76 if num_j==nbfield2 77 filename_new=name_generator(basename_new,num_i,1,'.vol','_i'); 78 imwrite(vol,filename_new,'png','BitDepth',16)% WRITE IN 16 bits: needed for the current version of civ3C3D 79 display([filename_new 'written (16bits image)']) 80 vol=[]; 81 end 82 end 83 end 78 84 79 85 80 86 81 function C=levels(A )87 function C=levels(A,bitdepth) 82 88 %whos A; 83 89 B=double(A(:,:,1)); … … 115 121 cmin=min(c_select); 116 122 cmax=max(c_select); 117 C=(C-cmin)/(cmax-cmin)*256; 118 %C=uint8(C); 123 if isequal(bitdepth,16) 124 C=((C-cmin)/(cmax-cmin))*256*256; 125 C=uint16(C); 126 else 127 C=((C-cmin)/(cmax-cmin))*256; 128 C=uint8(C); 129 end -
trunk/src/set_grid.m
r46 r73 482 482 tsaiA=[]; 483 483 end 484 [grid_imaA(:,1),grid_imaA(:,2)]=px_XYZ(tsaiA,grid_real(:,1),grid_real(:,2),0); 484 size(grid_real) 485 tsaiA 486 if isempty(tsaiA) 487 grid_imaA(:,1)=grid_real(:,1); 488 grid_imaA(:,2)=grid_real(:,2); 489 else 490 [grid_imaA(:,1),grid_imaA(:,2)]=px_XYZ(tsaiA,grid_real(:,1),grid_real(:,2),0); 491 end 485 492 A=imread(imageA); 486 493 siz=size(A); … … 537 544 grid_real2(:,2)=grid_real_y; 538 545 grid_real2(:,3)=zeros(nx_patch_new,1); 539 [grid_pix_A(:,1),grid_pix_A(:,2)]=px_XYZ(tsaiA,grid_real2(:,1),grid_real2(:,2)); 546 if isempty(tsaiA) 547 grid_pix_A(:,1)=grid_real2(:,1); 548 grid_pix_A(:,2)= grid_real2(:,2); 549 else 550 [grid_pix_A(:,1),grid_pix_A(:,2)]=px_XYZ(tsaiA,grid_real2(:,1),grid_real2(:,2)); 551 end 540 552 if testB 541 553 [grid_pix_B(:,1),grid_pix_B(:,2)]=px_XYZ(tsaiB,grid_real2(:,1),grid_real2(:,2)); -
trunk/src/uvmat.m
r72 r73 419 419 end 420 420 [FileName, PathName] = uigetfile( ... 421 {'*.xml;*.xls;*.civ;*.png;*.jpg;*.tif;*.avi;*.AVI;*. nc;*.cmx;*.fig;*.log;*.dat', ' (*.xml,*.xls,*.civ,*.jpg ,*.png, .tif, *.avi,*.nc,*.cmx ,*.fig,*.log,*.dat)';421 {'*.xml;*.xls;*.civ;*.png;*.jpg;*.tif;*.avi;*.AVI;*.vol;*.nc;*.cmx;*.fig;*.log;*.dat;*.bat;', ' (*.xml,*.xls,*.civ,*.jpg ,*.png, .tif, *.avi,*.vol,*.nc,*.cmx ,*.fig,*.log,*.dat,*.bat)'; 422 422 '*.xml', '.xml files '; ... 423 423 '*.xls', '.xls files '; ... … … 427 427 '*.tif','.tif image files'; ... 428 428 '*.avi;*.AVI','.avi movie files'; ... 429 '*.vol','.volume images (png)'; ... 429 430 '*.nc','.netcdf files'; ... 430 431 '*.cdf','.netcdf files'; ... … … 434 435 '*.log','.log text files ';... 435 436 '*.dat','.dat text files ';... 437 '*.bat','.bat system command text files';... 436 438 '*.*', 'All Files (*.*)'}, ... 437 439 'Pick a file',oldfile); … … 541 543 end 542 544 switch ext_test 543 case {'.civ','.log','.cmx','.cmx2','.txt' } %display text file545 case {'.civ','.log','.cmx','.cmx2','.txt','.bat'} %display text file 544 546 edit(fileinput) 545 547 case '.fig' %display matlab figure … … 795 797 set(handles.slices,'Value',1) 796 798 end 797 if is equal(GeometryCalib.NbSlice,'volume')799 if isfield(GeometryCalib,'NbSlice') && isequal(GeometryCalib.NbSlice,'volume') 798 800 set(handles.nb_slice,'String','volume') 799 801 else … … 4137 4139 4138 4140 %suppress the other options if grid is chosen 4139 % set(handles.create,'Value',0)4140 % set(handles.create,'BackgroundColor',[0 1 0])4141 4141 set(handles.edit_vect,'Value',0) 4142 4142 edit_vect_Callback(hObject, eventdata, handles) … … 4146 4146 set(handles.edit,'BackgroundColor',[0.7 0.7 0.7]) 4147 4147 set(handles.list_object_1,'Value',1) 4148 % set(handles.cal,'Value',0)4149 % set(handles.cal,'BackgroundColor',[0 1 0])4150 4148 4151 4149 %prepare display of the set_grid GUI … … 4153 4151 FileName=read_file_boxes(handles); 4154 4152 [hset_object,UvData.sethandles]=set_grid(FileName);% call the set_object interface 4155 set(h uvmat,'UserData',UvData);4153 set(handles.uvmat,'UserData',UvData); 4156 4154 4157 4155
Note: See TracChangeset
for help on using the changeset viewer.