code cleanup:
- remove unused defines. - quiet some shadow warnings. - bevel, ifdef out some asserts that are too common. - style
This commit is contained in:
@@ -52,14 +52,14 @@
|
||||
|
||||
ExceptionID SceneInvalid, CameraInvalid, ObserverInvalid;
|
||||
ExceptionID MirrorInvalid, MirrorSizeInvalid, MirrorNormalInvalid, MirrorHorizontal, MirrorTooSmall;
|
||||
ExpDesc SceneInvalidDesc (SceneInvalid, "Scene object is invalid");
|
||||
ExpDesc CameraInvalidDesc (CameraInvalid, "Camera object is invalid");
|
||||
ExpDesc ObserverInvalidDesc (ObserverInvalid, "Observer object is invalid");
|
||||
ExpDesc MirrorInvalidDesc (MirrorInvalid, "Mirror object is invalid");
|
||||
ExpDesc MirrorSizeInvalidDesc (MirrorSizeInvalid, "Mirror has no vertex or no size");
|
||||
ExpDesc MirrorNormalInvalidDesc (MirrorNormalInvalid, "Cannot determine mirror plane");
|
||||
ExpDesc MirrorHorizontalDesc (MirrorHorizontal, "Mirror is horizontal in local space");
|
||||
ExpDesc MirrorTooSmallDesc (MirrorTooSmall, "Mirror is too small");
|
||||
ExpDesc SceneInvalidDesc(SceneInvalid, "Scene object is invalid");
|
||||
ExpDesc CameraInvalidDesc(CameraInvalid, "Camera object is invalid");
|
||||
ExpDesc ObserverInvalidDesc(ObserverInvalid, "Observer object is invalid");
|
||||
ExpDesc MirrorInvalidDesc(MirrorInvalid, "Mirror object is invalid");
|
||||
ExpDesc MirrorSizeInvalidDesc(MirrorSizeInvalid, "Mirror has no vertex or no size");
|
||||
ExpDesc MirrorNormalInvalidDesc(MirrorNormalInvalid, "Cannot determine mirror plane");
|
||||
ExpDesc MirrorHorizontalDesc(MirrorHorizontal, "Mirror is horizontal in local space");
|
||||
ExpDesc MirrorTooSmallDesc(MirrorTooSmall, "Mirror is too small");
|
||||
|
||||
// constructor
|
||||
ImageRender::ImageRender (KX_Scene * scene, KX_Camera * camera) :
|
||||
@@ -294,7 +294,7 @@ BlendType<KX_Camera> cameraType ("KX_Camera");
|
||||
|
||||
|
||||
// object initialization
|
||||
static int ImageRender_init (PyObject *pySelf, PyObject *args, PyObject *kwds)
|
||||
static int ImageRender_init(PyObject *pySelf, PyObject *args, PyObject *kwds)
|
||||
{
|
||||
// parameters - scene object
|
||||
PyObject *scene;
|
||||
@@ -347,7 +347,7 @@ static PyObject *getBackground (PyImage *self, void *closure)
|
||||
}
|
||||
|
||||
// set color
|
||||
static int setBackground (PyImage *self, PyObject *value, void *closure)
|
||||
static int setBackground(PyImage *self, PyObject *value, void *closure)
|
||||
{
|
||||
// check validity of parameter
|
||||
if (value == NULL || !PySequence_Check(value) || PySequence_Size(value) != 4
|
||||
@@ -441,7 +441,7 @@ PyTypeObject ImageRenderType =
|
||||
};
|
||||
|
||||
// object initialization
|
||||
static int ImageMirror_init (PyObject *pySelf, PyObject *args, PyObject *kwds)
|
||||
static int ImageMirror_init(PyObject *pySelf, PyObject *args, PyObject *kwds)
|
||||
{
|
||||
// parameters - scene object
|
||||
PyObject *scene;
|
||||
@@ -523,7 +523,7 @@ static PyObject *getClip (PyImage *self, void *closure)
|
||||
}
|
||||
|
||||
// set clip
|
||||
static int setClip (PyImage *self, PyObject *value, void *closure)
|
||||
static int setClip(PyImage *self, PyObject *value, void *closure)
|
||||
{
|
||||
// check validity of parameter
|
||||
double clip;
|
||||
|
||||
Reference in New Issue
Block a user