<div dir="ltr">How do I learn what to do on the client side? I see the ParaViewWebClient.createClient() function, and I see that I can add a hash of custom protocols to it, but when I try, the client complains.<div><br></div><div>I tried this:</div><div><br></div><div><div>const config = { sessionURL: 'ws://localhost:1234/ws' };</div><div>const smartConnect = SmartConnect.newInstance({ config });</div><div><br></div><div>const amsProtocols = {</div><div> testbuttonService: function createMethods(session) {</div><div> return {</div><div> testbutton: () => {</div><div> console.log("hi there ******************");</div><div> return session.call('amsprotocol.testbutton',[])</div><div> .then((result) => log('result' + result));</div><div> },</div><div> };</div><div> },</div><div>};</div><div><br></div><div>smartConnect.onConnectionReady((connection) => {</div><div> const pvwClient =</div><div> ParaViewWebClient.createClient(connection,</div><div> [</div><div> 'MouseHandler',</div><div> 'ViewPort',</div><div> 'ViewPortImageDelivery',</div><div> 'testbuttonService' // <--- I thought this...</div><div> ],</div><div> amsProtocols); // <--- ...was a key into this hash. No?</div><div> </div></div><div>Obviously I'm misunderstanding something here, but can someone explain what I'm missing? Where is the structure of a client described?</div><div><br></div><div>Do I need to do any of this if all I'm trying to do is to get button presses and selection widgets to communicate with the pvpython server?</div><div><br></div><div>Thank you,</div><div><br></div><div> -Tom</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Feb 22, 2018 at 11:49 AM, Sgouros, Thomas <span dir="ltr"><<a href="mailto:thomas_sgouros@brown.edu" target="_blank">thomas_sgouros@brown.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Thank you, I will look at it. <div><br></div><div> -Tom</div></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Feb 22, 2018 at 11:24 AM, Sebastien Jourdain <span dir="ltr"><<a href="mailto:sebastien.jourdain@kitware.com" target="_blank">sebastien.jourdain@kitware.<wbr>com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">LightViz will be a good example as it defines a custom set of protocols instead of using only the default ones like in Visualizer.<div><br></div><div><a href="https://github.com/Kitware/light-viz/tree/master/server" target="_blank">https://github.com/Kitware/lig<wbr>ht-viz/tree/master/server</a><br></div></div><div class="gmail_extra"><br><div class="gmail_quote"><div><div class="m_3184310194794949366h5">On Thu, Feb 22, 2018 at 6:59 AM, Sgouros, Thomas <span dir="ltr"><<a href="mailto:thomas_sgouros@brown.edu" target="_blank">thomas_sgouros@brown.edu</a>></span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="m_3184310194794949366h5"><div dir="ltr">Hello all:<div><br></div><div>Can someone describe the steps necessary to create and use a web socket connection between a Paraviewweb client and a pvpython server? I am not having much luck finding the documentation for registerVtkWebProtocol() which appears to be an important part of the process. Google only helps me find pvw-visualizer.py, which I'm sure is useful code, but I'm having a hard time making much sense of it as an example.</div><div><br></div><div>I would appreciate even just being pointed to the vtk python code, but I'll take any pointers you can offer.</div><div><br></div><div>Thank you,</div><div><br></div><div> -Tom</div></div>
<br></div></div>______________________________<wbr>_________________<br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/opensou<wbr>rce/opensource.html</a><br>
<br>
Please keep messages on-topic and check the ParaView Wiki at: <a href="http://paraview.org/Wiki/ParaView" rel="noreferrer" target="_blank">http://paraview.org/Wiki/ParaV<wbr>iew</a><br>
<br>
Search the list archives at: <a href="http://markmail.org/search/?q=ParaView" rel="noreferrer" target="_blank">http://markmail.org/search/?q=<wbr>ParaView</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="https://public.kitware.com/mailman/listinfo/paraview" rel="noreferrer" target="_blank">https://public.kitware.com/mai<wbr>lman/listinfo/paraview</a><br>
<br></blockquote></div><br></div>
</blockquote></div><br></div>
</div></div></blockquote></div><br></div>