I’ve been using the iPhone 12 Pro lidar scanner for some of our projects.
I typically end up scanning different bits of projects in separate scans.
I export the scans as OBJ files. Rhino generally opens these correctly, including showing the correct textures.
However, if I try to merge these separate scans into a single file, rhino loses the texture information. I have tried copying and pasting the geometry, and I’ve tried importing. Both result in the geometry coming in correctly but without the textures.
Any suggestions would be gratefully appreciated. If someone from McNeel wants to have a look I can send the files over.
Hello - if possible, please make a small sample (it can be dead simple and small as long as it is two or more obj files involved). and post it or send to email@example.com, with a link back here in your comments.
Are you Booleaning the meshes together? If so, that is likely the issue as it will destroy the UV info on the separate meshes and they will share one material at that point. One possible approach to success though would be to run ComputeVertexColors on the scan mesh to bake the texture info into the vertices. Hide the texture map in the assigned materials after that and you can then Boolean them together without losing the ‘textures’ but at that point the vertice count will dictate your resolution. With a large scale Lidar scan this may be sufficient.
I’ve sent the email with two small scans. The problem occurs with them where importing a second OBJ file results in no textures. The same occurs even when saving them as 3DM files first.
I’ve also experimented again with the larger files. Interestingly, they are now coming in with textures but they are borked like they were here: Import OBJ Textures Wierd - #27 by pascal
I have no idea why they were coming in blank before but are now coming in all messed up. Or why they are coming in messed up now but the smaller scans are coming in blank. It’s all really weird.
Thanks, but I’ve not even got anywhere close to thinking about modifying the geometry in any way. The closest I got was starting to move the two models around to get them roughly aligned correctly when I realised the textures were missing.
To illustrate the issue on the examples I’ve sent:
Scan 2 imported into Scan 1 file (note the missing textures):
Thanks for the scans… I see the issue, it’s the material names being the same once you import one 3dm file into the other. Rename the materials with unique names and the mapping won’t get lost. Interestingly, if you Open one of the Obj files and then Import the other, the material name duplication isn’t an issue so that’s an alternate route. I think this is due to Rhino 3dm files consolidating materials of the same name.
Thanks, that’s interesting. It seems potentially problematic to merge materials on import entirely by name. If the materials are identical in every way, I can see the logic of discarding duplicates. But going by name seems like there could be numerous situations where different materials get wrongly merged. I’d have thought that giving imported materials a prefix / suffix unless explicitly required not to would be preferable.
Sure, it’s debatable… but did I solve your problem for you?
I haven’t had a chance to check yet (away from comp)
But, i personally don’t think this is really a debate. Sorry.
No one, or almost no one, is ever going to want to lose materials on import just because they happen to have the same name as one in the file the model is being imported into.
It seems more like a bug to me. I can’t believe anyone sentient would have done it that way by design.
Sorry for pushing on this, but the fact that this is an issue that has resulted in me wasting a couple of hours and then two of you guys getting involved here suggests this is broken as it is.
Hi there, I found this thread because I was having the same problem. I just wanted to let it be known that I opened each .obj file in Rhino and saved each as .3dm files with different names. Then I imported each into my model, and they came in fine, with the textures. Problem solved.
@Daisy_Hoyt @robinp may I ask which apps you are using for the scans and the process of getting into Rhino ?
Hi, sorry for the delay. Not visited for a few weeks.
I use PolycamAI for scanning and then export as OBJ files to import straight into Rhino.
Hi, I had tried that and it didn’t work for me. Glad it works for you though!