34 #include <Image/Camera.hh>
35 #include <Base/Image/ImageConvert.hh>
36 #include <Base/Image/ImageIO.hh>
37 #include <VideoSource/VideoSource_DCAM.hh>
38 #include <Base/Debug/TimeMeasure.hh>
50 #define StorageType unsigned char
52 int main(
int ,
char** )
56 unsigned int loopcount = 100;
59 cout <<
"Warning: Improper use can freeze your system and especially your filesystem "<<endl;
79 cerr<<
" Can not open camera. res="<<res<<endl;
97 for (
unsigned int i=0;i<loopcount; i++) {
98 cout <<
"Grabing image "<<i;
100 cout <<
" UID: "<<img.
GetUID()<<endl;
103 float fps = float(loopcount / (t1.
GetRealTime()/1000000.0));
104 cout <<
"FPS: "<<fps<<endl;
virtual int InitImage(BIAS::ImageBase &Image)
void SetFPS(float fps)
Set frame per second for image capturing.
int GrabSingle(BIAS::Camera< unsigned char > &image)
Select the port (bus-id) to use, only valid before OpenDevice()
This class VideoSource_DCAM implements access to IEEE1394 (Firewire, iLink) cameras following the DCa...
int OpenDevice()
Opens a dc1394 device.
const BIAS::UUID & GetUID() const
returns the UUID of the image
int SetShutter(float exptime)
set value for shutter
int SetDirectToDisk(const std::string &filename)
Enables the very fast direct-to-disk mode.
void SetDebugLevel(const long int lv)
double GetRealTime() const
return real time (=wall time clock) in usec JW For Win32: real-time is measured differently from user...
int CloseDevice()
closes a camera device and cleans up
int PostGrab()
stops iso transmission of a camera.
int PreGrab()
initializes the iso transmission of a camera.
class TimeMeasure contains functions for timing real time and cpu time.