camera-overlay

iOS - Positioning a custom overlay on camera (vertical alignment). Size of top black bar

五迷三道 提交于 2019-12-07 03:20:59
问题 I'm searching a programmatic solution to following problem: I want to draw a custom overlay on camera (iOS). And I want it to be vertically central on the camera output view. I've accomplished to draw my custom view centrically relatively to the screen, but not to the camera picture. To do that, I need to get the size of the top black bar . How can I get it? The size of top and bottom bars are not equal, that's why the picture I get has this annoying y-offset to the bottom. Notice the offset

Exlusive touch in cameraoverlay view (of the camerapicker) in iOS?

≯℡__Kan透↙ 提交于 2019-12-06 14:02:49
In my application, I added a cameraOverlayView to the camerapicker. It contains three subviews, two UIButtons and one UIImageView . The image is draggable. The buttons are used to change the image to another one. When I touch a button, or the image, the tap-to-focus rect of the camera will always be displayed beneath (and the actual focus will change). Setting exclusiveTouch to YES on all three subviews doesn't change the behaviour. Any idea, how i can stop the camerapicker from getting the touches of my buttons / subviews of my overlayview (but still getting the touches for touch-to-focus,

iOS - Positioning a custom overlay on camera (vertical alignment). Size of top black bar

走远了吗. 提交于 2019-12-05 06:10:17
I'm searching a programmatic solution to following problem: I want to draw a custom overlay on camera (iOS). And I want it to be vertically central on the camera output view. I've accomplished to draw my custom view centrically relatively to the screen, but not to the camera picture. To do that, I need to get the size of the top black bar . How can I get it? The size of top and bottom bars are not equal, that's why the picture I get has this annoying y-offset to the bottom. Notice the offset of the resulting pic: OK guys, I ended up using AVFoundation, which in the end was even better solution

How to customise the Camera screen frame?

梦想与她 提交于 2019-12-05 03:40:16
问题 I want to lauch camera with customised frame so that I should be able to show UIsearchBar in the same View and on touching the UISearchBar I need to close the camera, but the UIsearchBar should be visible. So I want to stop the camera to take the full iPhone screen as a frame. So I want to know how to customise the Camera Screen? 回答1: You basically have two options. The easiest one is to use the cameraOverlayView property of the UIImagePickerController. This allows you to display a view on

cameraOverlayView prevents editing with allowsEditing

≡放荡痞女 提交于 2019-12-04 20:45:31
问题 Editing a photo after it's been taken (moving and scaling it) works fine in my app with this line: [imagePicker setAllowsEditing:YES]; But if I also use a cameraOverlayView, the editing mode doesn't work anymore. The screen comes up, but pan and pinch gestures don't make anything happen. I'm using your average image picker controller: UIImagePickerController *imagePicker = [[UIImagePickerController alloc] init]; And I add a camera overlay view, created from a custom view controller's view:

Combining Images in CameraView with Overlay. (Swift 3)?

蓝咒 提交于 2019-12-04 18:41:34
I just about have this solved. Thanks to some brilliant help getting me on the right track. This is the code I have now. Basically, I can now make an image out of the drawn overlay, and the cameraPreview. But can't yet combine them. There seems very little useful code that I can find that does this simply. So the important part is the extension block right at the top, and the additions to the func saveToCamera() near the bottom of the code. In short, I now have the two images I need, I think. The snap of the myImage is appearing on a white background - so not sure if that's natural - or not.

How to customise the Camera screen frame?

眉间皱痕 提交于 2019-12-03 22:01:43
I want to lauch camera with customised frame so that I should be able to show UIsearchBar in the same View and on touching the UISearchBar I need to close the camera, but the UIsearchBar should be visible. So I want to stop the camera to take the full iPhone screen as a frame. So I want to know how to customise the Camera Screen? You basically have two options. The easiest one is to use the cameraOverlayView property of the UIImagePickerController. This allows you to display a view on top of the camera: http://developer.apple.com/library/ios/documentation/uikit/reference

cameraOverlayView prevents editing with allowsEditing

时间秒杀一切 提交于 2019-12-03 13:03:09
Editing a photo after it's been taken (moving and scaling it) works fine in my app with this line: [imagePicker setAllowsEditing:YES]; But if I also use a cameraOverlayView, the editing mode doesn't work anymore. The screen comes up, but pan and pinch gestures don't make anything happen. I'm using your average image picker controller: UIImagePickerController *imagePicker = [[UIImagePickerController alloc] init]; And I add a camera overlay view, created from a custom view controller's view: CameraOverlayViewController *overlayController = [[CameraOverlayViewController alloc] init]; UIView

How to record video with overlay view

让人想犯罪 __ 提交于 2019-12-01 10:45:46
Hi I am trying to record video with overlay. I have written: -(void)addOvelayViewToVideo:(NSURL *)videoURL to add overlay view on recorded video but it is not working. I written the code to record video in viewDidLoad using AVCaptureSession . //In ViewDidLoad //CONFIGURE DISPLAY OUTPUT self.previewLayer = [AVCaptureVideoPreviewLayer layerWithSession:self.captureSession]; [self.previewLayer setVideoGravity:AVLayerVideoGravityResizeAspectFill]; self.previewLayer.frame = self.view.frame; [self.view.layer addSublayer:self.previewLayer]; -(void)captureOutput:(AVCaptureFileOutput *)captureOutput

Using cameraOverlayView with UIImagePickerController

别来无恙 提交于 2019-11-30 08:57:46
I know this has been asked a number of time but I can't find an answer. I have an app that uses the UIImagePickerController to take a picture. The problem is that I only want the camera option to be available and I understand that I need to hide the standard controls: cameraUI.showsCameraControls=NO; and use a cameraOverlayView to provide my own controls. I have had a look at Apple's PhotoPicker project already and my initial problem is how do I get an Overlay object onto my storyboard? I can't find such an object in the library. Any help gratefully received. Here is the code : toolBar=[