This documentation is automatically generated from the openFrameworks source code using doxygen and refers to the most recent release, version 0.12.0.
#include <ofDirectShowGrabber.h>

Public Member Functions | |
ofDirectShowGrabber () | |
virtual | ~ofDirectShowGrabber () |
std::vector< ofVideoDevice > | listDevices () const |
Get a list of available video grabber devices. | |
bool | setup (int w, int h) |
Set up the grabber with the requested width and height. | |
void | update () |
Update the object's state. | |
bool | isFrameNew () const |
bool | isInitialized () const |
Determine if the video source is initialized. | |
bool | setPixelFormat (ofPixelFormat pixelFormat) |
Set the requested ofPixelFormat. | |
ofPixelFormat | getPixelFormat () const |
ofPixels & | getPixels () |
Get a reference to the underlying ofPixels. | |
const ofPixels & | getPixels () const |
Get a const reference to the underlying ofPixels. | |
void | close () |
Close the video source. | |
void | clearMemory () |
void | videoSettings () |
Request a native GUI for video grabber settings. | |
float | getWidth () const |
Get the video grabber's width. | |
float | getHeight () const |
Get the video grabber's height. | |
void | setVerbose (bool bTalkToMe) |
Set the video grabber's hardware verbosity level. | |
void | setDeviceID (int _deviceID) |
Set the video grabber's device ID. | |
void | setDesiredFrameRate (int framerate) |
Set the video grabber's desired frame rate. | |
![]() | |
virtual | ~ofBaseVideoGrabber () |
Destroy the ofBaseVideoGrabber. | |
virtual ofTexture * | getTexturePtr () |
Get the video grabber's internal ofTexture pointer if available. | |
![]() | |
virtual | ~ofBaseVideo () |
Destroy the ofBaseVideo. | |
![]() | |
virtual | ~ofBaseHasPixels_ () |
Destroy the ofAbstractHasPixels. | |
![]() | |
virtual | ~ofAbstractHasPixels () |
Destroy the ofAbstractHasPixels. | |
![]() | |
virtual | ~ofBaseUpdates () |
Destroy the ofBaseUpdates. | |
Protected Attributes | |
bool | bChooseDevice |
int | deviceID |
bool | bVerbose |
bool | bGrabberInited |
ofPixels | pixels |
int | attemptFramerate |
bool | bIsFrameNew |
int | width |
int | height |
Constructor & Destructor Documentation
◆ ofDirectShowGrabber()
ofDirectShowGrabber::ofDirectShowGrabber | ( | ) |
◆ ~ofDirectShowGrabber()
|
virtual |
Member Function Documentation
◆ clearMemory()
void ofDirectShowGrabber::clearMemory | ( | ) |
◆ close()
|
virtual |
Close the video source.
Implements ofBaseVideo.
◆ getHeight()
|
virtual |
◆ getPixelFormat()
|
virtual |
- Returns
- the current ofPixelFormat.
Implements ofBaseVideo.
◆ getPixels() [1/2]
|
virtual |
Get a reference to the underlying ofPixels.
- Returns
- a reference the underlying ofPixels.
Implements ofBaseHasPixels_< unsigned char >.
◆ getPixels() [2/2]
|
virtual |
Get a const reference to the underlying ofPixels.
- Returns
- a const reference the underlying ofPixels.
Implements ofBaseHasPixels_< unsigned char >.
◆ getWidth()
|
virtual |
◆ isFrameNew()
|
virtual |
- Returns
- true if the pixel data was updated since the last call to update().
Implements ofBaseVideo.
◆ isInitialized()
|
virtual |
Determine if the video source is initialized.
Video sources such as cameras are often initialized with a setup() method. Video sources such as movie players are often initialized with a load() method.
- Returns
- true if the video source is initialized.
Implements ofBaseVideo.
◆ listDevices()
|
virtual |
Get a list of available video grabber devices.
- Returns
- a std::vector of ofVideoDevice objects.
Implements ofBaseVideoGrabber.
◆ setDesiredFrameRate()
|
virtual |
Set the video grabber's desired frame rate.
Many video grabbers support user-specified frame rates. This frame rate should be considered a hint for the video grabber and is not guaranteed.
- Parameters
-
framerate the desired frame rate.
Reimplemented from ofBaseVideoGrabber.
◆ setDeviceID()
|
virtual |
Set the video grabber's device ID.
In most cases, a user can choose a specific grabber source by ID. This device ID information should be available to the user via the listDevices() method.
- Parameters
-
deviceID The device ID provided by listDevices().
Reimplemented from ofBaseVideoGrabber.
◆ setPixelFormat()
|
virtual |
Set the requested ofPixelFormat.
- Parameters
-
pixelFormat the requested ofPixelFormat.
- Returns
- true if the format was successfully changed.
Implements ofBaseVideo.
◆ setup()
|
virtual |
Set up the grabber with the requested width and height.
Some video grabbers may take the requested width and height as a hint and choose the closest dimensions to those requested. Users can check the actual width and height by calling getWidth() and getHeight() respectively after a successful setup.
- Parameters
-
w the requested width. h the requested height.
- Returns
- true if the video grabber was set up successfully.
Implements ofBaseVideoGrabber.
◆ setVerbose()
|
virtual |
Set the video grabber's hardware verbosity level.
- Parameters
-
bTalkToMe true if verbose grabber logging feedback is required.
Reimplemented from ofBaseVideoGrabber.
◆ update()
|
virtual |
Update the object's state.
Implements ofBaseUpdates.
◆ videoSettings()
|
virtual |
Request a native GUI for video grabber settings.
- Note
- This feature may not be implemented by all video grabbers.
Reimplemented from ofBaseVideoGrabber.
Member Data Documentation
◆ attemptFramerate
|
protected |
◆ bChooseDevice
|
protected |
◆ bGrabberInited
|
protected |
◆ bIsFrameNew
|
protected |
◆ bVerbose
|
protected |
◆ deviceID
|
protected |
◆ height
|
protected |
◆ pixels
|
protected |
◆ width
|
protected |
The documentation for this class was generated from the following file:
- /Users/icq4ever/Desktop/oF0120/libs/openFrameworks/video/ofDirectShowGrabber.h