{"id":18301349,"url":"https://github.com/lvgl/lv_img_conv","last_synced_at":"2025-08-08T18:35:14.066Z","repository":{"id":37699596,"uuid":"274214517","full_name":"lvgl/lv_img_conv","owner":"lvgl","description":"Image converter for LVGL, written in JS","archived":false,"fork":false,"pushed_at":"2024-07-23T15:25:10.000Z","size":3216,"stargazers_count":103,"open_issues_count":14,"forks_count":45,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-07-19T09:22:20.778Z","etag":null,"topics":["image-converter","lvgl"],"latest_commit_sha":null,"homepage":"https://lvgl.github.io/lv_img_conv/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lvgl.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-06-22T18:33:50.000Z","updated_at":"2025-07-11T01:34:37.000Z","dependencies_parsed_at":"2025-01-15T14:18:59.195Z","dependency_job_id":null,"html_url":"https://github.com/lvgl/lv_img_conv","commit_stats":{"total_commits":93,"total_committers":9,"mean_commits":"10.333333333333334","dds":0.5483870967741935,"last_synced_commit":"2c64f2dc93b33f406f8aff932bad4fb1891dc7b4"},"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/lvgl/lv_img_conv","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lvgl%2Flv_img_conv","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lvgl%2Flv_img_conv/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lvgl%2Flv_img_conv/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lvgl%2Flv_img_conv/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lvgl","download_url":"https://codeload.github.com/lvgl/lv_img_conv/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lvgl%2Flv_img_conv/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267763452,"owners_count":24140822,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-07-29T02:00:12.549Z","response_time":2574,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["image-converter","lvgl"],"created_at":"2024-11-05T15:15:26.505Z","updated_at":"2025-07-29T21:35:17.532Z","avatar_url":"https://github.com/lvgl.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Image converter for LVGL\n\n## How to install\n\n1. Make sure Node.js is installed.\n1. On Linux make sure the followings are installed: `sudo apt install gcc make g++ pkg-config libpixman-1-dev libcairo2-dev libpango1.0-dev libjpeg8-dev libgif-dev`\n1. Not always needed, but recommended: ensure the necessary [native dependencies for canvas](https://github.com/Automattic/node-canvas#compiling) are installed.\n1. Clone this repository.\n1. Run `npm install` to install needed dependencies.\n\n**NOTE: For Docker instructions skip ahead**\n\n### Extra steps for Windows\n1. Run 'npm install -g typescript'\n1. Move to 'lib' folder 'cd lib'\n1. Run 'npm install -g ts-node'\n\n**Note**: The converter might fail on Windows if the file path containes multiple byte characters (Chinese/Japanese/Korean characters etc.). It's recommended to rename these files before passing them to the converter, or you can switch on `enable Beta:Use Unicode UTF-8 for worldwide language support` options.\n\n## Example usage:\nFor Linux:\n```sh\n# C format\n./lv_img_conv.js logo_lvgl.png -f -c CF_TRUE_COLOR_ALPHA\n# Binary format (RGB565)\n./lv_img_conv.js logo_lvgl.png -f -c CF_TRUE_COLOR_ALPHA -t bin --binary-format 565\n# C format with dither algoritm\n./lv_img_conv.js logo_lvgl.png -f -d true -c CF_TRUE_COLOR_ALPHA\n```\n\nFor Windows:\n```sh\n# C format\nts-node cli.ts logo_lvgl.png -f -c CF_TRUE_COLOR_ALPHA\n# Binary format (RGB565)\nts-node cli.ts logo_lvgl.png -f -c CF_TRUE_COLOR_ALPHA -t bin --binary-format 565\n# C format with dither algoritm\nts-node cli.ts logo_lvgl.png -f -d true -c CF_TRUE_COLOR_ALPHA\n```\n\nA file called `logo_lvgl.c` will be created in the same directory.\n\n## Example usage with Docker:\n\n### Building locally\n\n```bash\ndocker build -t lv_img_conv .\n```\n\n### Run lv_img_conv.js directly\n\n```bash\ndocker run --rm \\\n    -u 1000:1000 \\\n    -v /path/to/project:/usr/src/proj \\\n    lv_img_conv \\\n    \u003clv_img_conv.js arguments\u003e\n```\n\n### Run interactive shell\n\n```bash\ndocker run -it --rm \\\n    -u 1000:1000 \\\n    -v /path/to/project:/usr/src/proj \\\n    lv_img_conv\n```\n\n`lv_img_conv.js` is in the `$PATH` and callable from the interactive shell.\n\n### Parameters\n\n| Parameter | Function |\n| --- | --- |\n| `-u 1000:1000` | Set to your host user's UID/GID, unless you don't mind root ownership on output files |\n| `-v /path/to/project:/usr/src/proj` | Change `/path/to/project` to directory with image(s) to convert |\n\n## Attribution\n\nThis converter was originally created by @embeddedt as an attempt to solve some of the common issues experienced with the PHP converter, such as running out of memory on large images or failing to read certain PNGs correctly.\n\nMuch of the actual conversion logic remains unchanged from the previous implementation, which can be found at https://github.com/lvgl/lv_utils/blob/b298fe71675e9c12016adabcc8889394b477b89b/img_conv_core.php.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flvgl%2Flv_img_conv","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flvgl%2Flv_img_conv","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flvgl%2Flv_img_conv/lists"}