[Sidefx-houdini-list] return

Rob Pieke rob-p at moving-picture.com
Wed Feb 11 18:36:14 EST 2009


Sadly I've turned into more of an observer on that list. MPC is more Maya-centric than C.O.R.E. was :)

That said, I just tried altering a transform's tx value by the number of periods in a filename and it seemed to work by putting this in for the parameter value:
pythonexprf( 'hou.node("/obj/geo1/file1").parm("file").eval().count(".")' )




> myString.count( ':' )
>
> for example:
>  >>> 'asdad:adsadff:asdaf:asdaf'.count(':')
> 3
>

Ya ... I tried that but probably not in right context. Here's what I'm
trying to do:

I have a geometry node called 'foo' which has a string parameter. Inside
that node I have another node with a float parameter. In this float
parameter, I need the expression to read the string up on the parent node &
generate a number using the count function as we talked about.

Can I do something like
a = hou.node("/obj/foo").parm("string_to_read").eval() ; a.count(':') ???

Cheers,
   Rob
_______________________________________________
Sidefx-houdini-list mailing list
Sidefx-houdini-list at sidefx.com
https://lists.sidefx.com:443/mailman/listinfo/sidefx-houdini-list



More information about the Sidefx-houdini-list mailing list