疏密调节接口
This commit is contained in:
parent
584f228c91
commit
a6a4a0860d
|
@ -1437,6 +1437,38 @@ export default class ClientConnection {
|
|||
);
|
||||
}
|
||||
|
||||
public async SetBlendingHorDensity(
|
||||
row: number,
|
||||
column: number,
|
||||
control_point: number,
|
||||
value: number
|
||||
) {
|
||||
return await this.doRpc<Protocol.NoneResponse>(
|
||||
new Protocol.SetBlendingHoDensityRequestEntity(
|
||||
row,
|
||||
column,
|
||||
control_point,
|
||||
value
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
public async SetBlendingVerDensity(
|
||||
row: number,
|
||||
column: number,
|
||||
control_point: number,
|
||||
value: number
|
||||
) {
|
||||
return await this.doRpc<Protocol.NoneResponse>(
|
||||
new Protocol.SetBlendingVerDensityRequestEntity(
|
||||
row,
|
||||
column,
|
||||
control_point,
|
||||
value
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
public destory() {
|
||||
this.ws?.close();
|
||||
if (this.ws) {
|
||||
|
|
|
@ -514,6 +514,12 @@ export namespace Protocol {
|
|||
public static get kSaveBlendingConfig() {
|
||||
return Commands.PROTOCOL_PREFIX + "SaveBlendingConfig";
|
||||
}
|
||||
public static get kSetBlendingHorDensity() {
|
||||
return Commands.PROTOCOL_PREFIX + "SetBlendingHorDensity";
|
||||
}
|
||||
public static get kSetBlendingVerDensity() {
|
||||
return Commands.PROTOCOL_PREFIX + "SetBlendingVerDensity";
|
||||
}
|
||||
|
||||
static _all_commands = new Set([
|
||||
Commands.kUnKnowCommand,
|
||||
|
@ -642,7 +648,9 @@ export namespace Protocol {
|
|||
Commands.kEnableBlending,
|
||||
Commands.kSetBlendingOverlap,
|
||||
Commands.kGetBlendingConfig,
|
||||
Commands.kSaveBlendingConfig,
|
||||
Commands.kSaveBlendingConfig,
|
||||
Commands.SetBlendingHorDensity,
|
||||
Commands.SetBlendingVerDensity,
|
||||
]);
|
||||
public static get AllCommands() {
|
||||
return this._all_commands;
|
||||
|
@ -3391,4 +3399,52 @@ export namespace Protocol {
|
|||
}
|
||||
name = "";
|
||||
}
|
||||
|
||||
export class SetBlendingHorDensityRequestEntity extends PacketEntity {
|
||||
constructor(
|
||||
row: number,
|
||||
column: number,
|
||||
control_point: number,
|
||||
value: number,
|
||||
rpc_id = 0
|
||||
) {
|
||||
super();
|
||||
super.command = Commands.kSetBlendingHorDensity;
|
||||
super.flag = PacketEntity.FLAG_REQUEST;
|
||||
super.rpc_id = rpc_id;
|
||||
|
||||
this.row = row ?? 0;
|
||||
this.column = column ?? 0;
|
||||
this.control_point = control_point ?? 0;
|
||||
this.value = value ?? 0;
|
||||
}
|
||||
row = 0;
|
||||
column = 0;
|
||||
control_point = 0; //控制点编号,1开始,从上到下从左到右
|
||||
value = 0;
|
||||
}
|
||||
|
||||
export class SetBlendingVerDensityRequestEntity extends PacketEntity {
|
||||
constructor(
|
||||
row: number,
|
||||
column: number,
|
||||
control_point: number,
|
||||
value: number,
|
||||
rpc_id = 0
|
||||
) {
|
||||
super();
|
||||
super.command = Commands.kSetBlendingVerDensity;
|
||||
super.flag = PacketEntity.FLAG_REQUEST;
|
||||
super.rpc_id = rpc_id;
|
||||
|
||||
this.row = row ?? 0;
|
||||
this.column = column ?? 0;
|
||||
this.control_point = control_point ?? 0;
|
||||
this.value = value ?? 0;
|
||||
}
|
||||
row = 0;
|
||||
column = 0;
|
||||
control_point = 0; //控制点编号,1开始,从上到下从左到右
|
||||
value = 0;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue