COMP10001 Lecture Notes - Lecture 10: Dynamic Html, Scalable Vector Graphics, Digital Image

47 views1 pages
Static HTML = web server
-
> static HTML page
-
> web browser
-
Dynamic HTML = web server
-
-
> dynamically generates the HTML page
-
> web
browser
-
HTML pages:
Represented as individual colour pixels
e.g. PNG, JPEG
Binary
Each pixel is a single integer specifying its greyscale value
0 = black
255 = white
Greyscale
Each pixel is a triple of integers specifying the RGB values
(0,0,0) = black
(255,0,0) = red
(0,255,0) = green
(0,0,255) = blue
(255,255,255) = white
Often expressed in a hexadecimal value
Colour
Types of digital image
Width and height of image are required
Raster images
-
Represented as points, lines, curves
e.g. SVG, PDF
Vector images
-
Images:
Bit = a single
-
digit binary number
-
Byte/octet = vector of 8 bits
-
Hexadecimal = base 16
-
0x = hexadecimal
0o = octal
0b = binary
Prefixes in Python
-
Use hex(), oct(), bin() to convert a decimal int to a string in another base
-
Kilo = 2^10
Mega = 2^20
Giga = 2^30
Tera = 2^40
But storage is often reported with a base of 10
Units
-
Computational coding:
Week 10
Sunday, 13 May 2018 8:07 PM
Foundations of Computing Page 1
Unlock document

This preview shows half of the first page of the document.
Unlock all 1 pages and 3 million more documents.

Already have an account? Log in

Document Summary

Stati(cid:272) html = (cid:449)e(cid:271) se(cid:396)(cid:448)e(cid:396) -> stati(cid:272) html page -> (cid:449)e(cid:271) (cid:271)(cid:396)o(cid:449)se(cid:396) D(cid:455)(cid:374)a(cid:373)i(cid:272) html = (cid:449)e(cid:271) se(cid:396)(cid:448)e(cid:396) -> p(cid:455)tho(cid:374) -> d(cid:455)(cid:374)a(cid:373)i(cid:272)all(cid:455) ge(cid:374)e(cid:396)ates the html page -> (cid:449)e(cid:271) (cid:271)(cid:396)o(cid:449)se(cid:396) Rep(cid:396)ese(cid:374)ted as i(cid:374)di(cid:448)idual (cid:272)olou(cid:396) pi(cid:454)els e. g. png, jpeg. Ea(cid:272)h pi(cid:454)el is a si(cid:374)gle i(cid:374)tege(cid:396) spe(cid:272)if(cid:455)i(cid:374)g its g(cid:396)e(cid:455)s(cid:272)ale (cid:448)alue (cid:1004) = (cid:271)la(cid:272)k (cid:1006)(cid:1009)(cid:1009) = (cid:449)hite. Ea(cid:272)h pi(cid:454)el is a t(cid:396)iple of i(cid:374)tege(cid:396)s spe(cid:272)if(cid:455)i(cid:374)g the rgb (cid:448)alues (cid:894)(cid:1004),(cid:1004),(cid:1004)(cid:895) = (cid:271)la(cid:272)k (cid:894)(cid:1006)(cid:1009)(cid:1009),(cid:1004),(cid:1004)(cid:895) = (cid:396)ed (cid:894)(cid:1004),(cid:1006)(cid:1009)(cid:1009),(cid:1004)(cid:895) = g(cid:396)ee(cid:374) (cid:894)(cid:1004),(cid:1004),(cid:1006)(cid:1009)(cid:1009)(cid:895) = (cid:271)lue (cid:894)(cid:1006)(cid:1009)(cid:1009),(cid:1006)(cid:1009)(cid:1009),(cid:1006)(cid:1009)(cid:1009)(cid:895) = (cid:449)hite. Rep(cid:396)ese(cid:374)ted as poi(cid:374)ts, li(cid:374)es, (cid:272)u(cid:396)(cid:448)es e. g. svg, pdf. P(cid:396)efi(cid:454)es i(cid:374) p(cid:455)tho(cid:374) (cid:1004)(cid:454) = he(cid:454)ade(cid:272)i(cid:373)al (cid:1004)o = o(cid:272)tal (cid:1004)(cid:271) = (cid:271)i(cid:374)a(cid:396)(cid:455) Use he(cid:454)(cid:894)(cid:895), o(cid:272)t(cid:894)(cid:895), (cid:271)i(cid:374)(cid:894)(cid:895) to (cid:272)o(cid:374)(cid:448)e(cid:396)t a de(cid:272)i(cid:373)al i(cid:374)t to a st(cid:396)i(cid:374)g i(cid:374) a(cid:374)othe(cid:396) (cid:271)ase. But sto(cid:396)age is ofte(cid:374) (cid:396)epo(cid:396)ted (cid:449)ith a (cid:271)ase of (cid:1005)(cid:1004)

Get access

Grade+
$40 USD/m
Billed monthly
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
10 Verified Answers
Class+
$30 USD/m
Billed monthly
Class+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
7 Verified Answers

Related Documents