diff --git a/protos/picture.proto b/protos/picture.proto index 0224524..6515057 100644 --- a/protos/picture.proto +++ b/protos/picture.proto @@ -7,4 +7,6 @@ enum PictureType { StationLayout = 0; /** Psl界面 */ Psl = 1; + /** 继电器柜界面 */ + RelayCabinetLayout = 2; } diff --git a/protos/relayCabinetLayoutGraphics.proto b/protos/relayCabinetLayoutGraphics.proto new file mode 100644 index 0000000..d6db94b --- /dev/null +++ b/protos/relayCabinetLayoutGraphics.proto @@ -0,0 +1,67 @@ +syntax = "proto3"; + +package graphicData; +option java_package = "club.joylink.bjrtss.ats.verify.protos"; +option java_outer_classname = "LayoutGraphicsProto"; +option go_package = "./ats/verify/protos/graphicData"; + +message RelayCabinetGraphicStorage { + Canvas canvas = 1; + repeated RelayCabinet relayCabinets = 2; + repeated Relay relays = 3; +} + +message Canvas { + // 画布宽 + int32 width = 1; + // 画布高 + int32 height = 2; + // 背景色 + string backgroundColor = 3; + // 视口变换 + Transform viewportTransform = 4; +} + +message Point { + // x坐标 + float x = 1; + // y坐标 + float y = 2; +} + +//变换 +message Transform { + // 位移 + Point position = 1; + // 缩放 + Point scale = 2; + // 旋转弧度 + float rotation = 3; + // 歪斜 + Point skew = 4; +} + +//子元素变换 +message ChildTransform { + // 子元素名称 + string name = 1; + // 子元素变换 + Transform transform = 2; +} +// 公共属性 +message CommonInfo { + string id = 1; + string graphicType = 2; + Transform transform = 3; + repeated ChildTransform childTransforms = 4; +} + +message RelayCabinet { + CommonInfo common = 1; + string code = 2; +} + +message Relay { + CommonInfo common = 1; + string code = 2; +}