Questions tagged [camera]

In the real world, a camera is a device that takes physical or digital photos. In the virtual world, it is used to aim at virtual objects and or move through a virtual scene.

Physical Camera

A camera is a device that records images that can be stored directly, transmitted to another location, or both. These images may be still photographs or moving images such as videos or movies.

A digital camera is a kind of camera that takes video or still photographs by recording images on an electronic image sensor. Most cameras sold today are digital, and are incorporated into many devices ranging from PDAs and mobile phones to vehicles.

An Internet protocol camera, or IP camera, is a type of digital video camera commonly employed for surveillance, and which unlike analog closed circuit television (CCTV) cameras can send and receive data via computer network and the Internet.

A webcam is similar to an IP camera, but is normally connected directly to a computer via fast physical connection (USB, FireWire, etc).

Virtual Cameras

Much as real-life cameras provide a view of a scene in the real world, a virtual camera system provides a view of scene in virtual worlds. In 3D video games, a virtual camera system aims at controlling a camera or a set of cameras to display a view of a 3D virtual world. These virtual camera systems are often used in video games, where their purpose is to show the action at the best possible angle; more generally, they are used in 3D virtual worlds when a third person view is required.

Cameras in Computer Vision

An important application for cameras in the context of programming is in the field of computer vision. In particular, development of algorithms and code for the purpose of recognition, motion analysis, scene reconstruction, image restoration and so forth. The camera parameters, calibration and references to other cameras are significant factors in these algorithms.


References

14695 questions
91
votes
7 answers

How to set Android camera orientation properly?

I want to set the camera orientation according to the device orientation in Android but nothing seems to be working. I tried to rotate the Surface as well as the camera parameters but the camera preview in portrait mode always comes upside down. I…
Abhinav
  • 38,516
  • 9
  • 41
  • 49
85
votes
10 answers

How do I open the "front camera" on the Android platform?

More generally, if a device has more than one embedded camera, is there a way to initialize one of them in particular? I didn't find it in Android reference…
Sol
  • 907
  • 1
  • 7
  • 5
79
votes
9 answers

Using Camera in the Android emulator

I wish to simulate camera in the android emulator using the webcam. Basically I need to only take photos with the camera in the emulator (live preview is not needed i.e if it makes it any easier) I followed the tutorial here which is the only one I…
Primal Pappachan
  • 25,857
  • 22
  • 67
  • 84
74
votes
9 answers

Presenting camera permission dialog in iOS 8

When my app tries to access the camera for the first time on iOS 8, the user is presented with a camera permission dialog, much like the microphone one for microphone access in iOS 7. In iOS 7, it was possible to invoke the microphone permission…
jamix
  • 5,484
  • 5
  • 26
  • 35
73
votes
5 answers

How SurfaceHolder callbacks are related to Activity lifecycle?

I've been trying to implement an application that requires camera preview on a surface. As I see the things, both activity and surface lifecycles consist of the following states: When I first launch my Activity:…
krugloid
  • 833
  • 1
  • 8
  • 5
72
votes
3 answers

How to draw an overlay on a SurfaceView used by Camera on Android?

I have a simple program that draws the preview of the Camera into a SurfaceView. What I'm trying to do is using the onPreviewFrame method, which is invoked each time a new frame is drawn into the SurfaceView, in order to execute the invalidate…
Cristian
  • 198,401
  • 62
  • 356
  • 264
68
votes
9 answers

How get permission for camera in android.(Specifically Marshmallow)

Hey I am designing an app in android studio. In which i require permission of camera. I have included in the the AndroidManifest.xml file. It is working properly in all versions of…
Toyas
  • 783
  • 1
  • 5
  • 6
67
votes
8 answers

Android Camera Intent: how to get full sized photo?

I am using intent to launch camera: Intent cameraIntent = new Intent( android.provider.MediaStore.ACTION_IMAGE_CAPTURE); getParent().startActivityForResult(cameraIntent, CAMERA_PIC_REQUEST); and using: Bitmap thumbnail = (Bitmap)…
Heuristic
  • 5,087
  • 9
  • 54
  • 94
67
votes
4 answers

iPad remembering camera permissions after delete—how to clear?

I'm trying to recreate the condition where the following code returns AVAuthorizationStatusNotDetermined: AVAuthorizationStatus authStatus = [AVCaptureDevice authorizationStatusForMediaType:AVMediaTypeVideo]; However, the iPad appears to remember…
Rogare
  • 3,234
  • 3
  • 27
  • 50
66
votes
4 answers

Single intent to let user take picture OR pick image from gallery in Android

I'm developing an app for Android 2.1 upwards. I want to enable my users to select a profile picture within my app (I'm not using the contacts framework). The ideal solution would be to fire an intent that enables the user to select an image from…
Damian
  • 8,062
  • 4
  • 42
  • 43
66
votes
7 answers

Taking pictures with camera on Android programmatically

I have created an app with a button and wrote onClickListener for that button. I have tried several sample code examples and none of them worked. They all bring up the Android camera app and don't take photographs. I want some code which I can put…
Kevik
  • 9,181
  • 19
  • 92
  • 148
64
votes
4 answers

Is there a way to ask user for Camera access after they have already denied it on iOS?

I am using this code, but unfortunately it doesn't work. After a user has denied camera access, I want to ask them for permission to use the camera again the next time they try to load it (in this case it's a barcode scanner using the camera view).…
Ethan Allen
  • 14,425
  • 24
  • 101
  • 194
62
votes
1 answer

Best way to access web camera in Java

I need to access web camera using Java. This is what I want to do Access web cam Now the user can see web cam working because his face is visible on screen (have heard some libs are there which doesn't show the video output of webcam) when user…
PeakGen
  • 21,894
  • 86
  • 261
  • 463
60
votes
9 answers

method called after release() exception unable to resume with android camera

While developing a camera app I've encountered an exception that only happened when I switch to other app (onPause() for my app). 01-15 17:22:15.017: E/AndroidRuntime(14336): FATAL EXCEPTION: main 01-15 17:22:15.017: E/AndroidRuntime(14336):…
tom91136
  • 8,662
  • 12
  • 58
  • 74
55
votes
13 answers

Get last image from Photos.app?

I have seen other apps do it where you can import the last photo from the Photos app for quick use but as far as I know, I only know how to get A image and not the last (most recent one). Can anyone show me how to get the last image?
SimplyKiwi
  • 12,376
  • 22
  • 105
  • 191