Changeset 193 for trunk/src/set_object.m


Ignore:
Timestamp:
Feb 20, 2011, 10:42:19 AM (13 years ago)
Author:
sommeria
Message:

improves the use of get_field, no projection object by default in uvmat( allows usual 1D plots),

various bug repairs, elimination of get_plot_handles.m (not useful)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/set_object.m

    r187 r193  
    703703testnew=0;
    704704ObjectData=read_set_object(handles);%read the input parameters defining the object in the GUI set_object
    705 PlotHandles=get_plot_handles(hhuvmat);
    706 projview='view_field';%default
    707705if strcmp(ListObject{IndexObj_1},ObjectName)% we are editing the object whose projection is viewed in the uvmat frame
    708706    IndexObj=IndexObj_1;
    709707    projview='uvmat';
    710      plotaxes=hhuvmat.axes3;%handle of axes3 in view_field
    711708elseif ~isempty(IndexObj_2) && IndexObj_2<=numel(ListObject)&& strcmp(ListObject{IndexObj_2},ObjectName)% we are editing the object whose projection is viewed in view_field 
    712709    IndexObj=IndexObj_2;
     710    projview='view_field';
    713711else %new object
    714712    testnew=1;
    715713    IndexObj=numel(ListObject)+1;
    716     hview_field=findobj(allchild(0),'tag','view_field');
    717     if ~isempty(hview_field)
    718         PlotHandles=guidata(hview_field);
    719         plotaxes=PlotHandles.axes3;%handle of axes3 in view_field
    720     end
     714    projview='view_field';
    721715end
    722716if strcmp(projview,'view_field')
     
    728722    PlotHandles=guidata(hview_field);
    729723    plotaxes=PlotHandles.axes3;%handle of axes3 in view_field
     724else
     725    PlotHandles=hhuvmat;
     726    plotaxes=hhuvmat.axes3;%handle of axes3 in view_field
    730727end   
    731 
    732728
    733729%% naming the object
     
    780776%% plot the field projected on the object and store in the corresponding figue
    781777ProjData= proj_field(UvData.Field,ObjectData);%project the current interface field on ObjectData
    782 [PlotType,Object_out{IndexObj}.PlotParam,plotaxes]=plot_field(ProjData,plotaxes,PlotHandles);%update an existing field plot
     778PlotParam=read_plot_param(PlotHandles);
     779[PlotType,Object_out{IndexObj}.PlotParam,plotaxes]=plot_field(ProjData,plotaxes,PlotParam);%update an existing field plot
    783780
    784781%% update the GUI uvmat
Note: See TracChangeset for help on using the changeset viewer.