Camera Class

[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]

The base class for camera application support.

Inheritance Hierarchy


Namespace:  Microsoft.Devices
Assembly:  Microsoft.Phone (in Microsoft.Phone.dll)


Public MustInherit Class Camera _
    Implements IDisposable
public abstract class Camera : IDisposable

The Camera type exposes the following members.


  Name Description
AvailableResolutions Queries the camera for the available resolutions.
CameraType Gets the type of camera that the Camera object represents; indicates the location of the camera on the device.
Orientation Gets the number of degrees that the viewfinder brush needs to be rotated clockwise to align with the camera sensor.
PreviewResolution Gets the current resolution of the image provided by the PhotoCameraGetPreviewBuffer methods. This method is for use by the live viewfinder.
Resolution Gets or sets the resolution of the image captured by the camera.



  Name Description
Dispose Disposes of the image source stream and frees resources used by the Camera object.
Equals(Object) Determines whether the specified Object is equal to the current Object. (Inherited from Object.)
Finalize Releases unmanaged resources and performs other cleanup operations before the Camera object is reclaimed by garbage collection. (Overrides Object..::.Finalize()()().)
GetHashCode Serves as a hash function for a particular type. (Inherited from Object.)
GetType Gets the Type of the current instance. (Inherited from Object.)
IsCameraTypeSupported Determines whether the specified type of camera is supported on the device.
MemberwiseClone Creates a shallow copy of the current Object. (Inherited from Object.)
ToString Returns a string that represents the current object. (Inherited from Object.)



  Name Description
Initialized Occurs when the camera object has been initialized.



For more information about how to implement the members in this class, see How to create a base camera app for Windows Phone 8.

Important Note:

If photo capture is not a core feature of your application, consider using the Camera Capture Task to capture photos instead of using the camera APIs directly. Memory allocated for the Camera Capture Task does not count toward total application memory use. This helps minimize your application’s memory use, which is particularly important when your application runs on a lower-memory device. For more information, see Developing apps for lower-memory phones for Windows Phone 8 and How to use the camera capture task for Windows Phone 8.


If you use this API in your app, you must specify the following capabilities in the app manifest. Otherwise, your app might not work correctly or it might exit unexpectedly.


Windows Phone 8, Windows Phone OS 7.1

For more info, see App capabilities and hardware requirements for Windows Phone 8.

Version Information

Windows Phone OS

Supported in: 8.1, 8.0, 7.1


Windows Phone

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

See Also


Microsoft.Devices Namespace