commit du soir, espoir
This commit is contained in:
@@ -103,11 +103,30 @@ nbre = fi->width * fi->height * fi->type;
|
||||
#if DEBUG_LEVEL
|
||||
fprintf(stderr, "%s, nbre is %d\n", __func__, nbre);
|
||||
#endif
|
||||
for (idx=0; idx<nbre; nbre++) {
|
||||
for (idx=0; idx<nbre; idx++) {
|
||||
fi->R[idx] += value;
|
||||
}
|
||||
}
|
||||
/* ---------------------------------------------------------------- */
|
||||
void fimg_mul_cste(FloatImg *fi, float value)
|
||||
{
|
||||
int nbre, idx;
|
||||
|
||||
if (fi->type != FIMG_TYPE_RGB) {
|
||||
fprintf(stderr, "%s : type %d invalide\n",
|
||||
__func__, fi->type);
|
||||
return;
|
||||
}
|
||||
|
||||
nbre = fi->width * fi->height * fi->type;
|
||||
// #if DEBUG_LEVEL
|
||||
fprintf(stderr, "%s, nbre is %d\n", __func__, nbre);
|
||||
// #endif
|
||||
for (idx=0; idx<nbre; idx++) {
|
||||
fi->R[idx] *= value;
|
||||
}
|
||||
}
|
||||
/* ---------------------------------------------------------------- */
|
||||
/* Warning: this function is _very_ slow */
|
||||
void fimg_drand48(FloatImg *fi, float kmul)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user