6 i_img* i_transform2(int width, int height, int channels,
7 struct rm_op *ops, int ops_count,
8 double *n_regs, int n_regs_count,
9 i_color *c_regs, int c_regs_count,
10 i_img **in_imgs, int in_imgs_count)
17 /* since the number of images is variable and the image numbers
18 for getp? are fixed, we can check them here instead of in the
19 register machine - this will help performance */
20 for (i = 0; i < ops_count; ++i) {
21 switch (ops[i].code) {
25 if (ops[i].code - rbc_getp1 + 1 > in_imgs_count) {
32 new_img = i_img_empty_ch(NULL, width, height, channels);
33 for (x = 0; x < width; ++x) {
34 for (y = 0; y < height; ++y) {
37 val = rm_run(ops, ops_count, n_regs, n_regs_count, c_regs, c_regs_count,
38 in_imgs, in_imgs_count);
39 i_ppix(new_img, x, y, &val);