CSC104H1 Lecture Notes - Lecture 14: Animage

46 views4 pages

Document Summary

> ; images as lists of pixel colors. ; an 1*1 orange square: (define s (square 1 solid orange)) ; to turn an image into a list or red-green-blue-opacity lists. ; the image s has one dot (one pixel), with color 100% red, 64. 7% green, 0% blue, 100% opaque. (length (image->colors s)) > (image->colors s) (list (list 100 64. 7 0 100)) > (square 100 colid (list 100 64. 7 0 100)) square: expects a mode (solid or outline) for the second argument, but received colid > (square 100 solid (list 100 64. 7 0 100)) ; a 2*2 red square: (define s2 (square 2 solid red)) > (sacle 100 s2) sacle: this function is not defined. ;each pixel is the same : 100 red 0 green 0 blur 100 opaque. (image->colors s2) (list (list 100 0 0 100) (list 100 0 0 100) (list 100 0 0 100) (list 100 0 0 100))

Get access

Grade+20% off
$8 USD/m$10 USD/m
Billed $96 USD annually
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
40 Verified Answers
Class+
$8 USD/m
Billed $96 USD annually
Class+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
30 Verified Answers

Related Documents