Knitting in 3D is quite popular these days. Although it is not too hard to achieve, building a knitting setup presents some challenges to the TD. In this tutorial Manuel shows you one way of modeling a knitted 3D object and a method of making the knit conform to the animated mesh.
On top of this foundation the setup can be extended to feature secondary yarns, yarn colors and strand rendering. Ideas how to achieve these effects can be found in the attached artwork scene file.
Download the assets used in the demo files
Download the start scene
Download the artwork file
Pingback: Creating Knitting in Houdini 3d Building a UV Deformer
You could avoid this super complicated extrude/bool/polyline reconstruction setup by just saving @P.y into a separate attribute before the extrude and lay down everything flat. Then do the extrude and bool and delete all the points after the bool, which are > 0 in P.y … That’s much faster and you can reuse the saved attribute for P.y again at the end to recalc the height. Much faster, more reliable and versatile and cleaner network.
Hi Philipp, Thanx for this idea. But would it really work? After deleting the points that are above 0 in Y, you would face the same situation as in my setup, wouldn’t you? Points in the wrong order, as the bool creates new points and messes up point order. How would you takle this problem and reconstruct the polylines?
By removing the points in a wrangle you should be left with a polyline again, no need to reconstruct the prims. Here is a hip: https://we.tl/atsABbyZoj
Just one of a lot of ways how to tackle this, as always in houdini. But in this case it is worth it I think, altough your setup might have more educational value as there is more stuff in it 🙂
There is an error in the file. N should be derived from opinput2 in the end…
Thanx Philipp, I will have a look add soon as I get home. Never liked the messy solution:-)
Hi Phillip, I had a look at your file. Thanx again for taking the time to look into this. But your method only works half ways. For use with the polywire it’s fine. But unfortunately you’re left with polylines made up of multiple primitives with your method. The order is lost. So creating secondary curves or even coloring the strands along curveu is not possible anymore. To do somthing like this, you would have to fall back to the same messy tricks I used to restore the point order.
The intersectionstitch node is designed to cut curves. Here I made an example: https://www.dropbox.com/s/y5tk8jvs2phd9n6/bool%20curves.hiplc?dl=0
Not nearly as messy as yours but still a bit convoluted. Its too bad boolean node doesn’t work on curves in h16.
Thank you so much Jonah for pointing the “Intersection Stitch” node out to me. I had no idea that this exists. Neither, about the “Intersection Analysis”. Are these two new to H16? Simplifies the setup quite a bit. Good to have two more nodes in the arsenal!
They are new to h16. Pretty powerful too. I remember hearing somewhere that the code under the hood is entirely different than the new Boolean, which is probably why they’re kept as separate nodes. In typical houdini fashion they’re cryptically named and buried away, so nobody knows of them!
You can use the timewarp node with the input set to 1-1 and output to $FSTART – $FEND and the extends set to hold instead of putting in the rop output / file input nodes. Useful for caching sop work without having as much in your geo directory.
You have no idea how long i have been waiting for this! your amazing!
do you know of pingo’s knitbox? I really want to be able to have control like he has in this.
Check the volumebreak node, it can cut polylines and other complex geometry by SDF, very usefull.
Hi Manual, Thanks for the great tutorial. I learn a lot of your tutorials and there is a lot to learn! On the vimeo channel arjanM posted his own version. It’s very fast. I’ve used you’re nodes to create the strands. But i can’t get it working. Looks like it has to do with the input format. Can you help me further? Here is the link to my file. On the left side your tree and on the right the alternative: https://www.dropbox.com/home/Public?preview=Knit-alternative_v0100.hipnc
AH, Got it!
I’m trying to put a texture on the knit (with the strands as in your final version) using the uv map. But can’t get it done. Would be nice if you could do a tutorial for that?
Pingback: module 1 retrospective – Ruiting Wang – MA VFX (3D)
Hey what do you advice for growth animation ?
I wanna make knitted rabbit,
I manage to do the ball 🙂 but have no idea to how to make growth animation of it
Hi Manuel, great stuff as usual!
To avoid the boolean construct why not use the extruded geo to group the points by boundary and use a polycut to delete them? Have a look at the attached file. It’s a lot faster and no need to reorder things. The main differences in outcome are the values of the ‘alternate’ attribute affecting the colour. I don’t have redshift, so I didn’t check how it’ll render.
Liebe Grüße aus Kapstadt,
How did u make that strands on individual polywire mesh?
I must be oversimplifying the problem, but why not set up a smaller the base knit, (say 15 to 20 loops instead of 50) to fit on each one of the six panels thus skipping the boolean altogether. Besides, giving you more control over the edges.(eliminating/avoiding the small polyline fragments,) this way also opens up the possibility of assigning different colors/textures to individual panels…?
Hello Manuel really nice tutorial, but I am facing a problem that its related to this more or less.
I make hair and in a base of that hair I made the hair cards, but my problem relies on the baking process.
I transform the cards uvs into 3d space and now I need to match my Hairs with the uvs in 3dSpace and I don’t know exactly how… ( both clusters of hair and cards shares the same cluster attrib)
More or less is the same as the tutorial but reverse process…
Maybe you can point me in the right direction.
Thanks in advance
to be honest I don’t get exactly what you are trying to do. Could you elaborate?
I made a pic based on this awesome technique: https://www.artstation.com/artwork/QANxx
Hi Simon, thanx for showing this. This really looks rad! cheers mnu
Great Tutorial as ever!! Thanks Manuel!!
Nice stuff! I am trying to re-implement a compositor example of T yarn knitting. I cannot find plane MK2 and UV connector as had been explained in this YouTube video: https://www.youtube.com/watch?v=AG4-sGcGyWI&list=LLuORS2hOBqsUJEgE645iWDQ&index=3&t=0s
I downloaded older blender versions, but I didnot find those nodes while search (shift+A).
Lastly, I downloaded the Github example file : https://github.com/enzyme69/blendersushi/issues/309
and I got this following error undefined socket, what I should do to solve this problem.
I noticed that maybe there are add-on must be added, but I dont know what they are.
Hi Manuel. Awesome tutorial. I got into Houdini a couple of days ago and been learning a lot in here and also in the Patreon page.
Quick question, would it be possible to use a Blast node on the “front” group of the poly-extrude to get rid of the extrusion after the boolean operation, that way keeping the original strands?
Great tutorial, thank you! How do create the littles fiber on the wire: https://i.gyazo.com/29293ef4ac676b95fa01c85a58dc59df.jpg