diff --git a/combine_images.c b/combine_images.c new file mode 100644 index 0000000..af727dc --- /dev/null +++ b/combine_images.c @@ -0,0 +1,33 @@ +#include + +int main(){ + +l_int32 w, d; +l_int32 tw, td; + PIX *pixa, *pixs, *pix2,*pix1; + pixa = pixaCreate(5); + pixs = pixRead("im2070.jpg"); + pixGetDimensions(pixs, &w, NULL, &d); + pixSaveTiled(pixs, pixa, 1.0, 0, 1,1); + pixDisplay(pixs,100,0); + pix2 = pixRead("binar6.png"); + pixDisplay(pix2,100,0); + pixSaveTiled(pix2, pixa, 1.0, 0, 1,1); + + pix1 = pixaDisplay(pixa, w*2, 0.80*d); + pixWrite("binar6.png", pix1, IFF_PNG); + + + td = pixEqual(pixs,pix2,&tw); + + if (tw == 1){ + printf("%s", "Muna"); + } + + printf("%d", td); + if (td == 1){ + printf("%s", "Tuna"); + } + + +} diff --git a/work.c b/work.c index f8a3d29..0647cd0 100644 --- a/work.c +++ b/work.c @@ -10,7 +10,7 @@ #define BLACK 20.0 #define YELLOW 70.0 - + #define min_f(a, b, c) (fminf(a, fminf(b, c))) #define max_f(a, b, c) (fmaxf(a, fmaxf(b, c))) @@ -18,6 +18,17 @@ int xflag = 0; int last_index =0; int skip_frames = 12; + +int t_flag = 0; + + +PIX *pix_temp; +PIX *pixa, *pix1; + +l_int32 w, d; + + + void rgb2lab(float R, float G, float B,float *L, float *a, float *b){ //Conversion to the CIE-LAB color space to get the Luminance float X, Y, Z, fX, fY, fZ; @@ -131,6 +142,8 @@ void _process_frame_tickertext(AVFrame *frame, int width, int height, int index) + + for(i=(92*height)/100;i