Hey. I was wondering how you could crop a png within Thunkable without photoshopping it. Help would be much appreciated
Hi there,
The Cloudinary API has functions for editing an image, including cropping.
Are you making some kind of photo editing app?
Thank you for your answer!
I’m making a physics formula-solving app, and I needed a cropped image of a certain symbol.
Just out of curiosity @danigarcia - which symbol was it?
I would generally edit assets that don’t need to be further edited during app run-time before adding them to your Thunkable app.
That said, learning to work with a photo editing API is a great skill anyway, and will give you the ability to make apps that do things like edit photos in the future!
It was this one: φ
OK, thank you for your advice!
What are the blocks required in Thunkable to crop the image?
There aren’t any specific blocks for that. You just change the url for the image you want to display in order to crop it. See Dynamically Resizing and Cropping Images | Cloudinary, especially the section that shows examples and urls for cropped images.
can u show an example how u do it in thunkable using the links in the Dynamically Resizing and Cropping Images | Cloudinary
There’s an example right on that web page:
They used the url https://res.cloudinary.com/demo/image/upload/c_crop,h_200,w_200/docs/models.jpg, which means that the original image was https://res.cloudinary.com/demo/image/upload/docs/models.jpg (if I remove the part of the url between “upload/” and “docs”).
With another sample image with this url:
https://res.cloudinary.com/demo/image/upload/lady.jpg
You would replace “upload/” with “upload/c_crop,h_400,w_200/”
https://res.cloudinary.com/demo/image/upload/c_crop,h_400,w_200/lady.jpg
This project has the blocks I used (see the first screen): Thunkable
And a screenshot of those blocks. For some reason, variables aren’t working on that screen.
thanks!