Scale Rectangles to Patch Size

Post your awesome Wire patches here, share tutorials
Post Reply
User avatar
Sjan Top
Posts: 65
Joined: Mon Dec 04, 2017 14:55
Location: Nederland

Scale Rectangles to Patch Size

Post by Sjan Top »

Heya

Scaling and getting the aspect ration right has taken me sometime to get right.
To save you that time, here is a example to get you moving.

Works for Shapes and 2D mesh, added the logic to get them to conform to Slices.

*the 'Get aspect ratio' part of the patch corrects for portrait mode patch size.
*there is addition Normalisation to get Slice data to conform the Mesh and Shape 'space'
Attachments
(Tech) Scale Mesh.wire
(42.78 KiB) Downloaded 762 times
Untitled.jpg

User avatar
Sjan Top
Posts: 65
Joined: Mon Dec 04, 2017 14:55
Location: Nederland

Re: Scale Rectangles to Patch Size

Post by Sjan Top »

Hi foks,

I have a update to this blueprint, some more logic to calculate the UV for the rectangle so textures get mapped right. Now we can use 2Mesh as a instanced crop tool, with all the extra benefits

Have fun!
Attachments
Untitled.jpg
(Tech) Scale Mesh.wire
(52.17 KiB) Downloaded 416 times

User avatar
Sjan Top
Posts: 65
Joined: Mon Dec 04, 2017 14:55
Location: Nederland

Re: Scale Rectangles to Patch Size

Post by Sjan Top »

Hi folks,

My first plugin is for sale on Juicebar, Animated Slice Transform.
Here is some of the logic that is at the core of the patch.

Beside the earlier addition of UVmapping, here is a way to get the collection of instances organised so we can manipulate the slice.

Just throwing a linear node on the Scale gives not the the right effect.
And Expanding a linear node to the amount of slices is also strange.
The problem there is that the Expand adds copy a the end of the collection. And for Slice we want to have them add sequential. So 1,1,1,1,2,2,2,2 ect instead of 1,2,1,2,1,2,1,2 The Sort node fixes this and reorders the collection sequential. Now the first 4 slices have size 1 and the next 4 have size 2.

In the patch they go smaller not bigger, but you get the idea, have fun.

If you don't want to build our own, there are more slice related plugins in the works, in time they will be added to Juicebar.
Attachments
(Tech) Scale Mesh.wire
(105.22 KiB) Downloaded 404 times
Untitled.jpg

Post Reply