Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2010-10-17 10:38:56 +0400
committerCampbell Barton <ideasman42@gmail.com>2010-10-17 10:38:56 +0400
commit30b79ddcc6e2737add3a7ebd49b167c1776e4087 (patch)
tree8fe9bdba84b7b4cbf9f9ad3b55af892e8eed13bf /source/blender/imbuf
parent28e144db920699a13e6cd196ac91f13e11b2877c (diff)
- fixed remaining unused warnings.
- omit render code from this warning (cmake only), until render branch is merged. - moved -Wunused-parameter warning to apply to all C code in blender (not just ./source/blender), (cmake only).
Diffstat (limited to 'source/blender/imbuf')
-rw-r--r--source/blender/imbuf/intern/anim.c9
-rw-r--r--source/blender/imbuf/intern/bmp.c4
-rw-r--r--source/blender/imbuf/intern/cineon/cineon_dpx.c2
-rw-r--r--source/blender/imbuf/intern/cineon/cineonlib.c4
-rw-r--r--source/blender/imbuf/intern/cineon/dpxlib.c9
-rw-r--r--source/blender/imbuf/intern/filetype.c2
-rw-r--r--source/blender/imbuf/intern/iris.c6
-rw-r--r--source/blender/imbuf/intern/jp2.c2
-rw-r--r--source/blender/imbuf/intern/jpeg.c2
-rw-r--r--source/blender/imbuf/intern/openexr/openexr_multi.h23
-rw-r--r--source/blender/imbuf/intern/radiance_hdr.c2
-rw-r--r--source/blender/imbuf/intern/targa.c2
12 files changed, 50 insertions, 17 deletions
diff --git a/source/blender/imbuf/intern/anim.c b/source/blender/imbuf/intern/anim.c
index 57d65bc6761..8df0d69bcfa 100644
--- a/source/blender/imbuf/intern/anim.c
+++ b/source/blender/imbuf/intern/anim.c
@@ -63,6 +63,7 @@
#include "MEM_guardedalloc.h"
#include "DNA_userdef_types.h"
+#include "BKE_utildefines.h"
#include "BKE_global.h"
#include "BKE_depsgraph.h"
@@ -214,14 +215,14 @@ int ismovie(char *name) {
#else
-int ismovie(char *name) {
+int ismovie(char *UNUSED(name)) {
return 0;
}
/* never called, just keep the linker happy */
-static int startmovie(struct anim * anim) { return 1; }
-static ImBuf * movie_fetchibuf(struct anim * anim, int position) { return NULL; }
-static void free_anim_movie(struct anim * anim) { ; }
+static int startmovie(struct anim *UNUSED(anim)) { return 1; }
+static ImBuf * movie_fetchibuf(struct anim *UNUSED(anim), int UNUSED(position)) { return NULL; }
+static void free_anim_movie(struct anim *UNUSED(anim)) { ; }
#endif
diff --git a/source/blender/imbuf/intern/bmp.c b/source/blender/imbuf/intern/bmp.c
index 4c7cf669d18..10dc23b1ad2 100644
--- a/source/blender/imbuf/intern/bmp.c
+++ b/source/blender/imbuf/intern/bmp.c
@@ -108,6 +108,8 @@ struct ImBuf *imb_bmp_decode(unsigned char *mem, size_t size, int flags)
int x, y, depth, skip, i;
unsigned char *bmp, *rect;
unsigned short col;
+
+ (void)size; /* unused */
if (checkbmp(mem) == 0) return(0);
@@ -199,6 +201,8 @@ int imb_savebmp(struct ImBuf *ibuf, char *name, int flags) {
int bytesize, extrabytes, x, y, t, ptr;
uchar *data;
FILE *ofile;
+
+ (void)flags; /* unused */
extrabytes = (4 - ibuf->x*3 % 4) % 4;
bytesize = (ibuf->x * 3 + extrabytes) * ibuf->y;
diff --git a/source/blender/imbuf/intern/cineon/cineon_dpx.c b/source/blender/imbuf/intern/cineon/cineon_dpx.c
index 0eee1bd082a..7a5a3fb011b 100644
--- a/source/blender/imbuf/intern/cineon/cineon_dpx.c
+++ b/source/blender/imbuf/intern/cineon/cineon_dpx.c
@@ -125,6 +125,8 @@ static int imb_save_dpx_cineon(ImBuf *buf, char *filename, int use_cineon, int f
int i, j;
int index;
float *fline;
+
+ (void)flags; /* unused */
cineon_conversion_parameters(&conversion);
diff --git a/source/blender/imbuf/intern/cineon/cineonlib.c b/source/blender/imbuf/intern/cineon/cineonlib.c
index 9c9156a4dd9..a2a0fae526d 100644
--- a/source/blender/imbuf/intern/cineon/cineonlib.c
+++ b/source/blender/imbuf/intern/cineon/cineonlib.c
@@ -185,6 +185,8 @@ dumpCineonImageInfo(CineonImageInformation* imageInfo) {
static void
fillCineonFormatInfo(CineonFile* cineon, CineonFormatInformation* formatInfo) {
+ (void)cineon; /* unused */
+
formatInfo->interleave = 0;
formatInfo->packing = 5;
formatInfo->signage = 0;
@@ -238,6 +240,8 @@ dumpCineonFormatInfo(CineonFormatInformation* formatInfo) {
static void
fillCineonOriginationInfo(CineonFile* cineon,
CineonOriginationInformation* originInfo, CineonFileInformation* fileInfo) {
+
+ (void)cineon; /* unused */
originInfo->x_offset = htonl(0);
originInfo->y_offset = htonl(0);
diff --git a/source/blender/imbuf/intern/cineon/dpxlib.c b/source/blender/imbuf/intern/cineon/dpxlib.c
index 365d56939ed..ade69b4d7c0 100644
--- a/source/blender/imbuf/intern/cineon/dpxlib.c
+++ b/source/blender/imbuf/intern/cineon/dpxlib.c
@@ -39,6 +39,8 @@
static void
fillDpxChannelInfo(DpxFile* dpx, DpxChannelInformation* chan, int des) {
+ (void)dpx; /* unused */
+
chan->signage = 0;
chan->ref_low_data = htonl(0);
chan->ref_low_quantity = htonf(0.0);
@@ -160,7 +162,12 @@ dumpDpxImageInfo(DpxImageInformation* imageInfo) {
static void
fillDpxOriginationInfo(
- DpxFile* dpx, DpxOriginationInformation* originInfo, DpxFileInformation* fileInfo) {
+ DpxFile* dpx, DpxOriginationInformation* originInfo, DpxFileInformation* fileInfo)
+{
+ /* unused */
+ (void)dpx;
+ (void)originInfo;
+ (void)fileInfo;
}
static void
diff --git a/source/blender/imbuf/intern/filetype.c b/source/blender/imbuf/intern/filetype.c
index fb5d2f2e4d7..0702fbe3907 100644
--- a/source/blender/imbuf/intern/filetype.c
+++ b/source/blender/imbuf/intern/filetype.c
@@ -45,7 +45,7 @@ static int imb_ftype_default(ImFileType *type, ImBuf *ibuf) { return (ibuf->ftyp
#if defined(__APPLE__) && defined(IMBUF_COCOA)
static int imb_ftype_cocoa(ImFileType *type, ImBuf *ibuf) { return (ibuf->ftype & TIF); }
#endif
-static int imb_ftype_iris(ImFileType *type, ImBuf *ibuf) { return (ibuf->ftype == IMAGIC); }
+static int imb_ftype_iris(ImFileType *type, ImBuf *ibuf) { (void)type; return (ibuf->ftype == IMAGIC); }
#ifdef WITH_QUICKTIME
static int imb_ftype_quicktime(ImFileType *type, ImBuf *ibuf) { return 0; } // XXX
#endif
diff --git a/source/blender/imbuf/intern/iris.c b/source/blender/imbuf/intern/iris.c
index 9037285a1c5..71ba9b06cad 100644
--- a/source/blender/imbuf/intern/iris.c
+++ b/source/blender/imbuf/intern/iris.c
@@ -123,7 +123,8 @@ static int file_offset;
static unsigned short getshort(FILE *inf)
{
unsigned char * buf;
-
+ (void)inf; /* unused */
+
buf = file_data + file_offset;
file_offset += 2;
@@ -133,6 +134,7 @@ static unsigned short getshort(FILE *inf)
static unsigned int getlong(FILE *inf)
{
unsigned char * buf;
+ (void)inf; /* unused */
buf = file_data + file_offset;
file_offset += 4;
@@ -258,6 +260,8 @@ struct ImBuf *imb_loadiris(unsigned char *mem, size_t size, int flags)
int bpp, rle, cur, badorder;
ImBuf * ibuf;
+ (void)size; /* unused */
+
if(!imb_is_a_iris(mem)) return NULL;
/*printf("new iris\n");*/
diff --git a/source/blender/imbuf/intern/jp2.c b/source/blender/imbuf/intern/jp2.c
index 5e7ef199500..0403d0044f5 100644
--- a/source/blender/imbuf/intern/jp2.c
+++ b/source/blender/imbuf/intern/jp2.c
@@ -670,6 +670,8 @@ int imb_savejp2(struct ImBuf *ibuf, char *name, int flags) {
opj_event_mgr_t event_mgr; /* event manager */
opj_image_t *image = NULL;
+ (void)flags; /* unused */
+
/*
configure the event callbacks (not required)
setting of each callback is optionnal
diff --git a/source/blender/imbuf/intern/jpeg.c b/source/blender/imbuf/intern/jpeg.c
index e020a5fa8fd..e7737e68fce 100644
--- a/source/blender/imbuf/intern/jpeg.c
+++ b/source/blender/imbuf/intern/jpeg.c
@@ -132,6 +132,7 @@ typedef my_source_mgr * my_src_ptr;
static void init_source(j_decompress_ptr cinfo)
{
+ (void)cinfo; /* unused */
}
@@ -165,6 +166,7 @@ static void skip_input_data(j_decompress_ptr cinfo, long num_bytes)
static void term_source(j_decompress_ptr cinfo)
{
+ (void)cinfo; /* unused */
}
static void memory_source(j_decompress_ptr cinfo, unsigned char *buffer, size_t size)
diff --git a/source/blender/imbuf/intern/openexr/openexr_multi.h b/source/blender/imbuf/intern/openexr/openexr_multi.h
index 3f80e5577a8..e96b52e121d 100644
--- a/source/blender/imbuf/intern/openexr/openexr_multi.h
+++ b/source/blender/imbuf/intern/openexr/openexr_multi.h
@@ -67,24 +67,27 @@ void IMB_exr_close (void *handle);
/* ugly... but we only use it on pipeline.c, render module, now */
void * IMB_exr_get_handle (void) {return NULL;}
-void IMB_exr_add_channel (void *handle, const char *layname, const char *channame, int xstride, int ystride, float *rect) {}
+void IMB_exr_add_channel (void *handle, const char *layname, const char *channame, int xstride, int ystride, float *rect) { (void)handle; (void)layname; (void)channame; (void)xstride; (void)ystride; (void)rect; }
-int IMB_exr_begin_read (void *handle, char *filename, int *width, int *height) {return 0;}
+int IMB_exr_begin_read (void *handle, char *filename, int *width, int *height) { (void)handle; (void)filename; (void)width; (void)height; return 0;}
void IMB_exr_begin_write (void *handle, char *filename, int width, int height, int compress) { (void)handle; (void)filename; (void)width; (void)height; (void)compress; }
-void IMB_exrtile_begin_write (void *handle, char *filename, int mipmap, int width, int height, int tilex, int tiley) {}
+void IMB_exrtile_begin_write (void *handle, char *filename, int mipmap, int width, int height, int tilex, int tiley) { (void)handle; (void)filename; (void)mipmap; (void)width; (void)height; (void)tilex; (void)tiley; }
-void IMB_exr_set_channel (void *handle, char *layname, char *channame, int xstride, int ystride, float *rect) {}
+void IMB_exr_set_channel (void *handle, char *layname, char *channame, int xstride, int ystride, float *rect) { (void)handle; (void)layname; (void)channame; (void)xstride; (void)ystride; (void)rect; }
-void IMB_exr_read_channels (void *handle) {}
-void IMB_exr_write_channels (void *handle) {}
-void IMB_exrtile_write_channels (void *handle, int partx, int party, int level) {}
-void IMB_exrtile_clear_channels (void *handle) {}
+void IMB_exr_read_channels (void *handle) { (void)handle; }
+void IMB_exr_write_channels (void *handle) { (void)handle; }
+void IMB_exrtile_write_channels (void *handle, int partx, int party, int level) { (void)handle; (void)partx; (void)party; (void)level; }
+void IMB_exrtile_clear_channels (void *handle) { (void)handle; }
void IMB_exr_multilayer_convert (void *handle, void *base,
void * (*addlayer)(void *base, char *str),
- void (*addpass)(void *base, void *lay, char *str, float *rect, int totchan, char *chan_id)) {}
+ void (*addpass)(void *base, void *lay, char *str, float *rect, int totchan, char *chan_id))
+ {
+ (void)handle; (void)base; (void)addlayer; (void)addpass;
+ }
-void IMB_exr_close (void *handle) {}
+void IMB_exr_close (void *handle) { (void)handle; }
#endif
diff --git a/source/blender/imbuf/intern/radiance_hdr.c b/source/blender/imbuf/intern/radiance_hdr.c
index 385124cd717..b356f56ab74 100644
--- a/source/blender/imbuf/intern/radiance_hdr.c
+++ b/source/blender/imbuf/intern/radiance_hdr.c
@@ -340,6 +340,8 @@ int imb_savehdr(struct ImBuf *ibuf, char *name, int flags)
int y, width=ibuf->x, height=ibuf->y;
unsigned char *cp= NULL;
+ (void)flags; /* unused */
+
if (file==NULL) return 0;
writeHeader(file, width, height);
diff --git a/source/blender/imbuf/intern/targa.c b/source/blender/imbuf/intern/targa.c
index e50e445034e..89a69242a46 100644
--- a/source/blender/imbuf/intern/targa.c
+++ b/source/blender/imbuf/intern/targa.c
@@ -238,6 +238,8 @@ int imb_savetarga(struct ImBuf * ibuf, char *name, int flags)
char buf[20];
FILE *fildes;
short ok = 0;
+
+ (void)flags; /* unused */
if (ibuf == 0) return (0);
if (ibuf->rect == 0) return (0);