ax203: ax206_compress_jpeg can use only "defined(HAVE_LIBGD) && defined(HAVE_LIBJPEG)"

This commit is contained in:
kou1okada
2016-10-05 11:14:00 +09:00
parent 6ac3133632
commit 9e596db121
2 changed files with 9 additions and 0 deletions

View File

@@ -1220,10 +1220,14 @@ ax203_encode_image(Camera *camera, int **src, char *dest, int dest_size)
camera->pl->height);
return size;
case AX206_COMPRESSION_JPEG:
#if defined(HAVE_LIBGD) && defined(HAVE_LIBJPEG)
return ax206_compress_jpeg (camera, src,
(uint8_t *)dest, dest_size,
camera->pl->width,
camera->pl->height);
#else
return GP_ERROR_NOT_SUPPORTED;
#endif
case AX3003_COMPRESSION_JPEG:
#ifdef HAVE_LIBJPEG
cinfo.err = jpeg_std_error (&jcerr);

View File

@@ -195,8 +195,13 @@ ax203_decode_yuv_delta(char *src, int **dest, int width, int height);
void
ax203_encode_yuv_delta(int **src, char *dest, int width, int height);
#if defined(HAVE_LIBGD) && defined(HAVE_LIBJPEG)
int
ax206_compress_jpeg(Camera *camera, int **in, uint8_t *outbuf, int out_size,
int width, int height);
#endif
#endif