Functions | |
| bool | setProfilingFlag (int argc, char **argv) |
Checks the command line arguments for the profiling flag, --profiling. More... | |
| template<typename T > | |
| uint64_t | nextPow2 (T num) |
| Returns the first power of 2 greater than or equal to the input. More... | |
| template<typename T > | |
| void | printBuffer (const char *title, T *ptr, uint32_t width, uint32_t height) |
| Prints an array of an integer type to standard output. More... | |
| template<typename T > | |
| void | printBufferF (const char *title, T *ptr, uint32_t width, uint32_t height, uint32_t prec) |
| Prints an array of floating-point type to standard output. More... | |
| template<typename T1 , typename T2 > | |
| void | cpuTranspose (T1 *in, T2 *out, uint32_t width, uint32_t height) |
| Performs a matrix transposition. More... | |
| template<typename T > | |
| void | cpuSeparateRGB (T *in, T *r, T *g, T *b, uint32_t pixels) |
| Performs a matrix transposition. More... | |
| template<typename T2 > | |
| void | cpuSeparateRGB_N_Norm (unsigned char *in, T2 *r, T2 *g, T2 *b, uint32_t pixels) |
| Performs a matrix transposition. More... | |
| template<typename T > | |
| void | cpuCombineRGB (T *r, T *g, T *b, T *out, uint32_t pixels) |
| Performs a matrix transposition. More... | |
| template<typename T1 > | |
| void | cpuTranspose_N_Scale (T1 *r, T1 *g, T1 *b, unsigned char *out, uint32_t pixels) |
| Performs a matrix transpose. More... | |
| template<typename T > | |
| void | cpuDepthTo3D (T *depth, cl_float4 *pCloud, uint32_t width, uint32_t height, float f) |
| Transforms a depth image to a point cloud. More... | |
| template<typename T > | |
| void | cpuRGBDTo8D (T *D, T *R, T *G, T *B, cl_float8 *points, uint32_t width, uint32_t height, float f, bool rgbNorm) |
| Fuses geometry and color values into 8D feature points. More... | |
| template<typename T > | |
| void | cpuSplitPC8D (T *pc8d, T *pc4d, T *rgba, uint32_t n) |
| Splits an 8-D point cloud into 4-D geometry points and RGBA color points. More... | |
| template<typename T > | |
| void | cpuRGBNorm (T *in, T *out, uint32_t width, uint32_t height) |
| Performs RGB color normalization. More... | |
| template<typename T > | |
| void | cpuScan (T *in, T *out, uint32_t width, uint32_t height) |
| Performs a scan operation. More... | |
| template<typename T > | |
| void | cpuSAT (T *in, T *out, uint32_t width, uint32_t height) |
| Constructs a Summed Area Table (SAT). More... | |
| template<typename T > | |
| void | cpuBoxFilter (T *in, T *out, int width, int height, int radius) |
| Performs a blurring effect (mean filtering) on an array. More... | |
| template<typename T > | |
| void | cpuMult (T *a, T *b, T *out, int width, int height) |
| Performs an element-wise array multiplication. More... | |
| template<typename T > | |
| void | cpuPown (T *in, T *out, int width, int height, int n) |
| Performs a raise to an integer power. More... | |
| template<typename T > | |
| void | cpuGuidedFilter (T *p, T *q, int width, int height, int radius, float eps) |
| Performs edge preserving smoothing on an array. More... | |
Variables | |
| std::function< unsigned char()> | rNum_0_255 = std::bind (distribution1, generator) |
| Uniform number generator in the range \([0, 255]\). More... | |
| std::function< unsigned short()> | rNum_0_10000 = std::bind (distribution2, generator) |
| Uniform number generator in the range \([0, 10000]\). More... | |
| std::function< float()> | rNum_R_0_1 = std::bind (distributionR1, generator) |
| Uniform number generator in the range \([0.0, 1.0)\). More... | |
| std::function< float()> | rNum_R_1_255_E__6 = std::bind (distributionR2, generator) |
| Uniform number generator in the range \([1e-6, 255*1e-6)\). More... | |
| void GF::cpuBoxFilter | ( | T * | in, |
| T * | out, | ||
| int | width, | ||
| int | height, | ||
| int | radius | ||
| ) |
Performs a blurring effect (mean filtering) on an array.
It is just a naive serial implementation.
| [in] | in | input array. |
| [out] | out | output (blurred) array. |
| [in] | width | width of the array. |
| [in] | height | height of the array. |
| [in] | radius | radius of the square filter window. |
| void GF::cpuCombineRGB | ( | T * | r, |
| T * | g, | ||
| T * | b, | ||
| T * | out, | ||
| uint32_t | pixels | ||
| ) |
Performs a matrix transposition.
It is just a naive serial implementation.
| [in] | r | input image with channel r. |
| [in] | g | input image with channel g. |
| [in] | b | input image with channel b. |
| [out] | out | input image. |
| [in] | pixels | number of pixels in the input array. |
| void GF::cpuDepthTo3D | ( | T * | depth, |
| cl_float4 * | pCloud, | ||
| uint32_t | width, | ||
| uint32_t | height, | ||
| float | f | ||
| ) |
Transforms a depth image to a point cloud.
It is just a naive serial implementation.
| [in] | depth | depth image (for Kinect, type: uint16, unit: mm). |
| [out] | pCloud | point cloud. |
| [in] | width | width of the array. |
| [in] | height | height of the array. |
| [in] | f | focal length (for Kinect: 595.f). |
| void GF::cpuGuidedFilter | ( | T * | p, |
| T * | q, | ||
| int | width, | ||
| int | height, | ||
| int | radius, | ||
| float | eps | ||
| ) |
Performs edge preserving smoothing on an array.
It is just a naive serial implementation.
| [in] | p | input array. |
| [out] | q | output (smoothed) array. |
| [in] | width | width of the array. |
| [in] | height | height of the array. |
| [in] | radius | radius of the square filter window. |
| [in] | eps | regularization parameter \( \epsilon \). |
| void GF::cpuMult | ( | T * | a, |
| T * | b, | ||
| T * | out, | ||
| int | width, | ||
| int | height | ||
| ) |
Performs an element-wise array multiplication.
It is just a naive serial implementation.
| [in] | a | input array with the first operand. |
| [in] | b | input array with the second operand. |
| [out] | out | output array. |
| [in] | width | width of the array. |
| [in] | height | height of the array. |
| void GF::cpuPown | ( | T * | in, |
| T * | out, | ||
| int | width, | ||
| int | height, | ||
| int | n | ||
| ) |
Performs a raise to an integer power.
It is just a naive serial implementation.
| [in] | in | input array. |
| [out] | out | output array. |
| [in] | width | width of the array. |
| [in] | height | height of the array. |
| [in] | n | power. |
| void GF::cpuRGBDTo8D | ( | T * | D, |
| T * | R, | ||
| T * | G, | ||
| T * | B, | ||
| cl_float8 * | points, | ||
| uint32_t | width, | ||
| uint32_t | height, | ||
| float | f, | ||
| bool | rgbNorm | ||
| ) |
Fuses geometry and color values into 8D feature points.
It is just a naive serial implementation.
| [in] | D | depth image. |
| [in] | R | channel R of RGB image. |
| [in] | G | channel G of RGB image. |
| [in] | B | channel B of RGB image. |
| [out] | points | array of 8D feature points. |
| [in] | width | width of the input arrays. |
| [in] | height | height of the input arrays. |
| [in] | f | focal length (for Kinect: 595.f). |
| [in] | rgbNorm | flag to indicate whether to perform RGB normalization. |
| void GF::cpuRGBNorm | ( | T * | in, |
| T * | out, | ||
| uint32_t | width, | ||
| uint32_t | height | ||
| ) |
Performs RGB color normalization.
That is $$ \hat{p}.i = \frac{p.i}{p.r + p.g + p.b},\ \ i=\{r,g,b\} $$
| T | type of the data to be handled. |
| [in] | in | input data. |
| [out] | out | output (RGB normalized) data. |
| [in] | width | width of the array. |
| [in] | height | height of the array. |
| void GF::cpuSAT | ( | T * | in, |
| T * | out, | ||
| uint32_t | width, | ||
| uint32_t | height | ||
| ) |
Constructs a Summed Area Table (SAT).
It is just a naive serial implementation.
| T | type of the data to be handled. |
| [in] | in | input data. |
| [out] | out | output (SAT) data. |
| [in] | width | width of the array. |
| [in] | height | height of the array. |
| void GF::cpuScan | ( | T * | in, |
| T * | out, | ||
| uint32_t | width, | ||
| uint32_t | height | ||
| ) |
Performs a scan operation.
It is just a naive serial implementation.
| T | type of the data to be handled. |
| [in] | in | input data. |
| [out] | out | output (scan) data. |
| [in] | width | width of the array. |
| [in] | height | height of the array. |
| void GF::cpuSeparateRGB | ( | T * | in, |
| T * | r, | ||
| T * | g, | ||
| T * | b, | ||
| uint32_t | pixels | ||
| ) |
Performs a matrix transposition.
It is just a naive serial implementation.
| [in] | in | input image. |
| [out] | r | output image with channel r. |
| [out] | g | output image with channel g. |
| [out] | b | output image with channel b. |
| [in] | pixels | number of pixels in the input array. |
| void GF::cpuSeparateRGB_N_Norm | ( | unsigned char * | in, |
| T2 * | r, | ||
| T2 * | g, | ||
| T2 * | b, | ||
| uint32_t | pixels | ||
| ) |
Performs a matrix transposition.
It is just a naive serial implementation.
| [in] | in | input image. |
| [out] | r | output image with channel r. |
| [out] | g | output image with channel g. |
| [out] | b | output image with channel b. |
| [in] | pixels | number of pixels in the input array. |
| void GF::cpuSplitPC8D | ( | T * | pc8d, |
| T * | pc4d, | ||
| T * | rgba, | ||
| uint32_t | n | ||
| ) |
Splits an 8-D point cloud into 4-D geometry points and RGBA color points.
It is just a naive serial implementation.
| [in] | pc8d | array with 8-D points (homogeneous coordiates + RGBA values). |
| [out] | pc4d | array with 4-D geometry points. |
| [out] | rgba | array with 4-D color points. |
| [in] | n | number of points in the 8-D point cloud. |
| void GF::cpuTranspose | ( | T1 * | in, |
| T2 * | out, | ||
| uint32_t | width, | ||
| uint32_t | height | ||
| ) |
Performs a matrix transposition.
It is just a naive serial implementation.
| [in] | in | input image. |
| [out] | out | output (transpose) image. |
| [in] | width | width of the input array. |
| [in] | height | height of the input array. |
| void GF::cpuTranspose_N_Scale | ( | T1 * | r, |
| T1 * | g, | ||
| T1 * | b, | ||
| unsigned char * | out, | ||
| uint32_t | pixels | ||
| ) |
Performs a matrix transpose.
It is just a naive serial implementation.
| [in] | r | input image with channel r. |
| [in] | g | input image with channel g. |
| [in] | b | input image with channel b. |
| [out] | out | output (transpose) image. |
| [in] | pixels | number of pixels in the input array. |
| uint64_t GF::nextPow2 | ( | T | num | ) |
Returns the first power of 2 greater than or equal to the input.
| [in] | num | input data. |
| void GF::printBuffer | ( | const char * | title, |
| T * | ptr, | ||
| uint32_t | width, | ||
| uint32_t | height | ||
| ) |
Prints an array of an integer type to standard output.
| T | type of the data to be printed. |
| [in] | title | legend for the output. |
| [in] | ptr | array that is to be displayed. |
| [in] | width | width of the array. |
| [in] | height | height of the array. |
| void GF::printBufferF | ( | const char * | title, |
| T * | ptr, | ||
| uint32_t | width, | ||
| uint32_t | height, | ||
| uint32_t | prec | ||
| ) |
Prints an array of floating-point type to standard output.
| T | type of the data to be printed. |
| [in] | title | legend for the output. |
| [in] | ptr | array that is to be displayed. |
| [in] | width | width of the array. |
| [in] | height | height of the array. |
| [in] | prec | the number of decimal places to print. |
| bool GF::setProfilingFlag | ( | int | argc, |
| char ** | argv | ||
| ) |
Checks the command line arguments for the profiling flag, --profiling.
| [in] | argc | command line argument count |
| [in] | argv | command line arguments |
| std::function< unsigned short()> GF::rNum_0_10000 = std::bind (distribution2, generator) |
Uniform number generator in the range \([0, 10000]\).
| std::function< unsigned char()> GF::rNum_0_255 = std::bind (distribution1, generator) |
Uniform number generator in the range \([0, 255]\).
| std::function< float()> GF::rNum_R_0_1 = std::bind (distributionR1, generator) |
Uniform number generator in the range \([0.0, 1.0)\).
| std::function< float()> GF::rNum_R_1_255_E__6 = std::bind (distributionR2, generator) |
Uniform number generator in the range \([1e-6, 255*1e-6)\).
1.8.9.1