joedrago / avif Goto Github PK
View Code? Open in Web Editor NEWTHIS PROJECT HAS MOVED: https://github.com/AOMediaCodec/libavif
License: BSD 2-Clause "Simplified" License
THIS PROJECT HAS MOVED: https://github.com/AOMediaCodec/libavif
License: BSD 2-Clause "Simplified" License
I don't know if it's in the scope of this project, but I would love an avif encoder that can take common image formats as input instead of only 74m. PNG and JPG support would be most relevant, but WebP, Heic, GIF and TIFF would also be useful.
For example, cwebp supports PNG, JPEG, TIFF, WebP or raw Y'CbCr images. The decode libraries used by libwebp can be found at https://github.com/webmproject/libwebp/tree/master/imageio.
I think there is a proper way to specify which item in a .avif is the alpha channel, using the type auxC. Figure that out.
I.e., basically standardize on clang-format as the style for all non-external code. Totally up to you, so feel free to reject this "issue" with prejudice, but I feel this helps the legibility and maintainability of projects over time.
https://clang.llvm.org/docs/ClangFormat.html
https://github.com/llvm-mirror/clang/tree/master/tools/clang-format
Example implementation:
KhronosGroup/SPIRV-Tools#1029
If I'm being selfish I'd recommend the -style=Chromium, but really having any .clang-format standardized dotfile would be beneficial :)
Support 8, 10, 12 bit. Support YUV420 YUV422, YUV444.
I know that this library is used for experience and is work-in-progress. But current tagged release v1.0.3, the encoding speed seems too slow. Even I setup to use the 2/4/8 threads for encoding.
The encoding speed is now 100x slower than other image format such as WebP (libwebp) or HEIF (libheif), for even 512*512, 24 Bits images. You can use this demo image to test on the HEIF and PNG compression, using the tool colorist
The encoding speed runnnig on mobile iOS system is worse. Here is a simple codec plugin for iOS framework SDWebImageAVIFCoder, which have to mention this encoding speed, which means the AVIF encoding maybe not usable for users. However, the decoding speed is acceptable.
Test result:
<Decode> [PNG]: Time: 1.43 ms
<Decode> [JPEG]: Time: 0.39 ms
<Decode> [HEIC]: Time: 1.47 ms
<Decode> [HEIF]: Time: 102.06 ms
<Decode> [WebP]: Time: 24.00 ms
<Decode> [BPG]: Time: 39.60 ms
<Decode> [FLIF]: Time: 364.84 ms
<Decode> [AVIF]: Time: 154.54 ms
<Encode> [PNG]: Time: 39.63 ms
<Encode> [JPEG]: Time: 2.46 ms
<Encode> [HEIC]: Time: 65.51 ms
<Encode> [HEIF]: Time: 1799.63 ms
<Encode> [WebP]: Time: 168.42 ms
<Encode> [BPG]: Time: 2761.79 ms
<Encode> [FLIF]: Time: 6160.68 ms
<Encode> [AVIF]: Time: 346592.24 ms
"HEIC" means using Apple's built-in HEVC codec, "HEIF" means using libheif
Use the embedded colr box to calculate the YUV coefficients to use.
Add support for av1 cfg BMFF box output
Upon reaching feature complete, document all API calls properly.
Add support to read/write an ICC chunk into a colr box.
Hi. Sorry to bother here...
I'm a iOS/macOS developer, but is not expert in Image Decoding and Processing. But recentlly I have interests in AVIF image foramt. And I want to build a simple client-side image viewer, to see the render result of AVIF images.
So I found this project, and using the straight forward code to decode the AVIF images into RGB bitmap buffer. Then using the platform API to show the bitmap buffer on screen.
But, all the tests images I used, will result a Stretch
and Green
color of the original image. It's a little strange. Like the following:
v0.1.0
v1.0.0
and v1.0.0-errata1
The render result:
Actual image:
I wonder, if this is because of my usage issue ? Or something about AVIF spec changes ? Because I also try another AVIF library: libheif. Which use aom codec as well to decode HEIF && AVIF images. But sadly, it contains the exact same issue. So I wonder this may be my usage issue ๐
See also: strukturag/libheif#120
Right now you can only specify a generic quality (0-63). Figure out what else should be exposed and offer it.
(or perhaps expose a step where someone can directly manipulate the encoder?)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.