test.h
Go to the documentation of this file.
1 /**************************************************************************************************
2  Software License Agreement (BSD License)
3 
4  Copyright (c) 2011-2013, LAR toolkit developers - University of Aveiro - http://lars.mec.ua.pt
5  All rights reserved.
6 
7  Redistribution and use in source and binary forms, with or without modification, are permitted
8  provided that the following conditions are met:
9 
10  *Redistributions of source code must retain the above copyright notice, this list of
11  conditions and the following disclaimer.
12  *Redistributions in binary form must reproduce the above copyright notice, this list of
13  conditions and the following disclaimer in the documentation and/or other materials provided
14  with the distribution.
15  *Neither the name of the University of Aveiro nor the names of its contributors may be used to
16  endorse or promote products derived from this software without specific prior written permission.
17 
18  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
19  IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
20  FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
21  CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
22  DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
23  DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
24  IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
25  OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26 ***************************************************************************************************/
37 #ifndef _XB3_H_
38 #define _XB3_H_
39 
40 //####################################################################
41 // Includes:
42 //####################################################################
43 
44 #include <ros/ros.h>
45 #include <image_transport/image_transport.h>
46 #include <cv_bridge/cv_bridge.h>
47 #include <sensor_msgs/image_encodings.h>
48 #include <opencv2/imgproc/imgproc.hpp>
49 #include <opencv2/highgui/highgui.hpp>
50 
51 #include <signal.h>
52 //=============================================================================
53 // PGR Includes
54 //=============================================================================
55 #include "pgr_registers.h"
56 #include "pgr_stereocam.h"
57 
58 #define PFLN {printf("DEBUG PRINT FILE %s LINE %d\n",__FILE__,__LINE__);}
59 
60 
61 
62 typedef struct{
63  int use_shm;
64  char dummymode;
65  char debugmode;
66 }TYPE_flg;
67 
68 
69 
70 
71 
72 void handler_short_stereomask_change(char *a, char *b, char *c);
73 void handler_wide_stereomask_change(char *a, char *b, char *c);
75 
76 
77 
78 
79 #ifdef _XB3_CPP_
80 
81 
82 IplImage *image,*uimage,*pimage;
83 double filltime; //image timestamp
84 
85 TriclopsInput colorInput;
86 unsigned char* pucRightRGB = NULL;
87 unsigned char* pucLeftRGB = NULL;
88 unsigned char* pucCenterRGB = NULL;
89 
91 TriclopsImage16 depthImage16;
92 unsigned char* pucGreenBuffer;
93 unsigned char* pucRGBBuffer;
94 unsigned char* pucDeInterlacedBuffer;
95 PGRStereoCamera_t stereoCamera;
96 dc1394camera_t* camera;
97 dc1394error_t err;
98 
99 dc1394_t * d;
100 dc1394camera_list_t * list;
101 unsigned int nThisCam;
102 
103 char file_shortcal[255] = "config/short.cal";
104 char file_widecal[255] = "config/wide.cal";
105 
106 
107 //xb3_3dpointcloud_message pc_msg;
108 //xb3_3dpointcloud_message pc_msg1;
109 
110 TriclopsColorImage shortRectifiedColor;
111 TriclopsColorImage wideRectifiedColor;
112 
113 
114 
115 
116 
117 IplImage* RightCamera;
118 IplImage* CenterCamera;
119 IplImage* LeftCamera;
120 IplImage *Ileft;
121 IplImage *Iright;
122 IplImage *InvalidStereoMask;
123 IplImage *DicardedStereoMask;
124 IplImage *ShortDisparityImage;
125 IplImage *WideDisparityImage;
126 
127 
128 #endif
129 
130 #endif
131 
Header file for the registers for the PGR toolbox.
char dummymode
Definition: test.h:64
int convert_triclopscolorimage_2_iplimage(TriclopsColorImage *TI, IplImage *IPL)
void handler_wide_stereomask_change(char *a, char *b, char *c)
Library from Point Grey Research to access the xb3 images.
int use_shm
Definition: test.h:63
Definition: test.h:62
void handler_short_stereomask_change(char *a, char *b, char *c)
TriclopsError e
Definition: test.cpp:51
char file_shortcal[1024]
Definition: test.cpp:53
TriclopsError
Definition: triclops.h:99
char debugmode
Definition: test.h:65
char file_widecal[1024]
Definition: test.cpp:54


xb3
Author(s): Miguel Oliveira, Tiago Talhada
autogenerated on Mon Mar 2 2015 01:33:02