34 #include <Base/Common/W32Compat.hh>
35 #include <VideoSource/VideoSource_Net.hh>
36 #include <Base/Image/ImageIO.hh>
37 #include <Image/Camera.hh>
48 int main(
int argc,
char *argv[])
57 cout <<
"Connecting server "<<argv[1]<<endl;
58 int port = D_CS_DEFAULT_PORT;
59 if(argc>2) port = atoi(argv[2]);
64 cout<<
"usage: "<<argv[0]<<
" serverName [port]"<<endl;
78 sprintf(name,
"image_%04i.mip",imgNo);
80 cout<<
"Written image:"<<name<<
" to disk"<<endl;
83 if (imgNo==200) done=
true;
virtual int InitImage(BIAS::ImageBase &Image)
Defines a common interface to different devices.
unsigned int GetWidth() const
unsigned int GetChannelCount() const
returns the number of Color channels, e.g.
unsigned int GetHeight() const
static int Save(const std::string &filename, const ImageBase &img, const enum TFileFormat FileFormat=FF_auto, const bool sync=BIAS_DEFAULT_SYNC, const int c_jpeg_quality=BIAS_DEFAULT_IMAGE_QUALITY, const bool forceNewID=BIAS_DEFAULT_FORCENEWID, const bool &writeMetaData=true)
Export image as file using extrnal libs.
virtual int GrabSingle(BIAS::Camera< unsigned char > &image)
virtual int CloseDevice()
This class implements a video streaming client using TCP.