Triclops SDK
4.0.3.0
triclops3d.h
Go to the documentation of this file.
1 //=============================================================================
2 // Copyright © 2016 FLIR Integrated Imaging Solutions, Inc. All Rights Reserved.
3 //
4 // This software is the confidential and proprietary information of FLIR
5 // Integrated Imaging Solutions, Inc. ("Confidential Information"). You
6 // shall not disclose such Confidential Information and shall use it only in
7 // accordance with the terms of the license agreement you entered into
8 // with FLIR Integrated Imaging Solutions, Inc. (FLIR).
9 //
10 // FLIR MAKES NO REPRESENTATIONS OR WARRANTIES ABOUT THE SUITABILITY OF THE
11 // SOFTWARE, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE
12 // IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
13 // PURPOSE, OR NON-INFRINGEMENT. FLIR SHALL NOT BE LIABLE FOR ANY DAMAGES
14 // SUFFERED BY LICENSEE AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
15 // THIS SOFTWARE OR ITS DERIVATIVES.
16 //=============================================================================
17 
18 //=============================================================================
19 // $Id: triclops3d.h 309688 2016-12-21 18:28:11Z silvanoa $
20 //=============================================================================
21 
22 //=============================================================================
25  //=============================================================================
26 
27 #ifndef TRICLOPS3D_H
28 #define TRICLOPS3D_H
29 
30 //=============================================================================
31 // Project Includes
32 //=============================================================================
33 #include <triclops.h>
34 
35 #ifdef __cplusplus
36 extern "C"
37 {
38 #endif
39 
40 //=============================================================================
41 // Types
42 //============================================================================= // start of group TriclopsTypes
47 
52 typedef struct TriclopsPoint3d {
53  float point[3];
55 
67 typedef struct TriclopsImage3d {
68  int nrows;
70  int ncols;
72  int rowinc;
76 
83 typedef struct {
84  double matrix[4][4];
87  // End of group TriclopsTypes
89 
98 enum TriclopsError
100  float row,
101  float col,
102  float disp,
103  float *x,
104  float *y,
105  float *z);
127 enum TriclopsError
129  float row,
130  float col,
131  float disp,
132  float *x,
133  float *y,
134  float *z);
140 enum TriclopsError
142  int row,
143  int col,
144  unsigned short disp,
145  float *x,
146  float *y,
147  float *z);
148 
170 enum TriclopsError
172  float x,
173  float y,
174  float z,
175  float *row,
176  float *col,
177  float *disp);
182 enum TriclopsError
184  float row,
185  float col,
186  float disp,
187  float *x,
188  float *y,
189  float *z);
190 
214 enum TriclopsError
216  float row,
217  float col,
218  float disp,
219  float *x,
220  float *y,
221  float *z);
227 enum TriclopsError
229  int row,
230  int col,
231  unsigned short disp,
232  float *x,
233  float *y,
234  float *z);
256 enum TriclopsError
258  float x,
259  float y,
260  float z,
261  float *row,
262  float *col,
263  float *disp);
283 enum TriclopsError
285  const TriclopsTransform *transform);
297 enum TriclopsError
299  TriclopsTransform *transform);
300 
316 enum TriclopsError
317 triclopsGetTransformFromFile(const char *fileName,
318  TriclopsTransform *transform);
319 
334 enum TriclopsError
335 triclopsWriteTransformToFile(const char *fileName,
336  const TriclopsTransform *transform);
337 
353 enum TriclopsError
355  TriclopsImage3d **ppimage);
356 
361 void
363 
383 enum TriclopsError
385  TriclopsImage3d *pimage);
386 
404 enum TriclopsError
406  TriclopsImage3d *pimage);
407  // End of group Triclops3D
409 
410 
429 enum TriclopsError
431  float *centerRow,
432  float *centerCol);
433 
434 #ifdef __cplusplus
435 }
436 #endif
437 
438 #endif // #ifndef TRICLOPS3D_H
enum TriclopsError triclopsSetTriclopsToWorldTransform(TriclopsContext context, const TriclopsTransform *transform)
Sets the 3D world coordinates rototranslation matrix to a TriclopsContext.
Definition: triclops3d.cpp:180
TriclopsPoint3d * points
Definition: triclops3d.h:74
struct TriclopsPoint3d TriclopsPoint3d
Three dimensional point structure.
float point[3]
Definition: triclops3d.h:53
enum TriclopsError triclopsRCDFloatToWorldXYZ(TriclopsContext context, float row, float col, float disp, float *x, float *y, float *z)
Converts a 2D pixel coordinate in disparity space to a 3D point in world coordinate system...
Definition: triclops3d.cpp:132
enum TriclopsError triclopsRCDToXYZ(TriclopsContext context, float row, float col, float disp, float *x, float *y, float *z)
Converts a 2D pixel coordinate in disparity space to a 3D point in camera coordinate system...
Definition: triclops3d.cpp:36
enum TriclopsError triclopsWriteTransformToFile(const char *fileName, const TriclopsTransform *transform)
Saves a 3D world coordinates rototranslation matrix to memory.
int ncols
Definition: triclops3d.h:70
enum TriclopsError triclopsExtractWorldImage3d(TriclopsContext context, TriclopsImage3d *pimage)
Generates a 3D point in world space cloud from the provided context.
Definition: triclops3d.cpp:273
TriclopsError
Error enumerator.
Definition: triclopserror.h:46
enum TriclopsError triclopsGetTransformFromFile(const char *fileName, TriclopsTransform *transform)
Loads a 3D world coordinates rototranslation matrix from memory.
Definition: triclops3d.cpp:207
Three dimensional point structure.
Definition: triclops3d.h:52
void * TriclopsContext
Wrapper for the internal C++ Triclops context.
Definition: triclopstype.h:54
enum TriclopsError triclopsCreateImage3d(TriclopsContext context, TriclopsImage3d **ppimage)
Initialises a 3D image structure.
Definition: triclops3d.cpp:230
enum TriclopsError triclopsExtractImage3d(TriclopsContext context, TriclopsImage3d *pimage)
Generates a 3D point cloud in camera space from the provided context.
Definition: triclops3d.cpp:265
enum TriclopsError triclopsRCDFloatToXYZ(TriclopsContext context, float row, float col, float disp, float *x, float *y, float *z)
Converts a 2D pixel coordinate in disparity space to a 3D point in camera coordinate system...
Definition: triclops3d.cpp:52
enum TriclopsError triclopsRCD16ToXYZ(TriclopsContext context, int row, int col, unsigned short disp, float *x, float *y, float *z)
Converts a 2D pixel coordinate in disparity space to a 3D point in camera coordinate system...
Definition: triclops3d.cpp:67
enum TriclopsError triclopsXYZToRCD(TriclopsContext context, float x, float y, float z, float *row, float *col, float *disp)
Converts a 3D point in camera coordinate system to a 2D pixel coordinate in disparity space...
Definition: triclops3d.cpp:82
enum TriclopsError triclopsGetTriclopsToWorldTransform(TriclopsContext context, TriclopsTransform *transform)
Gets the 3D world coordinates rototranslation matrix to a TriclopsContext.
Definition: triclops3d.cpp:194
int nrows
Definition: triclops3d.h:68
int rowinc
Definition: triclops3d.h:72
Quaternion structure.
Definition: triclops3d.h:83
Triclops operations API.
enum TriclopsError triclopsRCD16ToWorldXYZ(TriclopsContext context, int row, int col, unsigned short disp, float *x, float *y, float *z)
Converts a 2D pixel coordinate in disparity space to a 3D point in world coordinate system...
Definition: triclops3d.cpp:148
void triclopsDestroyImage3d(TriclopsImage3d **ppimage)
Destroys a 3D image structure.
Definition: triclops3d.cpp:243
enum TriclopsError triclopsWorldXYZToRCD(TriclopsContext context, float x, float y, float z, float *row, float *col, float *disp)
Converts a 3D point in world coordinate system to a 2D pixel coordinate in disparity space...
Definition: triclops3d.cpp:164
enum TriclopsError triclopsGetImageCenter(const TriclopsContext context, float *centerRow, float *centerCol)
Returns the optical center for pinhole calculations.It is important that the context already has the ...
Definition: triclops3d.cpp:97
Three dimensional data structure.
Definition: triclops3d.h:67
struct TriclopsImage3d TriclopsImage3d
Three dimensional data structure.
enum TriclopsError triclopsRCDToWorldXYZ(TriclopsContext context, float row, float col, float disp, float *x, float *y, float *z)
Converts a 2D pixel coordinate in disparity space to a 3D point in world coordinate system...
Definition: triclops3d.cpp:115
Contact Support Triclops SDK Programmer's Guide and API Reference