Cover shapes in background with filled shapes in foreground

조회 수: 1 (최근 30일)
Saeid
Saeid 2020년 4월 2일
편집: Saeid 2020년 4월 2일
I would like to draw shapes using the polyshape function, e.g. by writing:
x0=[0 0 200 200]; y0=[10 0 0 10]
SquareShape=polyshape(x0,y0)
plot(SquareShape)
hold on
ElmX=[0 5 10 20 25 30 40 40 60 70 85 95]
ElmY=[12 -2 12 -2 12 -2 12 -2 12 -2 12 -2]
plot(ElmX,ElmY)
hold on
x1=[10 10 20 20]; y1=[10 0 0 10]
SquareShape=polyshape(x1,y1)
plot(SquareShape)
but when I run the routine it generates transparent pictures, whereas I want the last shape created last (in this case the one created in the line before last) to cover the surface beneath itself.

답변 (0개)

카테고리

Help CenterFile Exchange에서 Elementary Polygons에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by