且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

如何使用相机“圆圈"覆盖捕获图像并将其保存在 Xamarin.forms (Android) 中的路径上

更新时间:2023-09-28 11:43:58

SurfaceView 在原生Android中使用,你可以在android项目中创建一个包含surfaceview的customview,然后创建一个自定义viewrenderer 和 SetNativeControl(your customview) 你可以参考 Android 项目中的 CameraPreviewRendererNativeCameraPreview 类和 CameraPreview 类在表单项目中.您可以参考 SurfaceView 了解更多信息和 示例使用surfaceview

SurfaceView is in used in the native Android, you could create a customview that include an surfaceview in android project,then create a custom viewrenderer and SetNativeControl(your customview) your could refer to the CameraPreviewRenderer ,NativeCameraPreview classes in android project and CameraPreview class in forms project.You can refer to SurfaceView for more information and a sample for using surfaceview