Square cropping from the center, is there an easier way? RESOLVED |
[eluser]Référencement Google[/eluser]
Your way to do it is too complex. Look at this thread: http://ellislab.com/forums/viewthread/73906/ I think the best is to get first the image properties (width and height), you can use something like : Code: // Get the Image properties (this function is not documented in CI manual) Then the next is mathematics, divide by 2 the width and height and add to this the width and height of the desired cropped size. If you don't find, please post some code here. |
Messages In This Thread |
Square cropping from the center, is there an easier way? RESOLVED - by El Forum - 04-02-2008, 03:54 AM
Square cropping from the center, is there an easier way? RESOLVED - by El Forum - 04-02-2008, 04:45 AM
Square cropping from the center, is there an easier way? RESOLVED - by El Forum - 04-02-2008, 06:22 AM
|