diff --git a/.vitepress/Ecosystem.mts b/.vitepress/Ecosystem.mts index 729b5aa..012d39b 100644 --- a/.vitepress/Ecosystem.mts +++ b/.vitepress/Ecosystem.mts @@ -12,7 +12,7 @@ export const EcosystemSideBar: DefaultTheme.SidebarItem[] = [ { text: "jsonwebtoken", link: "/ecosystem/package/jsonwebtoken" }, { text: "snappy", link: "/ecosystem/package/snappy" }, { text: "xxhash", link: "/ecosystem/package/xxhash" }, - {text: 'image',link: '/ecosystem/package/image'} + { text: "image", link: "/ecosystem/package/image" }, ], }, { @@ -30,6 +30,7 @@ export const EcosystemSideBar: DefaultTheme.SidebarItem[] = [ { text: "OpenSSL", link: "/ecosystem/third/openssl" }, { text: "cURL", link: "/ecosystem/third/curl" }, { text: "MMKV", link: "/ecosystem/third/mmkv" }, + { text: "avif", link: "/ecosystem/third/avif" }, ], }, ]; diff --git a/src/ecosystem/third/avif.md b/src/ecosystem/third/avif.md new file mode 100644 index 0000000..f343523 --- /dev/null +++ b/src/ecosystem/third/avif.md @@ -0,0 +1,24 @@ +--- +editLink: true +--- + +# AVIF + +AVIF is a new image format based on AV1 video encoding. Compared with image formats such as JPEG and WEBP, it has a higher compression ratio and better picture details. And most importantly, it is free and open source, with no licensing fees. + +The rust community also provides the corresponding crate [libavif-sys](https://github.com/njaard/libavif-rs), implemented based on [libavif](https://github.com/AOMediaCodec/libavif). The relevant openharmony adaptation has been submitted, you can refer to this [PR](https://github.com/njaard/libavif-rs/pull/99). + +You can wait for the PR to merge or directly reference through git. + +## Example + +```toml +[dependencies] +libavif = { git = "https://github.com/southorange0929/libavif-rs.git", default-features = false, features = [ + "codec-aom", +] } +``` + +## Tip + +For the `x86_64-unknown-linux-ohos` target, you need to install `yasm` or `nasm` to support assembly compilation. \ No newline at end of file