I am exporting my web images from PSD by 'Save For Web' option along with using its Quality and Format controls as per the standards but when I check my image size they are heavy than the expectation. I see the image sizes on other web. Their GIF images are too small. i.e a bullet arrow GIF image (12px X 48px) is near around 90 bytes but when I create the same image in PSD and export as GIF my size goes upto 1 KB. I just wanted to know that is their any other way to export or create images for web to gain lower size?
You can check how many colors are you using.
If you create a GIF with less colors you get a smaller GIF.
The size also depends on how many colors are in the image, maybe the 90 bytes gif is pure black and white and yours have more colors.
When you Save For Web in Photoshop, there are a few variables you can play to gain lower size, that you already use. I tried to explain some for other users who find this question,in case you already know how them works:
Lossy: Lossy compression lets you compress more bytes out. Higher value produces low image quality and less weight.
Colors: More number of colors used in the image causes higher size image, as aleixventa says in his answer.
Web Snap: That's the option to convert the color of the image to web safe colors. More web safe colors results in a smaller image.
Combobox "No Dither": Dithering mixes pixels of the gradients to simulate the missing colors. You could retrieve more specific info about this feature here. BTW, less percentaje of difussion dittering results in higher image.
With all these variables in mind, you can see the total weight while playing with them:
Is there a possibility to make image colors exactly the same as HTML colors?
I have a rounded corners box, the corners are images and the background color is HTML, on my laptop it looks flawless, but on good monitors a difference in colors is noticeable.
Is it true that it isn't possible to have HTML generated colors exactly match image colors?
edit: I am using Photoshop and am using the exact hex equivalent of the RGB colors.
Another potential solution: you're seeing a color shift caused by color profiles.
These could be due to how those other monitors are configured (you can update your machine to use a specific profile; folks like designers will do this to make sure colors are accurate in photography or print design) or due to how your images are saved when exporting them from your favorite image editing tool (I'm looking at you, Photoshop). These issues can and will occur regardless of whether or not your hex colors are spot on and are ridiculously frustrating.
Give that link a shot; if you're dealing with an embedded color profile issue, that might get you going in the right direction.
Edit: That you're exporting from Photoshop makes me think this is the likely culprit.
If you use the same colors, e.g. #E1E1E1 in your CSS and your image (a tool like 'GIMP' will assist you with a color picker where you can directly enter these hex values) the colors will be identical.
My guess is your problem is most likely compression (by saving as .jpg and the artifacts it introduces). Use other formats (like the lossless PNG format) or save your JPG in a lossless way (with the quality slider up to 100 in most tools).
Browsers / monitors can look a tiny bit different for some colors. Matching up certain colors may prove to be a difficult task even if you are matching an image with the same hex value as the one you are using in your css. (this will work for most cases but not always) My recommendation is to use web safe colors where possible, these colors tend to render the same on multiple displays.
I noticed that many of the sprites on the internet has a solid color background and not transparent i am sure there is a reason behind that but what is it ?
like this one :
http://www.spriters-resource.com/gameboy_advance/gs2/sheet/47045
I can remove the bg using photoshop but if this was the purpose why people didn't save it as transparent png in the first place.
what is the easier way to use this sprites in flash it doesn't make sense to me to cut each one and put it in a separate frame i am sure there is an easier way.
Sprite sheets are not meant to be sliced up into different images before compilation. Rather, they are mainly used for a technique called blitting which involves copying the pixels from the spritesheet onto the display at runtime (traditionally done for a performance gain over the standard Flash display list rendering).
You can read up on blitting here: http://www.8bitrocket.com/2008/7/2/Tutorial-AS3-The-basics-of-tile-sheet-animation-or-blitting/
And on how to actually remove the background when blitting: http://active.tutsplus.com/tutorials/animation/blitting-with-as3-removing-a-bitmaps-background-color/
I've been ask to implement a site that is using a very large background image. Like 1600 X 900. It's 700K. I don't know how to make this smaller and still save it's quality. It's a black and white photo, I was saving it as a GIF. Any advice.
use photoshop to save it as a jpeg at 60% quality. if you don't know how to save for web, when you want to save, hold ctl+alt+shift and the S button.
Photoshop will show you a preview of the quality and the file size if you use 'save for web and other devices'
Unfortunately there are limits to how small a file can be before it starts to degrade. GIFs are usually more appropriate for smaller and fewer-color images like logos and buttons.
Because GIFs use indexed color, each pixel has a color byte associated with it which means that each pixel adds file size. In a JPG the file size is dependent on many factors, its usually the best option for non-geometirc images.
Even if JPEG always has more colors than GIFs, you could convert it to Indexed colors and back to RGB, just to have a smaller number of colors in your JPEG. This will make it somewhat smaller.
Also of course raise the compression level.... 69% seems to work fine. Sometimes, you could go so low as 49% or so... try blurring the image - and you won't see the pixels as clearly.
This question already has answers here:
Closed 13 years ago.
I am trying to create a personal home page for myself to learn more about web design (JavaScript, using Photo Shop, etc). I plan on having a graphical menu on the left, a banner across the top and also a "Photos" section where I can display photos of various pictures I have taken.
However, when I look at other sites that do anything similar, I see some using GIFs, and some use JPGs and some even use PNGs. Is there any difference between these? Should I use a GIF for graphical images used on the site and JPGs for my photos? Should I make everything PNGs?
Exact Duplicate:
PNG vs. GIF vs. JPEG vs. SVG - When best to use?
Website Image Formats: Choosing the right format for the right task.
Which format for small website images? GIF or PNG?
PNG should be used when:
You need transparency (either 1-bit or alpha transparency)
Lossless compression will work well (such as for a chart or logo, or computer generated image)
JPEG should be used when:
Lossless compression will not work well (such as a photograph)
GIF should be when:
PNG is not available, such as on very old software or browsers
Animation is necessary
Despite myths to the contrary, PNG outperforms GIF in most aspects. PNG is capable of every image mode of GIF apart from animation, and when using the same image mode, PNG will have better compression due to its superior DEFLATE algorithm compared to LZW. PNG is also capable of additional modes that GIF cannot do, such as 24 bit color, and alpha transparency, but this is where you need to be careful: if you forget to convert to palette mode your PNG image may be saved in 24 bit color which will take more space.
PNG modes include (this is just a small subset)
Palette colour of 2 to 256 colors (like GIF)
Palette colour of 2 to 256 colors, with transparent color (like GIF)
True color (24 bit color)
True color with alpha channel (24 bit color + 8 bit alpha transparency)
For best compression in PNG for the web, use a palette mode. If you find PNG files are larger than the equivalent GIF files, then you're saving the PNG in 24 bit color and the GIF in palette mode (because a GIF is always in palette mode). Try converting to palette mode first.
PNG also has other modes such as palette color with alpha transparency. Modes such as this cannot be created in Photoshop, but other applications can create them.
Edit 2013: Removed a bunch of stuff about IE6 compatibility.
XKCD style comic strip that explains it:
http://lbrandy.com/blog/2008/10/my-first-and-last-webcomic/
Use JPG for photos and PNG for everything except photos. GIF is not really a very good format and PNG can replace it completely in compression and quality for most applications, but sometimes there are compatibility issues, not sure if these have been ironed out in all the current webbrowsers. GIF can be read by basically everything, so that's when it's very useful.
For buttons, icons, logos use PNG. Use GIF only if you need small animated images.
PNG can do all that GIF can (except animation, and even that is coming in APNG), and should almost always be smaller. If PNG isn't smaller than GIF, then your software may be saving it poorly - look for PNG optimisation progams, like PNGOUT and pngnq.
There are problems with GIF:
It only supports up to 256 colours.
It uses a patented compression algorithm.
But it does have an advantage:
It can be used to display an animation
JPEG can have a higher compression ratio than PNG/GIF but is lossy as the cartoon above demonstrates. It is best used for images where the compression artifacts aren't noticeable, photos for example.
Combining images into a texture and using CSS to unpack them will reduce the size slightly and reduce the number of server requests.
Depends on what you want to create. Typically, for your web graphics, go with PNG. For photos, JPG is fine. The 24-bit PNG supports alpha transpancy, so if you want to use "true color" alpha transparency that's your only option really. 8-bit PNGs are better and smaller than GIFs and also have pretty much the same transparency settings as GIF (an indexed color pallet) so there's no reason to use GIF anymore (unless you're making...gasp...animated gifs?). Remeber the the PNG format is lossless compression, so it will be nicer looking that a compressed JPG. One thing to keep in mind is that supporting PNGs in Internet Explorer 6 and below can be a pain, but there are many workarounds.
GIF - losless, small, but limited to 256 colors, and has one bit transparency (transparent or not)
JPEG - bigger, no small color limit, lossy. Best for photos.
PNG - losless, better transparency (alpha channel), but IE6 doesn't support alpha correctly, just with special fixes (fix here).
GIF is best for images with lots of solid colour - JPEG for images with lots of colour variance (EDIT: thanks, cletus). PNG is a newer format and often better than either JPEG of GIF - especially for screenshots.
See http://www.ou.edu/class/digitalmedia/articles/CompressionMethods_Gif_Jpeg_PNG.html
In general, jpeg is better suited for photos, while gif is better for graphic objects, like buttons or rendered letters.
png is good in both regards, but that discussion tends to get a little religious because there are license fees to pay if you develop a programm that reads/writes gif or jpeg, while png is free.
The difference is mainly in the compression, gif gets smaller file sizes for buttons, jpeg for photos.
My best advise is to play around with the different compression optioopns offered by all three formats and see for yourself which one you want to use for which purpose.
Oh, and because this is mainly about file sizes: See if you can test your homepage from a computer with a low bandwidth connection. That way you get a feeling if you need to worry about compression at all ;-)
Historically, GIF was here first, then JPG, then PNG.
GIF is very efficient for images with large areas of the same color (white background, for instance), because the RLL encoding compresses this well. However, GIF is patented technology (Unisys) and is seeing less and less use. Color depth is limited to 256 colors (I think).
JPG and PNG work well for most applications, but the files will be larger than GIF for very simple graphics. GIF can handle transparency and animations.
Edit: You are right - the patents expired on October 1, 2006.