“wangzhongjie” 0fe5385625 最新代码
2024-02-26 15:01:27 +08:00

42 lines
1.0 KiB
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import {
examJudgeMapSetParam,
examJudgeMapSetScaling
} from '../api/index'
import FileUtil from '../../../common/utils/File'
import FileModel from './../utils/file-model'
const judgeTag = 'SURENJUN_JUDGE'
export default class JudgeImg {
private judgeUI
private modelPath:string
private fileModel:FileModel
private fileUtil:FileUtil
private plcData:any
constructor(judgeUI) {
this.modelPath = 'models/model_enc'
this.judgeUI = judgeUI
this.fileUtil = new FileUtil(judgeUI.context)
this.fileModel = new FileModel(judgeUI.context)
this.init()
}
async init(){
const isJudgeInitBool = globalThis.isJudgeInitBool;
const {judgeUI} = this;
console.info(judgeTag,'1.进入评判入口')
await examJudgeMapSetParam(640, 480); //设置参数宽、高
await examJudgeMapSetScaling(120); //设置缩放比例一般默认填100就是100%的意思) 数字越大视野越大数字越小视野越小不能为0
judgeUI.draw = true
}
//获取评判初始化数据
getInitInfo = () =>{
}
}