Hi Enrico,
there is a special initAsync() method.
bool updateConnectionState(std::string server, OSG::Real32 progress)
{
printf("%s %d", server.c_str(), progress);
return true;
}
try
{
if(!cluster_window->initAsync(updateConnectionState))
{
// destroy the cluster window this disconnects the servers.
subRefCP(cluster_window);
}
}
catch(OSG_STDEXCEPTION_NAMESPACE::exception &e)
{
// destroy the cluster window this disconnects the servers.
subRefCP(cluster_window);
}
Andreas
> Hi opensg users,
>
> I am working a bit on the interface for my multiple
> windowed system. Right now I'd like to check for the
> server presence on the line, and if none is present,
> to stop the application and warn the user.
>
> Right now the sketch looks like:
>
> 1) grab servers list
> 2) start connect thread
> 3) wait 5 seconds for connection
> 4) if no connection stop the thread and goto 1
>
> the connection thread simply does:
>
> 1) create a window
> 2) assign servers
> 3) call for win->init
>
> The problem is: when i stop the thread, the window won't shut
> the connection pipes so... if i launch the server
> the thing will lock on a previously defined pipe.
>
> Is there an abort connection signal? I gave a quick look
> at the code but couldn't find anything...
>
> thanks
> E.
>
>
> -------------------------------------------------------------------------
> 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
>
--
VREC
Robert-Bosch-Straße 7
D-64293 Darmstadt
Tel. 06151-4921035
-------------------------------------------------------------------------
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