{"id":18929495,"url":"https://github.com/thecodingmachine/utils.graphics.mouf-imagine","last_synced_at":"2025-04-15T15:31:04.293Z","repository":{"id":30816819,"uuid":"34374007","full_name":"thecodingmachine/utils.graphics.mouf-imagine","owner":"thecodingmachine","description":"Wrapper around the Imagine library, that allows to associate a set of Imagine Filters to an URL, like the LiipImagineBundle does for Symfony","archived":false,"fork":false,"pushed_at":"2018-11-27T09:28:23.000Z","size":517,"stargazers_count":1,"open_issues_count":1,"forks_count":7,"subscribers_count":5,"default_branch":"2.2","last_synced_at":"2025-04-11T18:59:52.350Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/thecodingmachine.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}},"created_at":"2015-04-22T06:51:54.000Z","updated_at":"2022-10-11T20:56:34.000Z","dependencies_parsed_at":"2022-08-24T12:00:56.245Z","dependency_job_id":null,"html_url":"https://github.com/thecodingmachine/utils.graphics.mouf-imagine","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thecodingmachine%2Futils.graphics.mouf-imagine","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thecodingmachine%2Futils.graphics.mouf-imagine/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thecodingmachine%2Futils.graphics.mouf-imagine/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thecodingmachine%2Futils.graphics.mouf-imagine/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/thecodingmachine","download_url":"https://codeload.github.com/thecodingmachine/utils.graphics.mouf-imagine/tar.gz/refs/heads/2.2","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249097861,"owners_count":21212363,"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":[],"created_at":"2024-11-08T11:33:00.800Z","updated_at":"2025-04-15T15:31:04.029Z","avatar_url":"https://github.com/thecodingmachine.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Mouf Imagine\n\nMouf Imagine uses the [imagine/imagine](https://github.com/avalanche123/Imagine) library to create automated image transformations based on images' paths.\n\n\u003e A big thank to [Romain Neutron](https://github.com/romainneutron) for his great work, the quality of this library allowed us to integrate it in our framework with a few lines of code.\n\nThis is a module for the [Mouf PHP framework](http://mouf-php.com). In order to use this module, your code should also use [Splash, the MVC router for Mouf](http://mouf-php.com/packages/mouf/mvc.splash/index.md).\n\n## The concept\n\n\u003ctable style=\"width 100%; text-align: center\"\u003e\n\u003ctr\u003e\n\u003cth colspan=\"3\"\u003eLet's say someone uploaded this image, But you need to display it in a smaller size, and in grayscale\u003c/th\u003e\n\u003c/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003e\n\u003cimg  width=\"300px\"  src=\"doc/img/imagine.jpg\" /\u003e\n\u003c/td\u003e\n\u003ctd style=\"width: 20px;\" align='center'\u003e \u003cfont style=\"font-size: 60px\"\u003e\u0026#x21d2;\u003c/font\u003e \u003c/td\u003e\n\u003ctd\u003e\n\u003cimg width=\"200px\" src=\"doc/img/imagine-preset.jpg\" /\u003e\n\u003c/td\u003e\n\u003c/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003e [WEB_ROOT]/uploads/image.jpg \u003c/td\u003e\n\u003ctd\u003e\u003c/td\u003e\n\u003ctd\u003e [WEB_ROOT]/300x300_black_n_white/image.jpg \u003c/td\u003e\n\u003c/tr\u003e\n\u003c/table\u003e\n\n## How to ?\n\nThis is very simple ! All you have to do is create an instance of the `ImagePresetController` class :\n\n\u003cimg width=\"80%\" src=\"doc/img/simple-instance.png\" /\u003e\n\nIn fact, what this package does for you is : apply a set of imagine filters on the original image, and display the image after saving it in the desired folder. All the rest is done by Imaging filters.\n\n\n## Advanced features\n\nWe will try to get some optimisations in Imagine code (more explicit constructors, etc...) so it will be easier to integrate that library in mouf. Moreover, for advanced image manipulation, please chekout the [utils.graphics.mouf-imagine-addons](https://github.com/thecodingmachine/utils.graphics.mouf-imagine-addons) package that will soon provide helpers and predefined advanced filters around the exising ones.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthecodingmachine%2Futils.graphics.mouf-imagine","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthecodingmachine%2Futils.graphics.mouf-imagine","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthecodingmachine%2Futils.graphics.mouf-imagine/lists"}