< prev index next >
src/java.desktop/share/native/liblcms/cmsxform.c
Print this page
rev 16232 : 8170798: Fix minor issues in java2d and sound coding.
@@ -282,10 +282,11 @@
_cmsHandleExtraChannels(p, in, out, PixelsPerLine, LineCount, Stride);
strideIn = 0;
strideOut = 0;
+ memset(fIn, 0, sizeof(fIn));
for (i = 0; i < LineCount; i++) {
accum = (cmsUInt8Number*)in + strideIn;
output = (cmsUInt8Number*)out + strideOut;
@@ -346,10 +347,11 @@
_cmsHandleExtraChannels(p, in, out, PixelsPerLine, LineCount, Stride);
strideIn = 0;
strideOut = 0;
+ memset(fIn, 0, sizeof(fIn));
for (i = 0; i < LineCount; i++) {
accum = (cmsUInt8Number*) in + strideIn;
output = (cmsUInt8Number*) out + strideOut;
@@ -383,10 +385,11 @@
_cmsHandleExtraChannels(p, in, out, PixelsPerLine, LineCount, Stride);
strideIn = 0;
strideOut = 0;
+ memset(wIn, 0, sizeof(wIn));
for (i = 0; i < LineCount; i++) {
accum = (cmsUInt8Number*)in + strideIn;
output = (cmsUInt8Number*)out + strideOut;
@@ -420,10 +423,11 @@
_cmsHandleExtraChannels(p, in, out, PixelsPerLine, LineCount, Stride);
strideIn = 0;
strideOut = 0;
+ memset(wIn, 0, sizeof(wIn));
for (i = 0; i < LineCount; i++) {
accum = (cmsUInt8Number*)in + strideIn;
output = (cmsUInt8Number*)out + strideOut;
@@ -446,14 +450,14 @@
static
void TransformOnePixelWithGamutCheck(_cmsTRANSFORM* p,
const cmsUInt16Number wIn[],
cmsUInt16Number wOut[])
{
- cmsUInt16Number wOutOfGamut;
+ cmsUInt16Number wOutOfGamut[cmsMAXCHANNELS];
- p ->GamutCheck ->Eval16Fn(wIn, &wOutOfGamut, p ->GamutCheck ->Data);
- if (wOutOfGamut >= 1) {
+ p ->GamutCheck ->Eval16Fn(wIn, wOutOfGamut, p ->GamutCheck ->Data);
+ if (wOutOfGamut[0] >= 1) {
cmsUInt16Number i;
_cmsAlarmCodesChunkType* ContextAlarmCodes = (_cmsAlarmCodesChunkType*) _cmsContextGetClientChunk(p->ContextID, AlarmCodesContext);
for (i=0; i < p ->Lut->OutputChannels; i++) {
@@ -463,11 +467,11 @@
}
else
p ->Lut ->Eval16Fn(wIn, wOut, p -> Lut->Data);
}
-// Gamut check, No caché, 16 bits.
+// Gamut check, No cache, 16 bits.
static
void PrecalculatedXFORMGamutCheck(_cmsTRANSFORM* p,
const void* in,
void* out,
cmsUInt32Number PixelsPerLine,
@@ -481,10 +485,11 @@
_cmsHandleExtraChannels(p, in, out, PixelsPerLine, LineCount, Stride);
strideIn = 0;
strideOut = 0;
+ memset(wIn, 0, sizeof(wIn));
for (i = 0; i < LineCount; i++) {
accum = (cmsUInt8Number*)in + strideIn;
output = (cmsUInt8Number*)out + strideOut;
< prev index next >