// ----------------------------------------------------------------------------------------------------- private static IRenderEngine createRenderEngine(ParamsCreateScreenVIZ vizParams, string sceneName) { ICollection <ServerInfo> lstServers = new List <ServerInfo>(); lstServers.Add(new ServerInfo() { Name = "Viz1", TCPAddress = vizParams.AnimationAddress, TCPPort = vizParams.AnimationPort, UDPAddress = vizParams.ValueAddress, UDPPort = vizParams.ValuePort, DataPoolAddress = vizParams.ValueAddress, DataPoolPort = vizParams.ValuePort }); IServerSettingsLoader sc_settings = new ServerSettingsLoaderDirect(lstServers); IGraphicEngineConn graphicEngineConn = new GraphicEngineConn(sc_settings); ICommandSenderVIZ commandSender; commandSender = new CommandSenderVIZ(graphicEngineConn); RenderEngineVIZ.SceneManager.ISceneConfig sceneConfigLoader = new RenderEngineVIZ.SceneManagerVIZ.SceneConfigLoaderBasicVIZ(sceneName); RenderEngineVIZ.SceneManager.ISceneManager sceneManager = new RenderEngineVIZ.SceneManagerVIZ.SceneManagerVIZ(sceneConfigLoader); return(new RenderEngineVizRT_2011(commandSender, sceneManager, graphicEngineConn)); }
internal static IGraphicsService Create(ParamsCreateScreenVIZ vizParams, string sceneName, IComputerVisionManager cvManager) { IRenderEngine renderEngine = createRenderEngine(vizParams, sceneName); // Crear el server --------------------------------------------------------------- IUserCommandParser userCommandParser = new UserCommandParser(); IOutputsSettings outputsSettings = new OutputsSettings(); GraphismVAS2015_0 theGraphism = new GraphismVAS2015_0(renderEngine, cvManager); TheGraphism = theGraphism; return(new GraphicsServiceBasic(userCommandParser, theGraphism, renderEngine, outputsSettings)); }
public void connectVIZ(string tcpadd, string udpadd, int tcpport, int udpport) { ParamsCreateScreenVIZ paramsVIZ = new ParamsCreateScreenVIZ( IPAddress.Parse(tcpadd), tcpport, IPAddress.Parse(udpadd), udpport); string sceneName = TxtScene.Text; if (mGraphicsService != null) { mGraphicsService.Stop(); mGraphicsService = null; } mGraphicsService = GraphicsServiceVAS0Factory.Create(paramsVIZ, sceneName, mComputerVisionManager); mGraphicsService.RenderEngine.CommandValueSentEvent += RenderEngine_CommandValueSentEvent; mGraphicsService.RenderEngine.CommandAnimationSentEvent += RenderEngine_CommandAnimationSentEvent; mGraphicsService.Start(); }