22 ms·
It's time to replace GIFs with AV1 video
- simlevesque 7y agoThe article claims that AV1 works since FF 65 but the examples do not work on FF 66.
- dwheeler 7y agoConfirm, doesn't work for me on FF on Windows. And this is a challenge for a "new" format: if AV1 works on 90% of systems, and GIF works on 100%, then in many cases GIF is the clearly correct solution. Why would I throw away 10% of my money? Why would I ignore 10% of my customers? In many businesses, just a few customer calls because of this could seriously hurt profitability.
- sp332 7y agoThe article shows how to make a fallback that serves GIF in cases where AV1 is not supported. That saves you 90% of your bandwidth for 90% of your image loads.
- milansuk 7y agoI'm running Chromium 73 on Debian 9 and AV1 examples also don't work. edit: I've downloaded first example[1] and video player won't play it neither. edit2: Firefox 66 works! [1] https://www.singhkays.com/blog/its-time-replace-gifs-with-av1-video/media/scene1/av1_200k.mp4 https://www.singhkays.com/blog/its-time-replace-gifs-with-av...
- aidenn0 7y agoCan also confirm does not work on firefox 66 for me; chromium does work though.
- deleted 7y ago[deleted]
- sp332 7y ago64-bit Windows users only, according to the release notes. https://www.mozilla.org/en-US/firefox/65.0/releasenotes/ https://www.mozilla.org/en-US/firefox/65.0/releasenotes/ Edit: as ataylor pointed out, Mac support was added in 66.0 https://www.mozilla.org/en-US/firefox/66.0/releasenotes/ https://www.mozilla.org/en-US/firefox/66.0/releasenotes/
- ataylor32 7y agoAre you on Linux? https://caniuse.com/#feat=av1 https://caniuse.com/#feat=av1 says that FF 66 has it enabled by default only for Windows and macOS users.
- nacs 7y agoI'm on Firefox 66 on Mac and the last couple AV1 videos don't play.
- matthberg 7y agoOdd, it's working for me: Firefox 66.0.5 (64-bit) on Windows 10
- vortico 7y agoSet `media.av1.enabled` to true in about:config.
- skosch 7y agoThat worked for me on Linux FF 66. Thank you.
- xmichael999 7y agoThier claims about encoding working in ffmpeg are also untrue..
- singhkays 7y agoAuthor here: Can you clarify this?
- leshokunin 7y agoI'd love to AV1 to become the standard, but as far as I've seen, it's just not implemented anywhere, and the spec wasn't 100% final. I was messing with ffmpeg a couple months ago, and it didn't look like a straightforward option to convert either. I'd say it's not quite time we replace GIFs with it.
- vortico 7y agolibaom support in ffmpeg is still experimental. ffmpeg -i input.mp4 -c:v libaom-av1 -strict experimental out.webm Encoding on the CPU is less than 1fps now. rav1e is a bit faster. Hardware encoder support might be available on CPUs in 2020.
- xmichael999 7y agoYah rav1e is a bit faster, only a few weeks ago I tried to transcode large test movie was around 8 gbps of h264. I was using a big 20 core e5 and was doing almost 1/2 a frame per second. I seem to recall working out the estimated time to encode to AV1 was about 3 weeks...
- clouddrover 7y agoUse Intel's AV1 encoder for more speed: https://www.phoronix.com/scan.php?page=news_item&px=SVT-AV1-Ending-April-High https://www.phoronix.com/scan.php?page=news_item&px=SVT-AV1-... https://github.com/OpenVisualCloud/SVT-AV1 https://github.com/OpenVisualCloud/SVT-AV1
- xmichael999 7y agoThanks, it compiling this was a bit of a pain but I got it and do see some performance increase but wow slow. Still though, I know this is outside the scope of the article but I don't see AV1 catching on anytime soon and I half laugh to point out that 2027 when h264's patents expire isn't that far out! Everyone talks about hardware encoding options for h264 being available, let's not forget how crappy the output from h264 hardware encoding is compared to software encoding.
- davidcollantes 7y agoIt seems VP9 and AV1 do not play on macOS Safari.
- vortico 7y agoThat is correct. Safari supports neither of these.
- ihuman 7y agoSafari recently added VP8 support for WebRTC, so hopefully they also support VP9 in the future. https://webkit.org/blog/8672/on-the-road-to-webrtc-1-0-including-vp8/ https://webkit.org/blog/8672/on-the-road-to-webrtc-1-0-inclu...
- aidenn0 7y agoWhy no h265? I suspect it's similar to VP9 in quality, but h264 is pretty old at this point (nowhere near as old as GIFs of course).
- wlesieutre 7y agoH264 has the advantage of very widespread decoding hardware. H265 is getting there, but in the meantime you'd be killing a lot of batteries with software decoding. This page claims 78% supported on iOS and 57% on Android as of last August: https://www.scientiamobile.com/growing-support-of-hevc-or-h-265-video-on-mobile-devices/ https://www.scientiamobile.com/growing-support-of-hevc-or-h-...
- degenerate 7y agoI believe the big issue with h265 was the huge licensing cost to bundle the decoder in the browser.
- singhkays 7y agoCorrect and also lackluster browser support https://caniuse.com/#feat=hevc https://caniuse.com/#feat=hevc I've added a note to the article
- singhkays 7y agoBecause of lackluster browser support https://caniuse.com/#feat=hevc https://caniuse.com/#feat=hevc I've added a note to the article
- aidenn0 7y agoThanks!
- ksec 7y agoBecause Google Refuse to pay a single dollar for HEVC, even on their Pixel Phones. So there will likely never be HEVC on Google related properties, that is from Chrome, Android, to Youtube.
- silversconfused 7y agoThe code shows the first three video formats being available and prioritized before gif, but the sample videos do not include gifs. It'd be nice to see the quality difference between the format that is being discouraged and the format being encouraged. Personally, I love gifs. They work with no fuss.
- farisjarrah 7y agoI like GIFs too, they do indeed work well on all platforms. But I agree with OP, in that we should be switching over to more sustainable standards. Think about the energy savings we could get across the web if even 25% of GIFs were converted to newer and more efficient formats.
- silversconfused 7y agoI have no problem being fed the fad of the month codec, as long as a reliable fallback is available.
- HeWhoLurksLate 7y agoHold up, we have those for codec's now? Gee, what's next? Linux distro flavors?
- vortico 7y agoAt similar bitrates, they would be barely disinguishable visual garbage. At similar visual qualities, they'd be 10-20x filesize. It would be useful for the author to make this point by example though.
- acdha 7y agoGIFs work with no fuss only for small file sizes. Once you get over a fairly low threshold the size differences have an enormous impact both for network performance — like a GIF takes tens of seconds longer to start — or CPU load because all common browsers even on low-end phones have hardware video decoding but have decode GIFs on the CPU. Since people increasingly use them for video clips I encounter that more than I would have expected 10 years ago.
- nightfly 7y agoCalling AV1 something that looks almost exactly like AVI seems like a mistake...
- joaomacp 7y agoFWIW, I never noticed the connection until now. I guess AVI has been 'gone' for too long, and it's not in most people's minds anymore.
- mkl 7y agoThe naming is a bit annoying, but they are completely different kinds of thing: AVI is a container format (which can contain a variety of different codecs, e.g. mpeg-4), and AV1 is a codec (which can be put in a variety of different container formats, e.g. mp4). We don't seem to get confused between mpeg-4 and mp4, which have the same kind of similarity.
- gardaani 7y agoIt'll be fixed when AV2 comes out..
- EliRivers 7y agoGIFs take up a massive amount of space (often multiple megabytes!) and if you’re a web developer, then that’s completely against your ethos! Judging by most websites I comes across, this must be referring to some other universe.
- silversconfused 7y agoThey usually just blame marketing and wash their hands of the finished product.
- antirez 7y agoGIFs are still here because people make art with it, in some form. This is how we got still GIFs around, not because we needed to transfer videos. The idea of replacing everything based on technical superiority is extremely shortsighted. We need more humanists in computing.
- tdb7893 7y agoYou can make the same art with other formats. I'm not sure exactly what your point is here.
- antirez 7y ago1. One of the reasons a kinda secondary feature of GIFs (animations) became so popular is because it's so easy to generate them. 2. A big feature is that they are not lossy compressed so you can do animations of all the kinds. 3. They allow to set very slow FPS settings in a trivial way. Animated GIFs are not really a video format, they are just a set of non-lossy compressed images shown at a timer interval. Such small details are hugely important when some media is used in a creative way.
- vortico 7y agoIf you have an application where you need lossless and optionally low FPS, then GIF is fine (and APNG and webp for smaller filesizes but less compatibility). But the average GIF in the wild these days is a reencoding from a video that doesn't match this description, which is what should be changed to h264, vp8, vp9, or AV1.
- silversconfused 7y agoMaybe the movement could and should clarify their goals for world domination do not include dancing baby gifs?
- erichocean 7y agoYou can write the same algorithm in some other language. I'm not sure what exactly your point is here. /sarc
- ChrisGranger 7y agoAV1 is not enabled by default in Firefox 66 on Linux. You have to flip a switch in about:config to get it to work. media.av1.enabled For what it's worth, AV1 videos play really slowly on my machine. There's probably a reason AV1 is not enabled by default yet.
- eclipseo76 7y agoThey use Dav1d in Nightly so it will be fast soon.
- bscphil 7y agoAs far as I know, dav1d can be enabled even on 66: media.av1.use-dav1d = true
- TD-Linux 7y agoIt's enabled on Linux on 67+ (currently Beta).
- niftich 7y agoAV1 is an open and free format, but if people really wanted to replace GIFs they could've done it with H.264 or VP9 or VP8. Notwithstanding any issues about video codec support in browsers, GIFs will continue to have value until browser-vendors, spec-writers, and webmasters accidentally or deliberately coalesce around a sane ruleset for embedded motion picture completely devoid of audio. Today, browser-makers have concerns about which videos to autoplay, webmasters' tools for specifying "muted" videos have been unreliable. GIFs completely sidestep that conversation, because GIFs cannot contain audio, and will always autoplay.
- FreeFull 7y agoPerhaps audio-free videos should be allowed in <img> tags
- pavlov 7y agoI'd support that (as if anyone's asking me...) on three conditions: 1) Maximum duration of, say, 10 s (with mandatory looping) 2) Maximum display size of, say, 25% viewport area 3) Browsers must enforce "Click to stop" on these "video-img" elements even if there are other DOM elements on top.
- TheCoreh 7y agoIf none of these conditions apply to gifs, why should they apply to videos in img tags?
- jodrellblank 7y agoBecause we can't change the past, but we can improve the future.
- masklinn 7y agoAudio-free videos are often allowed to autoplay (though you may need to flag them as muted as well). TFA'a video autoplay just fine in both Safari and Firefox.
- _Gyan_ 7y agoJust a parenthetical note: The article, in its ffmpeg encoding guide says, -f - Only used in the first pass. Specifies the format of the output file in the second pass i.e. MP4 in this case This is not required to be the same as the intended output format. Using `-f null -` will work just as well, as long as the encoder is epxressly set, which it is, in the commands shown.
- singhkays 7y agoThank you for the explanation. I'll update the article.
- jjordan 7y agoWhat ever happened to the APNG format? I remember dabbling with it years ago but seems to have never caught on. https://en.wikipedia.org/wiki/APNG https://en.wikipedia.org/wiki/APNG
- vortico 7y agoAll browsers except IE/Edge support it, so it "caught on", but I don't see it in the wild, so it hasn't caught on with web publishers.
- kevingadd 7y agoIt was stonewalled by multiple browser vendors for a long time which helped eat away at its momentum. In that time period people tended to give up and just use webm/h264 instead (after all, those work almost everywhere, including old devices that don't have apng)
- niftich 7y agoChrome didn't support it until 2017 [1], with the release of Chrome 59 [2]. [1] https://news.ycombinator.com/item?id=13871809 https://news.ycombinator.com/item?id=13871809 [2] https://www.chromestatus.com/feature/6691520493125632 https://www.chromestatus.com/feature/6691520493125632
- Dylan16807 7y agoIt's fine, but it's lossless so it's not good for most video use cases.
- pjc50 7y agoSo is animated gif, though.
- Dylan16807 7y agoWhat I'm saying is, in uses akin to this article, apng is not a meaningful upgrade over gif. It's a huge upgrade for certain kinds of content, especially animated icons with aliased edges. But that narrowness means there's only a moderately small push toward adoption.
- codetrotter 7y ago> It is 2019 and we need to make a decision about GIFs I thought "everyone" already agreed on this. Video files are smaller and if you choose the right set of codecs for which clients have hardware acceleration then playback consumes less energy, meaning your visitors don't drain the batteries of their devices as fast. > replacing GIFs with video has now been common for a few years Indeed. Which kind of leaves me wondering why author seems to be introducing their article as though it wasn't. Of course, the article does go on to argue for a specific codec. Still, to me it seems to talk in a way as if not using GIF is "controversial".
- dqybh 7y agoAV1 will never work on Safari, so it's dead in the water.
- thrower123 7y agoDesktop or mobile? I suppose this must mean iOS, because desktop Safari is nearly as dead as Edge or Opera.
- dagenix 7y agoApple is a member of the Alliance for Open Media, the group behind AV1: https://aomedia.org/membership/members/ https://aomedia.org/membership/members/. I'd suspect apple will roll out support at some point.
- paavoova 7y agoApple is also a member of MPEG LA, and has refused to adopted VP9. With AV1 perhaps they changed their tune and/or had no choice industry wise.
- acdha 7y agoVP9 is a Google project which competed with the MPEG-developed H.265. It’s not surprising that Apple implemented the format they contributed to and then jumped to the next generation format rather than spending time on an older format which never saw significant adoption.
- acdha 7y agoDo you have a citation for that claim? Apple is in the “Founding Members” section of https://aomedia.org/membership/members/ https://aomedia.org/membership/members/ so “never” seems like a stretch
- izzydata 7y agoThe most important part of GIFs for me is that they behave like images in browsers. They are always auto-playing with no concept of play and pause. You can drag and drop them from a browser to your desktop to save them. You can save an entire page and have all the image files save with it. I've never had this work for webm or other video formats. You could even argue that GIFs not being a video with no video decoding required is a feature. It may take longer to load, but I can have 100+ GIFs playing at once with no impact to my CPU. I don't care about video compression or hardware decoding or whatever until they function the same way as GIFs do.
- masklinn 7y ago> The most important part of GIFs for me is that they behave like images in browsers. They are always auto-playing with no concept of play and pause. You can drag and drop them from a browser to your desktop to save them. You can save an entire page and have all the image files save with it. I've never had this work for webm or other video formats. The saving bit is the only part which doesn't work right with videos AFAIK. Sound-less (/muted) videos can autoplay and loop, and there's no controls unless you ask for them (via the `controls` attribute) or bring your own. The examples in the article (the scenes are videos) autoplay, loop and don't have control in either Firefox or Safari.
- izzydata 7y agoI understand that they can be made to autoplay with no controls, but I don't even want the possibility of them being paused. This way the format has no choice but to behave as expected across everything.
- PhasmaFelis 7y agoThere's nothing about allowing play/pause that prevents videos from behaving exactly like gifs. I've seen browsers with play/pause options for gifs, even.
- 7y ago
- acdha 7y agoIt's telling that the author doesn't list all of the file sizes. The GIFs are gigantic but the AV1 files are LARGER than either the H.264 or VP9 versions in every example. If we wanted to replace GIFs you'd want to go with something closer to a comparable level of support and at this scale there's no reason to use a format with no hardware support and limited client support in general: https://caniuse.com/#feat=mpeg4 https://caniuse.com/#feat=mpeg4 97.16% https://caniuse.com/#feat=webm https://caniuse.com/#feat=webm 86.39% https://caniuse.com/#feat=hevc https://caniuse.com/#feat=hevc 16.57% https://caniuse.com/#feat=av1 https://caniuse.com/#feat=av1 35% Note also that this is _any_ support at all, including the slow software implementations which boost the VP9 and AV1 numbers but have significant drawbacks if you care about quality, battery life, or the impact on other things running on the same device.
- VikingCoder 7y agoum, I think at least mpeg4 and webm decoders have been emscriptemed to run in pure JS. https://jsmpeg.com/ https://jsmpeg.com/ http://libwebpjs.appspot.com/vp8/webm-javascript-decoder/ http://libwebpjs.appspot.com/vp8/webm-javascript-decoder/ And I think this: https://developers.google.com/web/updates/2018/08/wasm-av1 https://developers.google.com/web/updates/2018/08/wasm-av1 So I don't think your "_any_ support at all" comment is correct.
- xmichael999 7y agoIncorrect, jsmpeg decodes mpeg1 and mpeg2 (which are basically the same) Decoding MPEG4 in Javascript can be done, check out broadway but it uses massive massive CPU and basically sucks.
- acdha 7y agoThey've also been done in WASM but the comment is correct as written because the idea is that the vast majority of times when you serve a <video> with an MPEG-4 source file it'll be decoded entirely in hardware whereas AV1, H.265, and to a lesser extent, VP-9 will be loading up the CPU. To put this in perspective, I have a 9 year old MacBook Air at home which I use for testing. If you look at 720/1080p video on YouTube, even that ancient hardware it takes 5-10% CPU to play H.264 content. I have a 2017 desktop at work with 4.2GHz Core i7 which still takes almost 100% of a CPU to play 720p AV-1 and ~60% to play VP9, or ~1% to play H.264. That's a really big difference for something like a GIF successor which will be widely shared, often with multiple visible at the same time, and people will expect to just work even on hardware which is more than a year old while still leaving capacity to do other things.
- Flavius 7y agoFor whatever reason my browser is crashing when trying to read this article, so I guess I'll keep my GIFs.
- singhkays 7y agoI've noticed Firefox crashes more often than Chromium based browsers. Most likely a point in time thing as Firefox updates to the latest version of dav1d decoder
- davidhyde 7y agoThis is the one time I am very happy that standards have failed to materialise. Leave me to read in peace with distraction free web pages thank you very much. If I want to see an animation I’m fine with touch or a click for activation.
- errantspark 7y agoYou can pry my GIFs from my cold dead hands. Aesthetically speaking GIFs have a character that you gotta jump through a lot of hoops to approximate with another format. In addition to that they function everywhere, always autoplay, can't have annoying audio, and support transparency, these are all important features that nothing else on the 'market' can match. I'm aware that there is lossless animated WebP with transparency, and I can encode a low-color animation into one of those for something functionally identical to a GIF, excepting the fact that it won't be supported anywhere except a recent Chrome.
- bscphil 7y agoIf you want a "degraded" aesthetic, nothing is stopping you from encoding a gif, then encoding the gif to a video format. The last stage should be roughly lossless, and the video will still use way less space than the corresponding gif.
- follower 7y ago> can't have annoying audio Good news, they can now: https://news.ycombinator.com/item?id=19935900 https://news.ycombinator.com/item?id=19935900
- therealmarv 7y agoWaiting for end 2020 Macbooks which can decode (and encode?) AV1 on CPU hardware hopefully (and hopefully also solved the keyboard mac problems).
- gok 7y agoEr, it has only ~35% global support today. I'd hold off.
- xmichael999 7y agoWell let's get one thing straight, VP9 does not achieve 50% more compression compared to H.264... Second the demo videos were cherry picked to support their argument - using full motion panning...
- clouddrover 7y agoNetflix disagrees with you: https://medium.com/netflix-techblog/optimized-shot-based-encodes-now-streaming-4b9464204830 https://medium.com/netflix-techblog/optimized-shot-based-enc...
- syphilis2 7y agoMy browser (FF66 Win10) lags and hangs when browsing this site. Also, the AV1 videos have frozen and I can't get them to play again without refreshing. I can recreate both of these bugs by simply changing tabs. Despite that, I'm ready to switch to video too.
- MagicPropmaker 7y agoOne great thing about GIFs is that they are always silent!
- booleandilemma 7y agoI predict that users will go on calling AV1 video (or any other formats we use in the future) “gif”s anyway. The word “gif” will come to mean “animated image”.
- iainmerrick 7y agoI thought that had happened already!
- telesilla 7y agoAnyone know what the movies are in the sample GIFS?
- singhkays 7y agoTears of Steel https://mango.blender.org/ https://mango.blender.org/
- sexyflanders 7y agoFine, but do it transparently so the file is named .gif and it behaves the same as a gif only better optimized. I hate opening “gifs” that are actually videos and, for example, interrupt my currently playing music to playback silence.
- debt 7y ago"The AV1 recipe..." fifteen ffmpeg commands Yeah I don't think AV1 is the answer.
- singhkays 7y agoThat's why it's a recipe and not a command ;) Also it can be easily scripted out, where the only input needs to be a source video
- brian-armstrong 7y agoYep, shelling out to ffmpeg on your production network is probably not particularly scalable nor safe.
- natch 7y agoSounds good but my browser (Safari on iOS) shows just white space for the VP9 and AV1 example videos.
- Jnr 7y agoBut can I put those videos in PowerPoint presentations?
- Ezhik 7y agoAt this point, killing GIF is a UX problem, not a format problem. I've talked about this before [0], but the big problem for me is that video is just difficult as hell. Compared to a GIF, it is just that much harder to save a video on a phone, and then upload it the same way as an image. Try to save a "GIF" from Twitter or from GIPHY - it's a /huge/ pain. Whatever the GIF killer is will need to pass the right click test - I need to be able to just right click and save it. [0]: https://news.ycombinator.com/item?id=14181158 https://news.ycombinator.com/item?id=14181158
- iainmerrick 7y agoYes. Just one problem I discovered recently is that no other format does looping properly. With a GIF, you can right-click and save it, and all the looping info is inside the file. The quality is crappy, but it just works. With all “proper” video formats, looping info is metadata, stored separately. You can’t even go for something slightly more modern, animated PNGs, because there are warring formats and very few tools that support them.
- afiori 7y agowasn't webp supposed to have GIF like animations? As far as i know I have never seen one in the wild, just webm. I think the problem is that GIFs are images and so displayed as such with little concept of play-control. A video format communicate that you might want to pause for example. I believe a GIF-killer will need to be considered an image as a format.
- iainmerrick 7y agoYes, agreed. That lack of play-control is both a weakness and a strength of GIF. The strength is misunderstood and underrated by those who think videos should replace all usage of GIFs.
- Kaiyou 7y agoPlay control isn't impossible for GIF. I'm using sxiv for viewing images, which is as minimal as it gets, but it does have pause, single step forward and single step backward for GIF.
- samirm 7y agoAs long as AV1 works without js, sure.
- singhkays 7y agoIt sure does
- compiler-guy 7y agoThe "We need a gif replacement" discussion isn't quite in xkcd 927 territory yet, but its very close. And that is what is working against something completely replacing it. https://xkcd.com/927/ https://xkcd.com/927/
- floatingatoll 7y agoThe test results in this blog do not function correctly on iOS latest, so while I endorse this as a general future goal, make sure you have a proper fallback solution in place if iPhone users are relevant to you.
- singhkays 7y agoNormally, you can specify GIF as a fallback as seen in this article https://www.singhkays.com/blog/detect-rolling-credits-video-indexer/ https://www.singhkays.com/blog/detect-rolling-credits-video-... Even though the first preference is AV1, the 2nd, 3rd & 4th preferences are VP9, H264 and GIF which should play
- CameronBanga 7y agoThe VP9 and AV1 aren't loading in my browser, (latest Safari on Mojave 10.14.4). I understand pushing for progress, but with this table, I'm not sure "it's time" just yet. https://caniuse.com/#feat=av1 https://caniuse.com/#feat=av1
- jraph 7y agoMaybe this would incentive Apple into supporting these formats. For vp9, it seems to me there isn't any good excuse for not supporting it.
- acdha 7y ago> For vp9, it seems to me there isn't any good excuse for not supporting it. Exporting video formats is expensive: there's a lot of optimization work to have a high-quality battery-friendly implementation, decode hardware has to be licensed & updated, and they have to do security hardening and support every time they add a new format. If they're already working on AV1, why double the cost to add support for an older format which is almost never used as the only option?
- jraph 7y agoIt’s not like Apple can’t bear this cost. VP9 has existed since 2012, Android has supported the format since version 4.4 released in 2013. AV1 was then unheard of. Surely they weren’t working on it then. VP9 is still interesting today since there are many devices out there that decode it and will never decode AV1 with hardware. I think the reason is not technical. Apple has patents for MPEG formats, I think they wanted to push these formats instead. By not supporting VP8/VP9, they force(d) everyone to support their formats. Now, if I want to make a video call with someone with an Apple device, I'll probably need, if I live in a place where software patents apply, to pay a license to decode/encode an MPEG format where the royalty-free VP9 would have done the job. Worse, I probably indirectly pay these fees (anyway) when I buy devices with support for MPEG formats, even if I live at some place were software patents don't apply.
- the8472 7y agoThis is fine for real world videos crammed into gifs. But please think of animated pixel art, which is antithetical to many the assumptions that DCT-block based codecs make. Doubly so when you consider that most encoders default to 4:2:0 and ignore transparency. APNG or similar image formats are better for this purpose
- bscphil 7y ago>Doubly so when you consider that most encoders default to 4:2:0 I agree, but I want to add that this has another side effect you don't mention: it makes high quality images impossible. In 2019, it would nice to have something better than cjpeg -q 98 for near lossless (or completely lossless images). I've spent many hours tinkering with the new inter frame based image codecs, and I haven't been able to achieve this because despite their advertised support for better standards, the decoders seem to have only implemented 8 bit 4:2:0 subsampled sRGB images. I guess I'll go on storing my photography in 150 MB TIFF files...
- jimbo1qaz 7y agoGood: - AV1 has a palette predictor designed to improve on pixel art by storing individual pixels as indexes into a palette. - Chroma from luma helps preserve exact colors in pixel art, assuming color is lonely related to brightness (won't work as well for color-only changes, possibly not when brightness and color vary separately, or multiple colors and brightness are mixed) Bad: - AV1 takes seconds to minutes per frame. I let my laptop chug for half to several hours, running Manjaro AUR with bleeding-edge ffmpeg-git, encoding multicore tiled AV1, and it managed to encode under 3 seconds of video. (Did it link to an older libaom-av1 or is it bundled statically with ffmpeg?) - When chroma subsampling and CfL (chroma from luma) mix, the brightness is subsampled to create a color prediction, instead of being used to add extra color resolution. - Youtube's sample AV1 encodes have 4:2:0 subsampling (aka color channels have halved width and height resolution). Rav1e may be faster, but apparently disabling chroma subsampling breaks CfL and inter-frames.
- parentheses 7y agoI don't think it can be killed unless (unordered) - looping is solved and convenient to configure - it can be cross media barriers (copied into a text, copied into an e-mail, etc.) - it pleases the bandwidth gods (are gifs usually smaller? i know that they have a limited color palette)
- singhkays 7y agoYour problems 1 & 3 are solved in the article. I compare the size of the GIF to the videos. In one of the scenes it's ~11 MB for GIF and < 500 KB for AV1 video
- parentheses 7y agoMy bad. I should have read more of the article before "contributing". That being said, #2 is critical. I often open Safari to get gifs to copy to iMessage because Chrome and Firefox don't properly copy gifs. AV1 may be a way to make that more "standard" (big hand wave) but adoption is conditional upon this type of common man friendly portability.
- darkpuma 7y agoOkay, I'm on board. But what container am I meant to be using for my AV1 content? I see the value of a limited subset of mkv, e.g. webm, but webm is too limited in my opinion. It has no facilities for soft subtitles for instance. How is that an acceptable state of affairs? That's an accessibility issue. And yes, I know websites can send subtitles separately then render the subtitles over the <video> element, but that's no excuse for an ostensibly modern media container to not support subtitle tracks.
- Proven 7y agoNo it's not. Maybe some specific content should be released as AV1, but most existing can stay as GIF (it just works)
- Andrex 7y agoAnimated PNG seems to be the least-bad option that covers every key GIF feature, and most importantly will be supported by every major browser once Edge-Chromium ships: https://www.caniuse.com/#feat=apng https://www.caniuse.com/#feat=apng
- travofoz 7y agoI think it really comes down to use case. If your intent is to display content that is originally video, then you should use the best and most supported video format. If your intent is to display some effect through animation, a gif isnt a bad thing. For example, the ajax loader that we are all familiar with? The size difference is minor. The gif is 16k, an mp4 is 11k. HOWEVER, with the video I have worry about the browser playing it, looping it, and does it handle transparency? (i dunno) If I wanted one of those full page & full motion backgrounds, it would definitely be a video. The first time I saw a page like that load, load really fast, and be high quality video, I was amazed (leave aside aesthetics)
- thanatropism 7y agoWorse is better.
- HocusLocus 7y ago1995: Compuserve/Unisys is becoming obnoxious! 1996: The GIF KILLER is going to be PNG! (We wait for animation. The PNG committee fails to deliver, they had a LZ method not covered by patent, they had the world cheering them on -- and having myself seen some of the listserv emails back then, some of the committee had asshole reasons thinly disguised like someone didn't like blinking banner ads.) 2001: The GIF killer is going to be MNG! (Oh now simple animation is too hardz! We're going to dump a kitchen sink of video features into it! Later! The rest of us have given up on the PNG committee) The GIF KILLER is going to be APNG! (Says Mozilla, not too convincingly but they did deliver something) [embarrassing span of time passes] 2007: (The world gave up on all that. GIF is still alive) [Interestingly, within this time the only other embed besides GIF that loops smoothly is Flash, and --- surprise -- it is universally hated by the Beautiful People] [embarrassing span of time passes] 2016: With stupid player and JS tricks Geniuses loop video files that stutter and jump at the loop point and pretend they're GIFs. We have millions of colors but crappy loop stitches. 2019: GIF is still alive! Who'da thunk it. We have crappy 256 dither barf BUT perfect loop stitches! Because extending the simple concept to 16 million colors waaaay back in 1996 was just too advanced for the human race. Let's have a round of applause for the PNG committee. /SARC fuelled by some frustrating web development compromises
- usermac 7y agoWhile investigating if I could actually use this—animated PNG, I found this website and it convinced me it is the new direction I should take: http://littlesvr.ca/apng/gif_apng_webp.html http://littlesvr.ca/apng/gif_apng_webp.html
- xvilka 7y agoYou can blame both Google and Mozilla for ruining the chance to replace GIFs with APNG and WebP respectively. People were waiting the support of those for years in Chrome/Firefox, but their stubbornness already forced some image hosting sites to use video formats like WebM. At this point I am not sure WebP or APNG would become popular. But using proper image format for animation is a better solution , I think.
- deleted 7y ago[deleted]
- tomc1985 7y agoThese "It's year 20XX, throw out this outdated tech!" arguments get so very old after a while
- qwerty456127 7y agoHell no, it's not. None of my devices can play HEVC videos filmed with a recent iPhone without severe performance glitches. I fear to imagine how hard it is going to be to play AV1. MP4 AVC feels like a great replacement for animated GIFs and almost every device in use today plays it nicely yet, sadly, most of the websites that would allow inserting a GIF in a post won't allow an MP4 file instead. For some sites you even have to convert an MP4 to GIF before uploading it just to see it converted back to MP4 on their side for serving. Perhaps it could be handy if img tags would just be extended to accept video files (of all the video formats the browser supports) below certain size. Or we should better (perhaps) just forget such a category as an "animated picture" and switch to treating them like regular videos, introducing a separate button to insert such alongside to the "insert picture" button.
- indolering 7y agoAV1 has enough support from enough vendors that it has a very high chance of replacing H.264 as the ubiquitous video codec. The headline is a bit click-baity, but proposing new web standard "now" means it would be available everywhere in ~5 years.
- libraryatnight 7y agoThe limitations of GIFs are part of what makes them great. The constraints sort of lend themselves to forcing a little extra creativity. Finding that perfect loop, finding that great moment that so perfectly works out of context, spoofing text that fits the scene/mood to repurpose those frames for a niche community - it's just fun to make and share GIFs. The problem with video is its a video.
- miguelmota 7y agoTLDR; article suggests to replace a gif img tag with <video style="display:block; margin: 0 auto;" autoplay loop muted playsinline poster="RollingCredits.jpg"> <source src="media/RollingCredits.av1.mp4" type="video/mp4"> <source src="media/RollingCredits.vp9.webm" type="video/webm"> <source src="media/RollingCredits.x264.mp4" type="video/mp4"> <img src="media/RollingCredits.gif"> </video>
- njsubedi 7y agoAs an app developer, whenever I need something animated, I use the baseline MP4 format. My main motivation was that animated GIFs were not supported by Android without third party libraries. I've had 10-15 seconds of videos (640x480) at 10 fps well under 200 KB. I also compared JPEG with MP4 and decided to use MP4 video (1 frame) instead of JPEG to keep myself from re-implementing a UI again for an image.
- ezoe 7y agoWake me up when the AVI encoder's performance can be measured by Frames Per Second. Currently, it should better be counted by Frames Per Day. Decoder is also slow. We need a high end desktop computer for real-time decoding of AV1 video. There is no phone/tablet that can afford such performance.
- clouddrover 7y ago> Wake me up when the AVI encoder's performance can be measured by Frames Per Second. Okay, I will. Hrm. Intel's AV1 encoder is getting 24 frames per second: https://www.phoronix.com/scan.php?page=news_item&px=SVT-AV1-Ending-April-High https://www.phoronix.com/scan.php?page=news_item&px=SVT-AV1-... WAKE UP! > There is no phone/tablet that can afford such performance. Isn't there? I wonder how well the top end iPhones are decoding AV1: https://code.videolan.org/videolan/dav1d/issues/15 https://code.videolan.org/videolan/dav1d/issues/15 Decoding at over 100 frames per second multithreaded two weeks ago. Not bad.
- self_awareness 7y agoWell, the videos on this page are empty areas on my browser. But I can see GIFs just fine.
- xster 7y agoNobody mentioned so I'll add: the one thing holding me back is the current ability to insert autoplaying gifs into GitHub's markdown. No <video> type formats are supported and being able to add an animated gif showing what you're creating a pull request for is immensely useful.
- felixfbecker 7y agoCan I easily record a screencast as a video and paste it into a GitHub issue? If not, it’s useless for my use case and I need to stick with gifs
- cm2187 7y agoNone of his AV1 samples display on my ipad. It kinds of kill the idea in my opinion.
- dagenix 7y agoTerry Davis was extremely talented. He also had his demons. I dunno if there was anything he could do about them. But let's not pretend he didn't have them. He said some terrible stuff: https://wiki.installgentoo.com/wiki/Terry_Davis https://wiki.installgentoo.com/wiki/Terry_Davis.
- soulofmischief 7y agoI'm sorry, but your comment has no place here. I was discussing a dead soul with reverence and respect. That is not the time to jump in with "oh but actually he was terrible". That is incredibly rude and poor taste and disrespectful to the dead. Terry Davis suffered greatly from mental illness, specifically schizophrenia. He suffered from confusion. It's quite disgusting that you try to cite some of the ridiculous things he's said as reasons he is terrible. He did not have full autonomy over his thoughts and words. You should be ashamed of yourself.
- surrealize 7y agoRight after someone dies, there may be people mourning them, so it's terribly disrespectful to criticize the dead person. That concern about disrespect is largely about respecting the mourning process. But, after some time has passed, we should be able to discuss and evaluate a person's impact (good and bad). Otherwise history would be impossible to write. It's been eight months. I think it's okay to acknowledge the full range of what Davis said. Grandparent comment didn't say Davis was terrible, as you claim; the words were "He said some terrible stuff".
- soulofmischief 7y agoOh ok cool, I didn't realize Mother Nature gave you the responsibility of deciding when it was OK to disrespect a dead person with an irrelevant, unnecessary comment meant only to disparage, especially when that person was extremely mentally ill. So just to make sure I have it right, 8 months is the cutoff point? Then I'm allowed to talk shit about the deceased mentally ill every time their name comes up? Imagine you created a legacy. But you were schizophrenic and a little kooky. And 8 months after you died, every time someone ever brought up your name again, the conversation was completely derailed by someone who wanted attention and got it by bringing up stupid kooky shit you said. That's the kind of hot garbage you are proposing. I refuse to disrespect the dead in that manner. > Grandparent comment didn't say Davis was terrible, as you claim; the words were "He said some terrible stuff". That's like when I tell my relatives they're saying racist things instead of directly calling them racist. It's a way to hide behind your words. It's an emergency hatch.
- imdsm 7y agoIn order to truly have a shot at replacing gifs, it has to be as frictionless to use as gifs are. That means being able to refer to it with a single, simply tag. <video src="example.av1"> and, in addition, for as many people as possible to support opening of av1s as they do with gifs.
- dana321 7y agoI kind of thought it was pointless until i saw the file size difference. From 11.7 Meg to 330k is pretty good.
- vkaku 7y agoIn my unpopular opinion, the first steps that we need to bring AV1 to the web is to stop using HLS and start using DASH