[Sidefx-houdini-list] I3d Opacity

Pablo Giménez pablogipi at gmail.com
Mon Aug 7 04:19:14 EDT 2006


Hi Andrew, thanks for your complete reply.
Only to add my 2 cents to this discussion, I think that the only
reason to use Local variables instead of global variables in context
is memory.
The only thing, I think, that Andrew firget to say is why you can't
access to some variables in some circustances.
In Houdini there are some global variable, like $F, $FF, $FEND, $T, etc ...
But the variables that map attributes, regardless the context, are
always local, this means that are only availablr if the operator
enables it.
This problems is very noticiable in SOP context where always you can
find the problem to not be able to acces easily to an attribute
because the SOP you are using doesn't crate the local variable, then
you have two options:
- Use the point() expression: horrible and you need to have access to
the $PT variable.
- Use Attribute Create SOP: this actually creates global variables
instead of local variables.
In POP context is the same problem, the onlyu difference is that
almost all (ALMOST) POP operators creates the needed local variables,
but for example if you create your own VEX POP operator, because the
variables are local, you can't access to the $LIFE, $AGE, $V, etc ...
you have to use an Attribute POP  prior to your VEX POP to create
another global varible that maps to your needed attribute.
So, like Andrew have said, we have the problem to not be able to
access easily tou our date everytime, everywhere.
The only two reasons because I think SESI do this in this way are:
- Memory: to have all the attributes mapped to global variables needs
memory all the time to mantein these.
- The want to avois to have so much global variables.

Finally I am agree with andrew, much of the time we want to have an
easy access to our data so I think that to have automatically global
variables to all of our attributes will be solution.



-- 

Un saludo
Best Regards
Pablo Giménez



More information about the Sidefx-houdini-list mailing list