Open camera in part of screen - android

I want open camera not full screen. I want open in a particular position on the screen inside one rectangle.
Maybe a surface? I don't know.
How can I do?
I want camera in my view. For example in a rectangle in center of screen. And when I push a button Take a pic

You can use surface view with camera preview for this.
This may help you.

Related

Camera screen orientation issue in titanium appcelerator

I have some issue in device orientation. What i did is that, i have to open camera for screen capture. The camera view is customized by using overlay. Overlay contains a button view, when click on it it will capture image.
I implement device orientation in it. When custom camera opens it looks fine. But when we rotate(that is, rotate to 180 degree) the over lay looks fine, but the camera view inverted the screen. That is for example, if we wish to capture a tree by rotating device, it'll see like upside down and when after capture, the image also inverted. Does anybody have any idea about how to remove this camera invert while rotating.
This issue is headache for many devs.
How do you rotate the camera? You have to rotate your overlay and pretend user that user is rotating the camera.
To get More info see this
Explanation is good.

Outline of person's face on android camera

I want to super-impose an outline of a face when the camera launches in android. Kind of like an empty avatar or a silhouette. I'm NOT looking for face detection. I just the want the user to have the ability to align the outline to the person's face when taking the picture, so that all pictures are taken at the same distance. I already have the camera launching. I'm thinking of putting the facial outline as my main layout and have the camera launching as the background of that layout. Any ideas?
Here you go
there is a section detailing how to do this.
http://developer.android.com/guide/topics/media/camera.html#custom-camera

move overlay image on camera preview

I want overlay an image in live camera preview using surface view. There are lot of tutorial in this case and my program run perfectly. Now i want add ability to move overlay image in live camera preview with touch event. I can't find any code or tutorial that explain that. Can somebody help me please?
if you do not use OpenGL and just float your overlay with opacity over surfaceView, you can set your own onDragListener() that handles android DragEvent( http://developer.android.com/reference/android/view/DragEvent.html) that can move the overlay detecting user's finger

Camera with transparency margin

I need a camera function on my App. This is what I need:
(From barcode-scanner but I need something for making pictures)
I need a transparency margin. Now when I would press "shot photo" I need exactly this:
Someone know a tool like that?
Thanky in advance.
You're going to have to map that out yourself and crop the bitmap.
You can draw the boundaries of the transparency window on the Canvas of the FrameLayout your camera's view.
From there, you grab the position of the transparency window in relation to the screen and then use those boundaries to cut out the desired area from the bitmap returned by the camera.

How to draw on top of camera preview?

I want to draw some thing on the view which we get when our camera is on in android mobile.
I do not want to take picture nor record video just that view from camera and then draw some thing on screen.
Drawing on screen will not be and issue but when we turn on camera which view we get and how can we use that view in our application?
You'll want to check androids camera-API.
You can get the preview to display in a SurfaceView or your own View-subclass, which can then be used to draw on. Some more knowledge might be found here.
You can use a RelativeLayout to put other views aligned with the surfaceView used for camera preview

Categories

Resources