Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add PNG output support (Gets around the output size limitation of JPEG format) #4

Open
wants to merge 11 commits into
base: develop
Choose a base branch
from

Conversation

benclarkwood
Copy link

No description provided.

@benclarkwood
Copy link
Author

Note, this only really adds support to carion, but the CLI could be easily wired up too.

@filitchp
Copy link
Contributor

filitchp commented Feb 2, 2017

Running into some intermittent memory crashes in production. Trying a few things and meanwhile holding off on merging PR

@Systerr
Copy link
Contributor

Systerr commented Mar 12, 2017

Hi. Thank you for your pull request. I'm not sure that using "outputFormat (0,1)" is good idea.
What do you thing of pass output formats and that format parameters as nested json?

{
    "input_url": "image-1.jpg",
    "operations": [
        {
            "type": "resize",
            "params": {
                "width": 230,
                "height": 2000,
                "type": "width",
                "interpolation":"cubic",
                "quality": 85,//keep for compatibility (not required)
                "output_url": "image-1-230.jpg",// keep compatibility (not required)
                "output"://new output option for multi format support  (not required)
                   [
                    {url:"image-1-230p.jpg",quality:85, progressive:true,optimize:true},
                    {url:"image-1-230.png",compression:9, strategy:"huffman"},
                    {url:"image-1-230.jp2",quality:85, progressive:true},
                    {url:"image-1-230.webp",quality:85},
                   ]
            }
        }
    ]
}

For carion we can provide a method like

getOutput(String,Buffer);
getOutput(".jpg",Buffer);

or keep one format as additional parameter
What do you think?
@benclarkwood @filitchp

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants