Changeset 8106


Ignore:
Timestamp:
05/02/11 17:50:18 (14 years ago)
Author:
Eric.Larour
Message:

now displays NONE elements

File:
1 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk/src/m/model/plot/plot_elementstype.m

    r7380 r8106  
    4646        A=elements(posPS,1); B=elements(posPS,2); C=elements(posPS,3);
    4747        p8=patch( 'Faces', [A B C], 'Vertices', [x y z],'CData',PattynStokesApproximationEnum,'FaceColor','flat','EdgeColor',edgecolor);
    48         legend([p1 p2 p3 p5 p6 p7 p8],'Hutter''s elements','MacAyeal''s elements','Pattyn''s elements','MacAyealPattyn''s elements','Stokes''s elements','MacAyealStokes''s elements','PattynStokes''s elements');
     48        %None elements
     49        posNONE=find(data==NoneApproximationEnum);
     50        A=elements(posNONE,1); B=elements(posNONE,2); C=elements(posNONE,3);
     51        p9=patch( 'Faces', [A B C], 'Vertices', [x y z],'CData',NoneApproximationEnum,'FaceColor','flat','EdgeColor',edgecolor);
     52        legend([p1 p2 p3 p5 p6 p7 p8 p9],'Hutter''s elements','MacAyeal''s elements','Pattyn''s elements','MacAyealPattyn''s elements','Stokes''s elements','MacAyealStokes''s elements','PattynStokes''s elements','No element');
     53
    4954else
    5055        %Hutter elements
     
    105110        patch( 'Faces', [B E F C],'Vertices', [x y z],'CData', MacAyealStokesApproximationEnum,'FaceColor','flat','EdgeColor',edgecolor);
    106111        patch( 'Faces', [C A D F],'Vertices', [x y z],'CData', MacAyealStokesApproximationEnum,'FaceColor','flat','EdgeColor',edgecolor);
    107         legend([p1 p2 p3 p4 p5 p6 p7],'Hutter''s elements','MacAyeal''s elements','Pattyn''s elements','Stokes''s elements','MacAyealPattyn''s elements','PattynStokes''s elements','MacAyealStokes''s elements');
     112        %None elements
     113        PosNONE=find(data==NoneApproximationEnum);
     114        A=elements(PosNONE,1); B=elements(PosNONE,2); C=elements(PosNONE,3); D=elements(PosNONE,4); E=elements(PosNONE,5); F=elements(PosNONE,6);
     115        p8=patch( 'Faces', [A B C],'Vertices', [x y z],'CData', NoneApproximationEnum,'FaceColor','flat','EdgeColor',edgecolor);
     116        patch( 'Faces', [D E F],  'Vertices', [x y z],'CData', NoneApproximationEnum,'FaceColor','flat','EdgeColor',edgecolor);
     117        patch( 'Faces', [A B E D],'Vertices', [x y z],'CData', NoneApproximationEnum,'FaceColor','flat','EdgeColor',edgecolor);
     118        patch( 'Faces', [B E F C],'Vertices', [x y z],'CData', NoneApproximationEnum,'FaceColor','flat','EdgeColor',edgecolor);
     119        patch( 'Faces', [C A D F],'Vertices', [x y z],'CData', NoneApproximationEnum,'FaceColor','flat','EdgeColor',edgecolor);
     120        legend([p1 p2 p3 p4 p5 p6 p7 p8],'Hutter''s elements','MacAyeal''s elements','Pattyn''s elements','Stokes''s elements','MacAyealPattyn''s elements','PattynStokes''s elements','MacAyealStokes''s elements','None elements');
    108121end
    109122
Note: See TracChangeset for help on using the changeset viewer.