Skip to content
9miao Mobile Game edited this page Jul 8, 2014 · 1 revision

CAMediaManager Detailed Description

Class Description

Photograph functionality and photo album reading.

Base Class

CAObject

Attribute

Access modifier

Attribute name

Description

Protected

MediaDelegate

agent

Method

Access modifier

Method name

Description

public

shareCAMediaManager

Obtain singleton

public

addCameraView

Open camera

public

addAlbumView

Open photo album

Attribute Description

MediaDelegate
Type: CAMediaDelegate *
Description: we need to inherit CAMediaDelegate and rewrite the internal interface that is used to obtain photo when using media, so as to obtain the photo.

Method Description

static CAMediaManager shareCAMediaManager()*
Return value: CAMediaManager*
Description: build mediaManager singleton object

void addCameraView()
Return value: void
Description: open camera functionality.

void addAlbumView()
Return value: void
Description: open photo album functionality

Example:

1

2

3

CAMediaManager* media = CAMediaManager::shareCAMediaManager();

media->setMediaDelegate(this);

media->addAlbumView();

Clone this wiki locally