if(i!=nsf-1) printf(", ");
if(i==nsf-2) printf("or ");
}
+ if(i%8==0 && i!=0) printf("\n ");
}
printf(")\n");
printf("-hflip, -vflip, -transpose, -transverse, -rot90, -rot180, -rot270 =\n");
{
for(j=0; j<nsf; j++)
{
- if(temp1==scalingfactors[j].num && temp2==scalingfactors[j].denom)
+ if((double)temp1/(double)temp2
+ == (double)scalingfactors[j].num/(double)scalingfactors[j].denom)
{
sf=scalingfactors[j];
match=1; break;
JXFORM_TRANSVERSE, JXFORM_ROT_90, JXFORM_ROT_180, JXFORM_ROT_270
};
-#define NUMSF 4
+#define NUMSF 16
static const tjscalingfactor sf[NUMSF]={
+ {2, 1},
+ {15, 8},
+ {7, 4},
+ {13, 8},
+ {3, 2},
+ {11, 8},
+ {5, 4},
+ {9, 8},
{1, 1},
+ {7, 8},
+ {3, 4},
+ {5, 8},
{1, 2},
+ {3, 8},
{1, 4},
{1, 8}
};