{"id":25436768,"url":"https://github.com/trevorflahardy/image-merger","last_synced_at":"2025-10-29T04:18:49.537Z","repository":{"id":212238425,"uuid":"720162544","full_name":"trevorflahardy/image-merger","owner":"trevorflahardy","description":"A Rust image merging library that aims to be as fast as possible and provide good functionality.","archived":false,"fork":false,"pushed_at":"2024-06-30T21:41:24.000Z","size":143,"stargazers_count":8,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-08-11T00:46:42.051Z","etag":null,"topics":["image-processing","rust"],"latest_commit_sha":null,"homepage":"https://docs.rs/image-merger/latest/image_merger/","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/trevorflahardy.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2023-11-17T18:01:53.000Z","updated_at":"2024-07-27T05:35:36.000Z","dependencies_parsed_at":"2024-01-09T16:43:10.833Z","dependency_job_id":"b8c2674c-621b-4a31-bce5-064d7069a8c5","html_url":"https://github.com/trevorflahardy/image-merger","commit_stats":null,"previous_names":["nextchai/imagemerger","nextchai/image-merger"],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trevorflahardy%2Fimage-merger","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trevorflahardy%2Fimage-merger/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trevorflahardy%2Fimage-merger/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trevorflahardy%2Fimage-merger/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/trevorflahardy","download_url":"https://codeload.github.com/trevorflahardy/image-merger/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239258261,"owners_count":19608837,"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","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-processing","rust"],"created_at":"2025-02-17T08:28:54.682Z","updated_at":"2025-10-29T04:18:44.495Z","avatar_url":"https://github.com/trevorflahardy.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"![image-merger-banner](https://github.com/trevorflahardy/image-merger/assets/75498301/6a9fbd72-2837-44ea-ba4f-f50d7f4525fe)\n\nWelcome to Image Merger! A crate that provides blazing-fast functionality for merging many images. It is built on top of the image crate and works to boost performance by utilizing parallel processing and avoiding unnecessary costly operations.\n### What does it mean to \"merge\" images?\nA Merger paces many small images onto a larger canvas in a specific pattern/location. As of today, this library only has one type of Merger, a `KnownSizeMerger` which focuses on performance as its top priority, but more will be added soon. An example of an output from a `KnownSizeMerger` is below, this is the general output from [the crate's tests](tests/known_size_merging.rs).\n\n\u003cimg src=\"https://github.com/NextChai/image-merger/assets/75498301/a70fc92f-e5a6-4834-8ab0-37363cb2d178\" width=\"250\" height=\"250\"\u003e\n\u003cimg src=\"https://github.com/NextChai/image-merger/assets/75498301/ecdf0a62-e805-45ac-a2fc-5b4464c20f80\" width=\"250\" height=\"250\"\u003e\n\u003cimg src=\"https://github.com/NextChai/image-merger/assets/75498301/84d47b2d-cb79-42dc-aa91-553ceff9b7f4\" width=\"250\" height=\"250\"\u003e\n\n## Install\n\nRun the following Cargo command in your project directory:\n\n```\ncargo add image-merger\n```\n## Benchmarks\n### 100x100px Fixed-Size Images\nThe disparity in merging 10,000 images of 100x100 pixels between the merger and a linear implementation is significant. As depicted below, the x-axis illustrates the number of images being merged, ranging from 1 to 10,000, while the y-axis indicates the duration in milliseconds it took to merge all the images. The linear implementation is shown in green and the image merger in orange.\n\n\u003cimg src=\"https://github.com/NextChai/image-merger/assets/75498301/cc2dd6a8-6d6c-421d-89f2-7efa96119abc\" width=\"1080\" height=\"480\"\u003e\n\nOver the 10,000 image interval, the image merger yielded an average **3.646x speed increase** over the linear implementation. Effectively speaking, the combined average time, in ms, to generate a merged image with $n100^2$ pixels is $A(n)= 0.0082n$, where $n$ is the number of merged images. Moreover, the average time to paste a single given pixel, in ms, is $A\\left(n\\right)=\\frac{0.0082n}{100^{2}}$, where $n$ is the number of merged images.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftrevorflahardy%2Fimage-merger","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftrevorflahardy%2Fimage-merger","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftrevorflahardy%2Fimage-merger/lists"}