Changeset 403 for trunk/src/uvmat.m


Ignore:
Timestamp:
Apr 29, 2012, 11:35:16 AM (9 years ago)
Author:
sommeria
Message:

bugs corrected in uvmat (from previous modifications)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/uvmat.m

    r402 r403  
    234234%% refresh projection plane
    235235UvData.Object{1}.ProjMode='projection';%main plotting plane
    236 set(handles.ListObject,'Value',1)% default: empty projection object
     236set(handles.ListObject,'Value',1)% default: empty projection objectproj_field
    237237set(handles.ListObject,'String',{''})
    238238set(handles.Fields,'Value',1)
     
    24792479for imap=1:numel(IndexObj)
    24802480    iobj=IndexObj(imap);
    2481     if iobj==1 && ~isfield(UvData.Object{iobj},'Type')% case with no projection (only for the first empty object)
    2482         ord=10^(floor(log10(UvData.Field.Mesh)));%order of magnitude
    2483         if UvData.Field.Mesh/ord>=5
    2484             mesh=5*ord;
    2485         elseif UvData.Field.Mesh/ord>=2
    2486             mesh=2*ord;
    2487         else
    2488             mesh=ord;
    2489         end
    2490         coord_x=UvData.Field.XMin:mesh:UvData.Field.XMax;
    2491         coord_y=UvData.Field.YMin:mesh:UvData.Field.YMax;
    2492         [XI,YI]=meshgrid(coord_x,coord_y);
    2493         XI=reshape(XI,[],1);
    2494         YI=reshape(YI,[],1);
    2495         [ObjectData,errormsg]=calc_field({FieldName},UvData.Field,[XI YI]);
    2496     else
     2481%     if iobj==1 && ~isfield(UvData.Object{iobj},'Type')% case with no projection (only for the first empty object)
     2482%         ord=10^(floor(log10(UvData.Field.Mesh)));%order of magnitude
     2483%         if UvData.Field.Mesh/ord>=5
     2484%             mesh=5*ord;
     2485%         elseif UvData.Field.Mesh/ord>=2
     2486%             mesh=2*ord;
     2487%         else
     2488%             mesh=ord;
     2489%         end
     2490%         coord_x=UvData.Field.XMin:mesh:UvData.Field.XMax;
     2491%         coord_y=UvData.Field.YMin:mesh:UvData.Field.YMax;
     2492%         [XI,YI]=meshgrid(coord_x,coord_y);
     2493%         XI=reshape(XI,[],1);
     2494%         YI=reshape(YI,[],1);
     2495%         [ObjectData,errormsg]=calc_field({FieldName},UvData.Field,[XI YI]);
     2496%     else
    24972497        [ObjectData,errormsg]=proj_field(UvData.Field,UvData.Object{iobj});% project field on the object
    2498     end
     2498%     end
    24992499    if ~isempty(errormsg)
    25002500        return
Note: See TracChangeset for help on using the changeset viewer.