Hi Craig,
[EMAIL PROTECTED] wrote:
> Heya,
>
> Long time reader, first time writer to the lists. I am currently trying
> to get to grips with the development of custom nodes, and am currently
> working on my second test node. The main purpose of the node is to :
>
...
>
> Here is where my question comes in. I have added a quick test to the
> renderEnter function that tests whether the core has been initialised or
> not by calling
>
> if (!getInitialised()) {
> initialiseFromImage();
> }
>
> This means that if for whatever reason, after I edited some details and
> decided to invalidate the mesh, and decided to mark it as uninitialised,
> it would regenerate the code when the renderAction activates the
> renderEnter function.
>
> This has a slightly unexpected effect. When I set up a single server,
> and a single client, and run the client through all of the steps above
> and I *don't* call geo->initialiseFromImage();, the server receives the
> image, mesh resolution and initialisation data, but not the mesh data,
> and when it tries to render on the server, it notices that the data
> hasn't been initialised, and calls initialiseFromImage() from the
> server, so I don't need to distribute very large amounts of geometry. I
> have tested and this seems to work, however, only with a single server.
> If I attempt to use two different servers (and these are the generic
> servers, simply compiled from the OpenSG tutorial), neither of them
> register that my core has not been initialised, the client does not
> initialise, and so in fact no geometry is ever created. It is as though
> the core has not been distributed with the correct value of "initialised".
>
> Is there something fundamentally missing in my understanding about
> distribution works, I am missing something? Because with initialisation
> happening on the client, it works perfectly, and running it without
> distribution works perfectly.
Nope, that sounds perfectly fine. There is really no reason for one or two
servers to behave differently.
One scenario that I could imagine causing the behavior: I assume your NodeCore
is derived from Geometry. If you call beginEdit on it without setting a mask,
the inherited parts will be transfered, too, which would overwrite the changes
made on the server and remove the created geometry. Can you try setting the
fieldmasks for begin/endEdit and see if that makes a difference?
Dirk
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Opensg-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensg-users