Trouble converting png to jpg

I’m new to Lucee. I’ve installed Lucee 4.5.1.022 on Linux and it’s worked
great so far but now I can’t seem get a simple image file conversion to
work.

returns the exception message "Metadata components != number of destination bands".

This works just fine in ACF. Am I not using the cfimage tag correctly in
Lucee?

Hi Michael,

The syntax looks correct, maybe it is the particular PNG image you are
attempting to convert. Have you tried other PNG’s? That error almost reads
like the source file is corrupt somehow.

Kind regards,

Andrew
about.me http://about.me/andrew_dixon - mso http://www.mso.net - Lucee
Association Member http://lucee.orgOn 1 November 2015 at 22:23, Michael Wood <@Michael_Wood> wrote:

I’m new to Lucee. I’ve installed Lucee 4.5.1.022 on Linux and it’s worked
great so far but now I can’t seem get a simple image file conversion to
work.

returns the exception message "Metadata components != number of destination bands".

This works just fine in ACF. Am I not using the cfimage tag correctly in
Lucee?


You received this message because you are subscribed to the Google Groups
“Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an
email to lucee+unsubscribe@googlegroups.com.
To post to this group, send email to lucee@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com
https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.

Hello Andrew and thank you for replying.

I’ve spent a frustrating afternoon trying to sort this out. It seemed
unlikely that this wouldn’t work in Lucee but you never know…

Anyway I’ve taken some new photos and converted them to PNG’s using
Photoshop and the CFImage conversion back to JPG images works on the new
images. Also of note it seems like any editing of the images in photoshop
(cropping, etc) causes this issue.

I have a folder full of “test” images that I’ve collected over time and all
the PNG images fail this conversion. This fooled me. They convert okay on
an Windows based ACF server. But now I’m thinking there may be something
else going on, perhaps OS related.

I’ll keep digging for the actual cause and/or work-around.

Thank you again,

MichaelOn Sunday, November 1, 2015 at 2:28:35 PM UTC-8, Andrew Dixon wrote:

Hi Michael,

The syntax looks correct, maybe it is the particular PNG image you are
attempting to convert. Have you tried other PNG’s? That error almost reads
like the source file is corrupt somehow.

Kind regards,

Andrew
about.me http://about.me/andrew_dixon - mso http://www.mso.net - Lucee
Association Member http://lucee.org

On 1 November 2015 at 22:23, Michael Wood <mw...@stpo.com <javascript:>> wrote:

I’m new to Lucee. I’ve installed Lucee 4.5.1.022 on Linux and it’s worked
great so far but now I can’t seem get a simple image file conversion to
work.

returns the exception message "Metadata components != number of destination bands".

This works just fine in ACF. Am I not using the cfimage tag correctly in
Lucee?


You received this message because you are subscribed to the Google Groups
“Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an
email to lucee+un...@googlegroups.com <javascript:>.
To post to this group, send email to lu...@googlegroups.com <javascript:>
.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com
https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.

@Paul - Do you know if there is a bug logged in the bug tracker for this?

Kind regards,

Andrew
about.me http://about.me/andrew_dixon - mso http://www.mso.net - Lucee
Association Member http://lucee.orgOn 3 November 2015 at 13:16, Paul Klinkenberg <@Paul_Klinkenberg> wrote:

Hi Michael,

This is a known issue, has been around for a long time.
It has to do with the underlying image manipulation jars, Lucee can’t fix
it, unless they start using a different library, for example Imagemagick.
This error, and two more, were enough reason for me and the company I
worked for then, to start using Imagemagick instead of cfimage.

References:

https://www.google.com/search?q=cfimage+Metadata+components+!%3D+number+of+destination+bands
https://www.google.com/search?q=cfimage+Metadata+components+!=+number+of+destination+bands
Possible workaround:
https://issues.jboss.org/browse/RAILO-1849?focusedCommentId=13097442&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-13097442

Even though ImageMagick can take some time to setup and understand, in the
end it is worth it, imho.

Kind regards,

Paul Klinkenberg

Op 2 nov. 2015, om 02:02 heeft Michael Wood <@Michael_Wood> het volgende
geschreven:

Hello Andrew and thank you for replying.

I’ve spent a frustrating afternoon trying to sort this out. It seemed
unlikely that this wouldn’t work in Lucee but you never know…

Anyway I’ve taken some new photos and converted them to PNG’s using
Photoshop and the CFImage conversion back to JPG images works on the new
images. Also of note it seems like any editing of the images in photoshop
(cropping, etc) causes this issue.

I have a folder full of “test” images that I’ve collected over time and
all the PNG images fail this conversion. This fooled me. They convert okay
on an Windows based ACF server. But now I’m thinking there may be something
else going on, perhaps OS related.

I’ll keep digging for the actual cause and/or work-around.

Thank you again,

Michael

On Sunday, November 1, 2015 at 2:28:35 PM UTC-8, Andrew Dixon wrote:

Hi Michael,

The syntax looks correct, maybe it is the particular PNG image you are
attempting to convert. Have you tried other PNG’s? That error almost reads
like the source file is corrupt somehow.

Kind regards,

Andrew
about.me http://about.me/andrew_dixon - mso http://www.mso.net/ - Lucee
Association Member http://lucee.org/

On 1 November 2015 at 22:23, Michael Wood mw...@stpo.com wrote:

I’m new to Lucee. I’ve installed Lucee 4.5.1.022 on Linux and it’s
worked great so far but now I can’t seem get a simple image file conversion
to work.

returns the exception message "Metadata components != number of destination bands".

This works just fine in ACF. Am I not using the cfimage tag correctly in
Lucee?


You received this message because you are subscribed to the Google
Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send
an email to lucee+un...@googlegroups.com.
To post to this group, send email to lu...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com
https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.


You received this message because you are subscribed to the Google Groups
“Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an
email to lucee+unsubscribe@googlegroups.com.
To post to this group, send email to lucee@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/96744aa6-b55d-42a0-acd5-d961796014b8%40googlegroups.com
https://groups.google.com/d/msgid/lucee/96744aa6-b55d-42a0-acd5-d961796014b8%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.


You received this message because you are subscribed to the Google Groups
“Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an
email to lucee+unsubscribe@googlegroups.com.
To post to this group, send email to lucee@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/161BFF1A-8FAE-4E71-B5F9-7DB887F94622%40ongevraagdadvies.nl
https://groups.google.com/d/msgid/lucee/161BFF1A-8FAE-4E71-B5F9-7DB887F94622%40ongevraagdadvies.nl?utm_medium=email&utm_source=footer
.

For more options, visit https://groups.google.com/d/optout.

Hi,

Doesn’t looks like it, so raised:

https://luceeserver.atlassian.net/browse/LDEV-595

@Michael, looks like there is a work around in the comments.

Kind regards,

Andrew
about.me http://about.me/andrew_dixon - mso http://www.mso.net - Lucee
Association Member http://lucee.orgOn 3 November 2015 at 18:40, Paul Klinkenberg <@Paul_Klinkenberg> wrote:

Well… https://issues.jboss.org/browse/RAILO-1849

I don’t know if it has been copied to the Lucee bug tracker.

Op 3 nov. 2015, om 19:32 heeft Andrew Dixon <@Andrew_Dixon> het
volgende geschreven:

@Paul - Do you know if there is a bug logged in the bug tracker for this?

Kind regards,

Andrew
about.me http://about.me/andrew_dixon - mso http://www.mso.net/ - Lucee
Association Member http://lucee.org/

On 3 November 2015 at 13:16, Paul Klinkenberg <@Paul_Klinkenberg> wrote:

Hi Michael,

This is a known issue, has been around for a long time.
It has to do with the underlying image manipulation jars, Lucee can’t fix
it, unless they start using a different library, for example Imagemagick.
This error, and two more, were enough reason for me and the company I
worked for then, to start using Imagemagick instead of cfimage.

References:

https://www.google.com/search?q=cfimage+Metadata+components+!%3D+number+of+destination+bands
https://www.google.com/search?q=cfimage+Metadata+components+!=+number+of+destination+bands
Possible workaround:
https://issues.jboss.org/browse/RAILO-1849?focusedCommentId=13097442&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-13097442

Even though ImageMagick can take some time to setup and understand, in
the end it is worth it, imho.

Kind regards,

Paul Klinkenberg

Op 2 nov. 2015, om 02:02 heeft Michael Wood <@Michael_Wood> het
volgende geschreven:

Hello Andrew and thank you for replying.

I’ve spent a frustrating afternoon trying to sort this out. It seemed
unlikely that this wouldn’t work in Lucee but you never know…

Anyway I’ve taken some new photos and converted them to PNG’s using
Photoshop and the CFImage conversion back to JPG images works on the new
images. Also of note it seems like any editing of the images in photoshop
(cropping, etc) causes this issue.

I have a folder full of “test” images that I’ve collected over time and
all the PNG images fail this conversion. This fooled me. They convert okay
on an Windows based ACF server. But now I’m thinking there may be something
else going on, perhaps OS related.

I’ll keep digging for the actual cause and/or work-around.

Thank you again,

Michael

On Sunday, November 1, 2015 at 2:28:35 PM UTC-8, Andrew Dixon wrote:

Hi Michael,

The syntax looks correct, maybe it is the particular PNG image you are
attempting to convert. Have you tried other PNG’s? That error almost reads
like the source file is corrupt somehow.

Kind regards,

Andrew
about.me http://about.me/andrew_dixon - mso http://www.mso.net/ - Lucee
Association Member http://lucee.org/

On 1 November 2015 at 22:23, Michael Wood mw...@stpo.com wrote:

I’m new to Lucee. I’ve installed Lucee 4.5.1.022 on Linux and it’s
worked great so far but now I can’t seem get a simple image file conversion
to work.

returns the exception message "Metadata components != number of destination bands".

This works just fine in ACF. Am I not using the cfimage tag correctly
in Lucee?


You received this message because you are subscribed to the Google
Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send
an email to lucee+un...@googlegroups.com.
To post to this group, send email to lu...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com
https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.


You received this message because you are subscribed to the Google Groups
“Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an
email to lucee+unsubscribe@googlegroups.com.
To post to this group, send email to lucee@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/96744aa6-b55d-42a0-acd5-d961796014b8%40googlegroups.com
https://groups.google.com/d/msgid/lucee/96744aa6-b55d-42a0-acd5-d961796014b8%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.


You received this message because you are subscribed to the Google Groups
“Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an
email to lucee+unsubscribe@googlegroups.com.
To post to this group, send email to lucee@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/161BFF1A-8FAE-4E71-B5F9-7DB887F94622%40ongevraagdadvies.nl
https://groups.google.com/d/msgid/lucee/161BFF1A-8FAE-4E71-B5F9-7DB887F94622%40ongevraagdadvies.nl?utm_medium=email&utm_source=footer
.

For more options, visit https://groups.google.com/d/optout.


Love Lucee? Become a supporter and be part of the Lucee project today! -
http://lucee.org/supporters/become-a-supporter.html

You received this message because you are subscribed to the Google Groups
“Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an
email to lucee+unsubscribe@googlegroups.com.
To post to this group, send email to lucee@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/CAG1WijWUo26rhNhomyQhirDmdNsgo4tPzuJ4H%2BOWOVQPhxec3g%40mail.gmail.com
https://groups.google.com/d/msgid/lucee/CAG1WijWUo26rhNhomyQhirDmdNsgo4tPzuJ4H%2BOWOVQPhxec3g%40mail.gmail.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.


Love Lucee? Become a supporter and be part of the Lucee project today! -
http://lucee.org/supporters/become-a-supporter.html

You received this message because you are subscribed to the Google Groups
“Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an
email to lucee+unsubscribe@googlegroups.com.
To post to this group, send email to lucee@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/B722F568-4196-4C29-8B1B-823A2A6F0170%40ongevraagdadvies.nl
https://groups.google.com/d/msgid/lucee/B722F568-4196-4C29-8B1B-823A2A6F0170%40ongevraagdadvies.nl?utm_medium=email&utm_source=footer
.

For more options, visit https://groups.google.com/d/optout.

Hi Michael,

This is a known issue, has been around for a long time.
It has to do with the underlying image manipulation jars, Lucee can’t fix it, unless they start using a different library, for example Imagemagick.
This error, and two more, were enough reason for me and the company I worked for then, to start using Imagemagick instead of cfimage.

References:
https://www.google.com/search?q=cfimage+Metadata+components+!%3D+number+of+destination+bands https://www.google.com/search?q=cfimage+Metadata+components+!=+number+of+destination+bands
Possible workaround: https://issues.jboss.org/browse/RAILO-1849?focusedCommentId=13097442&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-13097442 https://issues.jboss.org/browse/RAILO-1849?focusedCommentId=13097442&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-13097442

Even though ImageMagick can take some time to setup and understand, in the end it is worth it, imho.

Kind regards,

Paul KlinkenbergOp 2 nov. 2015, om 02:02 heeft Michael Wood <@Michael_Wood> het volgende geschreven:

Hello Andrew and thank you for replying.

I’ve spent a frustrating afternoon trying to sort this out. It seemed unlikely that this wouldn’t work in Lucee but you never know…

Anyway I’ve taken some new photos and converted them to PNG’s using Photoshop and the CFImage conversion back to JPG images works on the new images. Also of note it seems like any editing of the images in photoshop (cropping, etc) causes this issue.

I have a folder full of “test” images that I’ve collected over time and all the PNG images fail this conversion. This fooled me. They convert okay on an Windows based ACF server. But now I’m thinking there may be something else going on, perhaps OS related.

I’ll keep digging for the actual cause and/or work-around.

Thank you again,

Michael

On Sunday, November 1, 2015 at 2:28:35 PM UTC-8, Andrew Dixon wrote:
Hi Michael,

The syntax looks correct, maybe it is the particular PNG image you are attempting to convert. Have you tried other PNG’s? That error almost reads like the source file is corrupt somehow.

Kind regards,

Andrew
about.me http://about.me/andrew_dixon - mso http://www.mso.net/ - Lucee Association Member http://lucee.org/
On 1 November 2015 at 22:23, Michael Wood <mw...@stpo.com <javascript:>> wrote:
I’m new to Lucee. I’ve installed Lucee 4.5.1.022 on Linux and it’s worked great so far but now I can’t seem get a simple image file conversion to work.

returns the exception message “Metadata components != number of destination bands”.

This works just fine in ACF. Am I not using the cfimage tag correctly in Lucee?


You received this message because you are subscribed to the Google Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an email to lucee+un...@googlegroups.com <javascript:>.
To post to this group, send email to lu...@googlegroups.com <javascript:>.
To view this discussion on the web visit https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com?utm_medium=email&utm_source=footer.
For more options, visit https://groups.google.com/d/optout https://groups.google.com/d/optout.


You received this message because you are subscribed to the Google Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an email to lucee+unsubscribe@googlegroups.com mailto:lucee+unsubscribe@googlegroups.com.
To post to this group, send email to lucee@googlegroups.com mailto:lucee@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/lucee/96744aa6-b55d-42a0-acd5-d961796014b8%40googlegroups.com https://groups.google.com/d/msgid/lucee/96744aa6-b55d-42a0-acd5-d961796014b8%40googlegroups.com?utm_medium=email&utm_source=footer.
For more options, visit https://groups.google.com/d/optout https://groups.google.com/d/optout.

Well… https://issues.jboss.org/browse/RAILO-1849 https://issues.jboss.org/browse/RAILO-1849

I don’t know if it has been copied to the Lucee bug tracker.Op 3 nov. 2015, om 19:32 heeft Andrew Dixon <@Andrew_Dixon> het volgende geschreven:

@Paul - Do you know if there is a bug logged in the bug tracker for this?

Kind regards,

Andrew
about.me http://about.me/andrew_dixon - mso http://www.mso.net/ - Lucee Association Member http://lucee.org/
On 3 November 2015 at 13:16, Paul Klinkenberg <@Paul_Klinkenberg mailto:Paul_Klinkenberg> wrote:
Hi Michael,

This is a known issue, has been around for a long time.
It has to do with the underlying image manipulation jars, Lucee can’t fix it, unless they start using a different library, for example Imagemagick.
This error, and two more, were enough reason for me and the company I worked for then, to start using Imagemagick instead of cfimage.

References:
https://www.google.com/search?q=cfimage+Metadata+components+!%3D+number+of+destination+bands https://www.google.com/search?q=cfimage+Metadata+components+!=+number+of+destination+bands
Possible workaround: https://issues.jboss.org/browse/RAILO-1849?focusedCommentId=13097442&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-13097442 https://issues.jboss.org/browse/RAILO-1849?focusedCommentId=13097442&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-13097442

Even though ImageMagick can take some time to setup and understand, in the end it is worth it, imho.

Kind regards,

Paul Klinkenberg

Op 2 nov. 2015, om 02:02 heeft Michael Wood <@Michael_Wood mailto:Michael_Wood> het volgende geschreven:

Hello Andrew and thank you for replying.

I’ve spent a frustrating afternoon trying to sort this out. It seemed unlikely that this wouldn’t work in Lucee but you never know…

Anyway I’ve taken some new photos and converted them to PNG’s using Photoshop and the CFImage conversion back to JPG images works on the new images. Also of note it seems like any editing of the images in photoshop (cropping, etc) causes this issue.

I have a folder full of “test” images that I’ve collected over time and all the PNG images fail this conversion. This fooled me. They convert okay on an Windows based ACF server. But now I’m thinking there may be something else going on, perhaps OS related.

I’ll keep digging for the actual cause and/or work-around.

Thank you again,

Michael

On Sunday, November 1, 2015 at 2:28:35 PM UTC-8, Andrew Dixon wrote:
Hi Michael,

The syntax looks correct, maybe it is the particular PNG image you are attempting to convert. Have you tried other PNG’s? That error almost reads like the source file is corrupt somehow.

Kind regards,

Andrew
about.me http://about.me/andrew_dixon - mso http://www.mso.net/ - Lucee Association Member http://lucee.org/
On 1 November 2015 at 22:23, Michael Wood <mw...@stpo.com <>> wrote:
I’m new to Lucee. I’ve installed Lucee 4.5.1.022 on Linux and it’s worked great so far but now I can’t seem get a simple image file conversion to work.

returns the exception message “Metadata components != number of destination bands”.

This works just fine in ACF. Am I not using the cfimage tag correctly in Lucee?


You received this message because you are subscribed to the Google Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an email to lucee+un...@googlegroups.com <>.
To post to this group, send email to lu...@googlegroups.com <>.
To view this discussion on the web visit https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com?utm_medium=email&utm_source=footer.
For more options, visit https://groups.google.com/d/optout https://groups.google.com/d/optout.


You received this message because you are subscribed to the Google Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an email to lucee+unsubscribe@googlegroups.com mailto:lucee+unsubscribe@googlegroups.com.
To post to this group, send email to lucee@googlegroups.com mailto:lucee@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/lucee/96744aa6-b55d-42a0-acd5-d961796014b8%40googlegroups.com https://groups.google.com/d/msgid/lucee/96744aa6-b55d-42a0-acd5-d961796014b8%40googlegroups.com?utm_medium=email&utm_source=footer.
For more options, visit https://groups.google.com/d/optout https://groups.google.com/d/optout.


You received this message because you are subscribed to the Google Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an email to lucee+unsubscribe@googlegroups.com mailto:lucee+unsubscribe@googlegroups.com.
To post to this group, send email to lucee@googlegroups.com mailto:lucee@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/lucee/161BFF1A-8FAE-4E71-B5F9-7DB887F94622%40ongevraagdadvies.nl https://groups.google.com/d/msgid/lucee/161BFF1A-8FAE-4E71-B5F9-7DB887F94622%40ongevraagdadvies.nl?utm_medium=email&utm_source=footer.

For more options, visit https://groups.google.com/d/optout https://groups.google.com/d/optout.


Love Lucee? Become a supporter and be part of the Lucee project today! - http://lucee.org/supporters/become-a-supporter.html http://lucee.org/supporters/become-a-supporter.html

You received this message because you are subscribed to the Google Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an email to lucee+unsubscribe@googlegroups.com mailto:lucee+unsubscribe@googlegroups.com.
To post to this group, send email to lucee@googlegroups.com mailto:lucee@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/lucee/CAG1WijWUo26rhNhomyQhirDmdNsgo4tPzuJ4H%2BOWOVQPhxec3g%40mail.gmail.com https://groups.google.com/d/msgid/lucee/CAG1WijWUo26rhNhomyQhirDmdNsgo4tPzuJ4H%2BOWOVQPhxec3g%40mail.gmail.com?utm_medium=email&utm_source=footer.
For more options, visit https://groups.google.com/d/optout https://groups.google.com/d/optout.

Paul, do you have any resources or information about how you work with
imagemagick from lucee? do you call out through cfexecute or use something
like jmagick? something else?On Tuesday, November 3, 2015 at 7:16:41 AM UTC-6, Paul Klinkenberg wrote:

Hi Michael,

This is a known issue, has been around for a long time.
It has to do with the underlying image manipulation jars, Lucee can’t fix
it, unless they start using a different library, for example Imagemagick.
This error, and two more, were enough reason for me and the company I
worked for then, to start using Imagemagick instead of cfimage.

References:

https://www.google.com/search?q=cfimage+Metadata+components+!%3D+number+of+destination+bands
https://www.google.com/search?q=cfimage+Metadata+components+!=+number+of+destination+bands
Possible workaround:
https://issues.jboss.org/browse/RAILO-1849?focusedCommentId=13097442&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-13097442

Even though ImageMagick can take some time to setup and understand, in the
end it is worth it, imho.

Kind regards,

Paul Klinkenberg

Op 2 nov. 2015, om 02:02 heeft Michael Wood <mw...@stpo.com <javascript:>> het volgende geschreven:

Hello Andrew and thank you for replying.

I’ve spent a frustrating afternoon trying to sort this out. It seemed
unlikely that this wouldn’t work in Lucee but you never know…

Anyway I’ve taken some new photos and converted them to PNG’s using
Photoshop and the CFImage conversion back to JPG images works on the new
images. Also of note it seems like any editing of the images in photoshop
(cropping, etc) causes this issue.

I have a folder full of “test” images that I’ve collected over time and
all the PNG images fail this conversion. This fooled me. They convert okay
on an Windows based ACF server. But now I’m thinking there may be something
else going on, perhaps OS related.

I’ll keep digging for the actual cause and/or work-around.

Thank you again,

Michael

On Sunday, November 1, 2015 at 2:28:35 PM UTC-8, Andrew Dixon wrote:

Hi Michael,

The syntax looks correct, maybe it is the particular PNG image you are
attempting to convert. Have you tried other PNG’s? That error almost reads
like the source file is corrupt somehow.

Kind regards,

Andrew
about.me http://about.me/andrew_dixon - mso http://www.mso.net/ - Lucee
Association Member http://lucee.org/

On 1 November 2015 at 22:23, Michael Wood mw...@stpo.com wrote:

I’m new to Lucee. I’ve installed Lucee 4.5.1.022 on Linux and it’s
worked great so far but now I can’t seem get a simple image file conversion
to work.

returns the exception message "Metadata components != number of destination bands".

This works just fine in ACF. Am I not using the cfimage tag correctly in
Lucee?


You received this message because you are subscribed to the Google
Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send
an email to lucee+un...@googlegroups.com.
To post to this group, send email to lu...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com
https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.


You received this message because you are subscribed to the Google Groups
“Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an
email to lucee+un...@googlegroups.com <javascript:>.
To post to this group, send email to lu...@googlegroups.com <javascript:>.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/96744aa6-b55d-42a0-acd5-d961796014b8%40googlegroups.com
https://groups.google.com/d/msgid/lucee/96744aa6-b55d-42a0-acd5-d961796014b8%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.

Hi Ryan,

I used im4java: http://im4java.sourceforge.net/ http://im4java.sourceforge.net/
Here is a snippet of code on how to use it.

Kind regards, Paul Klinkenberg
var convertCmd = createObject(“java”, “org.im4java.core.ConvertCmd”).init();
/* search path: where imagemagick is located (on linux, it can usually be found in path) */
convertCmd.setSearchPath(“C:\ImageMagick-6.7.9-Q16”);

var operation = createObject(“java”, “org.im4java.core.IMOperation”).init();
operation.addImage([arguments.image]);

operation.colorspace(“RGB”);

/* for JPG, add the quality /
if (newExt eq “jpg”)
{
var quality = structKeyExists(arguments, “quality”) ? arguments.quality : “”;
if (not isNumeric(quality) or quality eq 0)
{
quality = variables.defaultJPGQuality;
} else if (quality lt 1)
{
quality = quality
100;
}
operation.quality(javaCast(‘java.lang.Double’, quality));
}

// Support for a transparency fillcolor
if (structKeyExists(size, “background”))
{
operation.background(size.background);
operation.flatten();
}

/* rotation? */
if (doRotate)
{
operation.rotate(toString(size.rotation));
}

/* crop? /
if (doCrop)
{
operation.crop(arguments.width, arguments.height, 0, 0);
/
resize /
} else {
operation.resize(JavaCast(‘int’, arguments.width), javaCast(‘int’, arguments.height));
}
/
grayscale ? */
if (structKeyExists(arguments, “grayscale”) and arguments.grayscale eq true)
{
operation.colorspace(“gray”);
} else
{
operation.colorspace(“sRGB”);
}

// save the new file to a temp location
var tempImagePath = getTempDirectory() & createUUID() & “.#newExt#”;
operation.addImage([tempImagePath]);

convertCmd.run(operation, );

return tempImagePath;Op 4 nov. 2015, om 17:53 heeft Ryan Guill <@Ryan_Guill> het volgende geschreven:

Paul, do you have any resources or information about how you work with imagemagick from lucee? do you call out through cfexecute or use something like jmagick? something else?

On Tuesday, November 3, 2015 at 7:16:41 AM UTC-6, Paul Klinkenberg wrote:
Hi Michael,

This is a known issue, has been around for a long time.
It has to do with the underlying image manipulation jars, Lucee can’t fix it, unless they start using a different library, for example Imagemagick.
This error, and two more, were enough reason for me and the company I worked for then, to start using Imagemagick instead of cfimage.

References:
https://www.google.com/search?q=cfimage+Metadata+components+!%3D+number+of+destination+bands https://www.google.com/search?q=cfimage+Metadata+components+!=+number+of+destination+bands
Possible workaround: https://issues.jboss.org/browse/RAILO-1849?focusedCommentId=13097442&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-13097442 https://issues.jboss.org/browse/RAILO-1849?focusedCommentId=13097442&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-13097442

Even though ImageMagick can take some time to setup and understand, in the end it is worth it, imho.

Kind regards,

Paul Klinkenberg

Op 2 nov. 2015, om 02:02 heeft Michael Wood <mw…@ <>stpo.com http://stpo.com/> het volgende geschreven:

Hello Andrew and thank you for replying.

I’ve spent a frustrating afternoon trying to sort this out. It seemed unlikely that this wouldn’t work in Lucee but you never know…

Anyway I’ve taken some new photos and converted them to PNG’s using Photoshop and the CFImage conversion back to JPG images works on the new images. Also of note it seems like any editing of the images in photoshop (cropping, etc) causes this issue.

I have a folder full of “test” images that I’ve collected over time and all the PNG images fail this conversion. This fooled me. They convert okay on an Windows based ACF server. But now I’m thinking there may be something else going on, perhaps OS related.

I’ll keep digging for the actual cause and/or work-around.

Thank you again,

Michael

On Sunday, November 1, 2015 at 2:28:35 PM UTC-8, Andrew Dixon wrote:
Hi Michael,

The syntax looks correct, maybe it is the particular PNG image you are attempting to convert. Have you tried other PNG’s? That error almost reads like the source file is corrupt somehow.

Kind regards,

Andrew
about.me http://about.me/andrew_dixon - mso http://www.mso.net/ - Lucee Association Member http://lucee.org/
On 1 November 2015 at 22:23, Michael Wood <mw…@ <>stpo.com http://stpo.com/> wrote:
I’m new to Lucee. I’ve installed Lucee 4.5.1.022 on Linux and it’s worked great so far but now I can’t seem get a simple image file conversion to work.

returns the exception message “Metadata components != number of destination bands”.

This works just fine in ACF. Am I not using the cfimage tag correctly in Lucee?


You received this message because you are subscribed to the Google Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an email to lucee+un…@ <>googlegroups.com http://googlegroups.com/.
To post to this group, send email to lu…@ <>googlegroups.com http://googlegroups.com/.
To view this discussion on the web visit https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com?utm_medium=email&utm_source=footer.
For more options, visit https://groups.google.com/d/optout https://groups.google.com/d/optout.


You received this message because you are subscribed to the Google Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an email to lucee+un…@ <>googlegroups.com http://googlegroups.com/.
To post to this group, send email to lu…@ <>googlegroups.com http://googlegroups.com/.
To view this discussion on the web visit https://groups.google.com/d/msgid/lucee/96744aa6-b55d-42a0-acd5-d961796014b8%40googlegroups.com https://groups.google.com/d/msgid/lucee/96744aa6-b55d-42a0-acd5-d961796014b8%40googlegroups.com?utm_medium=email&utm_source=footer.
For more options, visit https://groups.google.com/d/optout https://groups.google.com/d/optout.


Love Lucee? Become a supporter and be part of the Lucee project today! - http://lucee.org/supporters/become-a-supporter.html http://lucee.org/supporters/become-a-supporter.html

You received this message because you are subscribed to the Google Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an email to lucee+unsubscribe@googlegroups.com mailto:lucee+unsubscribe@googlegroups.com.
To post to this group, send email to lucee@googlegroups.com mailto:lucee@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/lucee/697cb33a-4dd6-44b6-83c4-ded250b587a2%40googlegroups.com https://groups.google.com/d/msgid/lucee/697cb33a-4dd6-44b6-83c4-ded250b587a2%40googlegroups.com?utm_medium=email&utm_source=footer.
For more options, visit https://groups.google.com/d/optout https://groups.google.com/d/optout.

To be honest I would just use something like http://cloudinary.com/
instead. Much easier.

Mark Drew

develop • deploy • deliver
http://cmdhq.io
+44 7971 852296> On Dec 15, 2016, at 4:52 PM, <@onlinebase.nl> wrote:

Hi Paul, isn’t it possible to add other image-manipulation JAR’s to Lucee, like if this fails, please use the other one? Sebastiaan

Op dinsdag 3 november 2015 14:16:41 UTC+1 schreef Paul Klinkenberg:> Hi Michael,

This is a known issue, has been around for a long time.
It has to do with the underlying image manipulation jars, Lucee can’t fix it, unless they start using a different library, for example Imagemagick.
This error, and two more, were enough reason for me and the company I worked for then, to start using Imagemagick instead of cfimage.

References:
https://www.google.com/search?q=cfimage+Metadata+components+!%3D+number+of+destination+bands

Possible workaround: https://issues.jboss.org/browse/RAILO-1849?focusedCommentId=13097442&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-13097442

Even though ImageMagick can take some time to setup and understand, in the end it is worth it, imho.

Kind regards,

Paul Klinkenberg

Op 2 nov. 2015, om 02:02 heeft Michael Wood <mw...@stpo.com het volgende geschreven:

Hello Andrew and thank you for replying.

I’ve spent a frustrating afternoon trying to sort this out. It seemed unlikely that this wouldn’t work in Lucee but you never know…

Anyway I’ve taken some new photos and converted them to PNG’s using Photoshop and the CFImage conversion back to JPG images works on the new images. Also of note it seems like any editing of the images in photoshop (cropping, etc) causes this issue.

I have a folder full of “test” images that I’ve collected over time and all the PNG images fail this conversion. This fooled me. They convert okay on an Windows based ACF server. But now I’m thinking there may be something else going on, perhaps OS related.

I’ll keep digging for the actual cause and/or work-around.

Thank you again,

Michael

On Sunday, November 1, 2015 at 2:28:35 PM UTC-8, Andrew Dixon wrote:> Hi Michael,

The syntax looks correct, maybe it is the particular PNG image you are attempting to convert. Have you tried other PNG’s? That error almost reads like the source file is corrupt somehow.

Kind regards,

Andrew
about.me

  • mso
  • Lucee Association Member

On 1 November 2015 at 22:23, Michael Wood <mw...@stpo.com wrote:

I’m new to Lucee. I’ve installed Lucee 4.5.1.022 on Linux and it’s worked great so far but now I can’t seem get a simple image file conversion to work.

returns the exception message “Metadata components != number of destination bands”.

This works just fine in ACF. Am I not using the cfimage tag correctly in Lucee?


You received this message because you are subscribed to the Google Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an email to lucee+un...@googlegroups.com
.
To post to this group, send email to lu...@googlegroups.com
.
To view this discussion on the web visit https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com

.
For more options, visit https://groups.google.com/d/optout

.


You received this message because you are subscribed to the Google Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an email to lucee+un...@googlegroups.com

.
To post to this group, send email to lu...@googlegroups.com
.
To view this discussion on the web visit https://groups.google.com/d/msgid/lucee/96744aa6-b55d-42a0-acd5-d961796014b8%40googlegroups.com

.
For more options, visit https://groups.google.com/d/optout

.


You received this message because you are subscribed to the Google Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an email to lucee+unsubscribe@googlegroups.com
.
To post to this group, send email to lucee@googlegroups.com
.
To view this discussion on the web visit https://groups.google.com/d/msgid/lucee/1292e616-c8ae-42d1-a6eb-d27fec76f40f%40googlegroups.com
.
For more options, visit https://groups.google.com/d/optout
.

@Mark - how is that a solution to a simple cfimage convert functionality?
Here the issue is a user that can upload his/her picture of any said format
(JPG, JPEG, GIF, PNG) and then we convert it to a JPG for them so it fits
into our system. All’s well until a PNG is uploaded. Should’t that be fixed
then?Op donderdag 15 december 2016 17:57:10 UTC+1 schreef Mark Drew:

To be honest I would just use something like http://cloudinary.com/ instead.
Much easier.

Mark Drew

develop • deploy • deliver

http://cmdhq.io
+44 7971 852296

On Dec 15, 2016, at 4:52 PM, <online...@gmail.com <javascript:>> wrote:

Hi Paul, isn’t it possible to add other image-manipulation JAR’s to Lucee,
like if this fails, please use the other one? Sebastiaan

Op dinsdag 3 november 2015 14:16:41 UTC+1 schreef Paul Klinkenberg:

Hi Michael,

This is a known issue, has been around for a long time.
It has to do with the underlying image manipulation jars, Lucee can’t fix
it, unless they start using a different library, for example Imagemagick.
This error, and two more, were enough reason for me and the company I
worked for then, to start using Imagemagick instead of cfimage.

References:

https://www.google.com/search?q=cfimage+Metadata+components+!%3D+number+of+destination+bands
https://www.google.com/search?q=cfimage+Metadata+components+!=+number+of+destination+bands
Possible workaround:
https://issues.jboss.org/browse/RAILO-1849?focusedCommentId=13097442&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-13097442

Even though ImageMagick can take some time to setup and understand, in
the end it is worth it, imho.

Kind regards,

Paul Klinkenberg

Op 2 nov. 2015, om 02:02 heeft Michael Wood mw...@stpo.com het
volgende geschreven:

Hello Andrew and thank you for replying.

I’ve spent a frustrating afternoon trying to sort this out. It seemed
unlikely that this wouldn’t work in Lucee but you never know…

Anyway I’ve taken some new photos and converted them to PNG’s using
Photoshop and the CFImage conversion back to JPG images works on the new
images. Also of note it seems like any editing of the images in photoshop
(cropping, etc) causes this issue.

I have a folder full of “test” images that I’ve collected over time and
all the PNG images fail this conversion. This fooled me. They convert okay
on an Windows based ACF server. But now I’m thinking there may be something
else going on, perhaps OS related.

I’ll keep digging for the actual cause and/or work-around.

Thank you again,

Michael

On Sunday, November 1, 2015 at 2:28:35 PM UTC-8, Andrew Dixon wrote:

Hi Michael,

The syntax looks correct, maybe it is the particular PNG image you are
attempting to convert. Have you tried other PNG’s? That error almost reads
like the source file is corrupt somehow.

Kind regards,

Andrew
about.me http://about.me/andrew_dixon - mso http://www.mso.net/ - Lucee
Association Member http://lucee.org/

On 1 November 2015 at 22:23, Michael Wood mw...@stpo.comwrote:

I’m new to Lucee. I’ve installed Lucee 4.5.1.022 on Linux and it’s
worked great so far but now I can’t seem get a simple image file conversion
to work.

returns the exception message "Metadata components != number of destination bands".

This works just fine in ACF. Am I not using the cfimage tag correctly
in Lucee?


You received this message because you are subscribed to the Google
Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send
an email to lucee+un...@googlegroups.com.
To post to this group, send email to lu...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com
https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.


You received this message because you are subscribed to the Google Groups
“Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an
email to lucee+un...@googlegroups.com.
To post to this group, send email to lu...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/96744aa6-b55d-42a0-acd5-d961796014b8%40googlegroups.com
https://groups.google.com/d/msgid/lucee/96744aa6-b55d-42a0-acd5-d961796014b8%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.


You received this message because you are subscribed to the Google Groups
“Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an
email to lucee+un...@googlegroups.com <javascript:>.
To post to this group, send email to lu...@googlegroups.com <javascript:>.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/1292e616-c8ae-42d1-a6eb-d27fec76f40f%40googlegroups.com
https://groups.google.com/d/msgid/lucee/1292e616-c8ae-42d1-a6eb-d27fec76f40f%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.

BTW, I’m on Windows 10, same error on Windows Server machines. If this is a
Java library issue, how to program around this without resorting to other
Java-libs. Want to stay as standard as possible for this customer. All
extras are troublesome ;-)Op donderdag 15 december 2016 17:48:36 UTC+1 schreef online...@gmail.com:

Hi all, I’m on Lucee 5.x (latest stable build) and am getting this error:

https://luceeserver.atlassian.net/browse/LDEV-392 (CFIMAGE results in out
of bands with PNG files)

Anyone @Lucee have an update on why this is happening and why this bug
hasn’t been fixed yet?

Hope to hear from @Lucee on this.

Thnx.

Sebastiaan

Op zondag 1 november 2015 23:23:25 UTC+1 schreef Michael Wood:

I’m new to Lucee. I’ve installed Lucee 4.5.1.022 on Linux and it’s worked
great so far but now I can’t seem get a simple image file conversion to
work.

returns the exception message "Metadata components != number of destination bands".

This works just fine in ACF. Am I not using the cfimage tag correctly in
Lucee?

Hi all, I’m on Lucee 5.x (latest stable build) and am getting this error:

https://luceeserver.atlassian.net/browse/LDEV-392 (CFIMAGE results in out
of bands with PNG files)

Anyone @Lucee have an update on why this is happening and why this bug
hasn’t been fixed yet?

Hope to hear from @Lucee on this.

Thnx.

SebastiaanOp zondag 1 november 2015 23:23:25 UTC+1 schreef Michael Wood:

I’m new to Lucee. I’ve installed Lucee 4.5.1.022 on Linux and it’s worked
great so far but now I can’t seem get a simple image file conversion to
work.

returns the exception message "Metadata components != number of destination bands".

This works just fine in ACF. Am I not using the cfimage tag correctly in
Lucee?

Hi Paul, isn’t it possible to add other image-manipulation JAR’s to Lucee,
like if this fails, please use the other one? SebastiaanOp dinsdag 3 november 2015 14:16:41 UTC+1 schreef Paul Klinkenberg:

Hi Michael,

This is a known issue, has been around for a long time.
It has to do with the underlying image manipulation jars, Lucee can’t fix
it, unless they start using a different library, for example Imagemagick.
This error, and two more, were enough reason for me and the company I
worked for then, to start using Imagemagick instead of cfimage.

References:

https://www.google.com/search?q=cfimage+Metadata+components+!%3D+number+of+destination+bands
https://www.google.com/search?q=cfimage+Metadata+components+!=+number+of+destination+bands
Possible workaround:
https://issues.jboss.org/browse/RAILO-1849?focusedCommentId=13097442&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-13097442

Even though ImageMagick can take some time to setup and understand, in the
end it is worth it, imho.

Kind regards,

Paul Klinkenberg

Op 2 nov. 2015, om 02:02 heeft Michael Wood <mw...@stpo.com <javascript:>> het volgende geschreven:

Hello Andrew and thank you for replying.

I’ve spent a frustrating afternoon trying to sort this out. It seemed
unlikely that this wouldn’t work in Lucee but you never know…

Anyway I’ve taken some new photos and converted them to PNG’s using
Photoshop and the CFImage conversion back to JPG images works on the new
images. Also of note it seems like any editing of the images in photoshop
(cropping, etc) causes this issue.

I have a folder full of “test” images that I’ve collected over time and
all the PNG images fail this conversion. This fooled me. They convert okay
on an Windows based ACF server. But now I’m thinking there may be something
else going on, perhaps OS related.

I’ll keep digging for the actual cause and/or work-around.

Thank you again,

Michael

On Sunday, November 1, 2015 at 2:28:35 PM UTC-8, Andrew Dixon wrote:

Hi Michael,

The syntax looks correct, maybe it is the particular PNG image you are
attempting to convert. Have you tried other PNG’s? That error almost reads
like the source file is corrupt somehow.

Kind regards,

Andrew
about.me http://about.me/andrew_dixon - mso http://www.mso.net/ - Lucee
Association Member http://lucee.org/

On 1 November 2015 at 22:23, Michael Wood mw...@stpo.com wrote:

I’m new to Lucee. I’ve installed Lucee 4.5.1.022 on Linux and it’s
worked great so far but now I can’t seem get a simple image file conversion
to work.

returns the exception message "Metadata components != number of destination bands".

This works just fine in ACF. Am I not using the cfimage tag correctly in
Lucee?


You received this message because you are subscribed to the Google
Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send
an email to lucee+un...@googlegroups.com.
To post to this group, send email to lu...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com
https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.


You received this message because you are subscribed to the Google Groups
“Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an
email to lucee+un...@googlegroups.com <javascript:>.
To post to this group, send email to lu...@googlegroups.com <javascript:>.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/96744aa6-b55d-42a0-acd5-d961796014b8%40googlegroups.com
https://groups.google.com/d/msgid/lucee/96744aa6-b55d-42a0-acd5-d961796014b8%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.

I guess that new issue doubles for this
one: https://luceeserver.atlassian.net/browse/LDEV-392Op dinsdag 3 november 2015 19:51:48 UTC+1 schreef Andrew Dixon:

Hi,

Doesn’t looks like it, so raised:

https://luceeserver.atlassian.net/browse/LDEV-595

@Michael, looks like there is a work around in the comments.

Kind regards,

Andrew
about.me http://about.me/andrew_dixon - mso http://www.mso.net - Lucee
Association Member http://lucee.org

On 3 November 2015 at 18:40, Paul Klinkenberg <pa…@ongevraagdadvies.nl <javascript:>> wrote:

Well… https://issues.jboss.org/browse/RAILO-1849

I don’t know if it has been copied to the Lucee bug tracker.

Op 3 nov. 2015, om 19:32 heeft Andrew Dixon <andrew...@gmail.com <javascript:>> het volgende geschreven:

@Paul - Do you know if there is a bug logged in the bug tracker for this?

Kind regards,

Andrew
about.me http://about.me/andrew_dixon - mso http://www.mso.net/ - Lucee
Association Member http://lucee.org/

On 3 November 2015 at 13:16, Paul Klinkenberg <pa…@ongevraagdadvies.nl <javascript:>> wrote:

Hi Michael,

This is a known issue, has been around for a long time.
It has to do with the underlying image manipulation jars, Lucee can’t
fix it, unless they start using a different library, for example
Imagemagick.
This error, and two more, were enough reason for me and the company I
worked for then, to start using Imagemagick instead of cfimage.

References:

https://www.google.com/search?q=cfimage+Metadata+components+!%3D+number+of+destination+bands
https://www.google.com/search?q=cfimage+Metadata+components+!=+number+of+destination+bands
Possible workaround:
https://issues.jboss.org/browse/RAILO-1849?focusedCommentId=13097442&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-13097442

Even though ImageMagick can take some time to setup and understand, in
the end it is worth it, imho.

Kind regards,

Paul Klinkenberg

Op 2 nov. 2015, om 02:02 heeft Michael Wood <mw...@stpo.com <javascript:>> het volgende geschreven:

Hello Andrew and thank you for replying.

I’ve spent a frustrating afternoon trying to sort this out. It seemed
unlikely that this wouldn’t work in Lucee but you never know…

Anyway I’ve taken some new photos and converted them to PNG’s using
Photoshop and the CFImage conversion back to JPG images works on the new
images. Also of note it seems like any editing of the images in photoshop
(cropping, etc) causes this issue.

I have a folder full of “test” images that I’ve collected over time and
all the PNG images fail this conversion. This fooled me. They convert okay
on an Windows based ACF server. But now I’m thinking there may be something
else going on, perhaps OS related.

I’ll keep digging for the actual cause and/or work-around.

Thank you again,

Michael

On Sunday, November 1, 2015 at 2:28:35 PM UTC-8, Andrew Dixon wrote:

Hi Michael,

The syntax looks correct, maybe it is the particular PNG image you are
attempting to convert. Have you tried other PNG’s? That error almost reads
like the source file is corrupt somehow.

Kind regards,

Andrew
about.me http://about.me/andrew_dixon - mso http://www.mso.net/ - Lucee
Association Member http://lucee.org/

On 1 November 2015 at 22:23, Michael Wood mw...@stpo.com wrote:

I’m new to Lucee. I’ve installed Lucee 4.5.1.022 on Linux and it’s
worked great so far but now I can’t seem get a simple image file conversion
to work.

returns the exception message “Metadata
components != number of destination bands”.

This works just fine in ACF. Am I not using the cfimage tag correctly
in Lucee?


You received this message because you are subscribed to the Google
Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send
an email to lucee+un...@googlegroups.com.
To post to this group, send email to lu...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com
https://groups.google.com/d/msgid/lucee/7b298e4c-e079-4059-9264-1cda8a03ac13%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.


You received this message because you are subscribed to the Google
Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send
an email to lucee+un...@googlegroups.com <javascript:>.
To post to this group, send email to lu...@googlegroups.com
<javascript:>.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/96744aa6-b55d-42a0-acd5-d961796014b8%40googlegroups.com
https://groups.google.com/d/msgid/lucee/96744aa6-b55d-42a0-acd5-d961796014b8%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.


You received this message because you are subscribed to the Google
Groups “Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send
an email to lucee+un...@googlegroups.com <javascript:>.
To post to this group, send email to lu...@googlegroups.com
<javascript:>.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/161BFF1A-8FAE-4E71-B5F9-7DB887F94622%40ongevraagdadvies.nl
https://groups.google.com/d/msgid/lucee/161BFF1A-8FAE-4E71-B5F9-7DB887F94622%40ongevraagdadvies.nl?utm_medium=email&utm_source=footer
.

For more options, visit https://groups.google.com/d/optout.


Love Lucee? Become a supporter and be part of the Lucee project today! -
http://lucee.org/supporters/become-a-supporter.html

You received this message because you are subscribed to the Google Groups
“Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an
email to lucee+un...@googlegroups.com <javascript:>.
To post to this group, send email to lu...@googlegroups.com <javascript:>
.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/CAG1WijWUo26rhNhomyQhirDmdNsgo4tPzuJ4H%2BOWOVQPhxec3g%40mail.gmail.com
https://groups.google.com/d/msgid/lucee/CAG1WijWUo26rhNhomyQhirDmdNsgo4tPzuJ4H%2BOWOVQPhxec3g%40mail.gmail.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.


Love Lucee? Become a supporter and be part of the Lucee project today! -
http://lucee.org/supporters/become-a-supporter.html

You received this message because you are subscribed to the Google Groups
“Lucee” group.
To unsubscribe from this group and stop receiving emails from it, send an
email to lucee+un...@googlegroups.com <javascript:>.
To post to this group, send email to lu...@googlegroups.com <javascript:>
.
To view this discussion on the web visit
https://groups.google.com/d/msgid/lucee/B722F568-4196-4C29-8B1B-823A2A6F0170%40ongevraagdadvies.nl
https://groups.google.com/d/msgid/lucee/B722F568-4196-4C29-8B1B-823A2A6F0170%40ongevraagdadvies.nl?utm_medium=email&utm_source=footer
.

For more options, visit https://groups.google.com/d/optout.

Yes it should be fixed, of course.

I think Mark’s suggestion is that services like Cloudinary are a workaround
to the problem and offer much more in terms of capabilities than cfimage
does - perhaps leading to enhanced capabilities for your own site and your
own users.

That said, I convert everything to PNG in my applications and then run them
through the TinyPNG API for both scaling and for minimizing the file size -
but then I do a lot of responsive work for mobile and want the smallest
possible files to conserve bandwidth :slight_smile:

I haven’t used Cloudinary myself, but Sean Daniels has a Gist of an API
wrapper for it (https://gist.github.com/sjdaniels/a31bbd9192cd28e48fcf).
and if you want to use TinyPNG (also supports JPEG fwiw), I have an API
wrapper for that (https://github.com/ddspringle/TinyPngCFML)

HTH

– DennyOn Thursday, December 15, 2016 at 12:04:44 PM UTC-5, online...@gmail.com wrote:

@Mark - how is that a solution to a simple cfimage convert functionality?
Here the issue is a user that can upload his/her picture of any said format
(JPG, JPEG, GIF, PNG) and then we convert it to a JPG for them so it fits
into our system. All’s well until a PNG is uploaded. Should’t that be fixed
then?

Op donderdag 15 december 2016 17:57:10 UTC+1 schreef Mark Drew:

To be honest I would just use something like http://cloudinary.com/
http://www.google.com/url?q=http%3A%2F%2Fcloudinary.com%2F&sa=D&sntz=1&usg=AFQjCNHLAvhnIJtUaugw_qr7BjeGwiYwaQ instead.
Much easier.

Mark Drew

I think Mark’s suggestion is that services like Cloudinary are a
workaround to the problem and offer much more in terms of capabilities than
cfimage does - perhaps leading to enhanced capabilities for your own site
and your own users.

Until that service is offline or does not exist anymore.On Fri, Dec 16, 2016 at 3:34 PM, Denard Springle <@Denard_Springle> wrote:

I think Mark’s suggestion is that services like Cloudinary are a
workaround to the problem and offer much more in terms of capabilities than
cfimage does - perhaps leading to enhanced capabilities for your own site
and your own users.

Until that service is offline or does not exist anymore.

In which case there will be 13 other ones to replace it and you’re
guaranteed more days of employment. Nothing lasts forever, but not
embracing the technology that does exist because it might some day
disappear doesn’t make much sense either. Especially and if only as a
temporary workaround to a problem that is customer affecting in the now as
a fallback to cfimage. That said, I don’t know enough about Cloudinary to
speak to its reliability or longevity… but hey, it’s got cloud in the
name… that’s something :stuck_out_tongue:

– DennyOn Friday, December 16, 2016 at 10:49:04 PM UTC-5, jmoniatte wrote:

On Fri, Dec 16, 2016 at 3:34 PM, Denard Springle <denard....@gmail.com <javascript:>> wrote:

I’ve found this error message is caused by PNGs which have an alpha channel, so they need to be flattened before conversion.

You can test this easily if you have ImageMagick locally (use -alpha on to create a failing example):

$ file in.png
in.png: PNG image data, 590 x 812, 8-bit/color RGBA, non-interlaced
$ convert in.png -alpha off out.png
$ file out.png
out.png: PNG image data, 590 x 812, 8-bit/color RGB, non-interlaced

The CFML code I’m using to implement this before imageWrite is:

<!--- if the PNG has an alpha channel, flatten it before conversion to JPG --->
<cfif image.colormodel.alpha_channel_support>
    <!--- https://stackoverflow.com/a/35026166 --->
    <cfset flat = imageNew("", image.Width, image.Height, "rgb", "white")>
    <cfset imagePaste(flat, image, 0, 0)>
    <cfset image = flat>
</cfif>
1 Like

This just saved me! Thanks @pm554

I’m not sure of the default behavior in ACF, probably just flattens the image with a white canvas, but this should be the behavior in Lucee - flatten the image with a white background before converting an image with an alpha channel to a format that doesn’t support alpha channel. Maybe add a new param to ImageWrite to set the canvas color.

Regardless, the error message is not useful and should be clarified.