Retour

Source : souris.mp

Animation flash


souris.mp
prologues:=2;
input geometriesyr16
%etape1:oreilles
%1
u:=5mm;
figure(0,0,19u,28u);
trace grille(0.25) withcolor orange;
origine((20,20));
pair O,A,B,E,F,I;
O=pp(0,0);
I=pp(0,-8);
A=pp(-7,0);
B=symetrie(A,O,I);
E=pp(-9,-0.5);
F=symetrie(E,O,I);
path cc[];
cc1=cercles(A,2u);
cc2=cercles(B,2u);
cc3=cercles(E,2.5u);
cc4=cercles(F,2.5u);
marque_p:="plein";
pointe(A,B,E,F,O);
drawoptions(withcolor violet);
trace cc1;trace cc2;
drawoptions(dashed evenly withcolor gris);
trace cc3;trace cc4;
drawoptions();
fin;
%2
figure(0,0,19u,28u);
trace grille(0.25) withcolor orange;
pointe(A,B,E,F);
trace cc1;trace cc2;
drawoptions(withcolor violet);
trace cc4 cutbefore (subpath(0,length cc2/2) of cc2) cutafter (subpath(length cc2/2,length cc2) of cc2);
trace symetrie(cc4 cutbefore (subpath(0,length cc2/2) of cc2) cutafter (subpath(length cc2/2,length cc2) of cc2),O,I);
drawoptions(dashed evenly withcolor gris);
drawoptions();
picture etape[];
etape1=image(
  trace cc1;trace cc2;
  trace cc4 cutbefore (subpath(0,length cc2/2) of cc2) cutafter (subpath(length cc2/2,length cc2) of cc2);
  trace symetrie(cc4 cutbefore (subpath(0,length cc2/2) of cc2) cutafter (subpath(length cc2/2,length cc2) of cc2),O,I);
  );
fin;
%etape2:les yeux
%3
figure(0,0,19u,28u);
trace grille(0.25) withcolor orange;
origine((20,20));
pair C,D;
C=pp(-5,-8);
D=symetrie(C,O,I);
cc5=cercles(C,u);
cc6=cercles(C,1.5u);
cc7=cercles(D,u);
cc8=cercles(D,1.5u);
pointe(C,D);
trace etape1;
drawoptions(withcolor violet);
trace cc5;trace cc6;
drawoptions(dashed evenly withcolor gris);
trace cc7;trace cc8;
drawoptions();
fin;
%4
figure(0,0,19u,28u);
trace grille(0.25) withcolor orange;
pointe(C,D);
trace etape1;
trace cc5;trace cc6;
drawoptions(withcolor violet);
trace cc7;trace cc8;
drawoptions(dashed evenly withcolor gris);
drawoptions();
etape2=image(
  trace etape1;
  trace cc5;trace cc6;
  trace cc7;trace cc8;
  );
fin;
%etape3:corps et tete
%5
figure(0,0,19u,28u);
trace grille(0.25) withcolor orange;
origine((20,20));
pair G,H,J;
G=pp(-8,-3);
H=symetrie(G,O,I);
cc9=cercles(I,6.5u);
cc10=cercles(H,9u);
cc11=cercles(G,9u);
J=symetrie(cc10 intersectionpoint cc11,G,H);
cc12=cercles(J,1.5u);
pointe(G,H,J,I);
trace etape2;
trace cc5;trace cc6;
trace cc7;trace cc8;
drawoptions(withcolor violet);
drawoptions(dashed evenly withcolor gris);
trace cc9;trace cc10;trace cc11;trace cc12;
drawoptions();
fin;
%6
figure(0,0,19u,28u);
trace grille(0.25) withcolor orange;
pointe(G,H,J,I);
trace etape2;
trace cc5;trace cc6;
trace cc7;trace cc8;
drawoptions(withcolor violet);
trace cc9 cutbefore (subpath(length cc2/4,length cc2/2) of cc2) cutafter (subpath(0,length cc1/4) of cc1);
drawoptions(dashed evenly withcolor gris);
trace cc10;trace cc11;trace cc12;
drawoptions();
fin;
%7
figure(0,0,19u,28u);
trace grille(0.25) withcolor orange;
pointe(G,H,J,I);
trace etape2;
trace cc5;trace cc6;
trace cc7;trace cc8;
trace cc9 cutbefore (subpath(length cc2/4,length cc2/2) of cc2) cutafter (subpath(0,length cc1/4) of cc1);
drawoptions(withcolor violet);
trace cc10 cutbefore (subpath(length cc1/2,3*length cc1/4) of cc1) cutafter segment(J,J);
trace symetrie(cc10 cutbefore (subpath(length cc1/2,3*length cc1/4) of cc1) cutafter segment(J,J),O,I);
drawoptions(dashed evenly withcolor gris);
trace cc12;
drawoptions();
fin;
%8
figure(0,0,19u,28u);
trace grille(0.25) withcolor orange;
pointe(G,H,J,I);
trace etape2;
%tete
trace cc5;trace cc6;
trace cc7;trace cc8;
trace cc9 cutbefore (subpath(length cc2/4,length cc2/2) of cc2) cutafter (subpath(0,length cc1/4) of cc1);
trace cc10 cutbefore (subpath(length cc1/2,3*length cc1/4) of cc1) cutafter segment(J,J);
trace symetrie(cc10 cutbefore (subpath(length cc1/2,3*length cc1/4) of cc1) cutafter segment(J,J),O,I);
drawoptions(withcolor violet);
trace cc12 cutbefore cc11 cutafter (subpath(length cc10/2,0.7*length cc10) of cc10);
drawoptions(dashed evenly withcolor gris);
drawoptions();
fin;
%9
figure(0,0,19u,28u);
trace grille(0.25) withcolor orange;
pair M,N;
origine((20,20));
M=cc9 intersectionpoint cc1;
N=pp(-2,16);
cc13=cercles(M,N);
pointe(M,N);
trace etape2;
%tete
trace cc5;trace cc6;
trace cc7;trace cc8;
trace cc9 cutbefore (subpath(length cc2/4,length cc2/2) of cc2) cutafter (subpath(0,length cc1/4) of cc1);
trace cc10 cutbefore (subpath(length cc1/2,3*length cc1/4) of cc1) cutafter segment(J,J);
trace symetrie(cc10 cutbefore (subpath(length cc1/2,3*length cc1/4) of cc1) cutafter segment(J,J),O,I);
trace cc12 cutbefore cc11 cutafter (subpath(length cc10/2,0.7*length cc10) of cc10);
drawoptions(withcolor violet);
drawoptions(dashed evenly withcolor gris);
trace cc13;
drawoptions();
fin;
%10
figure(0,0,19u,28u);
trace grille(0.25) withcolor orange;
pointe(M,N);
trace etape2;
%tete
trace cc5;trace cc6;
trace cc7;trace cc8;
trace cc9 cutbefore (subpath(length cc2/4,length cc2/2) of cc2) cutafter (subpath(0,length cc1/4) of cc1);
trace cc10 cutbefore (subpath(length cc1/2,3*length cc1/4) of cc1) cutafter segment(J,J);
trace symetrie(cc10 cutbefore (subpath(length cc1/2,3*length cc1/4) of cc1) cutafter segment(J,J),O,I);
trace cc12 cutbefore cc11 cutafter (subpath(length cc10/2,0.7*length cc10) of cc10);
drawoptions(withcolor violet);
trace cc13 cutbefore cc2 cutafter cc10;
drawoptions(dashed evenly withcolor gris);
drawoptions();
etape3=image(
  trace etape2;
%tete
  trace cc5;trace cc6;
  trace cc7;trace cc8;
  trace cc9 cutbefore (subpath(length cc2/4,length cc2/2) of cc2) cutafter (subpath(0,length cc1/4) of cc1);
  trace cc10 cutbefore (subpath(length cc1/2,3*length cc1/4) of cc1) cutafter segment(J,J);
  trace symetrie(cc10 cutbefore (subpath(length cc1/2,3*length cc1/4) of cc1) cutafter segment(J,J),O,I);
  trace cc12 cutbefore cc11 cutafter (subpath(length cc10/2,0.7*length cc10) of cc10);
%corps
  trace cc13 cutbefore cc2 cutafter cc10;
);
fin;
%11
figure(0,0,19u,28u);
trace grille(0.25) withcolor orange;
origine((20,20));
pair R,S,P,Q;
R=pp(1,19);
P=pp(9,14);
Q=pp(15,12);
S=iso(P,Q);
pointe(P,R,Q,S);
cc14=cercles(N,P);
cc15=cercles(S,Q);
cc16=cercles(R,Q);
trace etape3;
drawoptions(withcolor violet);
drawoptions(dashed evenly withcolor gris);
trace cc14;trace cc15;trace cc16;
drawoptions();
fin;
%12
figure(0,0,19u,28u);
trace grille(0.25) withcolor orange;
pointe(P,R,Q,S);
trace etape3;
drawoptions(withcolor violet);
trace cc14 cutafter (subpath(length cc13/4,length cc13/2) of cc13);
trace cc14 cutbefore segment(P,P);
drawoptions(dashed evenly withcolor gris);
trace cc14;trace cc15;trace cc16;
drawoptions();
fin;
%13
figure(0,0,19u,28u);
trace grille(0.25) withcolor orange;
pointe(P,R,Q,S);
trace etape3;
trace cc14 cutafter (subpath(length cc13/4,length cc13/2) of cc13);
trace cc14 cutbefore segment(P,P);
drawoptions(withcolor violet);
trace arccercle(P,Q,S);
drawoptions(dashed evenly withcolor gris);
trace cc16;
drawoptions();
fin;
%14
figure(0,0,19u,28u);
trace grille(0.25) withcolor orange;
pointe(P,R,Q,S);
trace etape3;
trace cc14 cutafter (subpath(length cc13/4,length cc13/2) of cc13);
trace cc14 cutbefore segment(P,P);
trace arccercle(P,Q,S);
drawoptions(withcolor violet);
trace cc16 cutafter (subpath(length cc13/4,length cc13/2) of cc13);
trace cc16 cutbefore segment(Q,Q);
drawoptions(dashed evenly withcolor gris);
drawoptions();
etape4=image(
  trace etape3;
  trace cc14 cutafter (subpath(length cc13/4,length cc13/2) of cc13);
  trace cc14 cutbefore segment(P,P);
  trace arccercle(P,Q,S);
  trace cc16 cutafter (subpath(length cc13/4,length cc13/2) of cc13);
  trace cc16 cutbefore segment(Q,Q);
  );
fin;
%
for k=1 upto 5:
  figure(0,0,19u,28u);
  trace grille(0.25) withcolor blanc;
  trace etape4;
  fin;
endfor;
end