Reputation: 19
I am new in xamarin.forms and i wants to make a app using xamarin.forms for capture a image and save in given path. i also want add Camera Overlay to crop image in Circle shape. I have found below sample project-
'https://github.com/CrossGeeks/OverlaySample'
and modified it to add button in common project and call capture event using rendering. capture event successfully fire but image capturing not working because of 'SurfaceView' in above sample.
Please help- How to capture image using 'SurfaceView'.
Thanks in advance.
Upvotes: 0
Views: 1083
Reputation: 14981
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
Upvotes: 0