Exporting layer to sketchup tags

Hi @Gijs

Here your model modified in the way we would like to have it.
Test Model_SKP_gijs_modified.skp (265.0 KB)

Hmm I just downloaded the file and that is not the case.
If you enter each group, and select faces and edges, they are in untagged layer.

Faces are the faces of the geometry as in all other software.

Yes they do, but faces don’t.

If you do an export to SKP of the Rhino model I provided these are all the things wrong with it:

  1. At first opening the file, geometry is not zoomed in. For some reason camera is Top view extremely zoomed to 0,0,0 instead of focusing in geometry.
  2. Units are in inches despite Rhino units being in meters.
    image
  3. Each polysurface is exploded into faces in Sketchup, it should be a group, grouping the faces of the polysurface object. If not, all faces get welded together, equivalent to exploding and then joining your polysurfaces in Rhino, which would create a mess and join random faces between each other.
  4. Faces are not placed in untagged layer. Only edges are. You can see when I select a face that is it placed in its tag equivalent to Rhino layer. While edges are all left in untagged.

    When I turn off all layers except untagged, this is what I see.

    Instead, I should be seeing nothing, because all is turned off.
    I know what you are thinking, if you place all faces and edges in untagged, and leave untagged visibility on, wouldn’t the whole model be visible then? No, because your groups (grouping faces and edges) would be placed in the rest of the layers, which you turned off. Think of it as blocks in Rhino. You can have geometry in a layer named Untagged, while the block itself is in another layer named ‘Block’. If you turn ‘Block’ layer off, the whole block is no longer visible, despite its geometry being in Untagged layer.
  5. Materials are applied to Faces instead of to the group. Its more convenient to apply materials to groups rather than individual faces.

@ShynnSup
thanks for the additional info, please be patient with me as I’m completely new to Sketchup, I want to make sure that in the end I make a clear recipe for our dev.

So far I think I will need to log the following

  1. Camera settings of the active view need to be exported as the default camera view when opening the file in Sketchup
  2. Units of the Rhino file need to be preserved
  3. Polysurfaces need to end up in groups, since these are going to be exploded into their faces on export. And these groups need to get the layer (tag) name.
  4. Faces of Polysurfaces need to be left untagged. (Edges are already left untagged)
  5. Materials need to be applied to groups instead of the faces. This one needs a bit more clarification. Do I understand that this should work by setting object material ‘by layer’ in Rhino? In Sketchup, I don’t see a way to add materials to groups when I grouped them, but in the first demo file, I can use the bucket to apply the material to the group. Furthermore I see the difference that when I group individual faces, I get a misaligned boundingbox whereas in your example file that’s not the case

Then @Erik_Beeren wants the option to apply layername (tags) to all elements of the exported objects.

@martinsiegrist mentioned block units need to be taken care of.

Let me know if something is wrong or missing.

1 Like

Rhino named views to SketchUp scenes would be great too

1 Like

All perfect.

Let me clarify on point 5.

Tags in Sketchup can’t have materials, so Rhino setting by layer is irrelevant. Ergo any object in Rhino that has material set either per object or per layer should have same treatment in Sketchup. As a best practice its better to apply materials to groups rather to individual faces. Why? Because in order to edit material in faces you would need to double click, enter the group and change it there. It would be equal as to applying materials per object to objects inside many nested blocks in Rhino.

Its the same way you would with faces. Use the Bucket tool and click on the group.
With your group selected you can either go here:

Or you can use the Bucket Tool, select your material and click on the group.
image

Note: If your faces already have a material, adding a material to the group will have no effect. You need to unassigned the material assigned to the faces inside the group first and just after that you will be able to assign a material to the group. (this is irrelevant for the Rhino exporter, just explaining Sketchup at this point)

Oh yes, groups bounding box should be aligned to object bounding box, which facilitates scaling and other operations.

Groups have their own axes, apart from the main model axes. By default, when you create a group, its axes will be aligned to World Axis. And if your object is not aligned to it, well you get this misaligned boundingbox.

You can re locate the groups axis by entering it, selecting this tool, and clicking 3 times to align for xyz, same as when relocating gumball in Rhino.
image

Here I have re aligned the group axis.

@ShynnSup thanks, that clarifies a lot. As for the groups and their axis alignment, I don’t expect that that can be handled by Rhino, since objects have no recorded transformation. The only exceptions are extrusions as far as I know.

I can see now how the material assignment to groups makes sense and makes assigning materials a lot easier.

Of course all is depending on what’s possible with Sketchup’s SDK, but for now I logged all of the items:

RH-74212 Camera settings of the active view need to be exported as the default camera view when opening the file in Sketchup
RH-74213 Sketchup: Units of the Rhino file need to be preserved
RH-74214 Sketchup: Polysurfaces / Meshes handling
RH-74215 Sketchup export materials assignment
RH-74216 Sketchup export: Blocks units need to be preserved
RH-74217 Export named views to Sketchup

3 Likes

That would very nice!

Chiming in late to this topic - I’ve been wrestling for years with this issue of Rhino exports to SKP sending geometry to Tags associated with the originating Rhino layers, and surface edges landing on SKP Untagged tag. My understanding is that SKP is fundamentally different in that it’s surfaces always have edges that are actually separate entities, while Rhino surfaces do not. The Rhino to SKP export creates these edges (or SKP does on import).

What I’ve learned is that any Rhino geometry that is blocked (not grouped) in Rhino before export to SKP will send these irritating surface edges to the SKP tag associated with the Rhino layer where the Rhino block is established. Somehow, after blocking, the Rhino to SKP export bypasses the usual dumping of Rhino surface edges to SKP untagged layer.

The gist is that if one wants to be able to continue using the Rhino method of objects or materials by layer (as opposed to the SKP best practice of all geometry on a single ‘untagged’ or ‘0’ layer), it seems necessary to block all Rhino geometry before export. Any loose geometry or grouped loose geometry will get you all the edges on ‘untagged’.

This brings up the age old modeling process issue of SKP users building all things on one layer and associating groups or blocks/components of geometry to other tags to turn on or off, while most Rhino users seem to put geometry on various layers, in my case usually material-by-layer or sometimes object types-by-layer.