极客小将

您现在的位置是:首页 » scratch编程资讯

资讯内容

【Scratch扩展】神奇的图形绘制

极客小将2021-04-10-
Super Spirals Just like circles, spirals go around and around. The difference is that with a ci

Super Spirals

Just like circles, spirals go around and around. The difference is that with a circle, the radius always stays the same but in a spiral the radius keeps growing (or shrinking if you prefer). We looked at two ways to make a spiral using Scratch. The first way is very similar to the program used in Going in Circles. The main difference is that in the repeat you change the size of the shape using the "change size by" command. In our code we used the number "-1" -  the negative number makes the shape get smaller by 1% each time. You can also use a positive number and make the shape get bigger each time.

upload/article/images/2021-04-10/e8116be9f888abe85fd7cf27a41fd28c.jpg

You might like to play around with Colour Gradients颜色渐变 for this project. A colour gradient is a gradual change from one colour to another and gives the art work a feeling of depth. To create a gradient, draw a shape then select the paint bucket tool. Just below the bucket, click on one of the pictures showing a gradual change from black to white. Then pick two colours from the palette. Finally, click on a region of the picture that you want to fill with the gradient. Also don't forget to play with the position of the center of the costume.

upload/article/images/2021-04-10/0508dd02bb93567a9457f9b84feeaf0d.jpg

upload/article/images/2021-04-10/fa492ed23200bc3c150885624ea0e430.jpg

upload/article/images/2021-04-10/25b36c57fb2cb693ac63414d2afa56a0.jpg

upload/article/images/2021-04-10/0d905bad4f87b609917ef50130b07bfa.jpg

Another way to make a spiral is to use the Pen commands in Scratch. You can draw any shape, for example a triangle or a square by using the "pen down", "turn" and "move" commands. To turn this into a spiral, you need to change the distance you move each time you draw a side of the shape. To do this, we use a variable which we called length. The variable is initially set to a small size like 3 and on each repeat we increase the size of the variable using the "change [variable]" command. Play around with how much the length changes each time and see what this does to the spiral. 

upload/article/images/2021-04-10/854bfb103b0a1ab39412a5a816859294.jpg

upload/article/images/2021-04-10/e7a468e5b32baaed7c5c56ccb1bcf570.jpg


upload/article/images/2021-04-10/e6a54f4e1c8de634aff728f1453adac0.jpg

upload/article/images/2021-04-10/016248cacad73425ddd39be72a458b9e.jpg

You can also play around with how much you turn in each repeat. In the picture below, the left side of the picture turns 120 degrees - this gives us a triangular spiral. The right side of the picture turns 121 degrees each repeat. See what a difference this little change makes? Now it looks like you are drawing curves using straight lines. 

upload/article/images/2021-04-10/252689ca11f87907dbc81afb71e059d3.jpg

Here are some examples that the students created:
This one uses a random number for the line width: 

upload/article/images/2021-04-10/7ec148dd595fa8b7ff75677a036ccbc0.jpg
This one draws two spirals:

upload/article/images/2021-04-10/72597d80edc9b30f7caf21a467506b78.jpg

upload/article/images/2021-04-10/16352b7d685ffe4b549f00cfed1b268e.jpg

This one changes the pen color by 50: 

upload/article/images/2021-04-10/6ce098696112fbd060900bcdff5dbad4.jpg

upload/article/images/2021-04-10/f236feb73e71d401740c2043154fda48.jpg

声明:本文章由网友投稿作为教育分享用途,如有侵权原作者可通过邮件及时和我们联系删除

网友点评

共有5条评论来说两句吧...