Homepage Demos Overview Downloads Tutorials Reference
Credits
Main Page | Namespace List | Class Hierarchy | Alphabetical List | Compound List | File List | Namespace Members | Compound Members | File Members | Related Pages | Search

VisionSerializer.h

Go to the documentation of this file.
00001 #ifndef INCLUDED_VisionSerializer_h
00002 #define INCLUDED_VisionSerializer_h
00003 
00004 #include "Vision.h"
00005 #include "VisionInterface.h"
00006 #include "Shared/Serializer.h"
00007 
00008 //! Encodes and transmits camera images
00009 class VisionSerializer : public Serializer {
00010 public:
00011   VisionSerializer(); //!< constructor
00012   void serialize();   //!< encodes and sends current frame
00013   
00014 private:
00015   //! encodes the original camera image
00016   void encodeVisionRaw(char *buf,CMVision::image_yuv<const uchar> &img,
00017                        int scale);
00018   //! encodes the RLE processed image
00019   void encodeVisionRLE(char *buf,int num_runs,run *runs);
00020   //! helper function for encodeVisionRLE, encodes one run length
00021   inline char* encodeVisionRun(char *buf, run *run);
00022 
00023   VisionSerializer(const VisionSerializer&);              //!< don't call
00024   VisionSerializer& operator= (const VisionSerializer&);  //!< don't call
00025 
00026   Socket *visRaw;  //!< socket to which raw vision images should be sent
00027   Socket *visRLE;  //!< socket to which RLE images shoudl be sent
00028 };
00029 
00030 /*! @file
00031  * @brief Describes VisionSerializer, which encodes and transmits camera images
00032  * @author CMU RoboSoccer 2001-2002 (Creator)
00033  * @author alokl (Ported)
00034  * 
00035  * @verbinclude CMPack_license.txt
00036  *
00037  * $Author: ejt $
00038  * $Name: tekkotsu-1_4_1 $
00039  * $Revision: 1.2 $
00040  * $State: Exp $
00041  * $Date: 2003/06/12 23:41:41 $
00042  */
00043 
00044 #endif

Tekkotsu v1.4
Generated Sat Jul 19 00:06:32 2003 by Doxygen 1.3.2