Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

A wasm version for img2webp of libwebp

License

NotificationsYou must be signed in to change notification settings

libwebp-wasm/img2webp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Introduction

The process of converting thelibwebp project from C/C++ to WASM is achieved using theEmscripten compiler. The general workflow is as follows:

Emscripten Compilation Flow

Usage

Installation

Toolchain

This includes installingemsdk,cmake, andpnpm. For specific installation methods, refer to theEmscripten official documentation,pnpm official documentation, andinstalling cmake.

submodule

git submodule update --init --recursive --remote --rebase

Build

MacOS

If you are using zsh, it is recommended to installthe dotenv plugin to enable features like setting environment variables if a .env file is present in the current directory.

pnpm build:mac

Docker

Build Image
docker build -f ./docker/Dockerfile -t libwebp-wasm/img2webp:latest.
Run Image
docker run --rm  -v$(pwd)/dist:/img2webp/dist -v$(pwd)/es:/img2webp/es -v$(pwd)/lib:/img2webp/lib libwebp-wasm/img2webp:latest

Other

Note: The modification of upstream submodule project code is currently done by running the git apply command. Sometimes you need to commit your own changes in the submodule directory and manually generate the patch.

pnpm build:patch

Example

License

MIT

About

A wasm version for img2webp of libwebp

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors2

  •  
  •  

[8]ページ先頭

©2009-2025 Movatter.jp