features.h
Go to the documentation of this file.
1 /*******************************************************
2  * Copyright (c) 2014, ArrayFire
3  * All rights reserved.
4  *
5  * This file is distributed under 3-clause BSD license.
6  * The complete license agreement can be obtained at:
7  * http://arrayfire.com/licenses/BSD-3-Clause
8  ********************************************************/
9 
10 #pragma once
11 #include <af/defines.h>
12 
13 typedef void * af_features;
14 
15 #ifdef __cplusplus
16 namespace af
17 {
18  class array;
19 
20  class AFAPI features {
21  private:
22  af_features feat;
23 
24  public:
25  features();
26  features(const size_t n);
28 
29  ~features();
30 
31  features& operator= (const features& f);
32 
33  size_t getNumFeatures() const;
34  array getX() const;
35  array getY() const;
36  array getScore() const;
37  array getOrientation() const;
38  array getSize() const;
39  af_features get() const;
40  };
41 
42 }
43 #endif
44 
45 #ifdef __cplusplus
46 extern "C" {
47 #endif
48 
50 
52 
54 
56 
58 
60 
62 
64 
65  // Destroy af_features
67 
68 #ifdef __cplusplus
69 }
70 #endif
Definition: algorithm.h:14
AFAPI af_err af_release_features(af_features feat)
void * af_features
Definition: features.h:13
A multi dimensional data container.
Definition: array.h:27
AFAPI af_err af_get_features_score(af_array *score, const af_features feat)
static af::array array(af::dim4 idims, cl_mem buf, af::dtype type, bool retain=false)
Create an af::array object from an OpenCL cl_mem buffer.
Definition: opencl.h:329
af_err
Definition: defines.h:63
AFAPI af_err af_get_features_orientation(af_array *orientation, const af_features feat)
AFAPI af_err af_get_features_xpos(af_array *out, const af_features feat)
long long dim_t
Definition: defines.h:50
#define AFAPI
Definition: defines.h:31
AFAPI af_err af_create_features(af_features *feat, dim_t num)
AFAPI af_err af_get_features_size(af_array *size, const af_features feat)
Definition: features.h:20
void * af_array
Definition: defines.h:222
AFAPI af_err af_retain_features(af_features *out, const af_features feat)
AFAPI af_err af_get_features_ypos(af_array *out, const af_features feat)
AFAPI af_err af_get_features_num(dim_t *num, const af_features feat)