Viewport/Render texture inconsistency

Rhino textures render in an inconsistent manner. I used Rhino’s grid texture just to map my geometries.

Buildings in the top left corner are meshes made and mapped in Grasshopper (thanks to Human plugin) and act fine in external program (UE4). Big buildings are normal breps. Every roof in the scene is using the same material.

I’m using latest Rhino 6.

Viewport:

V-ray:

Rhino render:

Looks like your uv mappings go wrong. It’d help if you could share a file with the objects and textures (make sure to save the textures in the 3dm).

Thank you Nathan,

I exported those buildings but the most important thing for me is to know why it happened? I have some experience in texturing in Rhino (which is not a very pleasant thing to do). But differences between engines like this are ruining my confidence about my skills in texturing.

File size too big, I put it on my OneDrive.
https://1drv.ms/u/s!Ara31Y5vLih0gak66Glj8-nDInHnnQ

You used a mix of box and surface mapping on the roofs. You probably should use the same method for each of those.

You could first uvmap one roof, then match the rest to the one you did. You can always use the mapping widgets to adjust the uvmapping.

Here a screencast of a potential way of doing the mapping:

I know that I used different methods because I stopped texturing when I saw that Rhino Render is showing something else than Viewport and the same goes for V-Ray. Why it is different in viewport than in render is my concern.

EDIT:
Also the difference in resolution of the texture of the same material and mapped identically (cube matched mapping from the roof on the right) looks weird. Almost like a lens blure from that angle ;).

I don’t see with the red buildings as what you post, the UVs are a bit of a mess there, the surface mapping doesn’t really work for those. I see the same across all display modes and Rhino Render.

Adding to all a box mapping with a box of 100x100x100 gives nicer results in Rendered, Raytraced and Rhino Render.

I’m guessing that a box mapping of 100x100x100 on all buildings will work pretty well.

edit: hadn’t seen the update to your previous post, here a closeup of the roofs using the box mapping:

In some cases you may see some worse resolution in Rendered mode, but I think that is due to mapmapping.

UVs of the red buildings may look strange because whole geometry and mapping were made in grasshopper. To map them I used BoxMapping component from Human plugin. Thankfully they behave well in Unreal Engine. You got only a small piece of the scene. I couldn’t afford to map them individually. Many of them are placed on different angles so match mapping technique would not work well. Thanks to the grasshopper hundreds of them are mapped individually. Anyway, it’s extremely simple geometry.

Mapping components from Human plugin are a bit limited (but I’m very happy that there are some tools at all - thanks Andrew!) and we really need better grasshopper tools to deal with texture mapping. I will start a topic about that problem soon.

The model you shared had only surface mapping on the objects. Perhaps the baking of them went wrong?

Apparently, it’s how grasshopper components are interpreted at the end. We should ask @andheum to know more about it.

box mapping.gh (5.5 KB)

I don’t have Human, but you should try connecting your final geometry to the Custom Preview component, then switch to Rendered mode. The theory goes that you’ll see whatever the GH custom render mesh is, hopefully including the uvs.

happy to help where I can, but I’m not sure I understand the problem you’re trying to solve.

What supposed to be a box mapping is recognized by Rhino as surface mapping and looks almost as box mapping (can be good enough to trick you). After turning on V-ray nothing changes, but after turning on Cycles, created geometry reveals its real nature and UV layout changes.

box mapping human.3dm (147.6 KB)
box mapping.gh (8.7 KB)

I’m just using the RhinoCommon CreateBoxMapping method…

TextureMapping mapping = TextureMapping.CreateBoxMapping(B.Plane, B.X, B.Y, B.Z, true);

@Czaja does that happen also when you switch to Rendered mode before you switch to V-Ray interactive?

Raytraced itself doesn’t do any baking nor UV modifications. Raytraced gets all geometry through the socalled ChangeQueue mechanism.

I haven’t installed Human, since it isn’t in Yak yet (_TestPackageManager, and automatic install from GH).

Mapping stays the same, UV layout changes as soon as I run Cycles Interactive viewport.

@andy, it appears ChangeQueue somehow causes a change of the UV mapping. Could this be related to baking of textures?