[Image Utils Mobile] resize doesn't work in IOS
Forge component by Harlin Setiadarma
Published on 06 Nov 2019


I building a mobile application that capture picture using the camera, but I need to reduce the image size before sending to server. 

The resize doesn't work, when I try to debug using a break point in resize action, the debugger execution point vanish!

Tried to apply the  MegaPixImage script but still doesn't work.

there is a way to debug the java script ?

Hi João Cardoso, 

Did you test it under IOS?

I used it on every mobile app I built and tested it ok under Android. (I don't have any IOS devices) 

If you test it under IOS, try to set gradualResize property to False.

Open Image Utils Mobile espace, then Resize action.
Then click on JS_Resize, then change gradualResize parameter to False.

Let me know if it helps...

I will fix it by disable gradualResize (when under IOS) if it does works...

Hi, please update my component.

I have exposed the gradualResize input parameter, and make it automatically false if using in IOS device.

Here's the change log:


Rank: #32545


still doesn't work, when I call resize, the client action exit without any error message.


Hi sorry I'm really at lost. 

I don't have ios device so I can't really test it.

But on Android device it works perfectly.

I guess it's because of different javascript engine between Android/Chrome and IOS/Safari.

Rank: #556

Hi, just to say that I use the Resize action from the component and it worked for IOS. I only sent he MaxWidthOrHeight value, the image and is done


Rank: #556

Hi Harlin, sure, IOS 11.2.1, iPhone 7 


Rank: #22102

Hi guys, 

we tried to use this component in iOS, and it didn't work. So we made some investigation and we found one bug on the component (that didn't fix the issue, but it's still a bug), and the solution to make it run on iOS.

The bug

Harlin Setiadarma stated:

"I have exposed the gradualResize input parameter, and make it automatically false if using in IOS device."

And you can see that in the code:

But in the Javascript node JS_Resize, it's always passed True to the gradualResize input parameter. So the gradualResize variable value it's being ignored:

The highlighted attribute in the image, needs to be set to gradualResize.

The solution to make the component work in iOS

On the JS node JS_Resize, just remove (or comment) the instruction to set the crossOrigin attribute to anonymous:

That did the trick for us. 


João Carvalho

Wow, thank you João. 

I will fix it immediately. 

But the crossOrigin thing was needed in Android, I need to check it.

So maybe I'll make some condition based on device OS.

Thanks a lot... 

Hi João,

Please also help me test whether gradualResize works or not on IOS.

Many thanks.