PDA

View Full Version : script based node



m1j
11-01-2010, 10:24 AM
It would be nice to have a simple (javascript, python, lua) node that has all the common inputs and outputs.

Sensei
11-01-2010, 05:14 PM
What are these "common inputs and outputs"??

Work involved in making javascript, python interpreter which is running inside of node is so big, that hard coding some inputs and outputs have absolute no sense..

Better allow script making inputs and outputs dynamically..

Did you check out TrueArt's TrueGroup node allowing to make quasi-script node groups? http://www.trueart.pl

m1j
11-30-2010, 02:01 PM
What are these "common inputs and outputs"??

Work involved in making javascript, python interpreter which is running inside of node is so big, that hard coding some inputs and outputs have absolute no sense..

Better allow script making inputs and outputs dynamically..

Did you check out TrueArt's TrueGroup node allowing to make quasi-script node groups? http://www.trueart.pl

Thanks, I will look at the TrueGroups. After a quick look it does not look like what I had in mind. The end result I wanted is a node with all of LW connection types in place for both input and output. Only one item in the node properties and that is a script editor. In the script any of the input could be address as well as any of the outputs assigned a value. I use JavaScript a lot so I would be comfortable with it but core is moving towards python so I thought it could be used. The scripts could even be compiled on the fly when the render is started so they function faster while rendering. It would be like having the same flexibility and power that renderman shader language provides for renderman engines.

Lightwolf
11-30-2010, 05:23 PM
There's two main parts that make it kind of tricky.
One would be a decent text editing system within LW, as all the native controls allow for single line text editing only.

The other one is finding a decent engine that runs fast enough as it could otherwise slow down nodes to a massive crawl.

I suppose the third one is actually hooking up the language itself. For a node that is self contained it may even make more sense to use a decent (and fast) as well as extensible expressions parser.
I did actually look around at one point in time and found one... but that one wouldn't have been thread safe, which is another requirement for nodes.

Cheers,
Mike