WISH Preview Geometry for Selected Objects actual colors

I often find myself using colors to visualize my geometry from GH in Rhino. I use colors to distinguish between elements, understand how trees are organized etc.

The only way to have geometry visualized with colors is with the Custom Preview component. If you have many layers of geometry superimposed, most times you need to turn all other components off and just let the Custom Preview on. After that, I have no practical way of turning on again the components I turned off.

I think a quick solution to this could be to have the option on the Custom Preview component to, when selected, display current colors or display the document preview settings color.

This way, you will be able to only look at the selected Custom Preview component, but instead of having it monochromatic (green by default), it would display the colors that are inputted into it.

I hope this is a reasonable request.

1 Like

I get it, but it would be a weird solution to the problem. Making it behave counter to the way everything else behaves seems like a dangerous thing to do.

I don’t have a better idea yet, I’ll need to do some thinking. I would classify this as a debugging feature which ideally works on all components, not just custom preview.

What about an optional widget that draws some balloons as shortcuts anchored on the sides of the canvas control, on the left for inputs and on the right for outputs usually (or allow the user to choose which component to put in a balloon), with which you can move the canvas viewport to the component with double click, or interact remotely with right click (to hide, select, bake, move a slider, press a botton, reference a geometry…). This way you always have access to the inputs and outputs from the UI, without having to look for it on the canvas, they’re heading towards their position and disappear when the component/parameter is visible. It may be visually offensive, but you’re very good at making these things look good.

1 Like

I just did a quick proof of concept. I can’t change the display of GH so I chose to draw the bounding box instead. But the idea is still there, an auxiliary display.


Thank you David.

I feel that broadening the scope like this contributes to thinking about the solution as incoherent or disruptive. I think this is not the case when considering adding an extra option in the Custom Preview component such as the already existing tick box for “Render”, which lets you decide if the component shows its geometry while on Render mode in Rhino, even when its preview is set to off.

I didn’t mention this before because I felt that it would be over doing it, but ideally I think a kind of layer state functionality would be nice, pretty much like the save state option, but a quick one for previews. This way you could rapidly swap between debugging states and presentation states.

(for the time being, this has been logged under RH-58981)

1 Like

Hi, in the meanwhile I think you can reach these goals using Metahopper plugin (by the awesome Andrew Heumann)

Metahopper allows you to control -almost- every property of the components in the GH canvas

I think it’s all about creating the right filters (Match Text + wise grouping + wise group names) to be able turn on/off just their previews in one click

I have used it a dozen times and always worked like a charm :slight_smile:
in the Food4Rhino page there is also a video about how the different components work :+1:

Another option to mark the selected geometry is to draw only its contour/outline. Calculating this is very expensive with the Rhino geometry, but maybe it can be done in real time with OpenGL or the graphics engine that uses Rhino under the hood?

1 Like

So I’ve been playing with an idea for this today. What do you think?


An interesting approach, but I think in such a small definition it doesn’t show its potential? Does the drawing stay in the control coordinates or in the canvas coordinates? Drawing that shapes takes more time than clicking on the components with the option to visualize only the selected, doesn’t it? And if what you want to visualize is very far away, when you zoom out you lose the visualization of the icons, and it would be necessary to make more than one drawing at the same time, because trying to exclude what you do not want to show will be very difficult in long definitions with a single boundary. I think this problem (only one color selection) appears mainly in long definitions, when the cost of finding the component that displays each thing is high.

I’m not sure I got the original request of the post, but my problem is when I move around the canvas on a long definition to find the custom display or other components I want to show, they all look green and I can lose the reference of which component is displaying which thing because everything is displayed with the same color. So in this case, that idea seems to have the same problem, or I am missing something?


Exactly what I was thinking. I think it makes more sense to have a button that gives a “Clown preview” of all components selected (or visible?). Each selected component gets a separate color (or contour) and the rhino viewport shows whatever’s happening inside that component in the same color as the contour of that selected component.

@DavidRutten I think this feature request makes perfect sense, because in debug mode you have to select things in order to get them visible. It would be nice if we could mark instead of select items to stay visible in debug mode. This way @ShynnSup can still have the items in the colors they are meant to be, and we still keep the ability to select (and make green) objects in this debug mode.
The way it is done in Metahopper is pretty good, as you can make Selection sets of objects that you can toggle. But it does require to make sure all objects are invisible to start with.
I often need to debug selecting multiple objects on the canvas and then needing to move a slider. This goes wrong pretty often, a misclick and I have to start selecting again.
Not sure if this is possible, but could it be done that in debug mode, clicking an item once marks it (makes it visible) and clicking again selects it or something along that line?

No indeed, it was just for testing.

The boundary is defined in document coordinates, and it is part of the document. That is, it is saved along with the file. It is not however an object, so you can’t have more than one, and you cannot copy/paste it.

I don’t think so, especially not if you want to include a bunch of components. It’s more persistent than a selection set along with selected-only display mode, but less persistent than setting preview on/off for components.
As a bonus it doesn’t interfere with or override any existing preview settings or modes.

I don’t think of this as a visualisation feature. It’s a debugging/inspection feature, and you only ever inspect components that are near where you are.

It sounds like you are after an organised way to manage display sets, which would be a different feature altogether.

Basically, with GH display mode set to “Only draw preview geometry for selected objects” I wanted the Custom Preview component to display geometry with the colors inputted when selected, instead of green (default).

Display Mode

Instead of this:

I want this (imagine I could select the component)

Because it avoids having to turn off all geometry and set the Display Mode to “Draw shaded preview geometry”
Display Mode2
Right now this is the only way to get multiple color display in Gh.

In this video, you can see the problem, In order to see my geometry with colors I need to:

  1. Change display mode.
  2. Ctrl+A (select all), turn preview off for all components.
  3. Turn custom preview on.

for me this is often not the case

David, what if you use that boundary to hide everything that’s outside, and ignore whether what’s inside is selected or not? That would solve this request, wouldn’t it? Maybe include several modes that define the behavior (visible/hidden, select/deselect…) for inside and outside the boundary to complement it?

I just found out that making a cluster with the Custom Preview component inside with preview turned on, when I select the cluster, it shows with colors! Just what I wanted.

That is how it works. Any object not inside the boundary is not previewed, all objects on the interior behave like they would otherwise.

1 Like

lol :sweat_smile: :+1: