Jump to content

Syncker WorldSplineGraph Unigine 2.9.02


photo

Recommended Posts

(Unigine 2.9.0.2)

I am trying to dynamically generate a path for a pilot to follow.  The idea is that when the pilot presses a button I will create a worldSplineGraph from their current position to their next waypoint.  This works great on the Master computer but unfortunately it appears that Syncker does not support worldSplineGraphs as a node type. Thus the worldSplineGraph object is only visible on the center projector (master computer) and none of my 4 side projectors (slaves).  I have tried adding the worldSplineGraph as a child to a dummy node since that type is supported but I still get an error.

13:05:11 Spline Initialized
13:05:11 Syncker::Master::createNode(node_id: 1636585994, include_children: 1, add_to_sync: 1, sync_mask: 255)
13:05:11 Syncker::Master::send_tcp_create_node(): started
13:05:11 Syncker::Master::send_tcp_create_node(): existed and supported
13:05:11 Syncker::Master::send_tcp_create_node(): slaves count: 0
13:05:11 Syncker::Master::send_tcp_create_node(): added to buffer
13:05:11 Syncker::Master::send_tcp_create_node(): started
13:05:11 Syncker::Master::createNode(): unsupported node type "WorldSplineGraph"

To complicate things further the waypoint is located on a ship that is moving.  My solution to this is that I add the worldSplineGraph as a child to an existing IG::Ientity that represents the ship.  Again this works great on the master computer but the slaves can't seem to sync the worldSplineGraph.  The path has to be created on-demand as I do not know when or where the pilot will press the button to generate the flight path.

Any thoughts on a work around are highly appreciated.

Link to comment

Hi Robert,

WorldSplineGraph is really unstable object, we do not recommend to use it any production application.

As for the current task I think it would be possible to create a simple MeshDynamic object to display this visualization. You can use Geometry inflation option in material to be able to see the thin path from a far distance.

  • Like 1

How to submit a good bug report
---
FTP server for test scenes and user uploads:

Link to comment

I gave the MeshDynamic object a try and also get the same error about being an unsupported node type.  I see from the documentation that static mesh objects are supported so I tried converting it from a dynamic mesh to a static mesh:

int AppWorldLogic::init()
{...

        meshHolder = Mesh::create();
        mesh->getMesh(meshHolder);
        statMesh = ObjectMeshStatic::create(meshHolder);
        Log::message("meshes added to world\n");
        systemlogic_ptr->syncker_manager->getMaster()->createNode(mesh->getNode(), 1, 1);
        Log::message("dynamic mesh added to syncker\n");
        systemlogic_ptr->syncker_manager->getMaster()->createNode(statMesh->getNode(), 1, 1);
        //systemlogic_ptr->ig_manager->getSynckerMaster()->createNode(statMesh->getNode(), 1, 1);
        Log::message("static mesh added to syncker\n");

...

}

int AppWorldLogic::update(){

...

            statMesh->setParent(systemlogic_ptr->ig_manager->getEntity(1000)->getArticulatedPart(2)->getNode(0));
            statMesh->setPosition(Vec3(0.0f, 0.0f, 0.0f));
            int isSplineSynced = systemlogic_ptr->ig_manager->getSynckerMaster()->isSyncNode(spline->getNode());
            int isStatMeshSynced = systemlogic_ptr->ig_manager->getSynckerMaster()->isSyncNode(statMesh->getNode());
            Log::message("Is the static Mesh synced?: %f\n", isStatMeshSynced);

...

 

16:45:22 Is the static Mesh synced?: 0.000000

That doesn't give me the error about unsupported types but the object is still not being updated on the slave machines.  I can see it on the host machine.

Side note when I tried to add the statMesh to syncker using the commented out ig_manager option instead of directly with the syncker_manager the program would crash immediately upon loading.

 

Edited by robert.walters
change to <code> block
Link to comment

Hello!
if you created a mesh for objectmeshstatic at runtime, then information about that mesh is not available on the slave.
When master create an objectMeshStatic, it sent only the path to  file from slave load the mesh.

for the same reason, the ObjectMeshDynamic is not synchronized. meshes are not transmitted (this would be a very heavy load on the network in general)
if you need to synchronize meshes changed in runtime (ropes, cloth, deformation), then you can send mesh info through custom packages. (you can send only useful information - maybe only new positions of vertices or vectors and points of application of forces, etc.)


 

Link to comment
×
×
  • Create New...