Slashdot Mirror


Presenting APNG: Like MNG, Only Better

An anonymous reader writes "It's fair to say that most people love PNG images (or at least hate GIFs). However, the one advantage GIFs have over PNGs is that they can be animated. There is, of course, an animated version of PNG, MNG, but few programs can view these images (mainly because the MNG decoder is so large that the likes of Mozilla refuse to include it). But there may be an answer coming: Vladimir Vukicevic and Stuart 'Pavlov' Parmenter (of Mozilla fame) have put together a specification for APNG (Animated Portable Network Graphics)." (Read more below.)

"Unlike MNG, APNG is not a separate file format, but rather an extension to PNG. Thus, APNG images are just normal PNG images (with the .png extension) but can be animated. The system is fully backwards-compatable, so any program that can open a PNG image will be able to open an APNG image (though non-APNG viewers will only show the first frame). Vitally, the decoder just adds an extra few kilobytes onto a standard PNG decoder. APNG support is in the process of being checked into Mozilla. Hopefully, other programs will follow suit."

84 of 424 comments (clear)

  1. Too bad we can't use it by Anonymous Coward · · Score: 5, Funny

    IE won't support it until 2012, and even then, it'll only support half the features.

    1. Re:Too bad we can't use it by Daniel+Ellard · · Score: 4, Insightful
      IE won't support it until 2012...

      Sarcasm aside, this is a valid point. If IE doesn't support it, most authors won't use it on their web pages, and there aren't any IE updates scheduled any time soon...

      --
      Disclaimer: I work for a company, but I don't speak for them.
    2. Re:Too bad we can't use it by john_smith_45678 · · Score: 2, Funny

      and even then, it'll only support half the features

      You optimist ;P

    3. Re:Too bad we can't use it by josh3736 · · Score: 3, Informative
      Much like regular PNGs as it is.

      I hate the fact that when IE loads my PNGs with alpha it gives it an ugly solid bluish background. You have to hack it just to get my damned images to display correctly in IE. As a result, no one uses regular PNGs.

    4. Re:Too bad we can't use it by Ark42 · · Score: 4, Informative



      If you don't want to use the ugly IE5.5+ hack for alpha PNGs, you can at least set the background color setting in the PNG, which IE will use to blend into. I think you can set the background color tag from a pngcrush command line parameter if your software doesn't support that feature.

      For example alpha-msg.png should show a message written in magenta (the background color) if your browser blends using the background color of the PNG instead of the background color of the page. If your background color is white, you won't see any message if you are using Mozilla/Firefox/Opera. If you put that image in a div with a white background and use a IE5.5+ alpha hack of some sort, the image's message actually makes sense too.

    5. Re:Too bad we can't use it by rjch · · Score: 3, Interesting
      IE won't support it until 2012, and even then, it'll only support half the features.

      (sarcasm)You think it'll be that quick, do you?(/sarcasm)


      All jokes aside, I wouldn't be so sure of that. If FireFox and Mozilla make as much inroads into the browser market as some people think it will then Microsoft will either have to pull their finger out and keep IE up-to-date and standards-compliant or drop out of the market - something I seriously doubt will happen.


      FireFox is already a long way there. One department at work got so sick of the pop-up infested site they needed to use for some of their work that they demanded something be done about it. Our MIS deparment said nothing could be done until I suggested (and proofed) FireFox. Now it's a standard browser for that department and is being looked at for the rest of the organisation as well.

    6. Re:Too bad we can't use it by It'sYerMam · · Score: 2, Funny

      Never heard of ink and paper than? Naa, too bad.

      --
      im in ur .sig, writin ur memes.
    7. Re:Too bad we can't use it by dastrike · · Score: 2, Informative

      See for yourselves.

      IE supports the 1-bit transparency in 8-bit indexed PNGs. The problem with this transparency method is that it is the same way GIF uses transparency, which results in ugly jaggies in most cases.

      IE does not support the alpha-channel transparency in 32-bit RGBA PNGs without using the fugly proprietary CSS mess that invokes some DirectX stuff to make the transparency work.

      --
      while true; do eject; eject -t; done
  2. The burning question is... by whiteranger99x · · Score: 5, Insightful

    how soon will such functionality be implented in major graphic manipulation programs like Photoshop?

    Oh, and yeah, I'm sure someone will make it work with The Gimp, so don't flog me over that detail. :P

    --
    Join the TWIT army now!
  3. It's all about Microsoft by screwedcork · · Score: 4, Interesting

    Microsoft holds the power in their hands as to what file formats become standards. Hopefully they'll make the right decision...

  4. WIP by Mekabyte · · Score: 5, Informative

    Discussion can be found here: http://bugzilla.mozilla.org/show_bug.cgi?id=257263

  5. Don't hate it by andyrut · · Score: 4, Insightful

    It's fair to say that most people love PNG images (or at least hate GIFs).

    Now that Unisys's patent has expired across the globe, I certainly don't hate GIFs.

    1. Re:Don't hate it by Anonymous Coward · · Score: 4, Informative

      Why not? They're generally bigger than PNG, don't support 24-bit color, 8-bit transparency, etc.

    2. Re:Don't hate it by Ark42 · · Score: 3, Interesting


      I'll give you the transparency (which IE does not support on PNG without gross hacks) but GIF supports infinite colors basically, in increments of 256.
      gif-with-32697-colors

    3. Re:Don't hate it by bofkentucky · · Score: 4, Informative

      Can someone mod the parent down, PNG and Gif are both lossless (If you are talking about a 256 color (8 bit) palette.

      --
      09f911029d74e35bd84156c5635688c0
    4. Re:Don't hate it by X_Caffeine · · Score: 5, Interesting

      Why not? Alpha blending allows web developers to make fine adjustments to page layouts with necessitating the "recutting" of overlapping layers in Photoshop. It also allows for variance in browser layout without causing visible breaks -- thus Mozilla and KDE don't need to render "exactly" like MSIE down to the last pixel in order for layouts to basically look the same.

      GIF is gunk. Can we step into the 21st century yet?

      --
      // I will show you fear in a handful of jellybeans.
    5. Re:Don't hate it by damiam · · Score: 2, Insightful

      And that's not a "gross hack"? It takes eons to load and is 9 times the size of the equivilent PNG.

      --
      It's hard to be religious when certain people are never incinerated by bolts of lightning.
    6. Re:Don't hate it by david.given · · Score: 4, Interesting
      and btw, i never knew gifs could support more than 256 colors.

      It's a very neat trick. I remember marvelling at it the last time it came round.

      It works because each frame in an animated GIF has its own palette --- but that palette doesn't have to match the palette in the other frames. So the first frame draws the first 256 colours, then the second frame draws the next, etc. The test image has been slowed down so you can see it load.

      Of course, it's not actually useful --- the resulting image is far larger than, say, the PNG version --- but it's a clever hack anyway and I wish I'd thought of it...

    7. Re:Don't hate it by mgv · · Score: 5, Informative

      16,777,216 != infinity :-)

      Actually, there is no point getting an infinite number of colours because:

      1) Most displays cannot show that many colour
      2) Even with a display that does 16 777 216 colours, the human eye cannot distinguish between that many shades (particularly in the blue region) which is why 16 bit colour (which has 5 + 6 + 5 bits to divide amongst the red, green & blue) puts the extra information into the green (I think, could also be red, but its never the blue)

      3) Most RGB displays, while they have gradations finer than the eye can distinguish, cannot show the full spectrum in width (from 400nm to 700nm wavelengths). You can put as many bits as you want on to any consumer display, there are colours it simply cannot do.

      4) Humans vary in their ability to see colour, making alot of the finer gradations imprecise. 8% of males have altered colour vision - as do a small percentage of women and those bits are really wasted on them. On the other hand, if you have had cataract surgery, the implantable lens will let in low end ultraviolet (which your retina can see) that our natural lens does not allow through. Not that I'm suggesting that it is good to see into the UV range :)

      My 2c worth

      Michael

      --
      There is no cryptographic solution to the problem where the intended receiver and the attacker are the same entity.
    8. Re:Don't hate it by tyler_larson · · Score: 2, Insightful
      Why not? Alpha blending allows web developers to make fine adjustments to page layouts with necessitating the "recutting" of overlapping layers in Photoshop. It also allows for variance in browser layout without causing visible breaks -- thus Mozilla and KDE don't need to render "exactly" like MSIE down to the last pixel in order for layouts to basically look the same.

      Yes... now if only MSIE would correctly render alpha transparency in PNGs (without resorting to absurd coding tricks).

      --
      "With sufficient thrust, pigs fly just fine. However, this is not necessarily a good idea...."
      RFC 1925
    9. Re:Don't hate it by jericho4.0 · · Score: 2, Funny

      Your original posting? Oh! You're that Anonymous Coward character.

      --
      "A language that doesn't affect the way you think about programming, is not worth knowing" - Alan Perlis
    10. Re:Don't hate it by damiam · · Score: 4, Insightful

      The point is that it's not possible to do that in a GIF without animation, so anything >256 colors would have to be animated. I think it's fair to call that a hack.

      --
      It's hard to be religious when certain people are never incinerated by bolts of lightning.
    11. Re:Don't hate it by dustman · · Score: 2, Informative

      I was talking about the GIF format being lossy at >256 colors

      And, by talking this way, you are using the term "lossy" in a way that nobody else uses. Hence the confusion. Hence the request to use the word "lossy" to describe the actual compression of data, rather than the quantization of the image.

      If you compress a 256 color image using JPEG, what comes out isn't what you put in. That's why JPEG is called a lossy format. GIF is lossless.

    12. Re:Don't hate it by Myen · · Score: 2, Interesting

      It takes eons to load because it's an animated gif demonstrating the concept behind is (which is rather old):

      Each frame of the GIF can have up to 255 colours (+ transparent); but separate frames can have separate palettes. So frame #2 uses a different palette from frame #1, and so on. For real use, you can easily set the time interval between each frame to be zero (so they looks like it's done in one go).

      I remember seeing another image like this - I believe it was a picture of a ship of some sort - a few years back. It was actually neater, as it was loaded 'progressively' - it first presented a 8-bit version like a normal GIF, then overlaid extra colours on top. Certainly more interesting than this demo.

      It's bigger than PNG because it is limited to 8bits per pass - can't really look at how adjacent pixels have similiar (but not exactly matching) colours. Probably, anyway; I have not tried to dig deep into either GIF nor PNG :)

    13. Re:Don't hate it by Sparr0 · · Score: 3, Insightful

      you do realize that by dithering in anything other than an ordered fashion ruins your compression ratio right?

    14. Re:Don't hate it by Jah-Wren+Ryel · · Score: 4, Funny

      A more correct term is idempotent - take the output of a process (e.g. image compression), use it as the input for the next iteration of the exact same process and you will still get the exact same output. Repeat ad infintum. So, gif/png compression is idempotent. JPEG is not idempotent.

      Not to be confused with omnipotent which means the ability to get anything -- male, female, animate, inanimate -- pregnant. If you're omnipotent, the condom gets pregnant.

      --
      When information is power, privacy is freedom.
    15. Re:Don't hate it by Paul+d'Aoust · · Score: 2, Interesting

      Actually, from what I understand, we're least sensitive to variations in red. Which is very funny, because it's the colour our eyes are most sensitive to -- we just can't pick out subtle variations in that colour.

      I hope that makes sense? sensitive to red itself, but not to the differences in various shades of red.

      --
      Standing at the very edge of my imagination, I peered into the inky void and realised -- I couldn't think up a new sig.
    16. Re:Don't hate it by cookd · · Score: 2, Interesting

      Make the phosphors only excite one cone type each, and you can generate all the colors the eye can see.

      You are assuming that everybody's cones respond to the same wavelengths identically. That is most definitely not true. Different people's eyes respond to colors differently -- different people's cones have response curves centered at slightly different shades of red, green, and blue. In fact, some women have been found to have 4 different kinds of cones.

      There are two ways to produce a perception of color. One way is to create a beam of light of the correct wavelength. A light with a wavelength between red and green would stimulate both the red and the green cones in my eye, creating the sensation of yellow. Another way is to mix multiple beams of other wavelengths. A mixture of red and green lights would also stimulate the red and green cones in my eye, creating the same sensation.

      I could adjust two different beams of light (one pure yellow, one red + green) until they both appeared to me to be the same color. I would not be able to tell the difference between them. However, somebody else whose "red" cones centered on a slightly different wavelength of red would see the two beams of light to be slightly different colors.

      Monitor manufacturers actually can't make everybody happy. They do their best to pick the shades of red, blue, and green that are most commonly the centers of the response curves for people's cones. If they hit the centers dead-on for you, your monitor would be able to create any color that you could see. But if your centers weren't quite dead-on, or if you were a woman with 4 different types of cones, there would be a significant range of colors that the monitor could never produce properly for you.

      --
      Time flies like an arrow. Fruit flies like a banana.
    17. Re:Don't hate it by canavan · · Score: 4, Interesting

      the human eye cannot distinguish between that many shades (particularly in the blue region)

      While it may seem counterintuitive, the human eye is much better at discriminating between shades of blue than between red or green (where it is worst by far). There's a nice graph showing the MacAdam ellipses that represent the amount of variation in chromaticity where no difference can be percieved in this paper. This is obviously different from the responsiveness to brightness.

      16 bit color representaion usually has the 6 bits for green.

      For most people, 8 bit per RGB component on an linear scale, as used in almost all computers, is not enough - you can still see some banding. A logarithmic scale or 10 bit color can fix this.

  6. Animations by Seft · · Score: 5, Funny

    Haven't they realised that animated GIFs only serve to irritate?

  7. Good to hear by cyxxon · · Score: 5, Insightful

    Well now, this sounds really nice. I have always wondered why MGN never really took off, but then PNG never really took off either (you all know the MSFT story...). Just never knew this had a big-decoder-problem.

    So naturally I was disappointed when Mozilla took out MNG support back then, but this seems to make it better (read: more chances of survival in the real world out there) standard, and that is always a good thing.

    One more reason to finally get rid of all them GIFs, even if they are no longer patent-encumbered - the format is still not capable of alpha transparency...

    1. Re:Good to hear by bluephone · · Score: 4, Insightful

      Pretend "APNG" is spelled "GIF04" and your solution is here. No, it wouldn't be easier, because your suggestion is essentially creating a new format (been done) and just CALLING it a new GIF format.

      --
      jX [ Make everything as simple as possible, but no simpler. - Einstein ]
  8. We don't like bloat now do we by Rosco+P.+Coltrane · · Score: 5, Funny

    the MNG decoder is so large that the likes of Mozilla refuse to include it

    Yeah, and a damn good thing too, otherwise we'd have a browser that's so huge and bloated that...

    Nevermind...

    --
    "A door is what a dog is perpetually on the wrong side of" - Ogden Nash
  9. What is the greater of two evils... by nerd256 · · Score: 3, Funny

    ...no alternative to animated gifs or no IP fines for annoying dancing lemmings and flashing "under construction" pictures?

    ?$!@...@!$?

  10. Stupid Question by slyckshoes · · Score: 5, Interesting

    This is probably a stupid question, but what are animated gifs used for besides online ads? It seems to me that the animated gif is now an endangered animal found only in annoying online ads, or annoying web-pages that were put together by someone with a rudimentary knowledge of HTML and a free CD of clip-art (or images that they stole from another unattractive site). I would not be sad to see animated gifs (or apngs) disappear entirely. If someone can post a good use of apgns/gifs for which a better solution does not exist, I will humbly retract my opinion and we can all consider this to be have been, indeed, a stupid question.

    1. Re:Stupid Question by Ark42 · · Score: 3, Interesting

      http://sirocco.accuweather.com/nxssa_r1_h_500x620d /r1h/inxr1kgrra_h.gif

      This is better then any alternative java or javascript crap I have seen.

    2. Re:Stupid Question by carambola5 · · Score: 4, Informative

      Weather radar loops. Rather than have the client dl multiple jpegs and sequence them with javascript (eww, javascript), the client need only download a single apng.

      For an example, check out weather.com's "map in motion" for your locale. Then, check the source of the page. Much cleaner to simply have an <img> tag.

      --
      IWARS.
      People, in general, disappoint me. Politicians even more so.
    3. Re:Stupid Question by Anonymous Coward · · Score: 2, Funny

      That's great and all, but what about those of us who don't live in Michigan? I mean, we need a file format we can use for our weather, too.

    4. Re:Stupid Question by grm_wnr · · Score: 2, Interesting

      Actually, an animated .gif is the only animation format you can just put into an tag. That makes a huge difference if you are working with systems that don't allow you to write plain HTML. Web forums, for example. Or picture upload sites. And many people think animations are great, even if some don't like them at all. So the need for animated .gifs is there - and right now, there is no alternative.

    5. Re:Stupid Question by stienman · · Score: 3, Informative

      It's great for simple process visualizations.

      Check out uncommon or odd designs for engines, which would be very difficult to imagine from a text description with a few small pictures.

      There are others - google search animated gif "subject" to find useful illustrations for any process.

      -Adam

    6. Re:Stupid Question by epine · · Score: 3, Insightful


      That's not a stupid question at all. If Firefox had a setting (that I knew about) to disable all animation effects by default, I'd enable that feature immediately. More than 90% of animated content out there is crap or worse than crap. 100% of animated effects reduce my reading speed and comprehension. I've asked other people about this, and I seem to suffer this effect more than most people, to the extent that I often set my Firefox font size for inch tall letters so that the majority of the text spills below the aggravating imagery. Sometimes if I can't get the animation away from the text I'm readin, I actually hold one hand over the screen to block out the offending flicker. The few people I know who find this similarly annoying tend to be the exceptional readers. One of my close friends claims he sees every word on the printed page (for book reading) simultaneously, and he moves his eyes back and forth mostly for the purpose of getting the words into proper order for mental comprehension. But he usually knows what the author will claim before he gets there, because he knows what words are coming at the bottom of the page.

      For me, there is no "experience" involved in visiting a web page. I go there to suck out the content. I had a jazz musician friend in Montreal who said that he didn't much care if an LP had a gouge the size of the grand canyon, if the performance had "wit" he didn't even hear the clicks and pops. I feel the same way about text. All I'm there to do is discover whether the author has a moment of wit or substance.

      What I've learned about reading, serious reading where the aim is not to hear your own thoughts expressed by another person (or believe such), but to encounter thoughts that clash and spark and scrape the paint, to accomplish this the reader must open an expressway of comprehension that bypasses the internal thought police, the slow border crossings with open trunks and snuffling dogs. It seems to me that people who read at the pace of their own internal mind police do not experience the same distress I feel about the visual flickers of animated content: it's only slowing their visual processing down to the same speed their emotional filters were functioning in the first place.

      My reading style is that I'm a kind of ambulance chaser: I want the content to strike the rock bottom content of my soul in massive wreckage, trailing ambulances, autopsies, coroner's reports, and sprawling cemeteries full of petty self justifications, RIP.

      APNG I can live without.

    7. Re:Stupid Question by iabervon · · Score: 4, Informative

      Go to about:config, find image.animation_mode, and set it to "no". I actually set mine to "once", which means that I see animated images if I'm actually watching; I generally iconify the browser and do something else while pages load, so I miss all the ads, but I can actually watch a weather image if I want. As far as I can tell, there's no documentation for this anywhere.

    8. Re:Stupid Question by Saeger · · Score: 2, Interesting
      Rather than have the client dl multiple jpegs and sequence them with javascript

      You don't have to use javascript to sequence jpegs for an animation effect. You can instead stream a recorded or live "jpeg video" by using the 'multipart/x-mixed-replace; boundary=xxxfoobarxxx' mime-type with a frame delay between the boundary. The downside is that you need to keep a persistant connection open to the webserver for the duration of the vid.

      This isn't commonly done anymore, but it is how the first postage-stamp-sized live streaming (pr0n) video was done before the real codecs and players got critical mass. (I should know, I wrote such an "advanced streaming server" back in the 90's.)

      --

      --
      Power to the Peaceful
    9. Re:Stupid Question by Smack · · Score: 2, Insightful

      That engine page is actually way more interesting than this slashdot article.

    10. Re:Stupid Question by FyRE666 · · Score: 2, Informative

      [x-mixed-replace]
      This isn't commonly done anymore...

      Probably the biggest reason being that IE on Windows doesn't support it (surprise, surprise)...

  11. LZW? by Anonymous Coward · · Score: 2, Insightful

    well now that the lempel-ziv-welch algorithm patent has expired, maybe they should look into whether or not this algorithm could be used for a better *PNG format.

  12. Hate gif? by scheme · · Score: 2, Insightful
    It's fair to say that most people love PNG images (or at least hate GIFs).

    Most people don't know what png images are and they probably couldn't care less whether they get png or gif images.

    --
    "When you sit with a nice girl for two hours, it seems like two minutes. When you sit on a hot stove for two minutes, it
  13. Size? by Anonymous Coward · · Score: 3, Funny

    ...(mainly because the MNG decoder is so large that the likes of Mozilla refuse to include it)

    So large that even Mozilla won't include it, you say?

    Uh huh.

    Ooookay...

    *eyes >10MB binary while whistling*

  14. Love PNG and hate GIF? Most people? by Anonymous Coward · · Score: 3, Insightful
    most people love PNG images (or at least hate GIFs)

    Uh, no. Most people have no freakin' clue about what PNG and GIF are. Only we geeks know or care about the difference.

    And speaking as a fellow geek, if you're feeling emotions like "love" and "hate" over freakin' image formats you really need to get out of the house more often.

  15. Define "better solution" by Jonathan · · Score: 4, Insightful

    Java? Flash? I've seen lots of animated gifs in educational contexts -- showing how changing parameters affects a curve, for example. Yes, Java and Flash can be used, although they tend to be sluggish to load and crash browsers not infrequently,

  16. Re:MNG is being checked out of Firefox by CRCulver · · Score: 4, Informative

    MNG is being discontinued, as are a lot of features including the Javascript Console. "Bloat", they calls it.

    Not to worry, though. Nearly everything that is taken out of the Firefox core can be reimplemented as an extension. I know I've been loving my Mozilla Calendar, and Web Developer extensions. There's no reason that the Javascript Console can't just become a plugin.

  17. 90%+ Market share... by rmdir+-r+* · · Score: 3, Insightful

    Y'all are missing something. The browser market is dominated by IE, and, if I remember correctly, IE doesn't even support non-animated PNG's perfectly. What are the chances that APNG gets added? And if it doesn't get added, what web designer will use a format that can't be viewed by 93% of their users? I'm not trolling, I'm not dissing Moz, but the reality of the market is there...

  18. animated? by carpe_noctem · · Score: 4, Funny

    However, the one advantage GIFs have over PNGs is that they can be animated.

    Surely I am not the only one here to disagree with this statement.... !

    --
    "Quoting famous computer scientists out of context is the root of all evil (or at least most of it) in programming." - K
  19. Bad "most people" generalization by enosys · · Score: 4, Insightful

    The story begins with: "It's fair to say that most people love PNG images (or at least hate GIFs)." No, it's not fair to say that; it's wrong. Most computer users don't even know the difference and don't care as long as they can see the image. Most people don't know about the GIF patent issues and anyways GIF is now free. Plus why hate a file format? If you really want to hate something then hate what Unisys did.

  20. Why I don't use PNG by pez · · Score: 4, Insightful

    Web developer has been my full-time job since 1995, and I have tried *so many times* to switch to PNG. And every single time, I slowly (and unfortunately) end up reverting back to GIF.

    The two reasons that PNGs are unsuitable for large-scale use are:

    * MSIE support sucks. It is getting better, but it still sucks (yes, I know this is a Microsoft issue not a PNG issue, but I'm not trying to place blame here.)

    * Gamma value variation. Look at a PNG on one browser, and the blue value will match #0000CC, but look in another browser on another OS, and IT WON'T! Talk about maddening... this is one situation where the extra control by having the ability to specify a gamma value is a curse, not a blessing.

    Yes, I know there are workarounds for both of thses issues. But the fact that they are both fatal flaws, and both have to be worked around, makes PNGs unusable for every-day use.

    1. Re:Why I don't use PNG by jesser · · Score: 4, Insightful

      MSIE support sucks. It is getting better, but it still sucks

      I don't see how MSIE's lack of alpha-transparency could stop you from using PNGs, since you use GIFs now.

      --
      The shareholder is always right.
    2. Re:Why I don't use PNG by typhoonius · · Score: 4, Informative

      * MSIE support sucks. It is getting better, but it still sucks (yes, I know this is a Microsoft issue not a PNG issue, but I'm not trying to place blame here.)

      The only PNG features IE doesn't support are 8-bit transparency and animation.

      Obviously, GIFs don't give you a full alpha channel either, so the first feature is moot. IE supports 1-bit transparency in PNGs, which puts them on par with GIFs.

      PNG animation is a mess (when Mozilla leaves MNG support out because it's too bloated, you know something's wrong), but that a problem APNG hopes to solve. Remember that IE is being worked on again, so who knows? It has a chance of being implemented (certainly moreso than MNG does, anyway).

      * Gamma value variation. Look at a PNG on one browser, and the blue value will match #0000CC, but look in another browser on another OS, and IT WON'T! Talk about maddening... this is one situation where the extra control by having the ability to specify a gamma value is a curse, not a blessing.

      PNGCrush and PNGOut both get rid of the gamma value. You should run all your PNGs through one of those programs anyway to get the smallest file size, so it's a minor issue. Otherwise, get rid of it manually with TweakPNG.

      It sounds like a lot of work to process a single image, but spending time shrinking download time is something web designers have been doing for over a decade (although I know a lot of people are lazy in the broadband age; it really isn't much more work, though, once you get into the habit of doing it and write some scripts to automate most of it, and it's worth it for the smaller file sizes and the 24-bit color).

    3. Re:Why I don't use PNG by david.given · · Score: 4, Interesting
      The same can't be said for PNGs without verifying each of them by hand. That's the fatal flaw to which I speak -- it's just too damned hard to use them for the types of images they're supposed to be used for.

      The only thing I can think of is that the software you're using to save your PNG files must be horribly broken. It should be giving you the option to save the gamma value or not --- for what you want, you want not. The Gimp has a whole dialogue it pops up whenever you save a PNG file asking you what extra information you want to save; resolution, creation date, gamma, etc.

      To remove the gamma chunk from someone else's files, try this:

      sng $1
      grep -v gAMA $1 > gammaless-$1
      sng gammaless-$1

      ...although if you've been converting them to GIFs, you've probably been editing them.

  21. Why doesn't Mozilla include the MNG decoder? by Anonymous Coward · · Score: 2, Insightful

    The article says it's because it's too big, but that's hard to believe, coming from the Mozilla camp. Does anyone have more details? I've been wondering for a while why this hasn't shown up in any of the free browsers. Also, I wonder how SVG relates to APNG. SVG seems like a great format for distributing scalable and moving things, although it's not a bitmap format.

  22. A bit OT by Enrico+Pulatzo · · Score: 3, Insightful

    First off, I know all about the drama surrounding IE's PNG support. Secondly, I think those that gripe about it to Microsoft pretty much gripe in vain (at least for now). Thirdly, at least on my work computer, IE uses Quicktime to render PNG files. This leads me to conclude that we, the concerned few should ask Apple to make Quicktime for Windows support PNG's alpha channels. As we do this, we can ask Apple to add support for this APNG format too.

    1. Re:A bit OT by Enrico+Pulatzo · · Score: 2, Interesting

      That makes little sense, as the DirectX filters are usable on Windows NT. The filters came out with IE 5.5. This means that the alpha-blending group must either suffered political pressure, or were just overlooking this solution when it came to real support in IE 5.5. They could (probably) easily switched the PNG handler to DirectX rather than whatever it is now without the end user really noticing or caring.

      That being said, I'd like to hear their excuse for not supporint <object> properly ;)

  23. Two Uses of Flash by GeekDork · · Score: 4, Informative

    There are only two valid reasons to include Flash in a web document: sound (for which there should be a global setting in the Flash plugin) and stick fights (SVG anyone?). Everything else does nothing but reduce useability and accessibility. The absolute kicker are flash intros with the skip button embedded instead of a normal link.

    And: what do you need flash or MNG/APNG for if all you want is a red/green-annoyance? To make really good fakes of Luna GUI elements?

    --

    Fight hunger. Filet a politician and send him to a 3rd world country of your choice.

  24. They'll develop a DRM encumbered one.. by cbreaker · · Score: 4, Insightful

    They'll probably come out with the "WMG" format which you will have to pay for a license to sign your own images. Users that visit your site will contact a Microsoft server and ask if it's okay to decode the images. Only IE will work with this system.

    The official press release would be something like "We feel that this new open (to IE) format will provide the much needed protection against web site theft and give necessary control to Microsoft over your own content."

    Would it surprise you?

    --
    - It's not the Macs I hate. It's Digg users. -
  25. MNG as a format by Anonymous Coward · · Score: 4, Interesting

    MNG is as far as I can see the _only_ format suitable for an Amiga-DPaint-workalike in this day and age (no good one exists today except for the astronimically-priced Windows TVPaint/Mirage, and that is a direct descendant of Amiga TVPaint).

    APNG looks too lightweight, missing many features necessary to replace the ancient (but still in use!) Amiga-IFF-ANIM. Sure, it's a replacement for shitty animgifs. But can it replace the Amiga-IFF-ANIM7 roughs for a feature-length cartoon?

    Yes, much of the industry now uses vector animation (i.e. macromedia's stuff), but bitmapped animations are much easier to seamlessly integrate with bitmapped digitised film. Want a(nother) open source killer app? Take the cinepaint/gimp engine, add a dpaint-like interface and MNG support and lots of bitmap-animation-creation-and-editing features, and several animation companies I know can finally lose their old big-box Amiga stockpiles...

    1. Re:MNG as a format by sppavlov · · Score: 2, Informative

      We were only aiming to replace animated GIFs. MNG does have some interesting properties which may make it more useful for things like this, however it has been my experiance talking to web developers that the thing they really want is a small fast easy to use animated GIF replacement.

  26. Microsoft Extended Sequential Series by slashname3 · · Score: 5, Funny

    Microsoft recognizes that a new animated image format was needed (after seeing it mentioned on /.). As such they have announced the release of a new standard, Microsoft Extended Sequential Series (MESS).

    MESS will be incorporated into Longhorn and will be one of the major enhancements to the Microsoft operating system. The MESS graphics format will permit content providers to render highly complex images on a users system. The MESS format allows use of Active X components which permits all kinds of interesting effects on a users system.

    When asked about using existing standards executives at Microsoft responded that no other standard in this area exists. Patents have been applied for covering this novel concept and will be agressively defended. Anyone trying to duplicate the intelectual property of Microsoft would be better off using MESS as long as they pay the royalties due Microsoft or they may find them selves in an even bigger MESS.

    Executives were then asked about possible security implications of the new MESS protocol. Executives replied that security is a number one priority and that an updated SP3 patch is currently in the works that will address all security issues. The only thing holding up SP3 release is final release of SP2 patch 1 that is needed to address security issues caused by various linux distributions.

  27. Re:Need help by gujo-odori · · Score: 2, Informative

    You're probably trolling, but just in case you're really that stupid...

    Read the first half of what you wrote: 1 kg = 2.2 lbs.

    Now, quick, what is 1 x 2.2? Could it... 2.2?

    I hope this isn't too complicated, but let's go on to a more advanced example.

    If 1 kg = 2.2 pounds, then 2 kg (and you can verify this with a scale if you can't do simple arithmetic) must weigh 4.4 pounds. And by some odd coincidence, 2 x 2.2 = 4.4.

    Now, if you were to divide 1 by 2.2, you would get app. 0.45, which doesn't fit very well into the idea that to convert kilograms to pounds, you divide the kilogram figure by 2.2, since 1 kg most certainly does not equally app. 0.45 lbs.

    What, indeed, is the world coming to when people (pick one):

    A) Really can't do simple arithmetic anymore;
    B) Can't troll any better than claiming you divide kilograms by 2.2 to get pounds.

  28. Header size by maxence · · Score: 4, Informative
    the one advantage GIFs have over PNGs is that they can be animated

    Another advantage GIF has over PNG is its smaller header size which makes small images lighter. A typical 16x16 GIF icon weighing about 100 bytes will translate into a PNG of 200 bytes or more.

    That may sound like nitpicking but it can still matter, for example when transferring images to mobile phones.

    1. Re:Header size by Anonymous Coward · · Score: 5, Informative
      You're exaggerating a little, I think.

      Experiment #1: 1x1 white pixel. Results: GIF 35 bytes; PNG 67 bytes.

      Experiment #2: typical Slashdot icon resized to 16x16. Results: GIF 282 bytes; PNG 277 bytes.

      I don't see the header size making a huge difference. What does make a moderate difference is that PNG is not bound to 256 colours. You can use a 16-colour palette, in which case pixels are packed in 4 bits each. You can use a 4-colour palette, in which case pixels are packed in 2 bits each. Pixels can be of many different depths between 1 bit and 48 bits. GIF does not have this flexibility.

      This is important because icons very rarely use more than 16 colours. PNG gives a win in these cases.

    2. Re:Header size by Anonymous Coward · · Score: 3, Informative
      What does make a moderate difference is that PNG is not bound to 256 colours. You can use a 16-colour palette, in which case pixels are packed in 4 bits each. You can use a 4-colour palette, in which case pixels are packed in 2 bits each. Pixels can be of many different depths between 1 bit and 48 bits. GIF does not have this flexibility.

      Just FYI, GIFs can have 4-color or 16-color palettes.

  29. Why wasn't animation included in the first place? by erroneus · · Score: 3, Interesting

    The whole reason for PNG's creation was as a response to the potential doom spelled by the enforcement of GIF patents and of course they took the opportunity to improve on the limitations of GIF as well... but was back in the day, in the very beginning, I assumed that the PNG specification would include animation as part of PNG's purpose.

    I think the best answer here would be to enhance the existing PNG specification just as GIF's original specification was enhanced to include animation. Let's not call it "*.APNG" or "*.MNG" for that matter. It should still be called *".PNG" just as *.GIF always remained.

    I think it would be a mistake to add to the ever-increasing number of filename extensions that exist out there. Isn't this convention a part of DOS and CP/M's legacy anyway? Filename extensions are handy information to append but only to a point.

  30. Both your reasons suck by UnConeD · · Score: 3, Informative

    Your two problems are easy to get around.

    1) IE does support transparent PNG, you just need a CSS hack for it. There are tons of scripts around the web to include the hack automatically, one of which is the 'IE7' DHTML behaviour which fixes a lot more than just PNG transparency, and which anyone who wants to do modern webdesign (semantic and tableless) should consider.

    2) If you simply omit the gAMA chunk from your PNGs (pngcrush can do this easily, plus you get tiny PNGs to boot), then the gamma issues will be gone for 99.99% of the browsers. The only ones that will mess up are an outdated version of Opera, a pre-1.0 mozilla on Mac OS, and (unfortunately) Safari on Mac OS X. But Safari is still under development. You can assume that people who use it are keeping it up to date.

    You don't include any gamma information with the rest of your colors (CSS), so it makes sense not to have any in your PNGs either.

  31. Re:Love PNG and hate GIF? Most people? by typobox43 · · Score: 3, Funny

    I refuse to consider you a fellow geek if you suggest getting out of the house.

  32. On talking about the format by inflex · · Score: 3, Informative

    I just took a look at the 'specification' and I think it's a great one.

    It's not overly complex, it's backwards compatible and it's easy to implement.

    It probably will lack some features which would be nice but at the moment I don't see them being spoken about in the specification (ie, what mode of application for the next frame, OR/AND/XOR/INVERT etc).

    I think with it being as simple as it is to create an APNG from existing PNG's, we could see this format take off a lot faster than MNG. Now it's simply a matter of waiting for Firefox/Mozilla/Opera to pick up their end and make use of the APNG format.

    PLD.

    1. Re:On talking about the format by sppavlov · · Score: 3, Informative

      Vlad and I are currently looking at adding composite operators as well as disposal methods such as those in GIF. They should be in the spec by 1.0.

  33. Re:Give me animated JPEG, its easy as piss to code by sppavlov · · Score: 2, Informative

    The standard way to animated JPEGs in the past has always been using server push (multipart/x-mixed-replace). Mozilla does support this. A lot of webcam sites use this.

  34. Re:Why wasn't animation included in the first plac by sppavlov · · Score: 5, Informative

    APNG files _are_ PNG files. We didn't create a whole new format (since that would be silly) so APNG files will still be .PNG files. The first frame in an APNG file looks to current PNG decoders to just be a regular PNG. The APNG spec specifies some additional chunks that if found tell an APNG aware decoder how to find the rest of the frames.

  35. Re:Why wasn't animation included in the first plac by argent · · Score: 2, Informative

    Several people tried to get animation in the original PNG standard, but they were rebuffed because it would take too long. Most of the energy that could have gone to getting a simple animation mechanism out was spent on generating really cool interlacing so that when you downloaded PNGs over your 9600 baud dial-up they'd fade in nicely.

    I admit that I thought the interlacing was kind of cool myself: I had a 9600 baud dial-up at the time.

    I lost interest in the process and left the PNG list after the MNG group was split off. I wanted a format that just let you place PNG images over the background at a given X, Y, and T, and re-use tagged images to make cartoony animations easier. It wasn't nearly as simple as APNG but I don't think it was excessively complex.

  36. summary by Anonymous Coward · · Score: 2, Informative
    http://bugzilla.mozilla.org/show_bug.cgi?id=18574: (emphasis added by me)

    ------- Additional Comment #474 From Mike Connor 2004-07-04 09:25 PDT [reply] -------

    reasons why this isn't going to block aviary 1.0 (again, posting to prevent more advocacy posting. If you want to debate this with me, feel free to email)

    a) the code isn't ready, per the owner of the bug and the person responsible for getting things to a point where it can be added back into CVS. We're on way too short of a timeline to take major last minute code.

    b) no one working on Firefox/Thunderbird really wants this at this point (speaking as one of the people heavily involved in Firefox). Thunderbird stopped building with MNG before CVS removal took place. Firebird was probably going to do the same, but CVS removal came first. Its not something that'll likely change going forward, unless MNG support is really low cost (i.e. not 200-300k). At 50-80k the case becomes stronger, of course. The "if you support it, they will come" argument is weak, since we did support this for three years and the content didn't come.

    c) Content that 90% of the web doesn't support isn't going to get created in any substantive way. MNG has the advantage of being more ideologically pure than Flash etc, but if people aren't using it, its cruft, and that's the reality. Given the choice, we'd be much better off bundling Flash with Firefox based on the "size vs. usability boost" equation. I realize lots of people don't like Flash for a myriad of reasons, but users don't care.

  37. Re:An unfortunate hack by vukicevic · · Score: 3, Informative

    It doesn't break such code -- if that code is expecting png datastreams one after the other, then it won't find a PNG header after the first one. The "bunch of user chunks" after the IEND are simply an entire PNG, minus the 8-byte PNG header, hardly random chunks. Finally, EOF is mentioned nowhere -- the number of frames that are expected to follow is clearly specified as part of the anIm chunk; EOF before this would be an error/incomplete data condition, and nothing more.

  38. Rather Pointless... by evilviper · · Score: 2, Informative

    I was quite interested in using MNG... Not for web images, but actually as a rather good lossless video codec. MNG would make a great codec, and it's already supported by Ogg... You can mux a MNG image into an ogg file (with audio) using oggmerge, available via cvs...err...I mean svn.

    Unfortunately, it seems that there is almost no MNG software available that supports delta encoding (eg. storing only the difference between sequential images), so if you take (10) 100K PNGs, you get a 1,000K MNG. No space savings, no point really. That is where MNG really falls behind GIF.

    It seems mostly pointless, to me, to introduce a new, very similar spec. Backwards compatibily is nice, but not all that necessary, as evidenced by PNG in the first place. In any case, APNG certainly can work where MNG failed, if only good software comes out for it. It's more likely that MNG will get properly advanced software first, but you never can tell.

    As for MNG not being in Mozilla, well that is a strange issue... libMNG supports PNG rendering, so if there were more than a nominal number of MNGs on the web, you might have seen libPNG removed instead. However, since you don't see many MNGs, there wasn't much point to keeping it.

    --
    Slashdot gets worse every day... Pipedot: News for nerds, without the corporate slant
  39. Animated JPEGs? by Air-conditioned+cowh · · Score: 2, Informative

    Anyone thought of this? Often animated gifs are used to animate photos. This is probably not the best way to do it and APNG won't help unless it supports some kind of lossy compression.

    Is it possible to implement little motion-JPEGs in a browser without it adding too much code?

    Just asking.

  40. Re:An unfortunate hack by sppavlov · · Score: 4, Informative

    We are changing the format of APNG so that all the frames live inside of a single IHDR/END. This should resolve any problems you might have. v0.3 of the spec (should be out tomorrow) will have these changes.

  41. Re:What I'd like first by vadim_t · · Score: 2, Insightful

    Because JPG is completely inappropiate for screenshots, that's why.

    JPG deals *very* badly with straight lines and black/white transitions, both of which are really common in screenshots, like interface elements and black text on a white background. 500KB screenshots mostly happen because people take a screenshot of their background image.