NURBSSURFACE BY POINTS TANGENTS not working

Hello all, I have a unique problem that I have been trying to solve for some time. I have a nested list of lists of points that are mostly in arrangements of vertical in nature that I am struggling to get an outer perimeter of them. I found this node NurbSurface.ByPointsTangents that appears like it should be able to patch a surface together for me in the direction that I need it to if I feed it the tangents of the curve. Which to me sounds good because what I have is essentially a topo map of points turned on its side. But the topo nodes dont work because it wants its normal to be in the “Z direction”. I want it to be in “whatever direction” (Usually horizontal-ish.) (see my background image of the solid I am trying to create in the image below). But I dont understand what this node is asking for. Does anyone have any examples of how to use this node? I dont know what to feed it. In my mind I just want to tell what the “normal” for each point should be. Which is only one vector per point. But this thing wants 4 vectors per point? I dont get it, please advise.

https://dictionary.dynamobim.com/#/Geometry/NurbsSurface/Create/ByPointsTangents

The graph at that link should work as an example.

Note that I would stick to the NurbsSurface.ByControlPoints if possible - what are you getting for an error message there?

Hi there! So it appears, from your graph that all I have to do is put the same vectors, which in my case will be the tangent vectors from each point, into all of the start/endtangents for U and V then? Because you are using the same vectors for each. Should I as well? Why do you have to translate the geometry before using the nurbssuface.bypoints node but not when you use the nurbssurface.bypointstangents node?
I cant seem to get any of the nurbs surfaces to work. I am using dynamo 1.3.4 btw


Also, I looked into the dictionary before posting here. There is no example there that I can see. Can you see something different? This is what I see (below). Thanks!

This depends on what you want to do with the surface. The tangent directions push, twist, and deform the surface in a way which causes the surface to be altered. It’s kind of like adjusting the weights and degrees of a nurbs curve.

The best way to understand this will be to play with the node in question, as I don’t know what you want specifically I can’t inform you what tangent vectors are desired.

I translated the geometry so you could observe the difference between the two resulting surfaces. If you want the most basic surface which passes though the collection of points then this node may be sufficient and would be the likely solution. Said another way: don’t complicate the code by using override values which you need not invoke.

I see the same. There is a button to download a graph showing how to use the node in question to the left of your lower ? annotation.

1 Like

Hi @jacob.small,
I cant seem to get these nodes to work at all on points that are mostly vertical in orientation. See my image above, No matter what types of points lists i feed into it, be it like sublists of 16 points or even sublists of only 4 points, the nodes error out and only produce “null” results. Do you know what I am doing wrong? I checked out the file on Dynamo dictionary but those node are mostly only horizontal in nature. I still cant get them to work at all. Any ideas? Please advise, thanks!

Can you type out the XYZ values of the points in a list formatted as you’ve got them and post here?

Sure, but I probably cant do get to it today. Can I post it tomorrow?

no rush - I’m pretty much always around. :slight_smile:

1 Like

Hi @jacob.small, my lists that create these areas that I want a vertical nurbs surface on are really long, so I dont know if Im able to type it all out. Do you have any ideas? I am pretty sure that the nurbs surfaces simply dont work when you try to do a vertical surface though. I tried with multiple points up to 32 points in a mostly vertical arrangement and also with only 4 points. Nothing I have tried with mostly vertical points have worked. So I dont think it should be that hard to duplicate. Are you experiencing the same results? Please advise.

Point.X
Point.Y
Point.Z

Write to excel.

Post that. :slight_smile:

hello again @jacob.small
Sorry it took me so long but I have been really busy. I managed to export the list of lists separated in excel. so there are actually 16 points per list in this file, x is the top row, y is the second row, z is the bottom row and each column is a different point. each blank row indicates a new sublist. I cant get ANY nurbs surface node to work with any of them. I even just tried a list of 16 points today all on a flat plain, (same Z level) and it didnt work even. Is my nodes out of date some how? or perhaps dynamo or revit? IDK please advise, thanks!
first row is x, second row is y, third row is Z, space means new sublist…xlsx (27.9 KB)

1 Like

Most current, functional, and stable Dynamo build for Revit 2019 and 2018 is 2.0.4. Assuming you are on 1.3.4 still, an update would help you a good amount.

I’ll check this point list next time I boot up my cpu.

Great thank you!!! But I cant upgrade at this point, because I have a lot of scripts still running on 1.3.4 and when I tried to upgrade to 2.0+ they all broke. the auto lacing feature really screwed things up for all my scripts I think.

I would prioritize getting that done - you’ll be down to one supported Revit version that works with any type of Dynamo 1 (2019) in a few months when 2022 comes out.

Also you’ve gotta learn how to upgrade faster - from 2020 on the Dynamo build is tied to your Revit build - that is you won’t have an option but to update Dynamo when Revit is updated.

How can I learn to upgrade faster?

Practice will be key, as there are lots of reasons things won’t work on an upgrade.

First set up simple rvt test files in the active Revit version then upgrade and test the DYN against them. Fix the dyn, try the next one. You want 3 elements to work with for each, not 3000. For you simplicity of that rvt will be key - your graphs tend to be very large and likely will take awhile to run - smaller data set = faster execution.

Simplifying your graph structure by converting large chunks of some graphs which are reused to custom nodes might help (you can deploy that package locally to colleagues), and can help with reuse of code too.

Avoid python nodes on the graph - these will require an update to Python 3 and a cPython implementation instead of the Iron Python that we use now. It is easier to update code once in your custom node, update the package and push on update through the office than find every copy of that dyn and fix the code each time.

Have a Dynamo graph library for each Revit version, this way you can update as you go. Plan on separate package libraries for each users too, as these will update year to year.

Any part of this may ‘break’ a thing here or there temporarily that you will have to fix, but expanding efficiency of maintenance is going to take some work - you’ve got what the tech industry refers to as technical debt that has to be addressed at some point.

1 Like

Ok thank you for the insight! I will be sure to implement it! Any idea why the nurbs surface node doesnt work?

Opened this up before starting my work day, I don’t have complete answers yet but will try and sketch out something to show what is happening later today - no promises though as it’s a full load for and time with my iPad to sketch isn’t easy to come by these days.

For the nurbs surface to work you’ve got to group your points into ‘rows’ on the face, which I think is your intent of the data set - each set of 16 points is a surface. I chopped up the surfaces into groups of four and some work, but not all. In those cases of failure The data you’re pulling is too disjointed and disorganized to function consistently.

Vertical data sets certainly work though - you can build a series of points with cross product lacing of a range from 0…10 inout to the X and Z inputs but leave Y blank (you can transform randomly on the Y axis to alter the form before creating of you like). It’s just that the values you have jump all over the place and don’t have a structure of rows which comply with the geometry rules.

1 Like

So, I found an error in my graph which I was using to sort out your data - had missed a transpose on the excel data which caused the list structure to fall apart. Sorry about that. :woozy_face:

You just need to chop your sublists of points into sub-sublists. that is instead of saying ‘these are the points which make up the surface’, you need to say ‘these are the points in these rows which make up the surface’.

List.Chop each sublist into groups of four while maintaining the list level should do the trick.

As far as if this is what you were after, I can’t say for sure as I don’t have the source data or any insight into what you were after:

I can say that the NurbsSurface.ByPoints (or even NurbsSurface.ByPointsTangents, if you wanted) works here - just a matter of feeding it the right data.

Ok thanks Ill try that. but that doesnt look right the nurbs surface looks like you are trying to stretch it over flat still, those surfaces should all be vertical. But it looks like the clustering is right-ish. Ill give it a go and post here the results I get. Thanks again!

1 Like