This commit is contained in:
tTh 2022-08-23 12:15:31 +02:00
parent bce4464719
commit 75584b8ada

View File

@ -36,12 +36,10 @@ if ( (foo=Image_compare_desc(src, dst)) )
return foo; return foo;
} }
cr = cg = cb = 0; cr = cg = cb = 0; /* raz des compteurs */
for (y=0; y<dst->height; y++) for (y=0; y<dst->height; y++) {
{ for (x=0; x<dst->width; x++) {
for (x=0; x<dst->width; x++)
{
Image_getRGB(src, x, y, &r, &g, &b); Image_getRGB(src, x, y, &r, &g, &b);
if (r > kr) { if (r > kr) {
foo = g; g = b; b = foo; foo = g; g = b; b = foo;
@ -61,7 +59,7 @@ for (y=0; y<dst->height; y++)
fprintf(stderr, "* %s : counts: %d %d %d\n", __func__, cr, cg, cb); fprintf(stderr, "* %s : counts: %d %d %d\n", __func__, cr, cg, cb);
return FUNC_IS_ALPHA; return FUNC_IS_BETA;
} }
/*::------------------------------------------------------------------::*/ /*::------------------------------------------------------------------::*/
/* 2 fevrier 2003: je fait du n'importe quoi, la... */ /* 2 fevrier 2003: je fait du n'importe quoi, la... */
@ -113,10 +111,10 @@ if ( (foo=Image_compare_desc(src, dst)) )
return foo; return foo;
} }
for (y=0; y<dst->height; y++) /* a vrai dire, je ne comprend pas ou caser kx, ky et kz */
{
for (x=0; x<dst->width; x++) for (y=0; y<dst->height; y++) {
{ for (x=0; x<dst->width; x++) {
r = src->Rpix[y][x]; r = src->Rpix[y][x];
g = src->Gpix[y][x]; g = src->Gpix[y][x];
b = src->Bpix[y][x]; b = src->Bpix[y][x];
@ -243,8 +241,7 @@ for (y=0; y<dst->height; y++)
return FUNC_IS_ALPHA; return FUNC_IS_ALPHA;
} }
/*::------------------------------------------------------------------::*/ /*::------------------------------------------------------------------::*/
int int Image_effect_x_4(Image_Desc *src, Image_Desc *dst, int flags)
Image_effect_x_4(Image_Desc *src, Image_Desc *dst, int flags)
{ {
int foo; int foo;
int x, y; int x, y;
@ -254,16 +251,13 @@ int r, g, b, r2, g2, b2;
fprintf(stderr, "*** effect x4 is not ready for prime time ***\n"); fprintf(stderr, "*** effect x4 is not ready for prime time ***\n");
#endif #endif
if ( (foo=Image_compare_desc(src, dst)) ) if ( (foo=Image_compare_desc(src, dst)) ) {
{
fprintf(stderr, "Image effect x 4: images are differents %d\n", foo); fprintf(stderr, "Image effect x 4: images are differents %d\n", foo);
return foo; return foo;
} }
for (y=0; y<src->height; y++) for (y=0; y<src->height; y++) {
{ for (x=0; x<src->width; x++) {
for (x=0; x<src->width; x++)
{
r = src->Rpix[y][x]; r = src->Rpix[y][x];
g = src->Gpix[y][x]; g = src->Gpix[y][x];
b = src->Bpix[y][x]; b = src->Bpix[y][x];
@ -290,6 +284,7 @@ return FUNC_IS_BETA;
/* 22 avril 2007: je vais essayer d'inventer un nouveau truc, mais il /* 22 avril 2007: je vais essayer d'inventer un nouveau truc, mais il
* faudrait que les gosses arretent de ma casser les oreilles avec leur * faudrait que les gosses arretent de ma casser les oreilles avec leur
* machine a batailles. putain de gamecube... */ * machine a batailles. putain de gamecube... */
/* 23 aout 2022 : j'ai bien envie d'une SNES et d'un Trinitron */
int int
Image_effect_x_5(Image_Desc *src, Image_Desc *dst, int kx, int ky, int kz) Image_effect_x_5(Image_Desc *src, Image_Desc *dst, int kx, int ky, int kz)
{ {
@ -300,7 +295,7 @@ double dr, dg, db, dr2, dg2, db2;
fprintf(stderr, "*** effect x5 is not ready for prime time ***\n"); fprintf(stderr, "*** effect x5 is not ready for prime time ***\n");
#if DEBUG_LEVEL #if DEBUG_LEVEL
fprintf(stderr, "%s ( %p %p %d %d %d )\n", __func__, src, dst, fprintf(stderr, ">>> %s ( %p %p %d %d %d )\n", __func__, src, dst,
kx, ky, kz); kx, ky, kz);
#endif #endif