Generate smartcrop renditions using Java | Community
Skip to main content
akshayrathnavas
Level 1
July 4, 2023
Solved

Generate smartcrop renditions using Java

  • July 4, 2023
  • 1 reply
  • 923 views

Is there any Java API or endpoint to generate smartcrop rendition of a given width and height (this is alraedy defined in the smartcrop presets)?

 

So far, I have tried exploring the com.scene7.isapi package but to no avail.

 

Can anyone guide me in the right direction to acheive this if any?

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by EstebanBustamante

To address the requirement of using SmartCrop renditions in your custom component, you can refer to the Image Core component V3. It provides pre-defined renditions that you can choose from. Instead of creating a completely custom component, consider integrating or embedding the ImageCore component within your own component.

 

I hope this helps.

 

 

1 reply

EstebanBustamante
Community Advisor and Adobe Champion
Community Advisor and Adobe Champion
July 5, 2023

Sorry, I am not aware of such API. Can you describe your use case for this? I don't understand why you would want to create Smartcrop Profiles via Java code, if you are planning to keep them in your code, you can do that without Java, simply, once generated, you sync the output of the configurations in your code base. 

Esteban Bustamante
akshayrathnavas
Level 1
July 6, 2023

Thank you for the reply Esteban.

 

I do not want to create the smartcrop profile via Java code, but rather the smartcrop renditions should be generated via the java code (instead of applying a profile to a folder in Assets).

 

I have a custom components which takes image as inputs. I would like to provide a smartcrop dimension option in the dialog (which is predefined) and the smartcrop should be processed for that image after its provided.

 

Is this possible, or any other way that I can deal with this?

EstebanBustamante
Community Advisor and Adobe Champion
EstebanBustamanteCommunity Advisor and Adobe ChampionAccepted solution
Community Advisor and Adobe Champion
July 6, 2023

To address the requirement of using SmartCrop renditions in your custom component, you can refer to the Image Core component V3. It provides pre-defined renditions that you can choose from. Instead of creating a completely custom component, consider integrating or embedding the ImageCore component within your own component.

 

I hope this helps.

 

 

Esteban Bustamante