I’m currently implementing websocket communication betweeb the server (VB .NET) and the client(web page)
I succeeded in sending text from server to the client and display the text using JavaScript and canvas,
Now I want to send an image from the server to be displayed in the HTML5 canvas,
The websocket server implementation I use is Fleck
any suggestion? I lack binary/bmp knowledge
From a quick look at the Fleck source, you can send binary data using
(where socket will be a member variable you store in the
OnOpendelegate of theIWebSocketConnectionpassed to your server’sStartmethod)Note that not all browsers support reading binary frames yet. Recent versions of Chrome support it; I’m not sure if any others do yet.