diff options
author | Joseph Gilbert <ascotan@gmail.com> | 2006-04-24 19:09:07 +0400 |
---|---|---|
committer | Joseph Gilbert <ascotan@gmail.com> | 2006-04-24 19:09:07 +0400 |
commit | 87949e5c670e8b761ab6b86c0dff2fa5feb4295e (patch) | |
tree | 795ba502cfdfec00853e9b6cab146ca0ccb9332b /source/blender/python/api2_2x/Ipo.c | |
parent | 4bfb0e30ec1ac6b0188b1abde14af28c9198fff4 (diff) |
warnings cleanup for the python project on windows
Diffstat (limited to 'source/blender/python/api2_2x/Ipo.c')
-rw-r--r-- | source/blender/python/api2_2x/Ipo.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/source/blender/python/api2_2x/Ipo.c b/source/blender/python/api2_2x/Ipo.c index 1de2ad0806a..380d9bc2923 100644 --- a/source/blender/python/api2_2x/Ipo.c +++ b/source/blender/python/api2_2x/Ipo.c @@ -533,7 +533,7 @@ static short lookup_curve_name( char *str, int blocktype, int channel ) else { int param = (short)*adrcodes & ~MA_MAP1; param |= texchannel_to_adrcode( channel ); - return param; + return (short)param; } } ++adrcodes; @@ -630,13 +630,13 @@ static short lookup_curve_adrcode( int code, int blocktype, int channel ) /* if not a texture channel, just return the adrcode */ if( channel == -1 || *adrcodes < MA_MAP1 ) - return *adrcodes; + return (short)*adrcodes; /* otherwise adjust adrcode to include current channel */ else { int param = *adrcodes & ~MA_MAP1; param |= texchannel_to_adrcode( channel ); - return param; + return (short)param; } } ++adrcodes; @@ -1057,7 +1057,7 @@ static PyObject *Ipo_getCurveNames( BPy_Ipo * self ) PyObject *dict; int *vals = NULL; char name[32]; - PyObject *attr; + PyObject *attr = Py_None; /* determine what type of Ipo we are */ @@ -1163,7 +1163,7 @@ static PyObject *Ipo_getCurveNames( BPy_Ipo * self ) char *ptr = name+3; strcpy( name+3, lookup_name( *vals ) ); while( *ptr ) { - *ptr = toupper( *ptr ); + *ptr = (char)toupper( *ptr ); ++ptr; } PyConstant_Insert( (BPy_constant *)attr, name, @@ -1175,8 +1175,8 @@ static PyObject *Ipo_getCurveNames( BPy_Ipo * self ) void generate_curveconsts( PyObject* module ) { - namefunc lookup_name; - int size; + namefunc lookup_name = NULL; + int size = 0; int *vals = NULL; char name[32]; @@ -1253,7 +1253,7 @@ void generate_curveconsts( PyObject* module ) char *ptr = name+3; strcpy( name+3, lookup_name( *vals ) ); while( *ptr ) { - *ptr = toupper( *ptr ); + *ptr = (char)toupper( *ptr ); ++ptr; } PyModule_AddIntConstant( module, name, *vals ); @@ -1498,8 +1498,8 @@ static int Ipo_setIpoCurveByName( BPy_Ipo * self, PyObject * key, if( !flt || !val ) goto AttrError; - time = PyFloat_AS_DOUBLE( flt ); - curval = PyFloat_AS_DOUBLE( val ); + time = (float)PyFloat_AS_DOUBLE( flt ); + curval = (float)PyFloat_AS_DOUBLE( val ); Py_DECREF( flt ); Py_DECREF( val ); |