Classes | Defines | Typedefs | Enumerations | Functions | Variables
ccv.h File Reference
#include <unistd.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <stdarg.h>
#include <string.h>
#include <float.h>
#include <math.h>
#include <assert.h>
#include <alloca.h>
Include dependency graph for ccv.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  ccv_array_t
struct  ccv_bbf_classifier_cascade_t
struct  ccv_bbf_feature_t
struct  ccv_bbf_new_param_t
struct  ccv_bbf_param_t
struct  ccv_bbf_stage_classifier_t
union  ccv_cache_index_t
struct  ccv_cache_t
struct  ccv_comp_t
struct  ccv_compressed_sparse_matrix_t
struct  ccv_contour_t
struct  ccv_daisy_param_t
struct  ccv_decimal_point_t
struct  ccv_decimal_point_with_status_t
struct  ccv_dense_matrix_t
struct  ccv_dense_vector_t
struct  ccv_dpm_mixture_model_t
struct  ccv_dpm_new_param_t
struct  ccv_dpm_param_t
struct  ccv_dpm_part_classifier_t
struct  ccv_dpm_root_classifier_t
struct  ccv_ferns_t
struct  ccv_keypoint_t
union  ccv_matrix_cell_t
struct  ccv_minimize_param_t
struct  ccv_mser_keypoint_t
struct  ccv_mser_param_t
struct  ccv_point_t
struct  ccv_rect_t
struct  ccv_root_comp_t
struct  ccv_sift_param_t
struct  ccv_size_t
struct  ccv_sparse_matrix_t
struct  ccv_swt_param_t
struct  ccv_tld_info_t
struct  ccv_tld_param_t
struct  ccv_tld_t

Defines

#define ccfree   free
#define ccmalloc   malloc
#define ccrealloc   realloc
#define CCV_ALL_DATA_TYPE   (CCV_8U | CCV_32S | CCV_32F | CCV_64S | CCV_64F)
#define ccv_array_get(a, i)   (((char*)((a)->data)) + (a)->rsize * (i))
#define CCV_BBF_POINT_MAX   (8)
#define CCV_BBF_POINT_MIN   (3)
#define ccv_clamp(x, a, b)   (((x) < (a)) ? (a) : (((x) > (b)) ? (b) : (x)))
#define ccv_compute_dense_matrix_size(rows, cols, type)   (sizeof(ccv_dense_matrix_t) + (((cols) * CCV_GET_DATA_TYPE_SIZE(type) * CCV_GET_CHANNEL(type) + 3) & -4) * (rows))
#define CCV_DEFAULT_CACHE_SIZE   (1024 * 1024 * 64)
#define CCV_DPM_PART_MAX   (10)
#define CCV_GET_CHANNEL(x)   ((x) & 0xFF)
#define CCV_GET_DATA_TYPE(x)   ((x) & 0xFF00)
#define CCV_GET_DATA_TYPE_SIZE(x)   _ccv_get_data_type_size[CCV_GET_DATA_TYPE(x) >> 8]
#define ccv_get_dense_matrix_cell(x, row, col, ch)   ccv_get_dense_matrix_cell_by((x)->type, x, row, col, ch)
#define ccv_get_dense_matrix_cell_by(type, x, row, col, ch)
#define ccv_get_dense_matrix_cell_value(x, row, col, ch)   ccv_get_dense_matrix_cell_value_by((x)->type, x, row, col, ch)
#define ccv_get_dense_matrix_cell_value_by(type, x, row, col, ch)
#define CCV_GET_SPARSE_PRIME(x)   _ccv_get_sparse_prime[(x)]
#define ccv_get_value(type, ptr, i)
#define ccv_max(a, b)   (((a) > (b)) ? (a) : (b))
#define CCV_MAX_CHANNEL   (0xFF)
#define ccv_min(a, b)   (((a) < (b)) ? (a) : (b))
#define CCV_PI   (3.141592653589793)
#define ccv_read(in, x, type,...)   ccv_read_n(in, x, type, ##__VA_ARGS__, 0, 0, 0)
#define ccv_read_n(in, x, type, rows, cols, scanline,...)   ccv_read_impl(in, x, type, rows, cols, scanline)
#define ccv_set_value(type, ptr, i, value, factor)

Typedefs

typedef int(* ccv_array_group_f )(const void *, const void *, void *)
typedef void(* ccv_cache_index_free_f )(void *)
typedef struct ccv_dense_vector_t ccv_dense_vector_t
typedef double(* ccv_filter_kernel_f )(double x, double y, void *)
typedef void ccv_matrix_t
typedef int(* ccv_minimize_f )(const ccv_dense_matrix_t *x, double *f, ccv_dense_matrix_t *df, void *)

Enumerations

enum  {
  CCV_8U = 0x0100, CCV_32S = 0x0200, CCV_32F = 0x0400, CCV_64S = 0x0800,
  CCV_64F = 0x1000
}
enum  { CCV_C1 = 0x01, CCV_C2 = 0x02, CCV_C3 = 0x03, CCV_C4 = 0x04 }
enum  {
  CCV_L1_NORM = 0x01, CCV_L2_NORM = 0x02, CCV_GSEDT = 0x04, CCV_NEGATIVE = 0x08,
  CCV_POSITIVE = 0x00
}
enum  { CCV_NO_PADDING = 0x00, CCV_PADDING_ZERO = 0x01, CCV_PADDING_EXTEND = 0x02, CCV_PADDING_MIRROR = 0x04 }
enum  { CCV_SIGNED = 0x00, CCV_UNSIGNED = 0x01 }
enum  { CCV_A_TRANSPOSE = 0x01, CCV_B_TRANSPOSE = 0X02, CCV_C_TRANSPOSE = 0X04 }
enum  { CCV_FLIP_X = 0x01, CCV_FLIP_Y = 0x02 }
enum  { CCV_RGB_TO_YUV = 0x01 }
enum  { CCV_INTER_AREA = 0x01, CCV_INTER_LINEAR = 0X02, CCV_INTER_CUBIC = 0X04, CCV_INTER_LANCZOS = 0X08 }
enum  { CCV_DAISY_NORMAL_PARTIAL = 0x01, CCV_DAISY_NORMAL_FULL = 0x02, CCV_DAISY_NORMAL_SIFT = 0x03 }
enum  { CCV_BRIGHT_TO_DARK = -1, CCV_DARK_TO_BRIGHT = 1 }
enum  { CCV_DPM_NO_NESTED = 0x10000000 }
enum  { CCV_MATRIX_DENSE = 0x010000, CCV_MATRIX_SPARSE = 0x020000, CCV_MATRIX_CSR = 0x040000, CCV_MATRIX_CSC = 0x080000 }
enum  { CCV_BBF_GENETIC_OPT = 0x01, CCV_BBF_FLOAT_OPT = 0x02 }
enum  { CCV_BBF_NO_NESTED = 0x10000000 }
enum  { CCV_GARBAGE = 0x80000000, CCV_REUSABLE = 0x40000000, CCV_UNMANAGED = 0x20000000, CCV_NO_DATA_ALLOC = 0x10000000 }
enum  { CCV_SPARSE_VECTOR = 0x00100000, CCV_DENSE_VECTOR = 0x00200000 }
enum  { CCV_SPARSE_ROW_MAJOR = 0x00, CCV_SPARSE_COL_MAJOR = 0x01 }
enum  { CCV_IO_GRAY = 0x100, CCV_IO_RGB_COLOR = 0x300 }
enum  { CCV_IO_NO_COPY = 0x10000 }
enum  {
  CCV_IO_ANY_STREAM = 0x010, CCV_IO_BMP_STREAM = 0x011, CCV_IO_JPEG_STREAM = 0x012, CCV_IO_PNG_STREAM = 0x013,
  CCV_IO_PLAIN_STREAM = 0x014, CCV_IO_DEFLATE_STREAM = 0x015, CCV_IO_ANY_FILE = 0x020, CCV_IO_BMP_FILE = 0x021,
  CCV_IO_JPEG_FILE = 0x022, CCV_IO_PNG_FILE = 0x023, CCV_IO_BINARY_FILE = 0x024, CCV_IO_ANY_RAW = 0x040,
  CCV_IO_RGB_RAW = 0x041, CCV_IO_RGBA_RAW = 0x042, CCV_IO_ARGB_RAW = 0x043, CCV_IO_BGR_RAW = 0x044,
  CCV_IO_BGRA_RAW = 0x045, CCV_IO_ABGR_RAW = 0x046, CCV_IO_GRAY_RAW = 0x047
}
enum  {
  CCV_IO_FINAL = 0x00, CCV_IO_CONTINUE, CCV_IO_ERROR, CCV_IO_ATTEMPTED,
  CCV_IO_UNKNOWN
}

Functions

ccv_dense_matrix_t__attribute__ ((warn_unused_result)) ccv_dense_matrix_renew(ccv_dense_matrix_t *x
int ccv_any_nan (ccv_matrix_t *a)
void ccv_array_clear (ccv_array_t *array)
void ccv_array_free (ccv_array_t *array)
void ccv_array_free_immediately (ccv_array_t *array)
int ccv_array_group (ccv_array_t *array, ccv_array_t **index, ccv_array_group_f gfunc, void *data)
void ccv_array_push (ccv_array_t *array, void *r)
void ccv_array_zero (ccv_array_t *array)
void ccv_bbf_classifier_cascade_free (ccv_bbf_classifier_cascade_t *cascade)
void ccv_bbf_classifier_cascade_new (ccv_dense_matrix_t **posimg, int posnum, char **bgfiles, int bgnum, int negnum, ccv_size_t size, const char *dir, ccv_bbf_new_param_t params)
int ccv_bbf_classifier_cascade_write_binary (ccv_bbf_classifier_cascade_t *cascade, char *s, int slen)
void ccv_blur (ccv_dense_matrix_t *a, ccv_dense_matrix_t **b, int type, double sigma)
void ccv_cache_cleanup (ccv_cache_t *cache)
void ccv_cache_close (ccv_cache_t *cache)
int ccv_cache_delete (ccv_cache_t *cache, uint64_t sign)
uint64_t ccv_cache_generate_signature (const char *msg, int len, uint64_t sig_start,...)
void * ccv_cache_get (ccv_cache_t *cache, uint64_t sign, uint8_t *type)
void ccv_cache_init (ccv_cache_t *cache, size_t up, int cache_types, ccv_cache_index_free_f ffree,...)
void * ccv_cache_out (ccv_cache_t *cache, uint64_t sign, uint8_t *type)
int ccv_cache_put (ccv_cache_t *cache, uint64_t sign, void *x, uint32_t size, uint8_t type)
void ccv_canny (ccv_dense_matrix_t *a, ccv_dense_matrix_t **b, int type, int size, double low_thresh, double high_thresh)
void ccv_close_outline (ccv_dense_matrix_t *a, ccv_dense_matrix_t **b, int type)
void ccv_color_transform (ccv_dense_matrix_t *a, ccv_dense_matrix_t **b, int type, int flag)
void ccv_compress_sparse_matrix (ccv_sparse_matrix_t *mat, ccv_compressed_sparse_matrix_t **csm)
void ccv_compressive_sensing_reconstruct (ccv_matrix_t *a, ccv_matrix_t *x, ccv_matrix_t **y, int type)
void ccv_contour_free (ccv_contour_t *contour)
ccv_contour_tccv_contour_new (int set)
void ccv_contour_push (ccv_contour_t *contour, ccv_point_t point)
void ccv_daisy (ccv_dense_matrix_t *a, ccv_dense_matrix_t **b, int type, ccv_daisy_param_t params)
static ccv_decimal_point_t ccv_decimal_point (float x, float y)
void ccv_decimal_slice (ccv_dense_matrix_t *a, ccv_dense_matrix_t **b, int type, float y, float x, int rows, int cols)
void ccv_decompress_sparse_matrix (ccv_compressed_sparse_matrix_t *csm, ccv_sparse_matrix_t **smt)
ccv_dense_matrix_t ccv_dense_matrix (int rows, int cols, int type, void *data, uint64_t sig)
void ccv_disable_cache (void)
void ccv_distance_transform (ccv_dense_matrix_t *a, ccv_dense_matrix_t **b, int type, ccv_dense_matrix_t **x, int x_type, ccv_dense_matrix_t **y, int y_type, double dx, double dy, double dxx, double dyy, int flag)
double ccv_dot (ccv_matrix_t *a, ccv_matrix_t *b)
void ccv_dpm_mixture_model_free (ccv_dpm_mixture_model_t *model)
void ccv_dpm_mixture_model_new (char **posfiles, ccv_rect_t *bboxes, int posnum, char **bgfiles, int bgnum, int negnum, const char *dir, ccv_dpm_new_param_t params)
void ccv_drain_cache (void)
void ccv_eigen (ccv_matrix_t *a, ccv_matrix_t *b, ccv_matrix_t **d, int type)
void ccv_enable_cache (size_t size)
void ccv_enable_default_cache (void)
void ccv_ferns_correct (ccv_ferns_t *ferns, uint32_t *fern, int c, int repeat)
void ccv_ferns_feature (ccv_ferns_t *ferns, ccv_dense_matrix_t *a, int scale, uint32_t *fern)
void ccv_ferns_free (ccv_ferns_t *ferns)
float ccv_ferns_predict (ccv_ferns_t *ferns, uint32_t *fern)
void ccv_filter (ccv_dense_matrix_t *a, ccv_dense_matrix_t *b, ccv_dense_matrix_t **d, int type, int padding_pattern)
void ccv_filter_kernel (ccv_dense_matrix_t *x, ccv_filter_kernel_f func, void *data)
void ccv_flatten (ccv_matrix_t *a, ccv_matrix_t **b, int type, int flag)
void ccv_flip (ccv_dense_matrix_t *a, ccv_dense_matrix_t **b, int btype, int type)
void ccv_gemm (ccv_matrix_t *a, ccv_matrix_t *b, double alpha, ccv_matrix_t *c, double beta, int transpose, ccv_matrix_t **d, int type)
ccv_dense_matrix_tccv_get_dense_matrix (ccv_matrix_t *mat)
ccv_sparse_matrix_tccv_get_sparse_matrix (ccv_matrix_t *mat)
ccv_matrix_cell_t ccv_get_sparse_matrix_cell (ccv_sparse_matrix_t *mat, int row, int col)
ccv_dense_vector_tccv_get_sparse_matrix_vector (ccv_sparse_matrix_t *mat, int index)
void ccv_gradient (ccv_dense_matrix_t *a, ccv_dense_matrix_t **theta, int ttype, ccv_dense_matrix_t **m, int mtype, int dx, int dy)
void ccv_hog (ccv_dense_matrix_t *a, ccv_dense_matrix_t **b, int b_type, int sbin, int size)
void ccv_invert (ccv_matrix_t *a, ccv_matrix_t **b, int type)
void ccv_make_array_immutable (ccv_array_t *array)
void ccv_make_array_mutable (ccv_array_t *array)
void ccv_make_matrix_immutable (ccv_matrix_t *mat)
void ccv_make_matrix_mutable (ccv_matrix_t *mat)
int ccv_matrix_eq (ccv_matrix_t *a, ccv_matrix_t *b)
void ccv_matrix_free (ccv_matrix_t *mat)
void ccv_matrix_free_immediately (ccv_matrix_t *mat)
void ccv_minimize (ccv_dense_matrix_t *x, int length, double red, ccv_minimize_f func, ccv_minimize_param_t params, void *data)
void ccv_move (ccv_matrix_t *a, ccv_matrix_t **b, int btype, int y, int x)
void ccv_multiply (ccv_matrix_t *a, ccv_matrix_t *b, ccv_matrix_t **c, int type)
double ccv_norm (ccv_matrix_t *mat, int type)
double ccv_normalize (ccv_matrix_t *a, ccv_matrix_t **b, int btype, int flag)
void ccv_optical_flow_lucas_kanade (ccv_dense_matrix_t *a, ccv_dense_matrix_t *b, ccv_array_t *point_a, ccv_array_t **point_b, ccv_size_t win_size, int level, double min_eigen)
int ccv_otsu (ccv_dense_matrix_t *a, double *outvar, int range)
void ccv_perspective_transform (ccv_dense_matrix_t *a, ccv_dense_matrix_t **b, int type, float m00, float m01, float m02, float m10, float m11, float m12, float m20, float m21, float m22)
ccv_decimal_point_t ccv_perspective_transform_apply (ccv_decimal_point_t point, ccv_size_t size, float m00, float m01, float m02, float m10, float m11, float m12, float m20, float m21, float m22)
static ccv_point_t ccv_point (int x, int y)
int ccv_read_impl (const void *in, ccv_dense_matrix_t **x, int type, int rows, int cols, int scanline)
static ccv_rect_t ccv_rect (int x, int y, int width, int height)
static int ccv_rect_is_zero (ccv_rect_t rect)
void ccv_resample (ccv_dense_matrix_t *a, ccv_dense_matrix_t **b, int btype, int rows, int cols, int type)
void ccv_sample_down (ccv_dense_matrix_t *a, ccv_dense_matrix_t **b, int type, int src_x, int src_y)
void ccv_sample_up (ccv_dense_matrix_t *a, ccv_dense_matrix_t **b, int type, int src_x, int src_y)
void ccv_sat (ccv_dense_matrix_t *a, ccv_dense_matrix_t **b, int type, int padding_pattern)
void ccv_set_sparse_matrix_cell (ccv_sparse_matrix_t *mat, int row, int col, void *data)
void ccv_shift (ccv_matrix_t *a, ccv_matrix_t **b, int type, int lr, int rr)
void ccv_sift (ccv_dense_matrix_t *a, ccv_array_t **keypoints, ccv_dense_matrix_t **desc, int type, ccv_sift_param_t params)
static ccv_size_t ccv_size (int width, int height)
static int ccv_size_is_zero (ccv_size_t size)
void ccv_slice (ccv_matrix_t *a, ccv_matrix_t **b, int type, int y, int x, int rows, int cols)
void ccv_sobel (ccv_dense_matrix_t *a, ccv_dense_matrix_t **b, int type, int dx, int dy)
void ccv_solve (ccv_matrix_t *a, ccv_matrix_t *b, ccv_matrix_t **d, int type)
void ccv_sparse_coding (ccv_matrix_t *x, int k, ccv_matrix_t **A, int typeA, ccv_matrix_t **y, int typey)
void ccv_subtract (ccv_matrix_t *a, ccv_matrix_t *b, ccv_matrix_t **c, int type)
double ccv_sum (ccv_matrix_t *mat, int flag)
void ccv_swt (ccv_dense_matrix_t *a, ccv_dense_matrix_t **b, int type, ccv_swt_param_t params)
void ccv_tld_free (ccv_tld_t *tld)
ccv_comp_t ccv_tld_track_object (ccv_tld_t *tld, ccv_dense_matrix_t *a, ccv_dense_matrix_t *b, ccv_tld_info_t *info)
double ccv_trace (ccv_matrix_t *mat)
double ccv_variance (ccv_matrix_t *mat)
void ccv_visualize (ccv_matrix_t *a, ccv_dense_matrix_t **b, int type)
int ccv_write (ccv_dense_matrix_t *mat, char *out, int *len, int type, void *conf)
void ccv_zero (ccv_matrix_t *mat)

Variables

static const int _ccv_get_data_type_size [] = { -1, 1, 4, -1, 4, -1, -1, -1, 8, -1, -1, -1, -1, -1, -1, -1, 8 }
int _ccv_get_sparse_prime []
ccv_array_t ccv_dense_matrix_t
ccv_dense_matrix_t ** 
b
ccv_tld_t ccv_rect_t box
ccv_array_t
ccv_bbf_classifier_cascade_t ** 
cascade
const ccv_bbf_param_t ccv_bbf_default_params
const ccv_dpm_param_t ccv_dpm_default_params
const ccv_sift_param_t ccv_sift_default_params
const ccv_swt_param_t ccv_swt_default_params
const ccv_tld_param_t ccv_tld_default_params
ccv_dense_matrix_t int int cols
ccv_array_t
ccv_dpm_mixture_model_t int 
count
ccv_dense_matrix_t int int void * data
ccv_ferns_t int features
ccv_array_t ccv_dense_matrix_th
ccv_sparse_matrix_t int int int major
ccv_array_t
ccv_dpm_mixture_model_t ** 
model
ccv_array_t ccv_dense_matrix_t
ccv_dense_matrix_t int
ccv_mser_param_t 
params
ccv_dense_matrix_t int int int int prefer_type
ccv_array_t int rnum
ccv_dense_matrix_t int rows
ccv_ferns_t int int scales
ccv_dense_matrix_t int int int
int uint64_t 
sig
ccv_ferns_t int int ccv_size_tsizes
ccv_dense_matrix_t int int type
ccv_dense_matrix_t int int int types

Define Documentation

#define ccfree   free

Definition at line 26 of file ccv.h.

#define ccmalloc   malloc

Definition at line 24 of file ccv.h.

#define ccrealloc   realloc

Definition at line 25 of file ccv.h.

Definition at line 49 of file ccv.h.

#define ccv_array_get (   a,
 
)    (((char*)((a)->data)) + (a)->rsize * (i))

Definition at line 437 of file ccv.h.

#define CCV_BBF_POINT_MAX   (8)

Definition at line 770 of file ccv.h.

#define CCV_BBF_POINT_MIN   (3)

Definition at line 771 of file ccv.h.

#define ccv_clamp (   x,
  a,
  b 
)    (((x) < (a)) ? (a) : (((x) > (b)) ? (b) : (x)))

Definition at line 196 of file ccv.h.

#define ccv_compute_dense_matrix_size (   rows,
  cols,
  type 
)    (sizeof(ccv_dense_matrix_t) + (((cols) * CCV_GET_DATA_TYPE_SIZE(type) * CCV_GET_CHANNEL(type) + 3) & -4) * (rows))

Definition at line 201 of file ccv.h.

#define CCV_DEFAULT_CACHE_SIZE   (1024 * 1024 * 64)

Definition at line 213 of file ccv.h.

#define CCV_DPM_PART_MAX   (10)

Definition at line 687 of file ccv.h.

#define CCV_GET_CHANNEL (   x)    ((x) & 0xFF)

Definition at line 48 of file ccv.h.

#define CCV_GET_DATA_TYPE (   x)    ((x) & 0xFF00)

Definition at line 45 of file ccv.h.

Definition at line 46 of file ccv.h.

#define ccv_get_dense_matrix_cell (   x,
  row,
  col,
  ch 
)    ccv_get_dense_matrix_cell_by((x)->type, x, row, col, ch)

Definition at line 227 of file ccv.h.

#define ccv_get_dense_matrix_cell_by (   type,
  x,
  row,
  col,
  ch 
)
Value:
(((type) & CCV_32S) ? (void*)((x)->data.i32 + ((row) * (x)->cols + (col)) * CCV_GET_CHANNEL(type) + (ch)) : \
        (((type) & CCV_32F) ? (void*)((x)->data.f32+ ((row) * (x)->cols + (col)) * CCV_GET_CHANNEL(type) + (ch)) : \
        (((type) & CCV_64S) ? (void*)((x)->data.i64+ ((row) * (x)->cols + (col)) * CCV_GET_CHANNEL(type) + (ch)) : \
        (((type) & CCV_64F) ? (void*)((x)->data.f64 + ((row) * (x)->cols + (col)) * CCV_GET_CHANNEL(type) + (ch)) : \
        (void*)((x)->data.u8 + (row) * (x)->step + (col) * CCV_GET_CHANNEL(type) + (ch))))))

Definition at line 220 of file ccv.h.

#define ccv_get_dense_matrix_cell_value (   x,
  row,
  col,
  ch 
)    ccv_get_dense_matrix_cell_value_by((x)->type, x, row, col, ch)

Definition at line 238 of file ccv.h.

#define ccv_get_dense_matrix_cell_value_by (   type,
  x,
  row,
  col,
  ch 
)
Value:
(((type) & CCV_32S) ? (x)->data.i32[((row) * (x)->cols + (col)) * CCV_GET_CHANNEL(type) + (ch)] : \
        (((type) & CCV_32F) ? (x)->data.f32[((row) * (x)->cols + (col)) * CCV_GET_CHANNEL(type) + (ch)] : \
        (((type) & CCV_64S) ? (x)->data.i64[((row) * (x)->cols + (col)) * CCV_GET_CHANNEL(type) + (ch)] : \
        (((type) & CCV_64F) ? (x)->data.f64[((row) * (x)->cols + (col)) * CCV_GET_CHANNEL(type) + (ch)] : \
        (x)->data.u8[(row) * (x)->step + (col) * CCV_GET_CHANNEL(type) + (ch)]))))

Definition at line 231 of file ccv.h.

#define CCV_GET_SPARSE_PRIME (   x)    _ccv_get_sparse_prime[(x)]

Definition at line 132 of file ccv.h.

#define ccv_get_value (   type,
  ptr,
 
)
Value:
(((type) & CCV_32S) ? ((int*)(ptr))[(i)] : \
        (((type) & CCV_32F) ? ((float*)(ptr))[(i)] : \
        (((type) & CCV_64S) ? ((int64_t*)(ptr))[(i)] : \
        (((type) & CCV_64F) ? ((double*)(ptr))[(i)] : \
        ((unsigned char*)(ptr))[(i)]))))

Definition at line 240 of file ccv.h.

#define ccv_max (   a,
  b 
)    (((a) > (b)) ? (a) : (b))

Definition at line 198 of file ccv.h.

#define CCV_MAX_CHANNEL   (0xFF)

Definition at line 47 of file ccv.h.

#define ccv_min (   a,
  b 
)    (((a) < (b)) ? (a) : (b))

Definition at line 197 of file ccv.h.

#define CCV_PI   (3.141592653589793)

Definition at line 23 of file ccv.h.

#define ccv_read (   in,
  x,
  type,
  ... 
)    ccv_read_n(in, x, type, ##__VA_ARGS__, 0, 0, 0)

Definition at line 305 of file ccv.h.

#define ccv_read_n (   in,
  x,
  type,
  rows,
  cols,
  scanline,
  ... 
)    ccv_read_impl(in, x, type, rows, cols, scanline)

Definition at line 303 of file ccv.h.

#define ccv_set_value (   type,
  ptr,
  i,
  value,
  factor 
)
Value:
switch (CCV_GET_DATA_TYPE((type))) { \
        case CCV_32S: ((int*)(ptr))[(i)] = (int)(value) >> factor; break; \
        case CCV_32F: ((float*)(ptr))[(i)] = (float)value; break; \
        case CCV_64S: ((int64_t*)(ptr))[(i)] = (int64_t)(value) >> factor; break; \
        case CCV_64F: ((double*)(ptr))[(i)] = (double)value; break; \
        default: ((unsigned char*)(ptr))[(i)] = ccv_clamp((int)(value) >> factor, 0, 255); }

Definition at line 247 of file ccv.h.


Typedef Documentation

typedef int(* ccv_array_group_f)(const void *, const void *, void *)

Definition at line 428 of file ccv.h.

typedef void(* ccv_cache_index_free_f)(void *)

Definition at line 140 of file ccv.h.

typedef double(* ccv_filter_kernel_f)(double x, double y, void *)

Definition at line 500 of file ccv.h.

typedef void ccv_matrix_t

Definition at line 134 of file ccv.h.

typedef int(* ccv_minimize_f)(const ccv_dense_matrix_t *x, double *f, ccv_dense_matrix_t *df, void *)

Definition at line 496 of file ccv.h.


Enumeration Type Documentation

anonymous enum
Enumerator:
CCV_8U 
CCV_32S 
CCV_32F 
CCV_64S 
CCV_64F 

Definition at line 28 of file ccv.h.

anonymous enum
Enumerator:
CCV_C1 
CCV_C2 
CCV_C3 
CCV_C4 

Definition at line 36 of file ccv.h.

anonymous enum
Enumerator:
CCV_L1_NORM 
CCV_L2_NORM 
CCV_GSEDT 
CCV_NEGATIVE 
CCV_POSITIVE 

Definition at line 316 of file ccv.h.

anonymous enum
Enumerator:
CCV_NO_PADDING 
CCV_PADDING_ZERO 
CCV_PADDING_EXTEND 
CCV_PADDING_MIRROR 

Definition at line 326 of file ccv.h.

anonymous enum
Enumerator:
CCV_SIGNED 
CCV_UNSIGNED 

Definition at line 333 of file ccv.h.

anonymous enum
Enumerator:
CCV_A_TRANSPOSE 
CCV_B_TRANSPOSE 
CCV_C_TRANSPOSE 

Definition at line 347 of file ccv.h.

anonymous enum
Enumerator:
CCV_FLIP_X 
CCV_FLIP_Y 

Definition at line 514 of file ccv.h.

anonymous enum
Enumerator:
CCV_RGB_TO_YUV 

Definition at line 522 of file ccv.h.

anonymous enum
Enumerator:
CCV_INTER_AREA 
CCV_INTER_LINEAR 
CCV_INTER_CUBIC 
CCV_INTER_LANCZOS 

Definition at line 530 of file ccv.h.

anonymous enum
Enumerator:
CCV_DAISY_NORMAL_PARTIAL 
CCV_DAISY_NORMAL_FULL 
CCV_DAISY_NORMAL_SIFT 

Definition at line 575 of file ccv.h.

anonymous enum
Enumerator:
CCV_BRIGHT_TO_DARK 
CCV_DARK_TO_BRIGHT 

Definition at line 638 of file ccv.h.

anonymous enum
Enumerator:
CCV_DPM_NO_NESTED 

Definition at line 754 of file ccv.h.

anonymous enum
Enumerator:
CCV_MATRIX_DENSE 
CCV_MATRIX_SPARSE 
CCV_MATRIX_CSR 
CCV_MATRIX_CSC 

Definition at line 51 of file ccv.h.

anonymous enum
Enumerator:
CCV_BBF_GENETIC_OPT 
CCV_BBF_FLOAT_OPT 

Definition at line 796 of file ccv.h.

anonymous enum
Enumerator:
CCV_BBF_NO_NESTED 

Definition at line 819 of file ccv.h.

anonymous enum
Enumerator:
CCV_GARBAGE 
CCV_REUSABLE 
CCV_UNMANAGED 
CCV_NO_DATA_ALLOC 

Definition at line 58 of file ccv.h.

anonymous enum
Enumerator:
CCV_SPARSE_VECTOR 
CCV_DENSE_VECTOR 

Definition at line 91 of file ccv.h.

anonymous enum
Enumerator:
CCV_SPARSE_ROW_MAJOR 
CCV_SPARSE_COL_MAJOR 

Definition at line 107 of file ccv.h.

anonymous enum
Enumerator:
CCV_IO_GRAY 
CCV_IO_RGB_COLOR 

Definition at line 256 of file ccv.h.

anonymous enum
Enumerator:
CCV_IO_NO_COPY 

Definition at line 263 of file ccv.h.

anonymous enum
Enumerator:
CCV_IO_ANY_STREAM 
CCV_IO_BMP_STREAM 
CCV_IO_JPEG_STREAM 
CCV_IO_PNG_STREAM 
CCV_IO_PLAIN_STREAM 
CCV_IO_DEFLATE_STREAM 
CCV_IO_ANY_FILE 
CCV_IO_BMP_FILE 
CCV_IO_JPEG_FILE 
CCV_IO_PNG_FILE 
CCV_IO_BINARY_FILE 
CCV_IO_ANY_RAW 
CCV_IO_RGB_RAW 
CCV_IO_RGBA_RAW 
CCV_IO_ARGB_RAW 
CCV_IO_BGR_RAW 
CCV_IO_BGRA_RAW 
CCV_IO_ABGR_RAW 
CCV_IO_GRAY_RAW 

Definition at line 268 of file ccv.h.

anonymous enum
Enumerator:
CCV_IO_FINAL 
CCV_IO_CONTINUE 
CCV_IO_ERROR 
CCV_IO_ATTEMPTED 
CCV_IO_UNKNOWN 

Definition at line 294 of file ccv.h.


Function Documentation

ccv_tld_t * __attribute__ ( (warn_unused_result)  )
int ccv_any_nan ( ccv_matrix_t a)
void ccv_array_clear ( ccv_array_t array)
void ccv_array_free ( ccv_array_t array)
int ccv_array_group ( ccv_array_t array,
ccv_array_t **  index,
ccv_array_group_f  gfunc,
void *  data 
)
void ccv_array_push ( ccv_array_t array,
void *  r 
)
void ccv_array_zero ( ccv_array_t array)
void ccv_bbf_classifier_cascade_new ( ccv_dense_matrix_t **  posimg,
int  posnum,
char **  bgfiles,
int  bgnum,
int  negnum,
ccv_size_t  size,
const char *  dir,
ccv_bbf_new_param_t  params 
)
int ccv_bbf_classifier_cascade_write_binary ( ccv_bbf_classifier_cascade_t cascade,
char *  s,
int  slen 
)
void ccv_blur ( ccv_dense_matrix_t a,
ccv_dense_matrix_t **  b,
int  type,
double  sigma 
)
void ccv_cache_cleanup ( ccv_cache_t cache)
void ccv_cache_close ( ccv_cache_t cache)
int ccv_cache_delete ( ccv_cache_t cache,
uint64_t  sign 
)
uint64_t ccv_cache_generate_signature ( const char *  msg,
int  len,
uint64_t  sig_start,
  ... 
)
void* ccv_cache_get ( ccv_cache_t cache,
uint64_t  sign,
uint8_t *  type 
)
void ccv_cache_init ( ccv_cache_t cache,
size_t  up,
int  cache_types,
ccv_cache_index_free_f  ffree,
  ... 
)
void* ccv_cache_out ( ccv_cache_t cache,
uint64_t  sign,
uint8_t *  type 
)
int ccv_cache_put ( ccv_cache_t cache,
uint64_t  sign,
void *  x,
uint32_t  size,
uint8_t  type 
)
void ccv_canny ( ccv_dense_matrix_t a,
ccv_dense_matrix_t **  b,
int  type,
int  size,
double  low_thresh,
double  high_thresh 
)
void ccv_close_outline ( ccv_dense_matrix_t a,
ccv_dense_matrix_t **  b,
int  type 
)
void ccv_color_transform ( ccv_dense_matrix_t a,
ccv_dense_matrix_t **  b,
int  type,
int  flag 
)
void ccv_compressive_sensing_reconstruct ( ccv_matrix_t a,
ccv_matrix_t x,
ccv_matrix_t **  y,
int  type 
)
void ccv_contour_free ( ccv_contour_t contour)
void ccv_contour_push ( ccv_contour_t contour,
ccv_point_t  point 
)
void ccv_daisy ( ccv_dense_matrix_t a,
ccv_dense_matrix_t **  b,
int  type,
ccv_daisy_param_t  params 
)
static ccv_decimal_point_t ccv_decimal_point ( float  x,
float  y 
) [inline, static]

Definition at line 455 of file ccv.h.

void ccv_decimal_slice ( ccv_dense_matrix_t a,
ccv_dense_matrix_t **  b,
int  type,
float  y,
float  x,
int  rows,
int  cols 
)
ccv_dense_matrix_t ccv_dense_matrix ( int  rows,
int  cols,
int  type,
void *  data,
uint64_t  sig 
)
void ccv_disable_cache ( void  )
void ccv_distance_transform ( ccv_dense_matrix_t a,
ccv_dense_matrix_t **  b,
int  type,
ccv_dense_matrix_t **  x,
int  x_type,
ccv_dense_matrix_t **  y,
int  y_type,
double  dx,
double  dy,
double  dxx,
double  dyy,
int  flag 
)
double ccv_dot ( ccv_matrix_t a,
ccv_matrix_t b 
)
void ccv_dpm_mixture_model_new ( char **  posfiles,
ccv_rect_t bboxes,
int  posnum,
char **  bgfiles,
int  bgnum,
int  negnum,
const char *  dir,
ccv_dpm_new_param_t  params 
)
void ccv_drain_cache ( void  )
void ccv_eigen ( ccv_matrix_t a,
ccv_matrix_t b,
ccv_matrix_t **  d,
int  type 
)
void ccv_enable_cache ( size_t  size)
void ccv_enable_default_cache ( void  )
void ccv_ferns_correct ( ccv_ferns_t ferns,
uint32_t *  fern,
int  c,
int  repeat 
)
void ccv_ferns_feature ( ccv_ferns_t ferns,
ccv_dense_matrix_t a,
int  scale,
uint32_t *  fern 
)
void ccv_ferns_free ( ccv_ferns_t ferns)
float ccv_ferns_predict ( ccv_ferns_t ferns,
uint32_t *  fern 
)
void ccv_filter ( ccv_dense_matrix_t a,
ccv_dense_matrix_t b,
ccv_dense_matrix_t **  d,
int  type,
int  padding_pattern 
)
void ccv_filter_kernel ( ccv_dense_matrix_t x,
ccv_filter_kernel_f  func,
void *  data 
)
void ccv_flatten ( ccv_matrix_t a,
ccv_matrix_t **  b,
int  type,
int  flag 
)
void ccv_flip ( ccv_dense_matrix_t a,
ccv_dense_matrix_t **  b,
int  btype,
int  type 
)
void ccv_gemm ( ccv_matrix_t a,
ccv_matrix_t b,
double  alpha,
ccv_matrix_t c,
double  beta,
int  transpose,
ccv_matrix_t **  d,
int  type 
)
void ccv_gradient ( ccv_dense_matrix_t a,
ccv_dense_matrix_t **  theta,
int  ttype,
ccv_dense_matrix_t **  m,
int  mtype,
int  dx,
int  dy 
)
void ccv_hog ( ccv_dense_matrix_t a,
ccv_dense_matrix_t **  b,
int  b_type,
int  sbin,
int  size 
)
void ccv_invert ( ccv_matrix_t a,
ccv_matrix_t **  b,
int  type 
)
int ccv_matrix_eq ( ccv_matrix_t a,
ccv_matrix_t b 
)
void ccv_matrix_free ( ccv_matrix_t mat)
void ccv_minimize ( ccv_dense_matrix_t x,
int  length,
double  red,
ccv_minimize_f  func,
ccv_minimize_param_t  params,
void *  data 
)
void ccv_move ( ccv_matrix_t a,
ccv_matrix_t **  b,
int  btype,
int  y,
int  x 
)
void ccv_multiply ( ccv_matrix_t a,
ccv_matrix_t b,
ccv_matrix_t **  c,
int  type 
)
double ccv_norm ( ccv_matrix_t mat,
int  type 
)
double ccv_normalize ( ccv_matrix_t a,
ccv_matrix_t **  b,
int  btype,
int  flag 
)
void ccv_optical_flow_lucas_kanade ( ccv_dense_matrix_t a,
ccv_dense_matrix_t b,
ccv_array_t point_a,
ccv_array_t **  point_b,
ccv_size_t  win_size,
int  level,
double  min_eigen 
)
int ccv_otsu ( ccv_dense_matrix_t a,
double *  outvar,
int  range 
)
void ccv_perspective_transform ( ccv_dense_matrix_t a,
ccv_dense_matrix_t **  b,
int  type,
float  m00,
float  m01,
float  m02,
float  m10,
float  m11,
float  m12,
float  m20,
float  m21,
float  m22 
)
ccv_decimal_point_t ccv_perspective_transform_apply ( ccv_decimal_point_t  point,
ccv_size_t  size,
float  m00,
float  m01,
float  m02,
float  m10,
float  m11,
float  m12,
float  m20,
float  m21,
float  m22 
)
static ccv_point_t ccv_point ( int  x,
int  y 
) [inline, static]

Definition at line 443 of file ccv.h.

int ccv_read_impl ( const void *  in,
ccv_dense_matrix_t **  x,
int  type,
int  rows,
int  cols,
int  scanline 
)
static ccv_rect_t ccv_rect ( int  x,
int  y,
int  width,
int  height 
) [inline, static]

Definition at line 401 of file ccv.h.

static int ccv_rect_is_zero ( ccv_rect_t  rect) [inline, static]

Definition at line 411 of file ccv.h.

void ccv_resample ( ccv_dense_matrix_t a,
ccv_dense_matrix_t **  b,
int  btype,
int  rows,
int  cols,
int  type 
)
void ccv_sample_down ( ccv_dense_matrix_t a,
ccv_dense_matrix_t **  b,
int  type,
int  src_x,
int  src_y 
)
void ccv_sample_up ( ccv_dense_matrix_t a,
ccv_dense_matrix_t **  b,
int  type,
int  src_x,
int  src_y 
)
void ccv_sat ( ccv_dense_matrix_t a,
ccv_dense_matrix_t **  b,
int  type,
int  padding_pattern 
)
void ccv_set_sparse_matrix_cell ( ccv_sparse_matrix_t mat,
int  row,
int  col,
void *  data 
)
void ccv_shift ( ccv_matrix_t a,
ccv_matrix_t **  b,
int  type,
int  lr,
int  rr 
)
void ccv_sift ( ccv_dense_matrix_t a,
ccv_array_t **  keypoints,
ccv_dense_matrix_t **  desc,
int  type,
ccv_sift_param_t  params 
)
static ccv_size_t ccv_size ( int  width,
int  height 
) [inline, static]

Definition at line 381 of file ccv.h.

static int ccv_size_is_zero ( ccv_size_t  size) [inline, static]

Definition at line 389 of file ccv.h.

void ccv_slice ( ccv_matrix_t a,
ccv_matrix_t **  b,
int  type,
int  y,
int  x,
int  rows,
int  cols 
)
void ccv_sobel ( ccv_dense_matrix_t a,
ccv_dense_matrix_t **  b,
int  type,
int  dx,
int  dy 
)
void ccv_solve ( ccv_matrix_t a,
ccv_matrix_t b,
ccv_matrix_t **  d,
int  type 
)
void ccv_sparse_coding ( ccv_matrix_t x,
int  k,
ccv_matrix_t **  A,
int  typeA,
ccv_matrix_t **  y,
int  typey 
)
void ccv_subtract ( ccv_matrix_t a,
ccv_matrix_t b,
ccv_matrix_t **  c,
int  type 
)
double ccv_sum ( ccv_matrix_t mat,
int  flag 
)
void ccv_swt ( ccv_dense_matrix_t a,
ccv_dense_matrix_t **  b,
int  type,
ccv_swt_param_t  params 
)
void ccv_tld_free ( ccv_tld_t tld)
double ccv_trace ( ccv_matrix_t mat)
double ccv_variance ( ccv_matrix_t mat)
void ccv_visualize ( ccv_matrix_t a,
ccv_dense_matrix_t **  b,
int  type 
)
int ccv_write ( ccv_dense_matrix_t mat,
char *  out,
int *  len,
int  type,
void *  conf 
)
void ccv_zero ( ccv_matrix_t mat)

Variable Documentation

const int _ccv_get_data_type_size[] = { -1, 1, 4, -1, 4, -1, -1, -1, 8, -1, -1, -1, -1, -1, -1, -1, 8 } [static]

Definition at line 43 of file ccv.h.

Definition at line 643 of file ccv.h.

Definition at line 931 of file ccv.h.

Definition at line 826 of file ccv.h.

Definition at line 202 of file ccv.h.

Definition at line 761 of file ccv.h.

ccv_dense_matrix_t int int void* data

Definition at line 203 of file ccv.h.

Definition at line 848 of file ccv.h.

Definition at line 643 of file ccv.h.

Definition at line 207 of file ccv.h.

Definition at line 761 of file ccv.h.

Definition at line 643 of file ccv.h.

Definition at line 202 of file ccv.h.

Definition at line 426 of file ccv.h.

Definition at line 202 of file ccv.h.

Definition at line 848 of file ccv.h.

ccv_array_t int uint64_t sig

Definition at line 202 of file ccv.h.

Definition at line 848 of file ccv.h.

Definition at line 203 of file ccv.h.

Definition at line 202 of file ccv.h.



text_locator
Author(s): Vojtech Novak
autogenerated on Mon Oct 6 2014 07:55:19