panlei
2019-07-01 1f18ac5866a75db56657155bd10b2cddf0b1566c
main.go
@@ -10,24 +10,24 @@
   "gocv.io/x/gocv"
   "image"
   "image/color"
   "log"
   "os"
   "ruleprocess/insertdata"
   "ruleprocess/ruleserver"
   "ruleprocess/util"
   "sync"
)
func main() {
   //wg := sync.WaitGroup{}
   //wg.Add(1)
   //go ruleserver.TimeTicker()
   //nReciever("ipc:///tmp/sdk-2-rules-process.ipc", deliver.PushPull, 1)
   //wg.Wait()
   resp,err := DrawPolygonOnImage()
   if err != nil {
      log.Println("画框或者上传有问题")
   }
   log.Println(resp["fileUrl"].(string))
   wg := sync.WaitGroup{}
   wg.Add(1)
   go ruleserver.TimeTicker()
   nReciever("ipc:///tmp/sdk-2-rules-process.ipc", deliver.PushPull, 1)
   wg.Wait()
   //resp,err := DrawPolygonOnImage()
   //if err != nil {
   //   log.Println("画框或者上传有问题")
   //}
   //log.Println(resp["fileUrl"].(string))
}
func nReciever(url string, m deliver.Mode, count int) {
   c := deliver.NewServer(m, url)
@@ -117,7 +117,6 @@
         arg.IsStatic = false
         if len(sdkinfo.Sdkdata) > 1 {
            // 大于1才有数据
            fmt.Println("----------------------------------------------------",m.Cid)
            yoloParam := protomsg.ParamYoloObj{}
            err = proto.Unmarshal(sdkinfo.Sdkdata, &yoloParam)
            if err != nil {