- [Voiceover] In this movie, we'll take a look at the two
8-bit file formats which are .gif and an alternate
version of .png and the idea behind these 8-bit formats
is that they support a maximum of 256 colors,
which provides us with a big savings in file size.
And so, I'm going to advance to the second artboard
by pressing shift + page down,
and then, I'll go up to the file menu and choose
Save for Web or press Control + Shift + Alt + S
or Command + Shift + Option + S on a Mac.
And you can see that where this document is concerned
the transparency checkbox is turned off,
which is exactly what I want.
I want to go ahead and keep this white background.
And now, I'll go ahead and click on a format option
and choose .gif from the list.
And you may wonder why I'm calling it jif in stead of gif,
it's because that's what CompuServe, which is the company
that created .gif, that's what they call it, and so,
I figured I oughta call it what the originators called
the format, even if it sounds a little strange
to some people's ears.
Now, notice that we have a bunch of controls up here
in the upper right corner of the window,
which I'll come to in a second, but first,
I want you to see the file size listings.
The original is 2.58MB uncompressed,
whereas the .gif file is just 97.22K,
so, it's a heck of a lot smaller.
But the thing is, .gif doesn't offer anything over PNG-8,
and yet, if I choose PNG-8, we see the same options up here,
but we also see the file size drop to 75.35K
and that's because .png is a more modern file format
with better compression and so, if you're gonna create
8-bit images, I suggest you go with .png instead of .gif.
All right, now, you can see we have this big palette
of colors down here that Save for Web
has generated automatically.
And while things look pretty good
over here on the left side of the image,
that has a huge impact on this hue wheel right here.
And I'm gonna make it bigger just by pressing Control + Plus
or Command + Plus on the Mac to zoom in.
And you can see, right here, that we have
a bunch of colorful pixels that are trying to split
the difference between the various colors.
And this is what's known as a dither pattern.
Right now, the specific kind of pattern
is a diffusion pattern, but you can change that
to no dither if you want to, in which case you're just
gonna get a bunch of blobs of color,
or you can go with a pattern dither which is going
to arrange the pixels in regular patterns,
or if you want the most random effect, you can choose noise,
like so.
I'm gonna go ahead and switch back to diffusion
because it offers an additional option
in the form of this dither value.
And so, if you want to save a little bit on file size,
notice it's 75.35K right now, you can take that dither
value down to, say, 50%, in which case you're gonna get
larger blocks of color with less diffusion dither
in between, and the file size drops to 47.73K,
so it drops by quite a bit.
But that's pretty ugly, so I'm gonna take the dither value
up to 100% where this specific image is concerned.
You also have control over how many colors you want
and notice that they go in bit order,
meaning that we start with a 1-bit image,
which is two colors, black and white, essentially, like so,
and then we have two to the second power, which is four,
two to the third power, which is eight,
two the the fourth power, which is 16, and so on,
all the way up to 256, which is pretty much what I think
we want for this image.
All right, if you want to, you can snap
to the web safe colors, I don't recommend you do,
it doesn't really serve any purpose.
And then, finally, there's this option that determines
how Save for Web auto-selects colors.
And so, you can go with restrictive,
which is the web safe colors.
Again, there's no reason to do that.
Your image is gonna look cruddy if you do.
You've got adaptive, which is a strict popularity contest,
by the way, it's just gonna find the most popular colors
inside the image and go with them.
Then we have perceptual up here at the top,
which tries to do the best job of preserving
the gradient transitions, and then, if you want to split
the difference, which is generally the best way to go,
you want to go with selective.
In our case, however, since we've got this rainbow gradient,
I'm gonna go with perceptual.
And then, I'll go ahead and click the save button
and I'll go ahead and save over this image right there,
8-bit-hue-wheel.png and I'll click on the save button
and then click yes in order to write over it.
All right, now let's take a look at the image inside
of Photoshop and you can see that it comes out
pretty darn good.
The text looks great, for example.
The gradient's a little bit noisy,
but if we zoom out to 100%, it doesn't look half bad,
even though we're limited to just 256 colors
and nothing more.
Now, this is a great demonstration, at least
of how the dithering works, but it's not an ideal candidate
for saving as an 8-bit image.
So, let's go ahead and return to Illustrator and switch
to this low color, highly graphic file, right here.
This is perfect for 8-bit PNG.
And so, I'll go up to the file menu and choose Save for Web.
And now, notice, if I switch back to .gif, the file size
goes from 2.58MB all the way down to 30.38K,
which is nothing, by the way, it's a very, very small image,
but we can get even smaller by switching to PNG-8,
which gives us a file that's about 22.5K,
so, very dinky indeed.
Also, notice that even though we've got the colors
cranked up to 256, the color table doesn't contain
nearly that many colors.
In fact, I've figured out that I can take this colors
value down to 82 and the colors here inside this palette
aren't gonna change one wit.
And so, that's all Illustrator needs in order to represent
this graphic.
However, we're probably better off, where this graphic
is concerned, switching from perceptual to adaptive
so that we just get the most popular colors.
All right, so, it shouldn't make any difference
if I crank this back up to 256.
And, sure enough, our file size is exactly the same
and I can see the number of colors down here in the lower
right corner of the preview, we have just 81 colors in all,
so I stand corrected.
All right, now, I'll go ahead an click the save button
and I'll call this guy Just 81 colors, let's say,
and then I'll click on the save button in order
to save off that .png file.
All right, and finally, I'll go ahead and switch over
to Photoshop so we can check it out.
And despite the fact it's a low color graphic,
it looks absolutely great.
And that's how you save off an 8-bit screen graphic,
preferably s a .png file using the Save for Web command.