fix some more warnings in computer_vision

This commit is contained in:
Felix Ruess
2016-03-24 14:54:47 +01:00
parent a978656403
commit d8e032b29c
5 changed files with 18 additions and 18 deletions
@@ -53,11 +53,11 @@ volatile bool_t marker_enabled = FALSE;
volatile bool_t window_enabled = FALSE;
// Computer vision thread
bool_t cv_marker_func(struct image_t *img);
bool_t cv_marker_func(struct image_t *img) {
struct image_t* cv_marker_func(struct image_t *img);
struct image_t* cv_marker_func(struct image_t *img) {
if (!marker_enabled)
return FALSE;
return NULL;
struct marker_deviation_t m = marker(img, marker_size);
@@ -66,18 +66,18 @@ bool_t cv_marker_func(struct image_t *img) {
temp += m.y;
blob_locator = temp;
return FALSE;
return NULL;
}
#define Img(X,Y)(((uint8_t*)img->buf)[(Y)*img->w*2+(X)*2])
// Computer vision thread
bool_t cv_window_func(struct image_t *img);
bool_t cv_window_func(struct image_t *img) {
struct image_t* cv_window_func(struct image_t *img);
struct image_t* cv_window_func(struct image_t *img) {
if (!window_enabled)
return FALSE;
return NULL;
uint16_t coordinate[2] = {0,0};
@@ -114,15 +114,15 @@ bool_t cv_window_func(struct image_t *img) {
}
return FALSE;
return NULL;
}
bool_t cv_blob_locator_func(struct image_t *img);
bool_t cv_blob_locator_func(struct image_t *img) {
struct image_t* cv_blob_locator_func(struct image_t *img);
struct image_t* cv_blob_locator_func(struct image_t *img) {
if (!blob_enabled)
return 0;
return NULL;
// Color Filter
@@ -209,7 +209,7 @@ bool_t cv_blob_locator_func(struct image_t *img) {
image_free(&dst);
return 0; // No new image is available for follow up modules
return NULL; // No new image is available for follow up modules
}
#include "modules/computer_vision/cv_georeference.h"
@@ -31,12 +31,12 @@
#include "detect_window.h"
#include <stdio.h>
extern void detect_window_init(void)
void detect_window_init(void)
{
cv_add(detect_window);
}
extern bool_t detect_window(struct image_t *img)
struct image_t* detect_window(struct image_t *img)
{
uint16_t coordinate[2];
@@ -53,7 +53,7 @@ extern bool_t detect_window(struct image_t *img)
printf("Response = %d\n", response);
image_free(&gray);
return 0; // No new image was created
return NULL; // No new image was created
}
@@ -35,7 +35,7 @@
#include "inttypes.h"
extern void detect_window_init(void);
extern bool_t detect_window(struct image_t *img);
extern struct image_t* detect_window(struct image_t *img);
uint16_t detect_window_sizes(uint8_t *in, uint32_t image_width, uint32_t image_height, uint16_t *coordinate,
uint32_t *integral_image, uint8_t MODE);
@@ -99,5 +99,5 @@ struct image_t* qrscan(struct image_t *img)
zbar_image_destroy(image);
//zbar_image_scanner_destroy(scanner);
return 0; // QRCode is not returning a new image.
return NULL; // QRCode is not returning a new image.
}
@@ -189,7 +189,7 @@ struct image_t* viewvideo_function(struct image_t *img)
// Free all buffers
image_free(&img_jpeg);
image_free(&img_small);
return 0; // No new images were created
return NULL; // No new images were created
}
/**