return out;
}
-i_img *i_matrix_transform_bg(i_img *src, int xsize, int ysize, double *matrix,
- i_color *backp, i_fcolor *fbackp) {
+i_img *i_matrix_transform_bg(i_img *src, int xsize, int ysize, const double *matrix,
+ const i_color *backp, const i_fcolor *fbackp) {
i_img *result = i_sametype(src, xsize, ysize);
int x, y;
int ch;
sx = (x * matrix[0] + y * matrix[1] + matrix[2]) / sz;
sy = (x * matrix[3] + y * matrix[4] + matrix[5]) / sz;
}
+ else {
+ sx = sy = 0;
+ }
/* anything outside these ranges is either a broken co-ordinate
or outside the source */
sx = (x * matrix[0] + y * matrix[1] + matrix[2]) / sz;
sy = (x * matrix[3] + y * matrix[4] + matrix[5]) / sz;
}
+ else {
+ sx = sy = 0;
+ }
/* anything outside these ranges is either a broken co-ordinate
or outside the source */
sx = (x * matrix[0] + y * matrix[1] + matrix[2]) / sz;
sy = (x * matrix[3] + y * matrix[4] + matrix[5]) / sz;
}
+ else {
+ sx = sy = 0;
+ }
/* anything outside these ranges is either a broken co-ordinate
or outside the source */
return result;
}
-i_img *i_matrix_transform(i_img *src, int xsize, int ysize, double *matrix) {
+i_img *i_matrix_transform(i_img *src, int xsize, int ysize, const double *matrix) {
return i_matrix_transform_bg(src, xsize, ysize, matrix, NULL, NULL);
}
static void
-i_matrix_mult(double *dest, double *left, double *right) {
+i_matrix_mult(double *dest, const double *left, const double *right) {
int i, j, k;
double accum;
}
i_img *i_rotate_exact_bg(i_img *src, double amount,
- i_color *backp, i_fcolor *fbackp) {
+ const i_color *backp, const i_fcolor *fbackp) {
double xlate1[9] = { 0 };
double rotate[9];
double xlate2[9] = { 0 };