diff options
author | Campbell Barton <ideasman42@gmail.com> | 2015-04-20 16:37:04 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2015-04-20 18:50:20 +0300 |
commit | 57d9badc2100001df3bb60c44f9da68595bac0f5 (patch) | |
tree | ec3fe4f3f7e020b8814a69e123a0409d63cbb72e /source/blender/render/intern | |
parent | 6298632bfa00b90198bd76b82aa249985530e4fa (diff) |
Cleanup: use bool /w flag checks
Diffstat (limited to 'source/blender/render/intern')
-rw-r--r-- | source/blender/render/intern/source/multires_bake.c | 10 | ||||
-rw-r--r-- | source/blender/render/intern/source/texture_ocean.c | 2 |
2 files changed, 8 insertions, 4 deletions
diff --git a/source/blender/render/intern/source/multires_bake.c b/source/blender/render/intern/source/multires_bake.c index 6ba85ea5329..de57d4e7ba6 100644 --- a/source/blender/render/intern/source/multires_bake.c +++ b/source/blender/render/intern/source/multires_bake.c @@ -127,9 +127,13 @@ typedef struct { static void multiresbake_get_normal(const MResolvePixelData *data, float norm[],const int face_num, const int vert_index) { - unsigned int indices[] = {data->mface[face_num].v1, data->mface[face_num].v2, - data->mface[face_num].v3, data->mface[face_num].v4}; - const int smoothnormal = (data->mface[face_num].flag & ME_SMOOTH); + const unsigned int indices[] = { + data->mface[face_num].v1, + data->mface[face_num].v2, + data->mface[face_num].v3, + data->mface[face_num].v4, + }; + const bool smoothnormal = (data->mface[face_num].flag & ME_SMOOTH) != 0; if (!smoothnormal) { /* flat */ if (data->precomputed_normals) { diff --git a/source/blender/render/intern/source/texture_ocean.c b/source/blender/render/intern/source/texture_ocean.c index 5261374b34d..a932123243d 100644 --- a/source/blender/render/intern/source/texture_ocean.c +++ b/source/blender/render/intern/source/texture_ocean.c @@ -73,7 +73,7 @@ int ocean_texture(Tex *tex, const float texvec[2], TexResult *texres) return 0; } else { - const int do_normals = (omd->flag & MOD_OCEAN_GENERATE_NORMALS); + const bool do_normals = (omd->flag & MOD_OCEAN_GENERATE_NORMALS) != 0; int cfra = R.r.cfra; int retval = TEX_INT; |