Lesson video

In progress...

Loading...

Hi, my name is Mr. Hogan.

I'm so excited to be learning with you today.

We are going to have such a great time learning about data representation of images and sounds.

I will be supporting you with our learning during these lessons.

I am so pleased that you have decided to complete your learning with me today.

We are going to do brilliantly.

Welcome to today's lesson from the unit "Data representation: images and sounds." This lesson is called "Representing images with binary data." By the end of today's lesson, you will be able to explain how images are represented using binary digits and created using the RGB system.

I hope you enjoy it.

There are four keywords for this lesson.

Let's take a look at them.

We have pixel.

This is a single element of an image on a computer screen.

Bit.

This is a binary digit.

This is the basic unit of data within a computer system that has a value of 0 or 1.

RGB system.

This is a color model used to represent and create colors by combining three colors of light: red, green, and blue.

And the last keyword is intensity.

This is the strength of a color, shown by the value of each element: red, green, or blue.

So the lesson outline for today.

So it's split into three parts.

The first part is describe how images are formed of pixels.

Then we go on to describe how an image can be represented as bits.

And finally, moving on to combining red, green, and blue colors.

It's going to be a great lesson.

I'm really looking forward to it.

Let's start with describe how images are formed of pixels.

Have you ever taken a photograph on a digital device such as a phone or a camera? How does that device capture the image? Alex is asking, "How does the camera know how to store that image?" Laura is also asking, "What steps does the computer take to display that image?" Interesting questions that we hope to answer.

Digital images are composed of individual elements arranged in a grid.

The elements of a digital image are called pixels.

That's short for picture elements.

The pixels are displayed on the computer or device for you to view the image on.

So you can see we have a little game character on the right-hand side here.

And the individual squares, or individual elements that look like squares, they are called pixels.

When you zoom in or enlarge an image, the pixels are stretched into larger blocks.

So where we've zoomed in on this hummingbird, you can see the individual blocks that are pixels.

That's why images appear poor quality when you enlarge them too much, like this astronaut example where we've zoomed in on their leg.

The images appear blurry or blocky.

This is known as pixelated.

So you can see on this example, this animation, when we're zooming in, you can see it becomes like blurry and pixelated.

Let's have a quick check.

What happens to the pixels in a digital image when you zoom in or enlarge it? Is it A, the pixels stay the same size, but more pixels are added to fill the space? Is it B, the pixels get stretched and become larger, making the image look blocky or blurry? Or is it C, the pixels change color, making the image look distorted? Take your time.

Remember, you can always pause this video or even rewind it to previous slides to look at the answer.

Shall we have a look at the answer? It is B, the pixels get stretched and become larger, making the image look blocky or blurry.

Remember, this is known as pixelation.

Well done on getting the answer right.

If you didn't get the answer right, don't worry.

We carry on the lesson, and I'm sure you'll enjoy it.

This image is a grid of 12 x 12 pixels.

It contains 6 red pixels on, like, the tongue of the smiley face, 20 black pixels, so that's the eyes, so the winky eye and the mouth, 86 yellow pixels, so that's the remainder of the face, and 32 white pixels.

Don't forget about them.

They are on the background of the image.

Let's have a quick check.

This image is made up of 132 pixels.

Which of the following is true? A, there are equal amounts of white and black pixels, B, most of the pixels are blue, or C, there are 21 white pixels.

So you can pause the video at any time or rewind it if you want to to look at previous slides, but probably you need to pause this one because then you need to do some counting.

Shall we have a look at the answer? It is C, there are 21 white pixels.

So hopefully you counted those individual pixels.

Well done.

Let's have a practice now.

One, what are the tiny squares that make up a digital image called? Two, why may an image look blurry or blocky when you make it larger? Remember, you can pause the video at any time or rewind it.

Let's have a look at an answer.

So one, what are the tiny squares that make up a digital image called? So the tiny squares that make up a digital image are called pixels.

Two, why may an image look blurry or blocky when you make it larger? So an image looks blurry or pixelated when you zoom in too much because the pixels are stretched and become large and blocky.

Hopefully you got these answers right.

Well done.

We're going to move on to the second part of the lesson: Describe how an image can be represented as bits.

So we've looked at pixels.

Now we're gonna see how this actually is represented in bits.

Each pixel is assigned a binary number that represents a specific color.

This black and white smiley face can be represented using just one bit per pixel: 0 for a white pixel, and 1 for a black pixel.

So if you put those into the image, you can see that for every black pixel, it is represented by a 1, and for every white pixel, it's represented by a 0.

So we're using one bit to represent it.

Let's have a quick check.

How many different colors can one bit represent? Is it A, one, B, two, or C, four? Remember, pause the video at any time or you can rewind it to the previous slide.

Shall we have a look at the answer? It is two.

There are two combinations of a single bit, 1 and 0.

Laura is asking, "So one bit is used for an image with any two colors.

The first color can be 1 and the 0 can be the other color." Alex is questioning, "Yes, I understand that, but there are more than two colors in most images.

How does that work?" Let's move on and see if we can answer Alex's question.

Two bits can represent four colors.

Each combination of two bits can represent a color.

So here we have 00 for a white pixel, 01 for a yellow pixel, 10 for a black pixel, and 11 for a red pixel.

So putting those binary digits into the image, you can see that we have four colors represented by two bits.

Let's have a check.

This pointer on the white background uses three colors.

How many bits are needed to represent each pixel in this image? Is it A, one, B, two, or C, three? Remember, pause the video at any time or even rewind it to replay parts.

Shall we have a look at the answer? It is B, two.

Although only three colors are used in the image, two bits are required because the image contains more than two colors, and two bits can represent up to four colors.

So yeah, it needs two bits even though there are only three colors in the image.

Hopefully you got that answer right.

Well done.

We're gonna have a practice now.

One, the top row of this image contains two colors.

How many binary digits, bits, are required to store this row? Two, how many bits are required to store the colors in the whole image? Three, if you add a blue border one pixel wide to the image, how many bits will now be required to store the image? Four, why does using more bits per pixel allow you to have more colors in an image? These questions will take maybe a bit of time to answer, so please pause the video and remember to rewind it if you want to recap on anything.

So possible answers.

One, the top row of this image contains two colors.

How many binary digits, bits, are required to store this row? So if you're just storing this row, there are only two colors on the top row, so this could be represented with a single bit.

So we've just put the binary number in the top row to show you of 1 and 0, representing black and red.

Two, how many bits are required to store the colors in the whole image? So there are how many colors in this image? One, black, two, red, three, white, and four, blue.

So therefore, it is two bits, as you can see in the image now.

If you add a blue border one pixel wide to the image, how many bits will be now required to store the whole image? It would still be two because the color blue has already been used in the image, so no more bits are required.

Four, why does using more bits per pixel allow you to have more colors in an image? Well, each bit could either be a 0 or a 1.

Therefore, increasing the number of bits expands the possible combinations of 1s and 0s.

Each unique combination can represent a different color, enabling a greater variety of colors in the image.

Well done for getting this far.

Hopefully you're enjoying it.

I'm really, really enjoying it myself, looking at different ways that images can be represented as bits, and I've learned about pixels and images being pixelated, well done.

We're going to be moving on to combining red, green, and blue colors.

Computers create a variety of colors by mixing different amounts of three colors: red, green, and blue.

Overlaying these colors allows new combinations of colors: yellow, cyan, and magenta.

This is known as the RGB system.

So you can see on the animation that when these circles of red, green, and blue combine, where they overlap, they form different colors of yellow, cyan, and magenta.

Let's have a check.

In the RGB system, which color is created by combining red and green light? Remember, you can pause the video at any time, or if you want to go back and have a look at the previous slide to see if you can find the answer, please do that.

Shall we have a look at the answer? It is yellow.

Yeah, so now you can see the animation on this slide where you can see the red and green overlapping, now it forms yellow.

Color intensity is measured on a scale from 0 to 255 for each of the colors, the red, green, and blue.

0 means none of the color is present.

255 is the most intense color possible.

For example, 0 of the red, 255 of the green, and 0 of the blue represents green because the green is set to the highest intensity and the red and blue are not used at all.

So you can see on the image where we have a similar pattern representing red, 255, 0, 0, and blue, 0, 0, 255.

You can now see all the other colors and their intensities represented as RGB values.

The values of intensity to create the color blue are 0 for red, 0 for green, and 255 for blue.

The values of intensity to create the color cyan are 0 red, 255 green, and 255 blue.

You may remember the green and blue crossing over in the animation, and that provided the cyan color.

The color taken from this pixel has the following intensities: 255 for red, 187 for green, and 100 for blue.

So if you put these intensities together, it gives this color of the kingfisher's breast.

When the color changes, the values change.

So for this kingfisher's wing, which is sort of a light blue, it's represented by the intensities of 87 red, 165 green, and 235 blue.

Let's have a check.

In the RGB system, what does a color intensity value of 0 indicate? Is it A, the most intense version of that color, B, a medium intensity of that color, or C, none of that color is present.

Remember, you can rewind this video at any time or pause it to have a think about the answer.

Shall we have a look at the answer? It is C, none of that color is present.

Well done if you got that right.

And if you didn't, don't worry.

Take some time.

Maybe rewind and have a look at the other slides again.

Practice time.

So, question number one, what are the three colors that computers use to create other colors? Two, how do computers create different shades of a color? Three, what RGB values would you use if you want to create a red pixel? Four, what RGB values would you use if you want to create a yellow pixel? Remember, you can pause the video at any time or go back to previous slides.

Let's have a look at some answers.

Question one, what are the three colors that computers use to create other colors? So it's red, green, and blue.

Two, how do computers create different shades of a color? So computers create different shades of a color by changing the intensity of red, green, and blue.

Three, what RGB values would you use if you want to create a red pixel? So you have 255 on the red, the greatest intensity it can have, 0 on the green, and 0 on the blue because that is no intensity at all.

Four, what RGB values would you use if you want to create a yellow pixel? So you would have 255 for red, 255 for green, and 0 for blue.

So when red and green combine, like we saw on the animation, it forms yellow.

Well done.

You've come to the end of the lesson.

You've done so well.

I've really enjoyed learning with you today.

So in summary, you've learned that digital images are made up of tiny squares called pixels, and it's arranged in a grid.

Computers use bits, 1s and 0s, to store and display images.

The number of bits required depends on the number of colors the image is made of.

And also, each pixel's color is a mix of red, green, and blue.

Well done.

I've really enjoyed learning with you today.

Thank you very much.