Issue #1737 - Import libaom 2.0.2 source (excluding aom_ports/aom_once.h)

This commit is contained in:
roytam1 2021-03-04 09:29:28 +08:00
commit 7537b4d23a
767 changed files with 152707 additions and 85235 deletions

View file

@ -37,3 +37,4 @@ Local Modifications:
Add lines to turn off clang formatting for these files
Remove Fast 10, 11 and 12
Convert tabs to spaces
Prefix global functions with "aom_"

View file

@ -3,16 +3,16 @@
#include "fast.h"
xy* fast9_detect_nonmax(const byte* im, int xsize, int ysize, int stride, int b, int* ret_num_corners)
xy* aom_fast9_detect_nonmax(const byte* im, int xsize, int ysize, int stride, int b, int* ret_num_corners)
{
xy* corners;
int num_corners;
int* scores;
xy* nonmax;
corners = fast9_detect(im, xsize, ysize, stride, b, &num_corners);
scores = fast9_score(im, stride, corners, num_corners, b);
nonmax = nonmax_suppression(corners, scores, num_corners, ret_num_corners);
corners = aom_fast9_detect(im, xsize, ysize, stride, b, &num_corners);
scores = aom_fast9_score(im, stride, corners, num_corners, b);
nonmax = aom_nonmax_suppression(corners, scores, num_corners, ret_num_corners);
free(corners);
free(scores);

View file

@ -5,15 +5,15 @@
typedef struct { int x, y; } xy;
typedef unsigned char byte;
int fast9_corner_score(const byte* p, const int pixel[], int bstart);
int aom_fast9_corner_score(const byte* p, const int pixel[], int bstart);
xy* fast9_detect(const byte* im, int xsize, int ysize, int stride, int b, int* ret_num_corners);
xy* aom_fast9_detect(const byte* im, int xsize, int ysize, int stride, int b, int* ret_num_corners);
int* fast9_score(const byte* i, int stride, xy* corners, int num_corners, int b);
int* aom_fast9_score(const byte* i, int stride, xy* corners, int num_corners, int b);
xy* fast9_detect_nonmax(const byte* im, int xsize, int ysize, int stride, int b, int* ret_num_corners);
xy* aom_fast9_detect_nonmax(const byte* im, int xsize, int ysize, int stride, int b, int* ret_num_corners);
xy* nonmax_suppression(const xy* corners, const int* scores, int num_corners, int* ret_num_nonmax);
xy* aom_nonmax_suppression(const xy* corners, const int* scores, int num_corners, int* ret_num_nonmax);
#endif

View file

@ -5,7 +5,7 @@
typedef struct { int x, y; } xy;
typedef unsigned char byte;
int fast9_corner_score(const byte* p, const int pixel[], int bstart)
int aom_fast9_corner_score(const byte* p, const int pixel[], int bstart)
{
int bmin = bstart;
int bmax = 255;
@ -2958,7 +2958,7 @@ static void make_offsets(int pixel[], int row_stride)
int* fast9_score(const byte* i, int stride, xy* corners, int num_corners, int b)
int* aom_fast9_score(const byte* i, int stride, xy* corners, int num_corners, int b)
{
int* scores = (int*)malloc(sizeof(int)* num_corners);
int n;
@ -2967,13 +2967,13 @@ int* fast9_score(const byte* i, int stride, xy* corners, int num_corners, int b)
make_offsets(pixel, stride);
for(n=0; n < num_corners; n++)
scores[n] = fast9_corner_score(i + corners[n].y*stride + corners[n].x, pixel, b);
scores[n] = aom_fast9_corner_score(i + corners[n].y*stride + corners[n].x, pixel, b);
return scores;
}
xy* fast9_detect(const byte* im, int xsize, int ysize, int stride, int b, int* ret_num_corners)
xy* aom_fast9_detect(const byte* im, int xsize, int ysize, int stride, int b, int* ret_num_corners)
{
int num_corners=0;
xy* ret_corners;

View file

@ -5,7 +5,7 @@
#define Compare(X, Y) ((X)>=(Y))
xy* nonmax_suppression(const xy* corners, const int* scores, int num_corners, int* ret_num_nonmax)
xy* aom_nonmax_suppression(const xy* corners, const int* scores, int num_corners, int* ret_num_nonmax)
{
int num_nonmax=0;
int last_row;