This commit is contained in:
Shyotl
2014-11-22 22:20:32 -06:00
130 changed files with 2810 additions and 2321 deletions

View File

@@ -1178,13 +1178,13 @@ void LLImageRaw::copyLineScaled( U8* in, U8* out, S32 in_pixel_len, S32 out_pixe
a *= norm_factor; // skip conditional
S32 t4 = x * out_pixel_step * components;
out[t4 + 0] = U8(llround(r));
out[t4 + 0] = U8(llmath::llround(r));
if (components >= 2)
out[t4 + 1] = U8(llround(g));
out[t4 + 1] = U8(llmath::llround(g));
if (components >= 3)
out[t4 + 2] = U8(llround(b));
out[t4 + 2] = U8(llmath::llround(b));
if( components == 4)
out[t4 + 3] = U8(llround(a));
out[t4 + 3] = U8(llmath::llround(a));
}
}
}
@@ -1259,10 +1259,10 @@ void LLImageRaw::compositeRowScaled4onto3( U8* in, U8* out, S32 in_pixel_len, S3
b *= norm_factor;
a *= norm_factor;
in_scaled_r = U8(llround(r));
in_scaled_g = U8(llround(g));
in_scaled_b = U8(llround(b));
in_scaled_a = U8(llround(a));
in_scaled_r = U8(llmath::llround(r));
in_scaled_g = U8(llmath::llround(g));
in_scaled_b = U8(llmath::llround(b));
in_scaled_a = U8(llmath::llround(a));
}
if( in_scaled_a )

View File

@@ -30,8 +30,12 @@
#include <png.h>
#else
// Workaround for wrongly packaged prebuilt.
#if _MSC_VER >= 1800
#include <libpng16/png.h>
#else
#include "libpng15/png.h"
#endif
#endif
#include "llimage.h"
class LLPngWrapper