Integration of a node engine

Compiling, libraries, modules, coding guidelines and porting

Moderators: jesterKing, stiv

Post Reply
andrea-i
Posts: 0
Joined: Tue Oct 07, 2008 4:51 am
Location: sydney

Integration of a node engine

Post by andrea-i » Tue Oct 07, 2008 5:14 am

Hi,

First post for me here, I just got blender up and running from the trunk sources, and here I am ready to fire some questions : )

I'm working on an open source node engine with some innovative capabilities, and I'm slowly (as I'm working on it on my spare time) reaching the point where I'll need to build a bridge to a 3d application...I was thinking about blender, but I know nothing about it, so any help will be much appreciated!

My node engine will need to hook into different areas of the 3d application, mainly:
- viewport realtime rendering
- picking inside the viewport something that is not in the scene database
- manipulation of my custom data using existing manipulators

Of course I'd also be looking at the existing node editor in blender, but that would come at a latter stage.

I'd know how to do this in xsi and maya, but the open source nature of blender makes it probably a better starting place for my project...the question is now, can I do what I want to do in blender? and where do I start?

Thanks a lot and sorry for the 'blender for dummies' kind of questions : )
Andrea Interguglielmi
------------------------------------
Animation R&D @ Animal Logic
------------------------------------

ton
Site Admin
Posts: 350
Joined: Wed Oct 16, 2002 12:13 am
Contact:

Post by ton » Tue Oct 07, 2008 5:03 pm

Hi,

Very interesting! It would help if you can elaborate what a "node engine with some innovative capabilities" would be precisely, is this like XSI's ICE?

Blender already has a pretty good node editor builtin, which is extensible for many areas (tests have been done with 3d constraints, and we hope to get modifier nodes working too).

Further, quick help you can get via irc.freenode.net, #blendercoders. Most of the active developers are there nearly every day.

-Ton-

hdd
Posts: 0
Joined: Tue Aug 30, 2005 6:24 pm

Post by hdd » Tue Oct 07, 2008 6:52 pm

Hi Andrea !
It's great to see you here :)

here you can find some notes about actual node system :

http://www.blender.org/development/architecture/

http://www.blender.org/development/rele ... r-blender/

but I can suppose that Ton could help a little bit more ;)

L.

andrea-i
Posts: 0
Joined: Tue Oct 07, 2008 4:51 am
Location: sydney

Post by andrea-i » Wed Oct 08, 2008 1:37 am

ton wrote:Hi,

Very interesting! It would help if you can elaborate what a "node engine with some innovative capabilities" would be precisely, is this like XSI's ICE?

Blender already has a pretty good node editor builtin, which is extensible for many areas (tests have been done with 3d constraints, and we hope to get modifier nodes working too).

Further, quick help you can get via irc.freenode.net, #blendercoders. Most of the active developers are there nearly every day.

-Ton-
Hi Ton,

Very nice to meet you!

(Hi Hdd, glad to see you around here as well : )

I'll try and put in a nutshell what it is all about:
The graph I'm working on is formed by nodes which are able to expose properties, methods, nested nodes and also inherit from other nodes.

Such a system is able to produce a complex scene graph with nested tree structures and connections between those trees, at the same time each node is carrying around the methods needed to access and manipulate its data, providing a self expanding SDK which can be assembled by an artist and still programmed or accessed as if it had been written by a programmer in the first place.

Here is a prototype of this graph (written in python), is a little toy called nodepad:
http://nodepad2d.wiki.sourceforge.net/scene+graph

The c++ implementation of this concept is already in an advanced development stage.
Each node gets written in c++ and is automatically exposed to python, also the compilation of the nodes is handled automatically, so the system can be easily expanded by TDs.

So, what I'd like to do now is integrate the engine in blender to see its actual value as a production tool.

Andrea

ton
Site Admin
Posts: 350
Joined: Wed Oct 16, 2002 12:13 am
Contact:

Post by ton » Thu Oct 09, 2008 5:42 pm

Hi Andrea,

OK, seems to me a general node engine to control (or animate) properties, for example for objects.
However cool that can be (you can probably get it to work a bit for Objects) it will still entirely bypass Blender's transformations, interactions and animation system (hierarchies, constraints, drivers, ipos, dependency graph, etc).

My quick observation is you want to insert an 'alien' system in Blender, which will have limited scope or usability. Certainly if the aim is to provide something on a production tool level.
The reverse would be to take Blender's current functioning, and make a redesign and extension for how a node based system can well be used with it. That's however a gigantic task, even for experienced devs, and not something I expect to happen very soon. It would fit with our long term roadmap though.

Added note: as an experiment and prototype, helping to design further integration or redesigns, an effort like yours is of course very welcome :)

andrea-i
Posts: 0
Joined: Tue Oct 07, 2008 4:51 am
Location: sydney

Post by andrea-i » Fri Oct 10, 2008 8:40 am

Hi Ton,

You are right saying that the integration I proposed would mean having an 'alien' in blender, and this is because my interest is to test the node engine itself, and such a light integration would probably require less effort for me.

But, if the community is actually looking for a dependency graph in the short term similar to the one I'm developing (I don't really know blender's roadmap at the moment), we could look at integrating this node engine the same way softimage introduced ICE in xsi, a subgraph for moving particles, objects and vertices around.

This way the node engine would find an initial less intrusive implementation, and surely more useful to the blender community from the start.

Problem with that is, I won't be able to work on such a deep integration between the engine and blender, being my spare time allocated on the actual node engine itself.

So, just give me a shout if you think that engine might be compatible with the short term plans of blender, of course I'll keep on developing it to proof it actually works (you never know with these things ; ).

Andrea

mr_projects
Posts: 0
Joined: Sat Sep 12, 2009 12:47 am

Post by mr_projects » Sat Sep 12, 2009 1:01 pm

Hi I'm new to this community, I'm wondering any dev updates on this ? I recently found out that the Blender Textures now have nodal support, what are the chances of seeing blender adapting nodes on other areas ?

mtbnut
Posts: 0
Joined: Wed Dec 30, 2009 1:55 am

Post by mtbnut » Wed Dec 30, 2009 2:57 am

I'd like to see everything (including geometry, not just particle systems and materials) in a scene as the output of some network of nodes.

Standard idea: Each node would have various properties and inputs. The inputs can either be literal values, or outputs of other nodes. If you make any changes, these are automatically propagated throughout the network. The data the nodes can work on could be a variety of types including meshes, curves, textures, vectors, matrices, etc.

This seems quite attractive from a programming point of view. Once you have some basic nodes, these could be derived into more complex nodes in C++. Or you could have nodes which contain networks within them (compound nodes). A few special nodes could make a network powerful enough to implement any computational task.

From a user interface / workflow point of view, any changes made directly to the output of a network (e.g. the translation of a vertex from the UI) would be added as a new node in the network, that sits between the new output and the output of the old network. Then everything is automatically non-linear. And everything is automatically animatable - the timeline is a node. You can use it as an input to a curve, which determines a function whose value is the input to the node property you want animated, etc.

I'm wondering whether it would be easier to implement something from scratch rather than have it as a plugin to Blender. Either way there would need to be a core library of value types and nodes which work on them.

But then to make it standalone, I assume you'd want a SWIG interface, so this core library can be used and extended from Python. The user interface could be implemented in Qt, and rich viewports provided by OGRE 3D. There would be special nodes which take a value type, and provide a UI for it. E.g. give it a mesh, and it adds it to the OGRE scene in the viewports, handles object picking etc. A benefit of Qt is that it has a Python wrapper - much of the UI should be done from python.

Post Reply