custom color and shape ????

   5037   11   1
User Avatar
Member
112 posts
Joined: Feb. 2016
Offline
Hi
Just tried to set up custom colours and shapes.
It doesn't work. Save my custom colour and shapes under a new name.
Then load a new light for instance but it appears the same as the default, the same with all the other nodes.
What have I missed?
User Avatar
Staff
4435 posts
Joined: July 2005
Offline
Are you definitely setting new default colors/shapes for the node types? You must hold Ctrl when you click or drag a color/shape from the palette to change the default for the node type. If you don't hold Ctrl you'll just be setting the color/shape for the one instance of that node… If that's not the problem you can have a look for a file with a “.nodecolors” or “.nodeshapes” extension in your $HOME/houdini16.5 directory, and check if that file is being modified when you set a new default for a node type?
User Avatar
Member
112 posts
Joined: Feb. 2016
Offline
No Didn't know you had to hold ctrl down.
Thanks
Ralph
User Avatar
Staff
4435 posts
Joined: July 2005
Offline
Cool, I'm glad to hear that's all there was to it.
User Avatar
Member
112 posts
Joined: Feb. 2016
Offline
Works for shapes, not colour



shapes
{
“name” : “No Shapes Theme”,
“data” :
}

colour
{
“name” : “No Colors Theme”,
“data” :
}

This is what in those files. Is that correct?
I have given them a name.

Ralph
Edited by Ralph Pinel - Nov. 8, 2017 15:46:47
User Avatar
Member
112 posts
Joined: Feb. 2016
Offline
For some reason, it is not showing the square bracket in the forum post.
Edited by Ralph Pinel - Nov. 8, 2017 15:49:07
User Avatar
Staff
4435 posts
Joined: July 2005
Offline
Both work fine for me, starting from a copy of No Colors and No Shapes, I set the default geo object color to blue, and light color to red, and set shapes for both geo and light. Here are my files after those four changes:
{
"data": [
["Object/hlight::2.0", [1.0, 0.0, 0.0]],
["Object/geo", [0.09399999678134918, 0.36899998784065247, 0.6899999976158142]]
],
"name": "New No Colors"
}
And:
{
"data": [
["Object/hlight::2.0", "light"],
["Object/geo", "tilted"]
],
"name": "New No Shapes"
}

You can put pre-formatted text into a post using the “Code” button at the top of the edit area, between the quotation marks and the emoji. The square brackets are probably being interpreted by the forum as some sort of formatting hint.
User Avatar
Member
112 posts
Joined: Feb. 2016
Offline
Hi
It's not updating these two files for me.
although the shape is, it's the color that's not.
? why is the shape entry not recording the change yet its remembering??

{
“name” : “No Shapes Theme”,
“data” : []
}

{
“name” : “No Colors Theme”,
“data” : []
}
User Avatar
Staff
4435 posts
Joined: July 2005
Offline
If you want to be scientific about this, you should start from scratch. Delete or rename your $HOME/houdini16.5 directory so you don't have any custom themes. Start Houdini, switch to the no shape/no color themes, and make copies of each (giving them new names to avoid any confusion). Make sure that a single .nodeshapes file and a single .nodecolors file is not in $HOME/houdini16.5. At this point the file contents should be nearly empty, like the files you posted above.

Exit and restart Houdini and make sure Houdini is still set to use your new custom themes. Put down a geo object, and Ctrl-drag a red color onto the node, and Ctrl-drag circle shape onto the node. Check the contents of the theme files again. If they are both still blank as above, something has definitely gone wrong. Put down another geo object. It should be red and a circle. If it isn't, then the defaults have not been set. You can check the current default color/shape for the geo object node type by running the following in a Houdini python shell window:
>>> hou.nodeType('Object/geo').defaultColor()
>>> hou.nodeType('Object/geo').defaultShape()
If these don't return values that represent the color red and the word ‘circle’, then the defaults have not been set (so it would make sense they have not been saved to the theme files).

Also, if you're running on Mac, you may need to Cmd+drag from the color and shape palettes instead of Ctrl+dragging (though I doubt that's the problem if you got the default shape to change in a previous attempt). If you're runnning on Linux, check the console from which you launched Houdini and look for any error messages. Also check for error messages in the python shell window.
User Avatar
Member
112 posts
Joined: Feb. 2016
Offline
Cheers
User Avatar
Member
112 posts
Joined: Feb. 2016
Offline
Hang on… It works inside the SOP level but only the Shape works at the object level.
It won't retain the colour.

{"data": [["Object/hlight::2.0", [1.0, 0.7250000238418579, 0.0]], ["Sop/file", [0.8899999856948853, 0.41200000047683716, 0.7609999775886536]], ["Sop/grid", [0.32199999690055847, 0.2590000033378601, 0.5799999833106995]], ["Sop/sphere", [0.32199999690055847, 0.2590000033378601, 0.5799999833106995]], ["Sop/box", [0.32199999690055847, 0.2590000033378601, 0.5799999833106995]], ["Sop/heightfield", [0.32199999690055847, 0.2590000033378601, 0.5799999833106995]], ["Object/dopnet", [1.0, 0.0, 0.0]], ["Object/chopnet", [0.4749999940395355, 0.8119999766349792, 0.20399999618530273]], ["Sop/xform", [0.4749999940395355, 0.8119999766349792, 0.20399999618530273]], ["Sop/null", [0.0, 0.0, 0.0]], ["Sop/merge", [1.0, 0.5289999842643738, 0.6240000128746033]], ["Sop/blast", [0.800000011920929, 0.01600000075995922, 0.01600000075995922]], ["Object/geo", [0.32199999690055847, 0.2590000033378601, 0.5799999833106995]]], "name": "Ralph_Colours"}

Ralph
User Avatar
Staff
4435 posts
Joined: July 2005
Offline
Is it just the light object that doesn't work? I see you have custom colors for DOP Networks and CHOP Networks at the object level too… Do they show their modified default colors?

Are you using a default Houdini Light digital asset? If you bring up the info window for teh Light object, it should have a line at the bottom of the window that says “Defined By”… It should be a path that ends in something like “hfs/houdini/otls/OPlibObject.hda?Object/hlight::2.0” if you're using the standard light asset. The reason I ask this is that an HDA can have a “creation script” (a script that is run every time a node of that type is put down). If that creation script sets the color of the node to a particular value, it will override the “default” value. And I see in the file you posted that the light object is set to a yellowish color, so it seems unlikely that the object wouldn't show that yellow color unless it has been explicitly told not to (especially if things are working fine for SOPs, and possibly other object types).
  • Quick Links