??????? ? Pascal - PowerPoint PPT Presentation

About This Presentation
Title:

??????? ? Pascal

Description:

* * * * * * * * * * * * * * ... – PowerPoint PPT presentation

Number of Views:105
Avg rating:3.0/5.0
Slides: 29
Provided by: 2098191
Category:
Tags: pascal

less

Transcript and Presenter's Notes

Title: ??????? ? Pascal


1
??????? ? Pascal
2
??????????? ????????? ? Pascal'e

  • ??????? ???????????? ??????
  • ?????
  • ?????????????
  • ??????????
  • ??????
  • ????


?????
??????????
???? ?2
???? ?1
3
??????????? ?????
  • ??? ?????? ??????????? ??????????? ?? ?????
    ???????? ? ????? Pascal ?????????? ???????????
    ?????????? Graph, ??????????? ???????
    ?????????????? ??????????? ????????
  • uses Graph
  • ? ??????????? ?????? ?????? ????? ???????????
    ?? ?????? ??????? ??????? ?? ????????? ??????????
    ?????????? ????? ????????. ????? ???????
    ???????????? ????? ????????????? ????? ?????????.

4
??????????? ?????
(0,0)
(0,0)
(640,0)
(640,0)
?
?

(0,480)
(0,480)
y
y
?????? ?????? 640?480
5
????????????? ???????????? ??????
  • Program pr
  • Uses crt, graph ????????????? ????????????
    ??????
  • Var driver, ??????????? ???????
  • modeinteger ??????????? ?????
  • Begin
  • Driverdetect ?????????????????
    ????????
  • Initgraph(driver, mode,???? ? ?????
    egavga.bgi)
  • ????????? ? ????????? ??????????? ??????????
  • Readkey
  • Closegraph
  • End.

6
?????? ??????
  • 0 ??????
  • 1 ?????
  • 2 ???????
  • 3 ???????
  • 4 ???????
  • 5 ??????????
  • 6 ??????????
  • 7 ??????-?????
  • 8 ?????-?????
  • 9 ????-?????
  • 10 ????-???????
  • 11 ????-???????
  • 12 ????-???????
  • 13 ????-???????
  • 14 ??????
  • 15 ?????

7
? ????? ??? ????? ??????? ? ????? ??? ????? ???????
0 ?????????? (??????????? ?????? ????) 6
1 ?????????? ??????? ?????? 7
2 8
3 9
4 10
5 11
8
?????
  • ???????? LINE(X1,Y1,X2,Y2) ?????? ?? ??????
    ??????? ?????? ?? ????? ? ???????????? (x1,y1) ??
    ????? ? ???????????? (x2,y2).

9
????????? ?????
  • SetColor(Colorinteger)
  • ????????????? ???????? ???? ?????????
  • SetBkColor(Colorinteger)
  • ????????????? ??????? ??????? ????
  • ???????? ?????????? ?? ?????? ?????? ?????
    ??????? ?????? ?? ????? ? ????????????(100,50) ?
    ????? ? ????????????(400,300) ???????? ?????
  • SetBkColor(1)

  • SetColor(4)

  • LINE(100,50,400,300)

10
?????????????
  • ????????? Bar(x1,y1,x2,y2) ??????? ?? ?????
    ??????????? ????????????? ? ???????????? ??????
    ???????? ???? (?1,?1) ? ??????? ??????? ????
    (?2,?2).

????? ????????? ??????????? ?????? ?????
-?????????? ???? ?????? SETCOLOR(? ?????)
-?????????? ???? ? ????? ????????
SETFILLSTYLE(? ?????, ? ?????) -??????????
?????? ???????? ?????? (?????? ?????? ???
????????) -????????? ?????? FLOODFILL(x,y,?
????? ???????) ??? x,y ?????????? ????? ?
???????? ???????.
11
??????????
  • ????????? CIRCLE(x,y,r) ??????? ?? ?????
    ?????????? ? ??????? (?,?) ? ???????? r.

12
??????
  • ????????? ELLIPSE(x,y,L1,L2,Rx,Ry) ??????
    ????????????? ???? ?? ?????????? ???? L1 ??
    ?????????L2, ????????? ?,? ??? ?????????? ??????,
    ??? ?????????????? (Rx) ? ????????????(Ry)
    ??????.

13
????
  • ????????? Arc(x,y,L1,L2,r) ?????? ???? ?
    ??????? ? ????? (?,?) ?? ?????????? ???? L1 ??
    ????????? L2 ???????? r.

14
??????? ??????? ?????
???????? ????????
  • ?????????? ????????, ??????? ???????
    ????????????? ?? 20 ?? 400 ppi, ? ????? 20 ppi.
    ????? ?????? ????????? ? ??????? ????????. ????
    ????????? ???????? ????????? ??????. ??? ???????
    ?????? ???????????? ???? ? ????????????.

15
????? ?????????
16
????????? ??????
  • ?????????? ??????????, ???-?? ??????? ????????
    ?????????????. ?????, ?????? ? ???? ???????????
    ???????? ????????? ??????.

17
????? ?????????
18
??????
??????
  • ?????????? ?????? ??????? ???????.

?????? ??????? setcolor(15) line(200,40,300,180)
?????? ??????? setcolor(15) line(180,80,200,140)
?????? ??????? setcolor(15) line(300,80,320,140)

?????
19
????? ?????????
20
??????
??????
?????? ???? ????????? setcolor(14)
  • ?????????? ?????? ????????? ???????? Ellipse.

?????? ???????? Ellipse(100,300,0,180,25,20)
Ellipse(100,300,0,180,25,20) Ellipse(100,300,0,1
80,25,20) Ellipse(100,300,0,180,25,20)
?????? ???? ?????? setcolor(14)
?????? ???????? ?????? circle(100,50,15)
?????
21
???? ?????????
22
?????
??????
  • ?????????? ?????? ?? ???????????? ???????????????.

?????? ???????? setfillStyle(1,11) Bar(200,40,30
0,180)
?????? ?????? setfillStyle(1,15) Bar(180,80,200,1
40)
?????? ???? setfillStyle(1,14) Bar(300,80,320,140
)

?????
23
????? ?????????
24
????????
  • ?????????? ???????? ?????? ?????????????
    ????????????.

25
????? ?????????
26
???????
??????
  • ?????????? ??????? ?????? ????????????? ?????????.

?????? ???? ???????
?????? ????? ????
?????? ?????? ????
?????? ???
?????? ???
?????
27
????? ?????????
28
??????????
  • 1.??????? ???????????? ??????...3
  • 2.?????...8
  • 3.?????????????....10
  • 4.??????????.11
  • 5.??????....12
  • 6. ????....13
  • 7.??????? ??????? ?????14
  • ???????? ???????? -
  • ????????? ??????...16
  • ??????...18
  • ??????........20
  • ?????..22
  • ????????..24
  • ???????...........................................
    ............26


???? ?2
???? ?1
Write a Comment
User Comments (0)
About PowerShow.com