Hi
Still trying to setup some internal Ops fields, I'm going crazy !
I really don't understand the way knobs and fields are working.
As mentioned by Konstantin, setting the "expr0" field of an Expression Op using
set_field() seems to work (get_field() confirmed). but crashs Nuke !
Thus, I was trying to setup an Expression Op using it's knobs...
For example:
m_expr = dynamic_cast<Iop>(Iop::create("Expression"));
Now, in knobs(), I can display all the knobs of my Expression like this:
m_expr->knobs(f);
And I can set later (eg. in _validate) the "expr0" knob like that:
knob("expr0")->set_text("max(g,b)");
And everything works fine.
Note here that calling get_field("expr0",...) does not returns the expected
string... I suppose that this is related to the fact that the "expr0" knob is
NOT a STRING_KNOB, but rather a CUSTOM_KNOB.
Anyway, suppose that, in knobs() I only want to display the "expr0" knob and
not all the others (channel0, etc.). I will have imagine to do it like this:
Op_knob(f, m_expr, "expr0");
But, that don't work. The knob is not created as expected... :(
Yet calling this works:
Op_knob(f, m_expr, "channel0");
Where is the "expr0" knob ?
How can we setup an internal Expression Op without showing all its knobs in the
panel ? Same question for Shuffle Op fields, etc.
The add_knobs/replace_knobs mecanism does not seem to deal with that. But, may
be i'm wrong ?
Please, help !
Thanks
_______________________________________________
Nuke-dev mailing list
[email protected], http://forums.thefoundry.co.uk/
http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-dev