You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
470 B
23 lines
470 B
import QtWebSockets 1.1 |
|
|
|
import "." |
|
|
|
|
|
WebSocket { |
|
property string wsIp: "localhost" |
|
property int wsPort: 5050 |
|
|
|
url: "ws://" + wsIp + ":" + wsPort |
|
active: true |
|
|
|
onStatusChanged: { |
|
if(status === WebSocket.Closed || status === WebSocket.Error) { |
|
Common.wsocketClosed(); |
|
} |
|
} |
|
|
|
onBinaryMessageReceived: { |
|
let arrayBuffer = new Float32Array(message); |
|
Common.audioDataUpdated(arrayBuffer.slice()); |
|
} |
|
}
|
|
|