fix
This commit is contained in:
parent
7510b363d6
commit
e9c5e96c52
|
@ -1,6 +1,6 @@
|
|||
Name: render
|
||||
Host: 0.0.0.0
|
||||
Port: 8888
|
||||
Port: 9919
|
||||
SourceMysql: fusentest:XErSYmLELKMnf3Dh@tcp(110.41.19.98:3306)/fusentest
|
||||
Auth:
|
||||
AccessSecret: fusen2023
|
||||
|
|
|
@ -270,9 +270,10 @@ func (w *wsConnectItem) dealwithReciveData(data []byte) {
|
|||
d, _ := json.Marshal(parseInfo.D)
|
||||
//分消息类型给到不同逻辑处理,可扩展
|
||||
switch parseInfo.T {
|
||||
//图片渲染数据组装
|
||||
case constants.WEBSOCKET_RENDER_IMAGE_ASSEMBLE:
|
||||
w.assembleRenderData(d)
|
||||
//图片渲染
|
||||
case constants.WEBSOCKET_RENDER_IMAGE:
|
||||
//数据组装
|
||||
w.renderImage(d)
|
||||
default:
|
||||
|
||||
}
|
||||
|
|
|
@ -22,7 +22,7 @@ type renderImageControlChanItem struct {
|
|||
}
|
||||
|
||||
// 渲染发送到组装数据组装数据
|
||||
func (w *wsConnectItem) assembleRenderData(data []byte) {
|
||||
func (w *wsConnectItem) renderImage(data []byte) {
|
||||
var renderImageData websocket_data.RenderImageReqMsg
|
||||
if err := json.Unmarshal(data, &renderImageData); err != nil {
|
||||
w.outChan <- w.respondDataFormat(constants.WEBSOCKET_ERR_DATA_FORMAT, "invalid format of websocket render image message:"+string(data))
|
||||
|
|
Loading…
Reference in New Issue
Block a user