0001 function job_edit_act_update_spatialpattern(inst_id)
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016 global vbmeg_inst;
0017 if isempty(vbmeg_inst.editact{inst_id}.V), return; end
0018
0019
0020
0021
0022
0023 h_fig = vbmeg_inst.editact{inst_id}.h_fig;
0024 h_space = vbmeg_inst.editact{inst_id}.h_space;
0025 h_cbar = vbmeg_inst.editact{inst_id}.h_cbar;
0026 V = vbmeg_inst.editact{inst_id}.V;
0027 F = vbmeg_inst.editact{inst_id}.F;
0028 plot_parm = vbmeg_inst.editact{inst_id}.plot_parm;
0029 ix = vbmeg_inst.editact{inst_id}.ix;
0030 ed4 = vbmeg_inst.editact{inst_id}.ed4;
0031 ed6 = vbmeg_inst.editact{inst_id}.ed6;
0032 cb1 = vbmeg_inst.editact{inst_id}.cb1;
0033 cb2 = vbmeg_inst.editact{inst_id}.cb2;
0034 Vtal = vbmeg_inst.editact{inst_id}.Vtal;
0035 model_type_fold_rb = vbmeg_inst.editact{inst_id}.model_type_fold_rb;
0036 model_type_inflate_rb = ...
0037 vbmeg_inst.editact{inst_id}.model_type_inflate_rb;
0038 xxP = vbmeg_inst.editact{inst_id}.xxP;
0039 if ~isempty(xxP), xxP = xxP{1}; end
0040
0041
0042
0043
0044
0045 set(h_fig,'Pointer','arrow');
0046 drawnow;
0047
0048
0049 if get(model_type_fold_rb,'Value')==1,
0050 V = vbmeg_inst.editact{inst_id}.V;
0051 inf_C = [];
0052 else
0053 V = vbmeg_inst.editact{inst_id}.Vinf;
0054 inf_C = vbmeg_inst.editact{inst_id}.inf_C;
0055 end
0056
0057
0058 LRflag = [];
0059 if get(cb1,'Value')==get(cb1,'Max'), LRflag = 'L'; end
0060 if get(cb2,'Value')==get(cb2,'Max'), LRflag = [LRflag 'R']; end
0061 plot_parm.LRflag = LRflag;
0062
0063 if isempty(xxP), isact = 0; else isact = 1; end
0064 plot_parm.isact = isact;
0065
0066
0067
0068
0069
0070 set(h_fig,'CurrentAxes',h_space);
0071 cla;
0072 job_edit_act_plotbrain(plot_parm,V,F,inf_C,xxP,min(xxP),max(xxP));
0073 v = caxis;
0074 set(ed6,'String',['[' num2str(v) ']']);
0075 axis tight;
0076 axis equal;
0077 set(h_space,'Box','on','XTick',[],'YTick',[],'ZTick',[]);
0078 reset(h_cbar);
0079 colorbar(h_cbar);
0080
0081
0082 if ix~=0,
0083 hold on;
0084 h = plot3(V(ix,1),V(ix,2),V(ix,3),'gx');
0085 set(h,'MarkerSize',plot_parm.ms,'EraseMode','xor',...
0086 'LineWidth',plot_parm.lw);
0087
0088
0089 job_edit_act_update_talcoord(inst_id);
0090
0091
0092
0093
0094 end