Skip navigation
Currently Being Moderated

How to auto crop an image?

Jul 20, 2012 2:13 PM

How do you auto crop an uploaded image?  I see that there are workflow steps and it seems there might be a couple that can create new assets, but where is the documentation for that? 

 

Also, how do you set the auto crop aspect ratio for the html4image widget?

 
Replies
  • Currently Being Moderated
    Jul 22, 2012 9:19 PM   in reply to stewa52

    You can see example at the existing image component by adding more aspect ratios using the "cropConfig" node. Please reference one under - "/libs/cq/packaging/components/pack/definition/dialog/items/tabs/item s/tab3/cropConfig". In this manner, you can add in more option and specify the required height/width.

     

    AspectRatio.png

     
    |
    Mark as:
  • Currently Being Moderated
    Jul 23, 2012 6:14 PM   in reply to stewa52

    I think you can modify the workflow model to apply aspect ratio & some custamization to apply later. I will do little research to see if it exists in cq 5.5 & to confirm if it is lacking documentation for this feature.

     
    |
    Mark as:
  • Currently Being Moderated
    Jul 26, 2012 2:28 AM   in reply to stewa52

    Creating a different renditions (or different size images) at the time of uploading dam asset can be achieved by modifying the

    existing DAM workflow.

    Follow the given steps to modify DAM workflow.

    1. Go to workflow console

           http://localhost:4502/libs/cq/workflow/content/console.html

    1. Go to Models Tab
    2. Find "DAM Update Asset" workflow and edit the workflow It will take you to the detailed page.
    3. Find "Thumbnail creation" process step, Double click on it
    4. A dialog will open; Go to Second Tab (Process). There you will find "Arguments" for aspect ratios of images
    5. Here you can specify Aspect Ratio at which you want to auto crop the dam assest while uploading.
    6. Click Save.

     

    These steps are same for both the CQ version 5.4 and 5.5              .

     

    Thanks

    Brijesh

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points