| | |
| | | package service |
| | | |
| | | import ( |
| | | "bytes" |
| | | "encoding/json" |
| | | "errors" |
| | | "flag" |
| | | "fmt" |
| | | "gocv.io/x/gocv" |
| | | "io" |
| | | "log" |
| | | "mime/multipart" |
| | | "net/http" |
| | | "os" |
| | | "os/exec" |
| | | "path/filepath" |
| | | "strconv" |
| | | "time" |
| | | "webserver/extend/config" |
| | | "webserver/extend/esutil" |
| | | |
| | | "basic.com/dbapi.git" |
| | | "basic.com/valib/capture.git" |
| | | ) |
| | | |
| | | /*以下属于旧版本地摄像机获取截图(国标摄像机底图无法刷新) |
| | | func PostFormBufferData(uri string, filepath string, fileName string) (maps map[string]interface{}, err0 error) { |
| | | // 要指定转byte的格式 |
| | | picMat := gocv.IMRead(filepath, gocv.IMReadColor) |
| | |
| | | return "", errors.New("update filelocal to camera fail") |
| | | } |
| | | return filename, nil |
| | | } |
| | | }*/ |
| | | |
| | | //调用统一接口,刷新底图(集成国标底图刷新) |
| | | func UpdateCapture(cid string) (fileName string,err error){ |