#ifndef LIBU_DATA_H
#define LIBU_DATA_H

#include "jpeg.h"

#define Cb(i, j) Cb[i * BLOCK_WIDTH + j]
#define Cr(i, j) Cr[i * BLOCK_WIDTH + j]

typedef struct {
	SPACE_ALIGNED unsigned char Y[4][BLOCK_SIZE];
	SPACE_ALIGNED unsigned char Cb[BLOCK_SIZE];
	SPACE_ALIGNED unsigned char Cr[BLOCK_SIZE];

	unsigned int counter_lumVi_lumHi;
	unsigned int vi_cnt;
	unsigned int hi_cnt;
	unsigned int macroLine;
	unsigned int macroColumn;
	unsigned int frameCnt;

	int minR;
	int minG;
	int minB;
	int minA;
	int maxR;
	int maxG;
	int maxB;
	int maxA;
	int sumR;
	int sumG;
	int sumB;
	int sumA;
	int nbPixels;

} libu_struct;

#endif
