diff --git a/debian/patches/020110315~2a1524a.patch b/debian/patches/020110315~2a1524a.patch new file mode 100644 index 0000000..45f4949 --- /dev/null +++ b/debian/patches/020110315~2a1524a.patch @@ -0,0 +1,68 @@ +Description: Add #ifndef around all the math macros. + OpenCV defines MIN and MAX. Potentially other libs can too and more. +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=2a1524a +Author: Dan Dennedy +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/include/frei0r_math.h ++++ b/include/frei0r_math.h +@@ -17,38 +17,58 @@ + */ + + /* Clamps a int32-range int between 0 and 255 inclusive. */ ++#ifndef CLAMP0255 + unsigned char CLAMP0255(int32_t a) + { + return (unsigned char) + ( (((-a) >> 31) & a) // 0 if the number was negative + | (255 - a) >> 31); // -1 if the number was greater than 255 + } ++#endif + + /* Provided temporary int t, returns a * b / 255 */ ++#ifndef INT_MULT + #define INT_MULT(a,b,t) ((t) = (a) * (b) + 0x80, ((((t) >> 8) + (t)) >> 8)) ++#endif + + /* This version of INT_MULT3 is very fast, but suffers from some + slight roundoff errors. It returns the correct result 99.987 + percent of the time */ ++#ifndef INT_MULT3 + #define INT_MULT3(a,b,c,t) ((t) = (a) * (b) * (c) + 0x7F5B, \ + ((((t) >> 7) + (t)) >> 16)) ++#endif + ++#ifndef INT_BLEND + #define INT_BLEND(a,b,alpha,tmp) (INT_MULT((a) - (b), alpha, tmp) + (b)) ++#endif + ++#ifndef CLAMP + //! Clamp x at lower = l and upper = u. + #define CLAMP(x,l,u) ( x < l ? l : ( x > u ? u : x ) ) ++#endif + ++#ifndef ROUND + //! Round. + #define ROUND(x) ((int32_t)((x)+0.5)) ++#endif + ++#ifndef SQR + //! Square. + #define SQR(x) ((x) * (x)) ++#endif + ++#ifndef MAX255 + //! Limit a (0->511) int to 255. + uint8_t MAX255(uint32_t a) { return (uint8_t) (a | ((a & 256) - ((a & 256) >> 8))); } ++#endif + ++#ifndef MIN + #define MIN(x, y) ((x) < (y) ? (x) : (y)); ++#endif + ++#ifndef MAX + #define MAX(x, y) ((x) > (y) ? (x) : (y)); ++#endif + + #endif diff --git a/debian/patches/020110315~b4065ce.patch b/debian/patches/020110315~b4065ce.patch new file mode 100644 index 0000000..fe44ffb --- /dev/null +++ b/debian/patches/020110315~b4065ce.patch @@ -0,0 +1,72 @@ +Description: Sanitize parameters in OpenCV filters. + Some very low parameter values would case a crash inside OpenCV or make + it unresponsive (deadlock or infinite loop - did not check). +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=b4065ce +Author: Dan Dennedy +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/facebl0r/facebl0r.cpp ++++ b/src/filter/facebl0r/facebl0r.cpp +@@ -21,6 +21,7 @@ + #include + + #include ++#include + + typedef struct { + IplImage* hsv; //input image converted to HSV +@@ -133,7 +134,7 @@ + if (!cascade) { + cvSetNumThreads(cvRound(threads * 100)); + get_param_value(&classifier, FACEBL0R_PARAM_CLASSIFIER); +- if (classifier) { ++ if (classifier && strcmp(classifier, "")) { + if ( strcmp(classifier, old_classifier) == 0) { + // same as before, avoid repeating error messages + memcpy(out, in, size * 4); // of course assuming we are RGBA only +@@ -154,6 +155,12 @@ + return; + } + } ++ ++ // sanitize parameters ++ recheck = CLAMP(recheck, 0.001, 1.0); ++ search_scale = CLAMP(search_scale, 0.11, 1.0); ++ neighbors = CLAMP(neighbors, 0.01, 1.0); ++ + if( !image ) + image = cvCreateImage( cvSize(width,height), IPL_DEPTH_8U, 4 ); + +--- a/src/filter/facedetect/facedetect.cpp ++++ b/src/filter/facedetect/facedetect.cpp +@@ -27,6 +27,7 @@ + #include + #include + #include "frei0r.hpp" ++#include "frei0r_math.h" + + #define USE_ROI + #define PAD (40) +@@ -125,7 +126,7 @@ + cvSetNumThreads(cvRound(threads * 100)); + f0r_param_string classifier; + get_param_value(&classifier, FACEBL0R_PARAM_CLASSIFIER); +- if (classifier) { ++ if (classifier && strcmp(classifier, "")) { + cascade = (CvHaarClassifierCascade*) cvLoad(classifier, 0, 0, 0 ); + if (!cascade) + fprintf(stderr, "ERROR: Could not load classifier cascade %s\n", classifier); +@@ -136,7 +137,11 @@ + return; + } + } +- ++ ++ // sanitize parameters ++ search_scale = CLAMP(search_scale, 0.11, 1.0); ++ neighbors = CLAMP(neighbors, 0.01, 1.0); ++ + // copy input image to OpenCV + if( !image ) + image = cvCreateImage(cvSize(width, height), IPL_DEPTH_8U, 4); diff --git a/debian/patches/020110316~6c65d6a.patch b/debian/patches/020110316~6c65d6a.patch new file mode 100644 index 0000000..003b2f4 --- /dev/null +++ b/debian/patches/020110316~6c65d6a.patch @@ -0,0 +1,30 @@ +Description: Fix broken color parameters in facedetect. + They were all setting the first color! +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=6c65d6a +Author: Dan Dennedy +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/facedetect/facedetect.cpp ++++ b/src/filter/facedetect/facedetect.cpp +@@ -101,16 +101,16 @@ + register_param(color[0], "Color 1", "The color of the first object"); + f0r_param_color color1 = {0.0, 0.5, 1.0}; + color[1] = color1; +- register_param(color[0], "Color 2", "The color of the second object"); ++ register_param(color[1], "Color 2", "The color of the second object"); + f0r_param_color color2 = {0.0, 1.0, 1.0}; + color[2] = color2; +- register_param(color[0], "Color 3", "The color of the third object"); ++ register_param(color[2], "Color 3", "The color of the third object"); + f0r_param_color color3 = {0.0, 1.0, 0.0}; + color[3] = color3; +- register_param(color[0], "Color 4", "The color of the fourth object"); ++ register_param(color[3], "Color 4", "The color of the fourth object"); + f0r_param_color color4 = {1.0, 0.5, 0.0}; + color[4] = color4; +- register_param(color[0], "Color 5", "The color of the fifth object"); ++ register_param(color[4], "Color 5", "The color of the fifth object"); + srand(::time(NULL)); + } + diff --git a/debian/patches/020110806~0309859.patch b/debian/patches/020110806~0309859.patch new file mode 100644 index 0000000..a5ec076 --- /dev/null +++ b/debian/patches/020110806~0309859.patch @@ -0,0 +1,60 @@ +Description: Defish0r: fix possible /0 problem +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=0309859 +Author: Marko Cebokli +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/defish0r/interp.h ++++ b/src/filter/defish0r/interp.h +@@ -722,10 +722,10 @@ + for (i=7;i>=0;i--) + { + x1=xx*PI; +- wy[7-i]=(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)); ++ wy[7-i]=(x1!=0)?(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)):1.0; + xxx=(float)(2*i+1)-xx; + x1=xxx*PI; +- wy[8+i]=(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)); ++ wy[8+i]=(x1!=0)?(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)):1.0; + xx=xx-1.0; + } + //se po x +@@ -733,10 +733,10 @@ + for (i=7;i>=0;i--) + { + x1=xx*PI; +- wx[7-i]=(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)); ++ wx[7-i]=(x1!=0)?(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)):1.0; + xxx=(float)(2*i+1)-xx; + x1=xxx*PI; +- wx[8+i]=(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)); ++ wx[8+i]=(x1!=0)?(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)):1.0; + xx=xx-1.0; + } + +@@ -781,10 +781,10 @@ + for (i=7;i>=0;i--) + { + x1=xx*PI; +- wy[7-i]=(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)); ++ wy[7-i]=(x1!=0)?(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)):1.0; + xxx=(float)(2*i+1)-xx; + x1=xxx*PI; +- wy[8+i]=(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)); ++ wy[8+i]=(x1!=0)?(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)):1.0; + xx=xx-1.0; + } + //se po x +@@ -792,10 +792,10 @@ + for (i=7;i>=0;i--) + { + x1=xx*PI; +- wx[7-i]=(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)); ++ wx[7-i]=(x1!=0)?(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)):1.0; + xxx=(float)(2*i+1)-xx; + x1=xxx*PI; +- wx[8+i]=(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)); ++ wx[8+i]=(x1!=0)?(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)):1.0; + xx=xx-1.0; + } + diff --git a/debian/patches/020110806~f73c962.patch b/debian/patches/020110806~f73c962.patch new file mode 100644 index 0000000..c90c778 --- /dev/null +++ b/debian/patches/020110806~f73c962.patch @@ -0,0 +1,60 @@ +Description: Corners: fix possible /0 problem +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=f73c962 +Author: Marko Cebokli +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/c0rners/interp.h ++++ b/src/filter/c0rners/interp.h +@@ -722,10 +722,10 @@ + for (i=7;i>=0;i--) + { + x1=xx*PI; +- wy[7-i]=(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)); ++ wy[7-i]=(x1!=0)?(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)):1.0; + xxx=(float)(2*i+1)-xx; + x1=xxx*PI; +- wy[8+i]=(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)); ++ wy[8+i]=(x1!=0)?(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)):1.0; + xx=xx-1.0; + } + //se po x +@@ -733,10 +733,10 @@ + for (i=7;i>=0;i--) + { + x1=xx*PI; +- wx[7-i]=(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)); ++ wx[7-i]=(x1!=0)?(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)):1.0; + xxx=(float)(2*i+1)-xx; + x1=xxx*PI; +- wx[8+i]=(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)); ++ wx[8+i]=(x1!=0)?(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)):1.0; + xx=xx-1.0; + } + +@@ -781,10 +781,10 @@ + for (i=7;i>=0;i--) + { + x1=xx*PI; +- wy[7-i]=(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)); ++ wy[7-i]=(x1!=0)?(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)):1.0; + xxx=(float)(2*i+1)-xx; + x1=xxx*PI; +- wy[8+i]=(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)); ++ wy[8+i]=(x1!=0)?(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)):1.0; + xx=xx-1.0; + } + //se po x +@@ -792,10 +792,10 @@ + for (i=7;i>=0;i--) + { + x1=xx*PI; +- wx[7-i]=(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)); ++ wx[7-i]=(x1!=0)?(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)):1.0; + xxx=(float)(2*i+1)-xx; + x1=xxx*PI; +- wx[8+i]=(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)); ++ wx[8+i]=(x1!=0)?(sin(x1)/(x1))*(sin(x1*0.125)/(x1*0.125)):1.0; + xx=xx-1.0; + } + diff --git a/debian/patches/020110815~339ad24.patch b/debian/patches/020110815~339ad24.patch new file mode 100644 index 0000000..a85259f --- /dev/null +++ b/debian/patches/020110815~339ad24.patch @@ -0,0 +1,14 @@ +Description: 3dflippo: plug a mem leak +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=339ad24 +Author: Marko Cebokli +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/3dflippo/3dflippo.c ++++ b/src/filter/3dflippo/3dflippo.c +@@ -442,4 +442,5 @@ + inst->mask[pos]=ny*inst->width+nx; + } + } ++ matfree(mat); + } diff --git a/debian/patches/020110815~899fd4d.patch b/debian/patches/020110815~899fd4d.patch new file mode 100644 index 0000000..27c62a6 --- /dev/null +++ b/debian/patches/020110815~899fd4d.patch @@ -0,0 +1,26 @@ +Description: Hueshift0r: use BT 709 luma coeffs +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=899fd4d +Author: Marko Cebokli +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/hueshift0r/matrix.h ++++ b/src/filter/hueshift0r/matrix.h +@@ -10,9 +10,17 @@ + #include + #include + ++/* ++//Adobe ?? luma coeffs + #define RLUM (0.3086) + #define GLUM (0.6094) + #define BLUM (0.0820) ++*/ ++ ++//ITU_R BT 709 luma coeffs ++#define RLUM (0.2126) ++#define GLUM (0.7152) ++#define BLUM (0.0722) + + #define OFFSET_R 0 + #define OFFSET_G 1 diff --git a/debian/patches/020110815~9e606ce.patch b/debian/patches/020110815~9e606ce.patch new file mode 100644 index 0000000..360e358 --- /dev/null +++ b/debian/patches/020110815~9e606ce.patch @@ -0,0 +1,53 @@ +Description: Test_pat_G: fix possible /0 problem +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=9e606ce +Author: Marko Cebokli +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/generator/test_pat/test_pat_G.c ++++ b/src/generator/test_pat/test_pat_G.c +@@ -155,6 +155,7 @@ + unsigned char black,gray1,gray2,white; + int ox,oy; + ++if (size<1) size=1; + kx=size; ky=size; + kx=kx/ar; //kao aspect!=1 (anamorph) + +@@ -214,6 +215,8 @@ + + if (clr!=0) for (i=0;i<(w*h);i++) sl[i]=black; //black background + ++if (size1<1) size1=1; ++if (size2<1) size2=1; + iz=h/2-size1*((h/2)/size1); + for (i=iz;i +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/saturat0r/saturat0r.c ++++ b/src/filter/saturat0r/saturat0r.c +@@ -69,6 +69,7 @@ + { + saturat0r_instance_t* inst = (saturat0r_instance_t*)calloc(1, sizeof(*inst)); + inst->width = width; inst->height = height; ++ inst->saturation=1.0/MAX_SATURATION; + return (f0r_instance_t)inst; + } + diff --git a/debian/patches/020110816~2ddbaba.patch b/debian/patches/020110816~2ddbaba.patch new file mode 100644 index 0000000..a94a433 --- /dev/null +++ b/debian/patches/020110816~2ddbaba.patch @@ -0,0 +1,24 @@ +Description: Sharpness: plug memory leak +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=2ddbaba +Author: Marko Cebokli +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/sharpness/sharpness.c ++++ b/src/filter/sharpness/sharpness.c +@@ -230,6 +230,7 @@ + void f0r_destruct(f0r_instance_t instance) + { + inst *in; ++int i; + + in=(inst*)instance; + +@@ -239,6 +240,7 @@ + free(in->Rplano); + free(in->Gplano); + free(in->Bplano); ++for (i=0;ifp.msizeY;i++) free(in->fp.SC[i]); + + free(instance); + } diff --git a/debian/patches/020110816~9bf94ea.patch b/debian/patches/020110816~9bf94ea.patch new file mode 100644 index 0000000..93c71fd --- /dev/null +++ b/debian/patches/020110816~9bf94ea.patch @@ -0,0 +1,16 @@ +Description: C0rneres: remove leftover printf +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=9bf94ea +Author: Marko Cebokli +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/c0rners/c0rners.c ++++ b/src/filter/c0rners/c0rners.c +@@ -895,7 +895,6 @@ + break; + case 14: //Alpha operation + p->op=map_value_forward(*((double*)parm), 0.0, 4.9999); +- printf("setting p->op: %i\n", p->op); + break; + } + diff --git a/debian/patches/020110816~c8d6510.patch b/debian/patches/020110816~c8d6510.patch new file mode 100644 index 0000000..1088587 --- /dev/null +++ b/debian/patches/020110816~c8d6510.patch @@ -0,0 +1,46 @@ +Description: Pr0file: fix defaults +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=c8d6510 +Author: Marko Cebokli +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/measure/pr0file.c ++++ b/src/filter/measure/pr0file.c +@@ -317,7 +317,7 @@ + for (i=0;i<256;i++) {fs[i]=0; str[i]=0;} + if ((dit&0x00000001)!=0) //marker 1 value + { +- if (m1>=0) ++ if (m1>0) + { + forstr(data[0],1-u,0,frs); + sprintf(fs,"%%s Mk1=%s", frs); +@@ -328,7 +328,7 @@ + } + if ((dit&0x00000004)!=0) //marker 2 value + { +- if (m2>=0) ++ if (m2>0) + { + forstr(data[1],1-u,0,frs); + sprintf(fs,"%%s Mk2=%s", frs); +@@ -339,7 +339,7 @@ + } + if ((dit&0x00000010)!=0) //difference marker2-marker1 + { +- if ((m2>=0)&&(m1>=0)) ++ if ((m2>0)&&(m1>0)) + { + forstr(data[2],1-u,0,frs); + sprintf(fs,"%%s D=%s", frs); +@@ -764,8 +764,8 @@ + in->tilt=0.0; + in->len=3*width/4; + in->chn=3; +-in->m1=-1; +-in->m2=-1; ++in->m1=0; ++in->m2=0; + in->rt=1; + in->gt=1; + in->bt=1; diff --git a/debian/patches/020110817~0b4044c.patch b/debian/patches/020110817~0b4044c.patch new file mode 100644 index 0000000..34f4cd3 --- /dev/null +++ b/debian/patches/020110817~0b4044c.patch @@ -0,0 +1,32 @@ +Description: Test_pat_I: add some safeguards against /0 +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=0b4044c +Author: Marko Cebokli +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/generator/test_pat/test_pat_I.c ++++ b/src/generator/test_pat/test_pat_I.c +@@ -140,6 +140,7 @@ + int i,j; + float d,st,ct,g; + ++if (size==0.0) return; + st=sinf(tilt); + ct=cosf(tilt); + for (i=0;i +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/generator/test_pat/test_pat_R.c ++++ b/src/generator/test_pat/test_pat_R.c +@@ -134,6 +134,8 @@ + kx=x+wr; if (kx>w) kx=w; + ky=y+hr; if (ky>h) ky=h; + ++if (f1==0.0) f1=1.0E-12; ++if (f2==0.0) f2=1.0E-12; + dp1=PI*f1; dp2=PI*f2; //phase steps + dt1=1.0/dp1; dt2=1.0/dp2; + a=a/2.0; +@@ -200,6 +202,8 @@ + kx=x+wr; if (kx>w) kx=w; + ky=y+hr; if (ky>h) ky=h; + ++if (f1==0.0) f1=1.0E-12; ++if (f2==0.0) f2=1.0E-12; + dp1=PI*f1; dp2=PI*f2; //phase steps + dt1=1.0/dp1; dt2=1.0/dp2; + a=a/2.0; +@@ -262,6 +266,11 @@ + + for (x=0;x +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/generator/test_pat/test_pat_I.c ++++ b/src/generator/test_pat/test_pat_I.c +@@ -573,10 +573,10 @@ + *p = map_value_backward(inst->pw, 1.0, 100.0); + break; + case 4: //tilt +- *p = map_value_backward_log(inst->tilt, -PI/2.0, PI/2.0); ++ *p = map_value_backward(inst->tilt, -PI/2.0, PI/2.0); + break; + case 5: //negative +- *p = map_value_backward_log(inst->neg, 0.0, 1.0); ++ *p = map_value_backward(inst->neg, 0.0, 1.0); + break; + } + } diff --git a/debian/patches/020110817~e0f11e9.patch b/debian/patches/020110817~e0f11e9.patch new file mode 100644 index 0000000..9f783db --- /dev/null +++ b/debian/patches/020110817~e0f11e9.patch @@ -0,0 +1,21 @@ +Description: Test_pat_R: fix problem with parameter return +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=e0f11e9 +Author: Marko Cebokli +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/generator/test_pat/test_pat_R.c ++++ b/src/generator/test_pat/test_pat_R.c +@@ -1026,10 +1026,10 @@ + *p = map_value_backward(inst->linp, 0.0, 1.0); + break; + case 4: //frequency 1 +- *p = map_value_backward_log(inst->f1, 0.0, 1.0); ++ *p = map_value_backward(inst->f1, 0.0, 1.0); + break; + case 5: //frequency 2 +- *p = map_value_backward_log(inst->f2, 0.0, 1.0); ++ *p = map_value_backward(inst->f2, 0.0, 1.0); + break; + case 6: //aspect type + *p = map_value_backward(inst->aspt, 0.0, 6.9999); diff --git a/debian/patches/020110821~dc23844.patch b/debian/patches/020110821~dc23844.patch new file mode 100644 index 0000000..b4de4af --- /dev/null +++ b/debian/patches/020110821~dc23844.patch @@ -0,0 +1,28 @@ +Description: Light graffiti: Initializing all values to a default value +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=dc23844 +Author: Simon A. Eugster +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/lightgraffiti/lightgraffiti.cpp ++++ b/src/filter/lightgraffiti/lightgraffiti.cpp +@@ -167,10 +167,19 @@ + m_pSensitivity = 1; + m_pBackgroundWeight = 0; + m_pThresholdBrightness = 450; ++ m_pThresholdDifference = 0; + m_pThresholdDiffSum = 0; + m_pDim = 0; + m_pSaturation = 1; ++ m_pLowerOverexposure = 0; ++ m_pStatsBrightness = false; ++ m_pStatsDiff = false; ++ m_pStatsDiffSum = false; ++ m_pReset = false; ++ m_pTransparentBackground = false; + m_pBlackReference = false; ++ m_pLongAlpha = 0; ++ m_pNonlinearDim = 0; + + } + diff --git a/debian/patches/020110822~39e4492.patch b/debian/patches/020110822~39e4492.patch new file mode 100644 index 0000000..482ef8f --- /dev/null +++ b/debian/patches/020110822~39e4492.patch @@ -0,0 +1,17 @@ +Description: Fix scanline0r writing beyond end of out buffer. +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=39e4492 +Author: Dan Dennedy +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/scanline0r/scanline0r.cpp ++++ b/src/filter/scanline0r/scanline0r.cpp +@@ -15,7 +15,7 @@ + for (unsigned int line=0; line < height; line+=4) + { + std::copy(in+line*width,in+(line+1)*width,out+(line*width)); +- std::fill(out+(line+1)*width,out+(line+5)*width,0x00000000); ++ std::fill(out+(line+1)*width,out+(line+4)*width,0x00000000); + } + } + diff --git a/debian/patches/020110822~62b9f1c.patch b/debian/patches/020110822~62b9f1c.patch new file mode 100644 index 0000000..1eaecfd --- /dev/null +++ b/debian/patches/020110822~62b9f1c.patch @@ -0,0 +1,24 @@ +Description: Fix memory leak on deinit of delay0r. +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=62b9f1c +Author: Dan Dennedy +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/delay0r/delay0r.cpp ++++ b/src/filter/delay0r/delay0r.cpp +@@ -14,6 +14,15 @@ + register_param(delay,"DelayTime","the delay time"); + } + ++ ~delay0r() ++ { ++ for (std::list< std::pair< double, unsigned int* > >::iterator i=buffer.begin(); i != buffer.end(); ++i) ++ { ++ delete[] i->second; ++ i=buffer.erase(i); ++ } ++ } ++ + virtual void update() + { + unsigned int* reusable = 0; diff --git a/debian/patches/020110822~63f2186.patch b/debian/patches/020110822~63f2186.patch new file mode 100644 index 0000000..6851f96 --- /dev/null +++ b/debian/patches/020110822~63f2186.patch @@ -0,0 +1,16 @@ +Description: Fix default value for fader param in xfade0r. +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=63f2186 +Author: Dan Dennedy +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/mixer2/xfade0r/xfade0r.cpp ++++ b/src/mixer2/xfade0r/xfade0r.cpp +@@ -7,6 +7,7 @@ + public: + xfade0r(unsigned int width, unsigned int height) + { ++ fader = 0.0; + register_param(fader,"fader","the fader position"); + } + diff --git a/debian/patches/020110823~0eb9f2a.patch b/debian/patches/020110823~0eb9f2a.patch new file mode 100644 index 0000000..bd133df --- /dev/null +++ b/debian/patches/020110823~0eb9f2a.patch @@ -0,0 +1,16 @@ +Description: Fix alpha channel of cluster to be same as input. +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=0eb9f2a +Author: Dan Dennedy +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/cluster/cluster.c ++++ b/src/filter/cluster/cluster.c +@@ -311,6 +311,7 @@ + dst2[0] = cc->r; + dst2[1] = cc->g; + dst2[2] = cc->b; ++ dst2[3] = src2[3]; + + + diff --git a/debian/patches/020110823~22e4f73.patch b/debian/patches/020110823~22e4f73.patch new file mode 100644 index 0000000..1af395a --- /dev/null +++ b/debian/patches/020110823~22e4f73.patch @@ -0,0 +1,23 @@ +Description: Fix alpha channel of plasma to be opaque as intended. +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=22e4f73 +Author: Dan Dennedy +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/generator/dem0scene/plasma.cpp ++++ b/src/generator/dem0scene/plasma.cpp +@@ -222,12 +222,12 @@ + + uint32_t Plasma::palette2rgb(uint8_t idx) { + uint32_t rgba; +- rgba = 0xffffffff; + // just for little endian + // TODO: big endian + rgba = (colors[idx].r << 16) + | (colors[idx].g << 8) +- | (colors[idx].b ); ++ | (colors[idx].b ) ++ | (0xff << 24); + + return rgba; + } diff --git a/debian/patches/020110823~90ee1fa.patch b/debian/patches/020110823~90ee1fa.patch new file mode 100644 index 0000000..27e3739 --- /dev/null +++ b/debian/patches/020110823~90ee1fa.patch @@ -0,0 +1,17 @@ +Description: Fix background of tehRoxx0r to be black silence. +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=90ee1fa +Author: Dan Dennedy +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/tehroxx0r/tehRoxx0r.c ++++ b/src/filter/tehroxx0r/tehRoxx0r.c +@@ -137,6 +137,8 @@ + step_x = (double)w / (double)small_w; + step_y = (double)h / (double)small_h; + ++ // make background black transparent ++ memset(outframe, 0, w * h * sizeof(uint32_t)); + + // copy a downscaled version into the middle of the result frame + // (blocksize to x-blocksize and blocksize to y-blocksize) diff --git a/debian/patches/020110825~0be0cec.patch b/debian/patches/020110825~0be0cec.patch new file mode 100644 index 0000000..6d6144b --- /dev/null +++ b/debian/patches/020110825~0be0cec.patch @@ -0,0 +1,17 @@ +Description: Test_pat_G: fix problem with parameter return +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=0be0cec +Author: Marko Cebokli +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/generator/test_pat/test_pat_G.c ++++ b/src/generator/test_pat/test_pat_G.c +@@ -812,7 +812,7 @@ + *p = map_value_backward(inst->size2, 0.0, 64.0); + break; + case 3: //negative +- *p = map_value_backward(inst->size2, 0.0, 1.0); ++ *p = map_value_backward(inst->neg, 0.0, 1.0); + break; + case 4: //aspect type + *p = map_value_backward(inst->aspt, 0.0, 6.9999); diff --git a/debian/patches/020110825~b8f2300.patch b/debian/patches/020110825~b8f2300.patch new file mode 100644 index 0000000..3b47ddf --- /dev/null +++ b/debian/patches/020110825~b8f2300.patch @@ -0,0 +1,17 @@ +Description: Alphagrad: change width parameter to double +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=b8f2300 +Author: Marko Cebokli +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/alpha0ps/alphagrad.c ++++ b/src/filter/alpha0ps/alphagrad.c +@@ -143,7 +143,7 @@ + break; + case 1: + info->name = "Transition width"; +- info->type = F0R_PARAM_BOOL; ++ info->type = F0R_PARAM_DOUBLE; + info->explanation = ""; + break; + case 2: diff --git a/debian/patches/020110831~63c0878.patch b/debian/patches/020110831~63c0878.patch new file mode 100644 index 0000000..484be17 --- /dev/null +++ b/debian/patches/020110831~63c0878.patch @@ -0,0 +1,17 @@ +Description: Coloradj_RGB: fix bug in luma calculation +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=63c0878 +Author: Marko Cebokli +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/coloradj/coloradj_RGB.c ++++ b/src/filter/coloradj/coloradj_RGB.c +@@ -84,7 +84,7 @@ + { + case 0: //rec 601 + { +- l = 0.299*rr + 0.587*rr + 0.114*bb; ++ l = 0.299*rr + 0.587*gg + 0.114*bb; + break; + } + case 1: //rec 709 diff --git a/debian/patches/020110903~63bafff.patch b/debian/patches/020110903~63bafff.patch new file mode 100644 index 0000000..f0cf4fd --- /dev/null +++ b/debian/patches/020110903~63bafff.patch @@ -0,0 +1,23 @@ +Description: Set default for onecol0r's parameter +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=63bafff +Author: Dan Dennedy +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/generator/onecol0r/onecol0r.cpp ++++ b/src/generator/onecol0r/onecol0r.cpp +@@ -28,6 +28,7 @@ + onecol0r(unsigned int width, unsigned int height) + { + register_param(color,"Color","the color of the image"); ++ color.r = color.g = color.b = 0; + } + + virtual void update() +@@ -51,5 +52,5 @@ + frei0r::construct plugin("onecol0r", + "image with just one color", + "Martin Bayer", +- 0,1); ++ 0,2); + diff --git a/debian/patches/020110903~b467ddc.patch b/debian/patches/020110903~b467ddc.patch new file mode 100644 index 0000000..e8ed4b0 --- /dev/null +++ b/debian/patches/020110903~b467ddc.patch @@ -0,0 +1,36 @@ +Description: Fix range of balanc0r Green Tint parameter. +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=b467ddc +Author: Dan Dennedy +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/balanc0r/balanc0r.c ++++ b/src/filter/balanc0r/balanc0r.c +@@ -562,7 +562,7 @@ + colordistance_info->color_model = F0R_COLOR_MODEL_RGBA8888; + colordistance_info->frei0r_version = FREI0R_MAJOR_VERSION; + colordistance_info->major_version = 0; +- colordistance_info->minor_version = 2; ++ colordistance_info->minor_version = 3; + colordistance_info->num_params = 2; + colordistance_info->explanation = "Adjust the white balance / color temperature"; + } +@@ -655,6 +655,8 @@ + case 1: + { + double g = *((double*)param); ++ // convert frei0r range to natural range [1.0, 2.5] ++ g = 1.0 + (2.5 - 1.0) * g; + if (g != 1.2) { + inst->green = g; + setRGBmult(inst); +@@ -675,7 +677,8 @@ + *((f0r_param_color_t*)param) = inst->color; + break; + case 1: +- *((double*)param) = inst->green; ++ // convert natural range [1.0, 2.5] to frei0r range [0,1] ++ *((double*)param) = (inst->green - 1.0) / (2.5 - 1.0); + break; + } + diff --git a/debian/patches/020110903~f7cc65f.patch b/debian/patches/020110903~f7cc65f.patch new file mode 100644 index 0000000..6d9ce60 --- /dev/null +++ b/debian/patches/020110903~f7cc65f.patch @@ -0,0 +1,23 @@ +Description: Set defaults for lissajous0r parameters +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=f7cc65f +Author: Dan Dennedy +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/generator/lissajous0r/lissajous0r.cpp ++++ b/src/generator/lissajous0r/lissajous0r.cpp +@@ -34,6 +34,7 @@ + public: + lissajous0r(unsigned int width, unsigned int height) + { ++ r_x = r_y = 0.0; + register_param(r_x,"ratiox","x-ratio"); + register_param(r_y,"ratioy","y-ratio"); + } +@@ -72,5 +73,5 @@ + frei0r::construct plugin("Lissajous0r", + "Generates Lissajous0r images", + "Martin Bayer", +- 0,1); ++ 0,2); + diff --git a/debian/patches/020110910~047c762.patch b/debian/patches/020110910~047c762.patch new file mode 100644 index 0000000..1211325 --- /dev/null +++ b/debian/patches/020110910~047c762.patch @@ -0,0 +1,155 @@ +Description: Light Graffiti: Fix parameter ranges. +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=047c762 +Author: Till Theato +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/lightgraffiti/lightgraffiti.cpp ++++ b/src/filter/lightgraffiti/lightgraffiti.cpp +@@ -147,14 +147,14 @@ + m_prevMask = std::vector(width*height, rgb0); + #endif + +- register_param(m_pSensitivity, "sensitivity", "Sensitivity of the effect for light (higher sensitivity will lead to brighter lights)"); // [0,5] +- register_param(m_pBackgroundWeight, "backgroundWeight", "Describes how strong the (accumulated) background should shine through"); // [0,1] +- register_param(m_pThresholdBrightness, "thresholdBrightness", "Brightness threshold to distinguish between foreground and background"); // {0...765} +- register_param(m_pThresholdDifference, "thresholdDifference", "Threshold: Difference to background to distinguish between fore- and background"); // {0...255} +- register_param(m_pThresholdDiffSum, "thresholdDiffSum", "Threshold for sum of differences. Can in most cases be ignored (set to 0)."); // {0...765} +- register_param(m_pDim, "dim", "Dimming of the light mask"); // [0,1] +- register_param(m_pSaturation, "saturation", "Saturation of lights"); // [0,4] (higher values hardly meaningful) +- register_param(m_pLowerOverexposure, "lowerOverexposure", "Prevents some overexposure if the light source stays steady too long (varying speed)"); // {0...5} ++ register_param(m_pSensitivity, "sensitivity", "Sensitivity of the effect for light (higher sensitivity will lead to brighter lights)"); ++ register_param(m_pBackgroundWeight, "backgroundWeight", "Describes how strong the (accumulated) background should shine through"); ++ register_param(m_pThresholdBrightness, "thresholdBrightness", "Brightness threshold to distinguish between foreground and background"); ++ register_param(m_pThresholdDifference, "thresholdDifference", "Threshold: Difference to background to distinguish between fore- and background"); ++ register_param(m_pThresholdDiffSum, "thresholdDiffSum", "Threshold for sum of differences. Can in most cases be ignored (set to 0)."); ++ register_param(m_pDim, "dim", "Dimming of the light mask"); ++ register_param(m_pSaturation, "saturation", "Saturation of lights"); ++ register_param(m_pLowerOverexposure, "lowerOverexposure", "Prevents some overexposure if the light source stays steady too long (varying speed)"); + register_param(m_pStatsBrightness, "statsBrightness", "Display the brightness and threshold, for adjusting the brightness threshold parameter"); + register_param(m_pStatsDiff, "statsDifference", "Display the background difference and threshold"); + register_param(m_pStatsDiffSum, "statsDiffSum", "Display the sum of the background difference and the threshold"); +@@ -164,13 +164,13 @@ + register_param(m_pLongAlpha, "longAlpha", "Alpha value for moving average"); + register_param(m_pNonlinearDim, "nonlinearDim", "Nonlinear dimming (may look more natural)"); + m_pLongAlpha = 1/128.0; +- m_pSensitivity = 1; ++ m_pSensitivity = 1 / 5.; + m_pBackgroundWeight = 0; +- m_pThresholdBrightness = 450; ++ m_pThresholdBrightness = 450 / 765.; + m_pThresholdDifference = 0; + m_pThresholdDiffSum = 0; + m_pDim = 0; +- m_pSaturation = 1; ++ m_pSaturation = 1 / 4.; + m_pLowerOverexposure = 0; + m_pStatsBrightness = false; + m_pStatsDiff = false; +@@ -203,6 +203,13 @@ + + virtual void update() + { ++ double sensitivity = m_pSensitivity * 5; ++ double thresholdBrightness = m_pThresholdBrightness * 765; ++ double thresholdDifference = m_pThresholdDifference * 255; ++ double thresholdDiffSum = m_pThresholdDiffSum * 765; ++ double saturation = m_pSaturation * 4; ++ double lowerOverexposure = m_pLowerOverexposure * 10; ++ + // Copy everything to the output image. + // Most of the image will very likely not change at all. + std::copy(in, in + width*height, out); +@@ -757,9 +764,9 @@ + sum = GETR(out[pixel]) + GETG(out[pixel]) + GETB(out[pixel]); + + if ( +- maxDiff > m_pThresholdDifference +- && temp > m_pThresholdDiffSum +- && sum > m_pThresholdBrightness ++ maxDiff > thresholdDifference ++ && temp > thresholdDiffSum ++ && sum > thresholdBrightness + // If all requirements are met, then this should be a light source. + ) + { +@@ -769,7 +776,7 @@ + fg = CLAMP(g)/255.0; + fb = CLAMP(b)/255.0; + +- f = (fr + fg + fb) / 3 * m_pSensitivity; ++ f = (fr + fg + fb) / 3 * sensitivity; + fr *= f; + fg *= f; + fb *= f; +@@ -799,7 +806,7 @@ + + // Add the brightness of the light source to the brightness map (alpha map) + y = REC709Y(CLAMP(r), CLAMP(g), CLAMP(b)) / 255.0; +- y = y * m_pSensitivity; ++ y = y * sensitivity; + m_alphaMap[4*pixel] += y; + #endif + } else { +@@ -837,12 +844,12 @@ + fg = m_rgbLightMask[pixel].g; + fb = m_rgbLightMask[pixel].b; + +- if (m_pLowerOverexposure > 0) { ++ if (lowerOverexposure > 0) { + // Comparisation of plots with octave: + // clf;hold on;plot([0 1],[0 1],'k');plot(range,ones(length(range),1),'k');plot(range,sqrt(range));plot(range,log(1+range),'k');plot(range,log(1+range),'g');plot(range,(log(1+range)/3).^.5,'r');axis equal +- fr = pow( log(1+fr)/m_pLowerOverexposure, .5 ); +- fg = pow( log(1+fg)/m_pLowerOverexposure, .5 ); +- fb = pow( log(1+fb)/m_pLowerOverexposure, .5 ); ++ fr = pow( log(1+fr)/lowerOverexposure, .5 ); ++ fg = pow( log(1+fg)/lowerOverexposure, .5 ); ++ fb = pow( log(1+fb)/lowerOverexposure, .5 ); + } + + +@@ -876,8 +883,8 @@ + // Increase the saturation if the average brightness is below a certain level + // Do not use Rec709 Luma since we want to consider all colours to equal parts. + fy = (fr + fg + fb) / 3; +- if (fy < 1 && m_pSaturation > 0) { +- fsat = 1 + m_pSaturation*(1-fy); ++ if (fy < 1 && saturation > 0) { ++ fsat = 1 + saturation*(1-fy); + + fr = fy + fsat * (fr-fy); + fg = fy + fsat * (fg-fy); +@@ -974,7 +981,7 @@ + r = .8*sum/3; + g = .8*sum/3; + b = .8*sum/3; +- if (sum > m_pThresholdBrightness) { ++ if (sum > thresholdBrightness) { + b = 255; + } + out[pixel] = RGBA(r,g,b,0xFF); +@@ -988,7 +995,7 @@ + b = r; + } + +- if (maxDiff > m_pThresholdDifference) { ++ if (maxDiff > thresholdDifference) { + g = 255; + } + out[pixel] = RGBA(r,g,b,0xFF); +@@ -1003,7 +1010,7 @@ + if (!m_pStatsBrightness) { + b = r; + } +- if (temp > m_pThresholdDiffSum) { ++ if (temp > thresholdDiffSum) { + r = 255; + } + out[pixel] = RGBA(r,g,b,0xFF); +@@ -1052,5 +1059,5 @@ + frei0r::construct plugin("Light Graffiti", + "Creates light graffitis from a video by keeping the brightest spots.", + "Simon A. Eugster (Granjow)", +- 0,1, ++ 0,2, + F0R_COLOR_MODEL_RGBA8888); diff --git a/debian/patches/020110910~39e65be.patch b/debian/patches/020110910~39e65be.patch new file mode 100644 index 0000000..fbc1ec5 --- /dev/null +++ b/debian/patches/020110910~39e65be.patch @@ -0,0 +1,96 @@ +Description: Cartoon: Fix parameter ranges. +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=39e65be +Author: Till Theato +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/cartoon/cartoon.cpp ++++ b/src/filter/cartoon/cartoon.cpp +@@ -59,8 +59,8 @@ + + Cartoon(unsigned int width, unsigned int height) { + int c; +- register_param(triplevel, "triplevel", "level of trip: use high numbers, incremented by 100"); +- register_param(diffspace, "diffspace", "difference space: a value from 0 to 256"); ++ register_param(triplevel, "triplevel", "level of trip: mapped to [0,1] asymptotical"); ++ register_param(diffspace, "diffspace", "difference space: a value from 0 to 256 (mapped to [0,1])"); + + geo = new ScreenGeometry(); + geo->w = width; +@@ -79,8 +79,8 @@ + powprecal[c] = c*c; + black = 0xFF000000; + +- triplevel = 1000; +- diffspace = 1; ++ triplevel = 1 - 1 / (1000 + 1); ++ diffspace = 1 / 256.; + + } + +@@ -97,13 +97,14 @@ + // Cartoonify picture, do a form of edge detect + int x, y, t; + ++ m_diffspace = diffspace * 256; + +- for (x=(int)diffspace;xw-(1+(int)diffspace);x++) { ++ for (x=m_diffspace;xw-(1+m_diffspace);x++) { + +- for (y=(int)diffspace;yh-(1+(int)diffspace);y++) { ++ for (y=m_diffspace;yh-(1+m_diffspace);y++) { + + t = GetMaxContrast((int32_t*)in,x,y); +- if (t > triplevel) { ++ if (t > 1 / (1 - triplevel) - 1) { + + // Make a border pixel + *(out+x+yprecal[y]) = black; +@@ -129,6 +130,7 @@ + int *yprecal; + uint16_t powprecal[256]; + int32_t black; ++ int m_diffspace; + + void FlattenColor(int32_t *c); + long GetMaxContrast(int32_t *src,int x,int y); +@@ -163,23 +165,23 @@ + long error,max=0; + + /* Assumes PrePixelModify has been run */ +- c1 = *PIXELAT(x-(int)diffspace,y,src); +- c2 = *PIXELAT(x+(int)diffspace,y,src); ++ c1 = *PIXELAT(x-m_diffspace,y,src); ++ c2 = *PIXELAT(x+m_diffspace,y,src); + error = GMERROR(c1,c2); + if (error>max) max = error; + +- c1 = *PIXELAT(x,y-(int)diffspace,src); +- c2 = *PIXELAT(x,y+(int)diffspace,src); ++ c1 = *PIXELAT(x,y-m_diffspace,src); ++ c2 = *PIXELAT(x,y+m_diffspace,src); + error = GMERROR(c1,c2); + if (error>max) max = error; + +- c1 = *PIXELAT(x-(int)diffspace,y-(int)diffspace,src); +- c2 = *PIXELAT(x+(int)diffspace,y+(int)diffspace,src); ++ c1 = *PIXELAT(x-m_diffspace,y-m_diffspace,src); ++ c2 = *PIXELAT(x+m_diffspace,y+m_diffspace,src); + error = GMERROR(c1,c2); + if (error>max) max = error; + +- c1 = *PIXELAT(x+(int)diffspace,y-(int)diffspace,src); +- c2 = *PIXELAT(x-(int)diffspace,y+(int)diffspace,src); ++ c1 = *PIXELAT(x+m_diffspace,y-m_diffspace,src); ++ c2 = *PIXELAT(x-m_diffspace,y+m_diffspace,src); + error = GMERROR(c1,c2); + if (error>max) max = error; + +@@ -189,6 +191,4 @@ + frei0r::construct plugin("Cartoon", + "Cartoonify video, do a form of edge detect", + "Dries Pruimboom, Jaromil", +- 2,0); +- +- ++ 2,1); diff --git a/debian/patches/020110910~661a7b4.patch b/debian/patches/020110910~661a7b4.patch new file mode 100644 index 0000000..31782d3 --- /dev/null +++ b/debian/patches/020110910~661a7b4.patch @@ -0,0 +1,77 @@ +Description: Curves: Fix possible crash and parameter ranges. +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=661a7b4 +Author: Till Theato +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/curves/curves.c ++++ b/src/filter/curves/curves.c +@@ -190,7 +190,7 @@ + curves_info->color_model = F0R_COLOR_MODEL_RGBA8888; + curves_info->frei0r_version = FREI0R_MAJOR_VERSION; + curves_info->major_version = 0; +- curves_info->minor_version = 2; ++ curves_info->minor_version = 3; + curves_info->num_params = 16; + curves_info->explanation = "Adjust luminance or color channel intensity with curve level mapping"; + } +@@ -216,12 +216,12 @@ + case 2: + info->name = "Graph position"; + info->type = F0R_PARAM_DOUBLE; +- info->explanation = "Output image corner where curve graph will be drawn (1 = TOP,LEFT; 2 = TOP,RIGHT; 3 = BOTTOM,LEFT; 4 = BOTTOM, RIGHT)"; ++ info->explanation = "Output image corner where curve graph will be drawn (0.1 = TOP,LEFT; 0.2 = TOP,RIGHT; 0.3 = BOTTOM,LEFT; 0.4 = BOTTOM, RIGHT)"; + break; + case 3: + info->name = "Curve point number"; + info->type = F0R_PARAM_DOUBLE; +- info->explanation = "Number of points to use to build curve"; ++ info->explanation = "Number of points to use to build curve (/10 to fit [0,1] parameter range). Minimum 2 (0.2), Maximum 5 (0.5). Not relevant for Bézier spline."; + break; + case 4: + info->name = "Luma formula"; +@@ -268,7 +268,8 @@ + + void f0r_destruct(f0r_instance_t instance) + { +- free(((curves_instance_t*)instance)->bspline); ++ if (((curves_instance_t*)instance)->bspline) ++ free(((curves_instance_t*)instance)->bspline); + free(((curves_instance_t*)instance)->bsplineMap); + free(instance); + } +@@ -313,10 +314,10 @@ + inst->drawCurves = *((f0r_param_double *)param); + break; + case 2: +- inst->curvesPosition = *((f0r_param_double *)param); ++ inst->curvesPosition = floor(*((f0r_param_double *)param) * 10); + break; + case 3: +- inst->pointNumber = *((f0r_param_double *)param); ++ inst->pointNumber = floor(*((f0r_param_double *)param) * 10); + break; + case 4: + inst->formula = *((f0r_param_double *)param); +@@ -351,10 +352,10 @@ + *((f0r_param_double *)param) = inst->drawCurves; + break; + case 2: +- *((f0r_param_double *)param) = inst->curvesPosition; ++ *((f0r_param_double *)param) = inst->curvesPosition / 10.; + break; + case 3: +- *((f0r_param_double *)param) = inst->pointNumber; ++ *((f0r_param_double *)param) = inst->pointNumber / 10.; + break; + case 4: + *((f0r_param_double *)param) = inst->formula; +@@ -703,7 +704,7 @@ + points = (double*)calloc(inst->pointNumber * 2, sizeof(double)); + i = inst->pointNumber * 2; + //copy point values +- while(--i) ++ while(--i > 0) + points[i] = inst->points[i]; + //sort point values by X component + for(i = 1; i < inst->pointNumber; i++) diff --git a/debian/patches/020110910~d4d29e9.patch b/debian/patches/020110910~d4d29e9.patch new file mode 100644 index 0000000..e2a4155 --- /dev/null +++ b/debian/patches/020110910~d4d29e9.patch @@ -0,0 +1,35 @@ +Description: Vertigo: Fix parameter range. +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=d4d29e9 +Author: Till Theato +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/vertigo/vertigo.c ++++ b/src/filter/vertigo/vertigo.c +@@ -66,7 +66,7 @@ + vertigoInfo->color_model = F0R_COLOR_MODEL_RGBA8888; + vertigoInfo->frei0r_version = FREI0R_MAJOR_VERSION; + vertigoInfo->major_version = 1; +- vertigoInfo->minor_version = 0; ++ vertigoInfo->minor_version = 1; + vertigoInfo->num_params = 2; + vertigoInfo->explanation = "alpha blending with zoomed and rotated images"; + } +@@ -143,7 +143,7 @@ + break; + case 1: + /* zoomrate */ +- inst->zoomrate = *((double*)param); ++ inst->zoomrate = *((double*)param) * 5; + inst->tfactor = (inst->xc+inst->yc) * inst->zoomrate; + break; + } +@@ -163,7 +163,7 @@ + break; + case 1: + /* zoomrate */ +- *((double*)param) = (double) (inst->zoomrate); ++ *((double*)param) = (double) (inst->zoomrate) / 5.; + break; + } + } diff --git a/debian/patches/020110910~ee7bb57.patch b/debian/patches/020110910~ee7bb57.patch new file mode 100644 index 0000000..4217fb6 --- /dev/null +++ b/debian/patches/020110910~ee7bb57.patch @@ -0,0 +1,67 @@ +Description: Levels: Fix parameter ranges. +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=ee7bb57 +Author: Till Theato +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/levels/levels.c ++++ b/src/filter/levels/levels.c +@@ -64,7 +64,7 @@ + levels_instance_t->color_model = F0R_COLOR_MODEL_RGBA8888; + levels_instance_t->frei0r_version = FREI0R_MAJOR_VERSION; + levels_instance_t->major_version = 0; +- levels_instance_t->minor_version = 1; ++ levels_instance_t->minor_version = 2; + levels_instance_t->num_params = 8; + levels_instance_t->explanation = "Adjust luminance or color channel intensity"; + } +@@ -104,7 +104,7 @@ + info->explanation = "White output"; + break; + case 6: +- info->name = "Show histogram"; ++ info->name = "Show histogram"; + info->type = F0R_PARAM_BOOL; + info->explanation = "Show histogram"; + break; +@@ -145,7 +145,7 @@ + switch(param_index) + { + case 0: +- inst->channel = *((f0r_param_double *)param); ++ inst->channel = floor(*((f0r_param_double *)param) * 10); + break; + case 1: + inst->inputMin = *((f0r_param_double *)param); +@@ -166,7 +166,7 @@ + inst->showHistogram = *((f0r_param_bool *)param); + break; + case 7: +- inst->histogramPosition = *((f0r_param_double *)param); ++ inst->histogramPosition = floor(*((f0r_param_double *)param) * 10); + break; + } + } +@@ -180,7 +180,7 @@ + switch(param_index) + { + case 0: +- *((f0r_param_double *)param) = inst->channel; ++ *((f0r_param_double *)param) = inst->channel / 10.; + break; + case 1: + *((f0r_param_double *)param) = inst->inputMin; +@@ -201,7 +201,7 @@ + *((f0r_param_bool *)param) = inst->showHistogram; + break; + case 7: +- *((f0r_param_double *)param) = inst->histogramPosition; ++ *((f0r_param_double *)param) = inst->histogramPosition / 10.; + break; + } + } +@@ -392,4 +392,3 @@ + } + } + } +- diff --git a/debian/patches/020110911~a6c266a.patch b/debian/patches/020110911~a6c266a.patch new file mode 100644 index 0000000..480550c --- /dev/null +++ b/debian/patches/020110911~a6c266a.patch @@ -0,0 +1,86 @@ +Description: SOP/Sat: Fix parameter ranges. +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=a6c266a +Author: Till Theato +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/sopsat/sopsat.cpp ++++ b/src/filter/sopsat/sopsat.cpp +@@ -92,19 +92,19 @@ + register_param(bPower, "bPower", "Power (Gamma) of the blue color component"); + register_param(aPower, "aPower", "Power (Gamma) of the alpha component"); + register_param(saturation, "saturation", "Overall saturation"); +- rSlope = 1; +- gSlope = 1; +- bSlope = 1; +- aSlope = 1; +- rOffset = 0; +- gOffset = 0; +- bOffset = 0; +- aOffset = 0; +- rPower = 1; +- gPower = 1; +- bPower = 1; +- aPower = 1; +- saturation = 200; ++ rSlope = 1 / 20.; ++ gSlope = 1 / 20.; ++ bSlope = 1 / 20.; ++ aSlope = 1 / 20.; ++ rOffset = (0 - (-4)) / (double)(4 - (-4)); ++ gOffset = (0 - (-4)) / (double)(4 - (-4)); ++ bOffset = (0 - (-4)) / (double)(4 - (-4)); ++ aOffset = (0 - (-4)) / (double)(4 - (-4)); ++ rPower = 1 / 20.; ++ gPower = 1 / 20.; ++ bPower = 1 / 20.; ++ aPower = 1 / 20.; ++ saturation = 1 / 10.; + + // Pre-build the lookup table. + // For 1080p, rendering a 5-second video took +@@ -171,22 +171,22 @@ + double m_sat; + + void updateLUT() { +- double rS = rSlope; +- double gS = gSlope; +- double bS = bSlope; +- double aS = aSlope; +- +- double rO = rOffset; +- double gO = gOffset; +- double bO = bOffset; +- double aO = aOffset; +- +- double rP = rPower; +- double gP = gPower; +- double bP = bPower; +- double aP = aPower; ++ double rS = rSlope * 20; ++ double gS = gSlope * 20; ++ double bS = bSlope * 20; ++ double aS = aSlope * 20; ++ ++ double rO = -4 + rOffset * (4 - (-4)); ++ double gO = -4 + gOffset * (4 - (-4)); ++ double bO = -4 + bOffset * (4 - (-4)); ++ double aO = -4 + aOffset * (4 - (-4)); ++ ++ double rP = rPower * 20; ++ double gP = gPower * 20; ++ double bP = bPower * 20; ++ double aP = aPower * 20; + +- m_sat = saturation; ++ m_sat = saturation * 10; + + for (int i = 0; i < 256; i++) { + // above0 avoids overflows for negative numbers. +@@ -212,5 +212,5 @@ + frei0r::construct plugin("SOP/Sat", + "Slope/Offset/Power and Saturation color corrections according to the ASC CDL (Color Decision List)", + "Simon A. Eugster (Granjow)", +- 0,1, ++ 0,2, + F0R_COLOR_MODEL_RGBA8888); diff --git a/debian/patches/020110928~8f80908.patch b/debian/patches/020110928~8f80908.patch new file mode 100644 index 0000000..6fbe37e --- /dev/null +++ b/debian/patches/020110928~8f80908.patch @@ -0,0 +1,56 @@ +Description: Fix compile warning on undefined operation. +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=8f80908 +Author: Dan Dennedy +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/curves/curves.c ++++ b/src/filter/curves/curves.c +@@ -875,9 +875,12 @@ + for(int j = 0; j < scale; j++) { + if (j % cellSize > lineWidth) { //point doesn't aly on the grid + int offset = ((maxYvalue - i + graphYOffset) * stride + j + graphXOffset) * 4; +- dst[offset] = (dst[offset++] >> 1) + 0x7F; +- dst[offset] = (dst[offset++] >> 1) + 0x7F; +- dst[offset] = (dst[offset++] >> 1) + 0x7F; ++ dst[offset] = (dst[offset] >> 1) + 0x7F; ++ offset++; ++ dst[offset] = (dst[offset] >> 1) + 0x7F; ++ offset++; ++ dst[offset] = (dst[offset] >> 1) + 0x7F; ++ offset++; + } + } + } +--- a/src/filter/three_point_balance/three_point_balance.c ++++ b/src/filter/three_point_balance/three_point_balance.c +@@ -263,15 +263,22 @@ + for(int i = 0; i < inst->height; i++) { + int offset = (i * inst->width + j) * 4; + if (copyPixel) { +- dst[offset] = src[offset++]; +- dst[offset] = src[offset++]; +- dst[offset] = src[offset++]; ++ dst[offset] = src[offset]; ++ offset++; ++ dst[offset] = src[offset]; ++ offset++; ++ dst[offset] = src[offset]; ++ offset++; + } else { +- dst[offset] = mapRed[src[offset++]]; +- dst[offset] = mapGreen[src[offset++]]; +- dst[offset] = mapBlue[src[offset++]]; ++ dst[offset] = mapRed[src[offset]]; ++ offset++; ++ dst[offset] = mapGreen[src[offset]]; ++ offset++; ++ dst[offset] = mapBlue[src[offset]]; ++ offset++; + } +- dst[offset] = src[offset++]; // copy alpha ++ dst[offset] = src[offset]; // copy alpha ++ offset++; + } + } + diff --git a/debian/patches/020110928~9c93c22.patch b/debian/patches/020110928~9c93c22.patch new file mode 100644 index 0000000..ee2a51e --- /dev/null +++ b/debian/patches/020110928~9c93c22.patch @@ -0,0 +1,17 @@ +Description: appease the compiler, add return statement +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=9c93c22 +Author: Robert Schweikert +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/curves/curves.c ++++ b/src/filter/curves/curves.c +@@ -504,6 +504,8 @@ + double dx = x - coeffs[offset]; + return ((coeffs[offset + 4] * dx / 6. + coeffs[offset + 3] / 2.) * dx + coeffs[offset + 2]) * dx + coeffs[offset + 1]; + } ++ /* This should never be reached, statement passifies the compiler*/ ++ return -1.0; + } + + void swap(double *points, int i, int j) { diff --git a/debian/patches/020110928~f1794f8.patch b/debian/patches/020110928~f1794f8.patch new file mode 100644 index 0000000..8ae4d39 --- /dev/null +++ b/debian/patches/020110928~f1794f8.patch @@ -0,0 +1,17 @@ +Description: Fix default for stroke param of facedetect. +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=f1794f8 +Author: Dan Dennedy +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/facedetect/facedetect.cpp ++++ b/src/filter/facedetect/facedetect.cpp +@@ -90,7 +90,7 @@ + register_param(smallest, "Smallest", "Minimum window size in pixels, divided by 1000"); + scale = 1.0 / 1.5; + register_param(scale, "Scale", "Down scale the image prior detection"); +- stroke = CV_FILLED; ++ stroke = 0.0; + register_param(stroke, "Stroke", "Line width, divided by 100, or fill if 0"); + antialias = false; + register_param(antialias, "Antialias", "Draw with antialiasing"); diff --git a/debian/patches/020120331~0fade7e.patch b/debian/patches/020120331~0fade7e.patch new file mode 100644 index 0000000..4306f80 --- /dev/null +++ b/debian/patches/020120331~0fade7e.patch @@ -0,0 +1,137 @@ +Description: Select0r: Endian proofing +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=0fade7e +Author: Marko Cebokli +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/select0r/readme ++++ b/src/filter/select0r/readme +@@ -14,6 +14,9 @@ + Version 0.1 + "pre-alpha" (throw it out and see what happens... :-) + ++** mar 2012 ++Version 0.2 ++is now endian independent + + + DESCRIPTION +--- a/src/filter/select0r/select0r.c ++++ b/src/filter/select0r/select0r.c +@@ -627,7 +627,7 @@ + info->color_model=F0R_COLOR_MODEL_RGBA8888; + info->frei0r_version=FREI0R_MAJOR_VERSION; + info->major_version=0; +-info->minor_version=1; ++info->minor_version=2; + info->num_params=9; + info->explanation="Color based alpha selection"; + } +@@ -836,7 +836,10 @@ + float_rgba key; + triplet d,n; + int i; +-uint32_t a,t; ++uint32_t t; ++unsigned char *cin, *cout; ++float f1=1.0/256.0; ++unsigned char a1,a2; + + assert(instance); + in=(inst*)instance; +@@ -853,11 +856,13 @@ + n.z=in->nud3; + + //convert to float ++cin=(unsigned char *)inframe; + for (i=0;ih*in->w;i++) + { +- in->sl[i].r=((float)(inframe[i]&0x000000FF))*0.00392157; +- in->sl[i].g=((float)((inframe[i]&0x0000FF00)>>8))*0.00392157; +- in->sl[i].b=((float)((inframe[i]&0x00FF0000)>>16))*0.00392157; ++ in->sl[i].r=f1*(float)*cin++; ++ in->sl[i].g=f1*(float)*cin++; ++ in->sl[i].b=f1*(float)*cin++; ++ cin++; + } + + //make the selection +@@ -882,46 +887,63 @@ + in->sl[i].a = 1.0 - in->sl[i].a; + + //apply alpha ++cin=(unsigned char *)inframe; ++cout=(unsigned char *)outframe; + switch (in->op) + { + case 0: //write on clear + for (i=0;ih*in->w;i++) + { +- a=((uint32_t)(in->sl[i].a*255.0))<<24; +- outframe[i] = (inframe[i]&0x00FFFFFF) | a; ++ *cout++ = *cin++; //copy R ++ *cout++ = *cin++; //copy G ++ *cout++ = *cin++; //copy B ++ *cout++ = (unsigned char)(in->sl[i].a*255.0); ++ cin++; + } + break; + case 1: //max + for (i=0;ih*in->w;i++) + { +- a=((uint32_t)(in->sl[i].a*255.0))<<24; +- t=((inframe[i]&0xFF000000)>a) ? inframe[i]&0xFF000000 : a; +- outframe[i] = (inframe[i]&0x00FFFFFF) | t; ++ *cout++ = *cin++; //copy R ++ *cout++ = *cin++; //copy G ++ *cout++ = *cin++; //copy B ++ a1 = *cin++; ++ a2 = (unsigned char)(in->sl[i].a*255.0); ++ *cout++ = (a1>a2) ? a1 : a2; + } + break; + case 2: //min + for (i=0;ih*in->w;i++) + { +- a=((uint32_t)(in->sl[i].a*255.0))<<24; +- t=((inframe[i]&0xFF000000)sl[i].a*255.0); ++ *cout++ = (a1h*in->w;i++) + { +- a=((uint32_t)(in->sl[i].a*255.0))<<24; +- t=((inframe[i]&0xFF000000)>>1)+(a>>1); +- t = (t>0x7F800000) ? 0xFF000000 : t<<1; +- outframe[i] = (inframe[i]&0x00FFFFFF) | t; ++ *cout++ = *cin++; //copy R ++ *cout++ = *cin++; //copy G ++ *cout++ = *cin++; //copy B ++ a1 = *cin++; ++ a2 = (unsigned char)(in->sl[i].a*255.0); ++ t=(uint32_t)a1+(uint32_t)a2; ++ *cout++ = (t<=255) ? (unsigned char)t : 255; + } + break; + case 4: //subtract + for (i=0;ih*in->w;i++) + { +- a=((uint32_t)(in->sl[i].a*255.0))<<24; +- t= ((inframe[i]&0xFF000000)>a) ? (inframe[i]&0xFF000000)-a : 0; +- outframe[i] = (inframe[i]&0x00FFFFFF) | t; ++ *cout++ = *cin++; //copy R ++ *cout++ = *cin++; //copy G ++ *cout++ = *cin++; //copy B ++ a1 = *cin++; ++ a2 = (unsigned char)(in->sl[i].a*255.0); ++ *cout++ = (a1>a2) ? a1-a2 : 0; + } + break; + default: diff --git a/debian/patches/020120406~5f719f2.patch b/debian/patches/020120406~5f719f2.patch new file mode 100644 index 0000000..b46c7fb --- /dev/null +++ b/debian/patches/020120406~5f719f2.patch @@ -0,0 +1,88 @@ +Description: Select0r: use uint8_t +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=5f719f2 +Author: Marko Cebokli +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/select0r/select0r.c ++++ b/src/filter/select0r/select0r.c +@@ -837,9 +837,9 @@ + triplet d,n; + int i; + uint32_t t; +-unsigned char *cin, *cout; ++uint8_t *cin, *cout; + float f1=1.0/256.0; +-unsigned char a1,a2; ++uint8_t a1,a2; + + assert(instance); + in=(inst*)instance; +@@ -856,7 +856,7 @@ + n.z=in->nud3; + + //convert to float +-cin=(unsigned char *)inframe; ++cin=(uint8_t *)inframe; + for (i=0;ih*in->w;i++) + { + in->sl[i].r=f1*(float)*cin++; +@@ -887,8 +887,8 @@ + in->sl[i].a = 1.0 - in->sl[i].a; + + //apply alpha +-cin=(unsigned char *)inframe; +-cout=(unsigned char *)outframe; ++cin=(uint8_t *)inframe; ++cout=(uint8_t *)outframe; + switch (in->op) + { + case 0: //write on clear +@@ -897,7 +897,7 @@ + *cout++ = *cin++; //copy R + *cout++ = *cin++; //copy G + *cout++ = *cin++; //copy B +- *cout++ = (unsigned char)(in->sl[i].a*255.0); ++ *cout++ = (uint8_t)(in->sl[i].a*255.0); + cin++; + } + break; +@@ -908,7 +908,7 @@ + *cout++ = *cin++; //copy G + *cout++ = *cin++; //copy B + a1 = *cin++; +- a2 = (unsigned char)(in->sl[i].a*255.0); ++ a2 = (uint8_t)(in->sl[i].a*255.0); + *cout++ = (a1>a2) ? a1 : a2; + } + break; +@@ -919,7 +919,7 @@ + *cout++ = *cin++; //copy G + *cout++ = *cin++; //copy B + a1 = *cin++; +- a2 = (unsigned char)(in->sl[i].a*255.0); ++ a2 = (uint8_t)(in->sl[i].a*255.0); + *cout++ = (a1sl[i].a*255.0); ++ a2 = (uint8_t)(in->sl[i].a*255.0); + t=(uint32_t)a1+(uint32_t)a2; +- *cout++ = (t<=255) ? (unsigned char)t : 255; ++ *cout++ = (t<=255) ? (uint8_t)t : 255; + } + break; + case 4: //subtract +@@ -942,7 +942,7 @@ + *cout++ = *cin++; //copy G + *cout++ = *cin++; //copy B + a1 = *cin++; +- a2 = (unsigned char)(in->sl[i].a*255.0); ++ a2 = (uint8_t)(in->sl[i].a*255.0); + *cout++ = (a1>a2) ? a1-a2 : 0; + } + break; diff --git a/debian/patches/020120406~6b780c3.patch b/debian/patches/020120406~6b780c3.patch new file mode 100644 index 0000000..9d2ebcf --- /dev/null +++ b/debian/patches/020120406~6b780c3.patch @@ -0,0 +1,17 @@ +Description: host_param_test: fix string parameter +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=6b780c3 +Author: Marko Cebokli +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/host_param_test/host_param_test.c ++++ b/src/filter/host_param_test/host_param_test.c +@@ -129,7 +129,7 @@ + break; + case 4: + { +- char* sval = ((char*)param); ++ char* sval = (*(char**)param); + inst->svalue = (char*)realloc( inst->svalue, strlen(sval) + 1 ); + strcpy( inst->svalue, sval ); + break; diff --git a/debian/patches/020120608~7f54736.patch b/debian/patches/020120608~7f54736.patch new file mode 100644 index 0000000..2c2b54c --- /dev/null +++ b/debian/patches/020120608~7f54736.patch @@ -0,0 +1,48 @@ +Description: fix compiler warnings +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=7f54736 +Author: Dan Dennedy +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/delaygrab/delaygrab.cpp ++++ b/src/filter/delaygrab/delaygrab.cpp +@@ -245,7 +245,7 @@ + break; + } // switch + /* Clip values */ +- if (*curdelaymap<0) { ++ if ((int)(*curdelaymap)<0) { + *curdelaymap=0; + } else if (*curdelaymap>(QUEUEDEPTH-1)) { + *curdelaymap=(QUEUEDEPTH-1); +--- a/src/filter/lightgraffiti/lightgraffiti.cpp ++++ b/src/filter/lightgraffiti/lightgraffiti.cpp +@@ -835,7 +835,7 @@ + */ + #ifdef LG_ADV + if ( +- m_rgbLightMask[pixel].r != 0 || m_rgbLightMask[pixel].g != 0 || m_rgbLightMask[pixel].b != 0 ++ (m_rgbLightMask[pixel].r != 0 || m_rgbLightMask[pixel].g != 0 || m_rgbLightMask[pixel].b != 0) + && !m_pStatsBrightness && !m_pStatsDiff && !m_pStatsDiffSum + ) + { +@@ -1017,6 +1017,8 @@ + } + } + break; ++ default: ++ break; + } + } + +--- a/src/filter/tutorial/tutorial.cpp ++++ b/src/filter/tutorial/tutorial.cpp +@@ -135,7 +135,7 @@ + + // Add g+b and clamp with the second lookup table + *out_pointer = additionTable[*in_pointer + *(in_pointer+1)]; +- *out_pointer++; *in_pointer++; ++ out_pointer++; in_pointer++; + + // Copy the other channels + *out_pointer++ = *in_pointer++; diff --git a/debian/patches/020120828~33b8c35.patch b/debian/patches/020120828~33b8c35.patch new file mode 100644 index 0000000..ca46e93 --- /dev/null +++ b/debian/patches/020120828~33b8c35.patch @@ -0,0 +1,249 @@ +Description: Alpha0ps: endian proofing +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=33b8c35 +Author: Marko Cebokli +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/alpha0ps/alpha0ps.c ++++ b/src/filter/alpha0ps/alpha0ps.c +@@ -21,6 +21,10 @@ + along with this program; if not, write to the Free Software + Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + ++ ++ ++ 28 aug 2012 ver 0.2 endian proofing ++ + */ + + +@@ -50,66 +54,73 @@ + int inv; + + float *falpha,*ab; ++uint8_t *infr,*oufr; + } inst; + + + //--------------------------------------------------- +-//RGBA8888 little endian + void alphagray(inst *in, const uint32_t* inframe, uint32_t* outframe) + { +-uint32_t s; ++uint8_t s; + int i; + + if (in->din==0) + for (i=0;iw*in->h;i++) + { +- s=(outframe[i]&0xFF000000)>>24; +- s=s+(s<<8)+(s<<16); +- outframe[i]=(outframe[i]&0xFF000000)|s; ++ s=in->oufr[4*i+3]; ++ in->oufr[4*i]=s; ++ in->oufr[4*i+1]=s; ++ in->oufr[4*i+2]=s; ++ in->oufr[4*i+3]=0xFF; + } + else + for (i=0;iw*in->h;i++) + { +- s=(inframe[i]&0xFF000000)>>24; +- s=s+(s<<8)+(s<<16); +- outframe[i]=(outframe[i]&0xFF000000)+s; ++ s=in->infr[4*i+3]; ++ in->oufr[4*i]=s; ++ in->oufr[4*i+1]=s; ++ in->oufr[4*i+2]=s; ++ in->oufr[4*i+3]=0xFF; + } + } + + //--------------------------------------------------- +-//RGBA8888 little endian + void grayred(inst *in, const uint32_t* inframe, uint32_t* outframe) + { +-int i; +-uint32_t r,g,b,a,y,s; ++int i,rr; ++uint8_t r,g,b,a,y; + + if (in->din==0) + for (i=0;iw*in->h;i++) + { +- b=(inframe[i]&0x00FF0000)>>16; +- g=(inframe[i]&0x0000FF00)>>8; +- r=inframe[i]&0x000000FF; +- a=(outframe[i]&0xFF000000)>>24; ++ b=in->infr[4*i+2]; ++ g=in->infr[4*i+1]; ++ r=in->infr[4*i]; ++ a=in->oufr[4*i+3]; + y=(r>>2)+(g>>1)+(b>>2); //approx luma + y=64+(y>>1); +- r=y+(a>>1); +- if (r>255) r=255; +- s=r+(y<<8)+(y<<16); +- outframe[i]=(inframe[i]&0xFF000000)+s; ++ rr=y+(a>>1); ++ if (rr>255) rr=255; ++ in->oufr[4*i]=rr; ++ in->oufr[4*i+1]=y; ++ in->oufr[4*i+2]=y; ++ in->oufr[4*i+3]=0xFF; + } + else + for (i=0;iw*in->h;i++) + { +- b=(inframe[i]&0x00FF0000)>>16; +- g=(inframe[i]&0x0000FF00)>>8; +- r=inframe[i]&0x000000FF; +- a=(inframe[i]&0xFF000000)>>24; +- y=(r>>2)+(g>>1)+(b>>2); ++ b=in->infr[4*i+2]; ++ g=in->infr[4*i+1]; ++ r=in->infr[4*i]; ++ a=in->infr[4*i+3]; ++ y=(r>>2)+(g>>1)+(b>>2); //approx luma + y=64+(y>>1); +- r=y+(a<<1); +- if (r>255) r=255; +- s=r+(y<<8)+(y<<16); +- outframe[i]=(inframe[i]&0xFF000000)+s; ++ rr=y+(a>>1); ++ if (rr>255) rr=255; ++ in->oufr[4*i]=rr; ++ in->oufr[4*i+1]=y; ++ in->oufr[4*i+2]=y; ++ in->oufr[4*i+3]=0xFF; + } + } + +@@ -118,7 +129,7 @@ + { + int i; + uint32_t bk; +-uint32_t r,g,b,a,s; ++uint32_t r,g,b,a; + + switch (bg) + { +@@ -138,18 +149,17 @@ + else + bk=0x9B; + } +- b=(outframe[i]&0x00FF0000)>>16; +- g=(outframe[i]&0x0000FF00)>>8; +- r=outframe[i]&0x000000FF; +- a=(outframe[i]&0xFF000000)>>24; +- r=a*r+(255-a)*bk; +- r=r>>8; +- g=a*g+(255-a)*bk; +- g=g>>8; +- b=a*b+(255-a)*bk; +- b=b>>8; +- s=r+(g<<8)+(b<<16); +- outframe[i]=(inframe[i]&0xFF000000)+s; ++ b=in->oufr[4*i+2]; ++ g=in->oufr[4*i+1]; ++ r=in->oufr[4*i]; ++ a=in->oufr[4*i+3]; ++ r=(a*r+(255-a)*bk)>>8; ++ g=(a*g+(255-a)*bk)>>8; ++ b=(a*b+(255-a)*bk)>>8; ++ in->oufr[4*i]=r; ++ in->oufr[4*i+1]=g; ++ in->oufr[4*i+2]=b; ++ in->oufr[4*i+3]=0xFF; + } + else + for (i=0;iw*in->h;i++) +@@ -161,18 +171,17 @@ + else + bk=0x9B; + } +- b=(inframe[i]&0x00FF0000)>>16; +- g=(inframe[i]&0x0000FF00)>>8; +- r=inframe[i]&0x000000FF; +- a=(inframe[i]&0xFF000000)>>24; +- r=a*r+(255-a)*bk; +- r=r>>8; +- g=a*g+(255-a)*bk; +- g=g>>8; +- b=a*b+(255-a)*bk; +- b=b>>8; +- s=r+(g<<8)+(b<<16); +- outframe[i]=(inframe[i]&0xFF000000)+s; ++ b=in->infr[4*i+2]; ++ g=in->infr[4*i+1]; ++ r=in->infr[4*i]; ++ a=in->infr[4*i+3]; ++ r=(a*r+(255-a)*bk)>>8; ++ g=(a*g+(255-a)*bk)>>8; ++ b=(a*b+(255-a)*bk)>>8; ++ in->oufr[4*i]=r; ++ in->oufr[4*i+1]=g; ++ in->oufr[4*i+2]=b; ++ in->oufr[4*i+3]=0xFF; + } + } + +@@ -378,7 +387,7 @@ + info->color_model=F0R_COLOR_MODEL_RGBA8888; + info->frei0r_version=FREI0R_MAJOR_VERSION; + info->major_version=0; +-info->minor_version=1; ++info->minor_version=2; + info->num_params=6; + info->explanation="Display and manipulation of the alpha channel"; + } +@@ -507,8 +516,6 @@ + void f0r_get_param_value(f0r_instance_t instance, f0r_param_t param, int param_index) + { + inst *p; +-double tmpf; +-int tmpi; + + p=(inst*)instance; + +@@ -544,11 +551,13 @@ + + assert(instance); + in=(inst*)instance; ++in->infr=(uint8_t*)inframe; ++in->oufr=(uint8_t*)outframe; + + //printf("update, op=%d, inv=%d disp=%d\n",in->op,in->inv,in->disp); + + for (i=0;iw*in->h;i++) +- in->falpha[i]=(inframe[i]&0xFF000000)>>24; ++ in->falpha[i]=in->infr[4*i+3]; + + switch (in->op) + { +@@ -585,8 +594,11 @@ + in->falpha[i]=255.0-in->falpha[i]; + + for (i=0;iw*in->h;i++) +- outframe[i] = (inframe[i]&0x00FFFFFF) | (((uint32_t)in->falpha[i])<<24); +- ++ { ++ outframe[i] = inframe[i]; ++ in->oufr[4*i+3] = (uint8_t)in->falpha[i]; ++ } ++ + switch (in->disp) + { + case 0: +--- a/src/filter/alpha0ps/readme ++++ b/src/filter/alpha0ps/readme +@@ -19,6 +19,9 @@ + Version 0.1 + "pre-alpha" (throw it out and see what happens... :-) + ++** aug 2012 ++Version 0.2 ++Endian proofing (use uint8_t* to access image data) + + + ALPHAOPS: diff --git a/debian/patches/020121014~cbd4049.patch b/debian/patches/020121014~cbd4049.patch new file mode 100644 index 0000000..2e20448 --- /dev/null +++ b/debian/patches/020121014~cbd4049.patch @@ -0,0 +1,129 @@ +Description: Fix undefined symbols with "raw" inlines (not extern or static). + This was noticed with gcc when not using -O2 or perhaps some other + optimizations. +Origin: upstream, http://git.dyne.org/frei0r/commit/?id=cbd4049 +Author: Dan Dennedy +Forwarded: yes +Last-Update: 2012-12-23 + +--- a/src/filter/denoise/hqdn3d.c ++++ b/src/filter/denoise/hqdn3d.c +@@ -66,7 +66,7 @@ + //deNoise and PrecalaCoefs are from Mplayer "hqdn3d" filter + //by Daniel Moreno + +-inline unsigned int LowPassMul(unsigned int PrevMul, unsigned int CurrMul, int* Coef){ ++static inline unsigned int LowPassMul(unsigned int PrevMul, unsigned int CurrMul, int* Coef){ + // int dMul= (PrevMul&0xFFFFFF)-(CurrMul&0xFFFFFF); + int dMul= PrevMul-CurrMul; + unsigned int d=((dMul+0x10007FF)>>12); +--- a/src/filter/select0r/select0r.c ++++ b/src/filter/select0r/select0r.c +@@ -61,7 +61,7 @@ + // returns square of distance + // r==1 is edge of subspace + //box shape +-inline float dist_box(float cx, float cy, float cz, float dx, float dy, float dz, float x, float y, float z) ++static inline float dist_box(float cx, float cy, float cz, float dx, float dy, float dz, float x, float y, float z) + { + float ax,ay,az,r; + +@@ -75,7 +75,7 @@ + return r; + } + //ellipsoid shape +-inline float dist_eli(float cx, float cy, float cz, float dx, float dy, float dz, float x, float y, float z) ++static inline float dist_eli(float cx, float cy, float cz, float dx, float dy, float dz, float x, float y, float z) + { + float ax,ay,az,r; + +@@ -86,7 +86,7 @@ + return r; + } + //octahedron shape +-inline float dist_oct(float cx, float cy, float cz, float dx, float dy, float dz, float x, float y, float z) ++static inline float dist_oct(float cx, float cy, float cz, float dx, float dy, float dz, float x, float y, float z) + { + float ax,ay,az,r; + +@@ -98,7 +98,7 @@ + return r; + } + //box shape, cylindrical space +-inline float dist_box_c(float chue, float cy, float cz, float dhue, float dy, float dz, float hue, float y, float z) ++static inline float dist_box_c(float chue, float cy, float cz, float dhue, float dy, float dz, float hue, float y, float z) + { + float ax,ay,az,r; + +@@ -115,7 +115,7 @@ + return r; + } + //ellipsoid shape, cylindrical space +-inline float dist_eli_c(float chue, float cy, float cz, float dhue, float dy, float dz, float hue, float y, float z) ++static inline float dist_eli_c(float chue, float cy, float cz, float dhue, float dy, float dz, float hue, float y, float z) + { + float ax,ay,az,r; + +@@ -129,7 +129,7 @@ + return r; + } + //octahedron shape, cylindrical space +-inline float dist_oct_c(float chue, float cy, float cz, float dhue, float dy, float dz, float hue, float y, float z) ++static inline float dist_oct_c(float chue, float cy, float cz, float dhue, float dy, float dz, float hue, float y, float z) + { + float ax,ay,az,r; + +@@ -146,7 +146,7 @@ + + //---------------------------------------------------------- + //inline RGB to ABI conversion function +-inline void rgb2abi(float k32, float r, float g, float b, float *a, float *bb, float *i) ++static inline void rgb2abi(float k32, float r, float g, float b, float *a, float *bb, float *i) + { + *a=r-0.5*g-0.5*b; + *bb=k32*(g-b); +@@ -155,7 +155,7 @@ + + //---------------------------------------------------------- + //inline RGB to HCI conversion function +-inline void rgb2hci(float ipi2, float k32, float r, float g, float b, float *h, float *c, float *i) ++static inline void rgb2hci(float ipi2, float k32, float r, float g, float b, float *h, float *c, float *i) + { + float a,bb; + a=r-0.5*g-0.5*b; +@@ -167,24 +167,24 @@ + + //------------------------------------------------------ + //thresholding inline functions (hard and soft) +-inline float thres(float a) ++static inline float thres(float a) + { + return (a<1.0) ? 1.0 : 0.0; + } + +-inline float fat(float a) ++static inline float fat(float a) + { + a=a*a*a*a; + return (a<1.0) ? 1.0-a : 0.0; + } + +-inline float norm(float a) ++static inline float norm(float a) + { + a=a*a; + return (a<1.0) ? 1.0-a : 0.0; + } + +-inline float skiny(float a) ++static inline float skiny(float a) + { + return (a<1.0) ? 1.0-a : 0.0; + } +@@ -952,4 +952,4 @@ + + } + +-//********************************************************** +\ No newline at end of file ++//********************************************************** diff --git a/debian/patches/README b/debian/patches/README new file mode 100644 index 0000000..80c1584 --- /dev/null +++ b/debian/patches/README @@ -0,0 +1,3 @@ +0xxx: Grabbed from upstream development. +1xxx: Possibly relevant for upstream adoption. +2xxx: Only relevant for official Debian release. diff --git a/debian/patches/series b/debian/patches/series new file mode 100644 index 0000000..bf936d0 --- /dev/null +++ b/debian/patches/series @@ -0,0 +1,44 @@ +020110315~2a1524a.patch +020110315~b4065ce.patch +020110316~6c65d6a.patch +020110806~0309859.patch +020110806~f73c962.patch +020110815~339ad24.patch +020110815~899fd4d.patch +020110815~9e606ce.patch +020110815~f74a435.patch +020110816~2ddbaba.patch +020110816~9bf94ea.patch +020110816~c8d6510.patch +020110817~0b4044c.patch +020110817~1bb4a6c.patch +020110817~6197fb0.patch +020110817~e0f11e9.patch +020110821~dc23844.patch +020110822~39e4492.patch +020110822~62b9f1c.patch +020110822~63f2186.patch +020110823~0eb9f2a.patch +020110823~22e4f73.patch +020110823~90ee1fa.patch +020110825~0be0cec.patch +020110825~b8f2300.patch +020110831~63c0878.patch +020110903~63bafff.patch +020110903~b467ddc.patch +020110903~f7cc65f.patch +020110910~047c762.patch +020110910~39e65be.patch +020110910~661a7b4.patch +020110910~d4d29e9.patch +020110910~ee7bb57.patch +020110911~a6c266a.patch +020110928~8f80908.patch +020110928~9c93c22.patch +020110928~f1794f8.patch +020120331~0fade7e.patch +020120406~5f719f2.patch +020120406~6b780c3.patch +020120608~7f54736.patch +020120828~33b8c35.patch +020121014~cbd4049.patch