Can we get data from an imported geometry?

Hi everybody,

If we have an imported polysurface into a Rhino file and we want to know, for example, the name of the original file where that polysurface came from. How do we do that?

Thank you!

Hi Jordi - this would be possible with a customized (read: scripted) import routine that names objects with the incoming file name and some index or other unique decoration.But as is, no.
-Pascal

1 Like

Hi Pascal,

I’m taking note of it to try in the future.

Thank you so much

Hi Jordi - I dredged up an old script that does exactly this - it is set up for stl files but can be used for any- the slightly weird thing that the user requested was that each object coming in should get the exact same name - the incoming file name… would that work for you? It would be possible to add a number, or something else to the object names, or add the file name as user data on the object rather than the name… etc.

-Pascal

1 Like

Hi Pascal,

That would work perfectly!
Could you post the script please? I’m trying at your page but with no success…

Thanks a lot

Hi Jordi - see if this works - it’s a RhinoScript set up to add its own alias, so, save, drag and drop onto Rhino and that will register

ImportWithFileName

I took the STL perference out, so it now looks for all files indiscriminately…

ImportWithFileName.rvb (947 Bytes)

-Pascal

1 Like

Thank you very much Pascal :vulcan:,
I’m telling you something as soon as I try it!

Hi Pascal,

I got it tested and works better than expected.

It’s so cool to preserve the referenced object’s name even if we are exploding the imported block, any of its polysurfaces or splitting any of its surfaces… really useful.

Thanks a lot!