#include "lesson_10_halide.h"
#include <stdio.h>
int main(int argc, char **argv) {
int offset = 5;
int error = brighter(input, offset, output);
if (error) {
printf("Halide returned an error: %d\n", error);
return -1;
}
for (int y = 0; y < 480; y++) {
for (int x = 0; x < 640; x++) {
uint8_t correct_val = input_val + offset;
if (output_val != correct_val) {
printf("output(%d, %d) was %d instead of %d\n",
x, y, output_val, correct_val);
return -1;
}
}
}
printf("Success!\n");
return 0;
}
Defines a Buffer type that wraps from halide_buffer_t and adds functionality, and methods for more co...
A templated Buffer class that wraps halide_buffer_t and adds functionality.
unsigned __INT8_TYPE__ uint8_t