remove a stray floor() from cast

thanks lovell
This commit is contained in:
John Cupitt 2019-01-12 13:51:35 +00:00
parent 98def52715
commit d2f48a8875

View File

@ -194,9 +194,8 @@ G_DEFINE_TYPE( VipsCast, vips_cast, VIPS_TYPE_CONVERSION );
ITYPE * restrict p = (ITYPE *) in; \
OTYPE * restrict q = (OTYPE *) out; \
\
for( x = 0; x < sz; x++ ) { \
for( x = 0; x < sz; x++ ) \
q[x] = CAST( p[x] ); \
} \
}
/* Cast complex types to an int type. Just take the real part.
@ -206,10 +205,8 @@ G_DEFINE_TYPE( VipsCast, vips_cast, VIPS_TYPE_CONVERSION );
OTYPE * restrict q = (OTYPE *) out; \
\
for( x = 0; x < sz; x++ ) { \
TEMP v = VIPS_FLOOR( p[0] ); \
\
q[x] = CAST( p[0] ); \
p += 2; \
q[x] = CAST( v ); \
} \
}