ARWrapper Provides a C++ wrapper around ARToolKit and exposes a C and JNI API

- Main Page
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

All Classes Files Functions Variables Typedefs Enumerations Enumerator
Public Member Functions | Protected Attributes | List of all members
ARToolKitVideoSource Class Reference

Video source implementation using the ARToolKit arVideo module. More...

`#include <ARToolKitVideoSource.h>`

Inheritance diagram for ARToolKitVideoSource:

## Public Member Functions
| ARToolKitVideoSource ()
virtual const char * | getName ()
| Returns the name of this video source variation. More...
virtual bool | open ()
| Opens the video source. More...
virtual bool | captureFrame ()
| Asks the video source to capture a frame. More...
virtual bool | close ()
| Closes the video source. More...
Public Member Functions inherited from VideoSource
virtual | ~VideoSource ()
int | getError ()
bool | isOpen ()
| Returns true if the video source is open. More...
bool | isRunning ()
| Returns true if the video source is open and ready to be queried. More...
void | configure (const char *vconf, const char *cparaName, const char *cparaBuff, size_t cparaBuffLen)
    Sets initial parameters which will be used when the video source
is opened. More...
ARParamLT * | getCameraParameters ()
| Returns the camera parameters for the video source. More...
int | getVideoWidth ()
| Returns the width of the video in pixels. More...
int | getVideoHeight ()
| Returns the height of the video in pixels. More...
AR_PIXEL_FORMAT | getPixelFormat ()
| Returns the pixel format of the video. More...
ARUint8 * | getFrame ()
| Returns the current frame. More...
int | getFrameStamp ()
| Returns the current frame stamp. More...
bool | updateTexture (Color *buffer)
| Populates the provided color buffer with the current video frame. More...
bool | fastPath ()
bool | updateTexture32 (uint32_t *buffer)
void | updateTextureGL (int textureID)
| Updates the specified OpenGL texture with the current video frame. More...

## Protected Attributes
AR2VideoParamT * | gVid
Protected Attributes inherited from VideoSource
DeviceState | deviceState
| Current state of the video device. More...
char * | cameraParam
| Camera parameter filename. More...
char * | cameraParamBuffer
size_t | cameraParamBufferLen
ARParamLT * | cparamLT
| Camera paramaters. More...
char * | videoConfiguration
| Video configuration string. More...
int | videoWidth
| Width of the video frame in pixels. More...
int | videoHeight
| Height of the video frame in pixels. More...
AR_PIXEL_FORMAT | pixelFormat
| Pixel format from ARToolKit enumeration. More...
int | m_fastPath
GLenum | glPixIntFormat
GLenum | glPixFormat
GLenum | glPixType
ARUint8 * | frameBuffer
| Pointer to latest frame. Set by concrete subclass to point to frame data. More...
ARUint8 * | frameBuffer2
| For bi-planar formats, pointer to plane 2 of latest frame. Set by concrete subclass to point to frame data. More...
int | frameStamp
| Latest framestamp. Incremented in the concrete subclass when a new frame arrives. More...
int | m_error

## Additional Inherited Members
Static Public Member Functions inherited from VideoSource
static VideoSource * | newVideoSource ()
| Returns the correct VideoSource subclass for use on the current platform. More...
Protected Types inherited from VideoSource
enum | DeviceState { DEVICE_CLOSED, DEVICE_OPEN, DEVICE_GETTING_READY, DEVICE_RUNNING }
Protected Member Functions inherited from VideoSource
void | setError (int error)
| VideoSource ()
| The constructor is not public because instances are created using a factory method. More...

## Detailed Description

Video source implementation using the ARToolKit arVideo module.

This video source uses ARToolKit's built in video capture functions, and can therefore be used on any platform on which arVideo works, including Windows, Linux and OSX.

## Constructor & Destructor Documentation

ARToolKitVideoSource::ARToolKitVideoSource | ( |  | ) |

## Member Function Documentation

bool ARToolKitVideoSource::captureFrame | ( |  | ) |
| virtual

Asks the video source to capture a frame.

This method must be provided by the subclass.

Returns
  true if the video source captured a frame, otherwise false

Implements VideoSource.

bool ARToolKitVideoSource::close | ( |  | ) |
| virtual

Closes the video source.

This method must be provided by the subclass.

Returns
  true if the video source was closed successfully, otherwise false.

Implements VideoSource.

const char * ARToolKitVideoSource::getName | ( |  | ) |
| virtual

Returns the name of this video source variation.

This method must be provided by the subclass.

Returns
  Name of the video source

Implements VideoSource.

bool ARToolKitVideoSource::open | ( |  | ) |
| virtual

Opens the video source.

This method must be provided by the subclass.

Returns
  true if the video source was opened successfully, false if a fatal error occured.

Implements VideoSource.

## Member Data Documentation

AR2VideoParamT* ARToolKitVideoSource::gVid
| protected

The documentation for this class was generated from the following files:

- include/ARWrapper/ARToolKitVideoSource.h
- lib/SRC/ARWrapper/ARToolKitVideoSource.cpp