diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 0000000..35b58f8 --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,6 @@ +{ + "cmake.ignoreCMakeListsMissing": true, + "files.associations": { + "dart_native_api.h": "c" + } +} \ No newline at end of file diff --git a/lib/pages/pass_track/view.dart b/lib/pages/pass_track/view.dart index 50fb979..ca1b3f3 100644 --- a/lib/pages/pass_track/view.dart +++ b/lib/pages/pass_track/view.dart @@ -86,11 +86,11 @@ class _PasstrackState extends State { // }); }); var f = initPlatformState(); - + var future = controller.getHisFileList(_passTrackPlugin); f.then((void _) { _passTrackPlugin.setGridColor(const Color.fromARGB(255, 0, 0, 0).value); _passTrackPlugin.drawGrid(); - var future = controller.getHisFileList(_passTrackPlugin); + future.then((value) { _passTrackPlugin.setScale(1); for (var TID in controller.deviceMap.keys) { @@ -102,12 +102,15 @@ class _PasstrackState extends State { // 统计用时 获取当前时间 var start = DateTime.now().millisecondsSinceEpoch; // _passTrackPlugin.generateTile(0, value); - _passTrackPlugin.waitForTile(); + _passTrackPlugin.waitForTile((){ + var start = DateTime.now().millisecondsSinceEpoch; + print("len: ${_passTrackPlugin.allTileCnt()}"); + _passTrackPlugin.playTrack(0, value, true, 0, ffi.nullptr); + var end = DateTime.now().millisecondsSinceEpoch; + print("play: ${end - start}"); + }); // _passTrackPlugin.drawGrid(); - _passTrackPlugin.playTrack(0, value, true, 0, ffi.nullptr); // 获取当前时间 - var end = DateTime.now().millisecondsSinceEpoch; - print("耗时:${end - start}"); }); }); } diff --git a/plugins/pass_track b/plugins/pass_track index bc4de9c..65de63a 160000 --- a/plugins/pass_track +++ b/plugins/pass_track @@ -1 +1 @@ -Subproject commit bc4de9cc6145dd03116e9b0557902d87776e9671 +Subproject commit 65de63acc0c565de548b02b15be6554b24ebad11