Compiler warnings
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@1350 632fc199-4ca6-4c93-a231-07263d6284db
This commit is contained in:
@@ -55,7 +55,7 @@
|
|||||||
jfieldID _fid; \
|
jfieldID _fid; \
|
||||||
if(!_cls) goto bailout; \
|
if(!_cls) goto bailout; \
|
||||||
bailif0(_fid=(*env)->GetFieldID(env, _cls, "handle", "J")); \
|
bailif0(_fid=(*env)->GetFieldID(env, _cls, "handle", "J")); \
|
||||||
handle=(tjhandle)(jlong)(*env)->GetLongField(env, obj, _fid); \
|
handle=(tjhandle)(size_t)(*env)->GetLongField(env, obj, _fid); \
|
||||||
|
|
||||||
JNIEXPORT jint JNICALL Java_org_libjpegturbo_turbojpeg_TJ_bufSize
|
JNIEXPORT jint JNICALL Java_org_libjpegturbo_turbojpeg_TJ_bufSize
|
||||||
(JNIEnv *env, jclass cls, jint width, jint height, jint jpegSubsamp)
|
(JNIEnv *env, jclass cls, jint width, jint height, jint jpegSubsamp)
|
||||||
@@ -96,7 +96,7 @@ JNIEXPORT void JNICALL Java_org_libjpegturbo_turbojpeg_TJCompressor_init
|
|||||||
|
|
||||||
bailif0(cls=(*env)->GetObjectClass(env, obj));
|
bailif0(cls=(*env)->GetObjectClass(env, obj));
|
||||||
bailif0(fid=(*env)->GetFieldID(env, cls, "handle", "J"));
|
bailif0(fid=(*env)->GetFieldID(env, cls, "handle", "J"));
|
||||||
(*env)->SetLongField(env, obj, fid, (jlong)handle);
|
(*env)->SetLongField(env, obj, fid, (size_t)handle);
|
||||||
|
|
||||||
bailout:
|
bailout:
|
||||||
return;
|
return;
|
||||||
@@ -270,16 +270,16 @@ JNIEXPORT void JNICALL Java_org_libjpegturbo_turbojpeg_TJCompressor_encodeYUV___
|
|||||||
jint pitch, jint height, jint pf, jbyteArray dst, jint pad, jint subsamp,
|
jint pitch, jint height, jint pf, jbyteArray dst, jint pad, jint subsamp,
|
||||||
jint flags)
|
jint flags)
|
||||||
{
|
{
|
||||||
return TJCompressor_encodeYUV(env, obj, src, 1, x, y, width, pitch, height,
|
TJCompressor_encodeYUV(env, obj, src, 1, x, y, width, pitch, height, pf, dst,
|
||||||
pf, dst, pad, subsamp, flags);
|
pad, subsamp, flags);
|
||||||
}
|
}
|
||||||
|
|
||||||
JNIEXPORT void JNICALL Java_org_libjpegturbo_turbojpeg_TJCompressor_encodeYUV___3BIIII_3BII
|
JNIEXPORT void JNICALL Java_org_libjpegturbo_turbojpeg_TJCompressor_encodeYUV___3BIIII_3BII
|
||||||
(JNIEnv *env, jobject obj, jbyteArray src, jint width, jint pitch,
|
(JNIEnv *env, jobject obj, jbyteArray src, jint width, jint pitch,
|
||||||
jint height, jint pf, jbyteArray dst, jint subsamp, jint flags)
|
jint height, jint pf, jbyteArray dst, jint subsamp, jint flags)
|
||||||
{
|
{
|
||||||
return TJCompressor_encodeYUV(env, obj, src, 1, 0, 0, width, pitch, height,
|
TJCompressor_encodeYUV(env, obj, src, 1, 0, 0, width, pitch, height, pf, dst,
|
||||||
pf, dst, 4, subsamp, flags);
|
4, subsamp, flags);
|
||||||
}
|
}
|
||||||
|
|
||||||
JNIEXPORT void JNICALL Java_org_libjpegturbo_turbojpeg_TJCompressor_encodeYUV___3IIIIIII_3BIII
|
JNIEXPORT void JNICALL Java_org_libjpegturbo_turbojpeg_TJCompressor_encodeYUV___3IIIIIII_3BIII
|
||||||
@@ -292,7 +292,7 @@ JNIEXPORT void JNICALL Java_org_libjpegturbo_turbojpeg_TJCompressor_encodeYUV___
|
|||||||
if(tjPixelSize[pf]!=sizeof(jint))
|
if(tjPixelSize[pf]!=sizeof(jint))
|
||||||
_throw("Pixel format must be 32-bit when encoding from an integer buffer.");
|
_throw("Pixel format must be 32-bit when encoding from an integer buffer.");
|
||||||
|
|
||||||
return TJCompressor_encodeYUV(env, obj, src, sizeof(jint), x, y, width,
|
TJCompressor_encodeYUV(env, obj, src, sizeof(jint), x, y, width,
|
||||||
stride*sizeof(jint), height, pf, dst, pad, subsamp, flags);
|
stride*sizeof(jint), height, pf, dst, pad, subsamp, flags);
|
||||||
|
|
||||||
bailout:
|
bailout:
|
||||||
@@ -308,7 +308,7 @@ JNIEXPORT void JNICALL Java_org_libjpegturbo_turbojpeg_TJCompressor_encodeYUV___
|
|||||||
if(tjPixelSize[pf]!=sizeof(jint))
|
if(tjPixelSize[pf]!=sizeof(jint))
|
||||||
_throw("Pixel format must be 32-bit when encoding from an integer buffer.");
|
_throw("Pixel format must be 32-bit when encoding from an integer buffer.");
|
||||||
|
|
||||||
return TJCompressor_encodeYUV(env, obj, src, sizeof(jint), 0, 0, width,
|
TJCompressor_encodeYUV(env, obj, src, sizeof(jint), 0, 0, width,
|
||||||
stride*sizeof(jint), height, pf, dst, 4, subsamp, flags);
|
stride*sizeof(jint), height, pf, dst, 4, subsamp, flags);
|
||||||
|
|
||||||
bailout:
|
bailout:
|
||||||
@@ -340,7 +340,7 @@ JNIEXPORT void JNICALL Java_org_libjpegturbo_turbojpeg_TJDecompressor_init
|
|||||||
|
|
||||||
bailif0(cls=(*env)->GetObjectClass(env, obj));
|
bailif0(cls=(*env)->GetObjectClass(env, obj));
|
||||||
bailif0(fid=(*env)->GetFieldID(env, cls, "handle", "J"));
|
bailif0(fid=(*env)->GetFieldID(env, cls, "handle", "J"));
|
||||||
(*env)->SetLongField(env, obj, fid, (jlong)handle);
|
(*env)->SetLongField(env, obj, fid, (size_t)handle);
|
||||||
|
|
||||||
bailout:
|
bailout:
|
||||||
return;
|
return;
|
||||||
@@ -618,7 +618,7 @@ JNIEXPORT void JNICALL Java_org_libjpegturbo_turbojpeg_TJTransformer_init
|
|||||||
|
|
||||||
bailif0(cls=(*env)->GetObjectClass(env, obj));
|
bailif0(cls=(*env)->GetObjectClass(env, obj));
|
||||||
bailif0(fid=(*env)->GetFieldID(env, cls, "handle", "J"));
|
bailif0(fid=(*env)->GetFieldID(env, cls, "handle", "J"));
|
||||||
(*env)->SetLongField(env, obj, fid, (jlong)handle);
|
(*env)->SetLongField(env, obj, fid, (size_t)handle);
|
||||||
|
|
||||||
bailout:
|
bailout:
|
||||||
return;
|
return;
|
||||||
|
|||||||
Reference in New Issue
Block a user