Closed cl549723678 closed 3 months ago
var cameraContext = wx.createCameraContext(); cameraFrameListener = cameraContext.onCameraFrame((result) { try { buffer.write("onCameraFrame:${result.width},${result.height}\n"); update(); } catch (e) { buffer.write("error:${e.toString()}\n"); update(); } }); CameraFrameListenerStartOption? cameraFrameListenerStartOption = CameraFrameListenerStartOption() ..success = (result) { buffer.write("success:${result.errMsg}\n"); update(); } ..complete = (result) { buffer.write("complete:${result.errMsg}\n"); update(); }; cameraFrameListener?.start(cameraFrameListenerStartOption);
mpflutter版本: mpflutter_core: ^2.7.0 mpflutter_build_tools: ^2.7.1 mpflutter_wechat_api: ^2.2.3 flutter版本:3.22.1 操作系统:windows10 IDE:androidstudio 微信基础库版本:3.1.4
在onCameraFrame回调中使用result.width便报错
var cameraContext = wx.createCameraContext(); cameraFrameListener = cameraContext.onCameraFrame((result) { try { buffer.write("onCameraFrame:${result.width},${result.height}\n"); update(); } catch (e) { buffer.write("error:${e.toString()}\n"); update(); } }); CameraFrameListenerStartOption? cameraFrameListenerStartOption = CameraFrameListenerStartOption() ..success = (result) { buffer.write("success:${result.errMsg}\n"); update(); } ..complete = (result) { buffer.write("complete:${result.errMsg}\n"); update(); }; cameraFrameListener?.start(cameraFrameListenerStartOption);
mpflutter版本: mpflutter_core: ^2.7.0 mpflutter_build_tools: ^2.7.1 mpflutter_wechat_api: ^2.2.3 flutter版本:3.22.1 操作系统:windows10 IDE:androidstudio 微信基础库版本:3.1.4
在onCameraFrame回调中使用result.width便报错