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>2021-08-05 09:48:29 +0300
committerCampbell Barton <ideasman42@gmail.com>2021-08-05 09:54:34 +0300
commitf5acfd9c04697ee046297e1c7b36d0cef9e2440a (patch)
tree5fe8b83b7f08e6eba5d40a92e0ae30b22d12d0af /source/blender/blenkernel
parentd8582d966fe4ae46c82fcbb69d3d0ca62238ea93 (diff)
Cleanup: remove redundant parenthesis
Diffstat (limited to 'source/blender/blenkernel')
-rw-r--r--source/blender/blenkernel/intern/anim_sys.c4
-rw-r--r--source/blender/blenkernel/intern/autoexec.c2
-rw-r--r--source/blender/blenkernel/intern/fluid.c2
-rw-r--r--source/blender/blenkernel/intern/lib_override.c8
-rw-r--r--source/blender/blenkernel/intern/pbvh.c2
-rw-r--r--source/blender/blenkernel/intern/pointcache.c2
-rw-r--r--source/blender/blenkernel/intern/scene.c8
-rw-r--r--source/blender/blenkernel/intern/studiolight.c24
-rw-r--r--source/blender/blenkernel/intern/tracking_auto.c4
-rw-r--r--source/blender/blenkernel/intern/writeffmpeg.c2
10 files changed, 29 insertions, 29 deletions
diff --git a/source/blender/blenkernel/intern/anim_sys.c b/source/blender/blenkernel/intern/anim_sys.c
index fae75762cde..10a865880f2 100644
--- a/source/blender/blenkernel/intern/anim_sys.c
+++ b/source/blender/blenkernel/intern/anim_sys.c
@@ -426,7 +426,7 @@ bool BKE_animsys_rna_path_resolve(PointerRNA *ptr,
}
/* less than 1.0 evaluates to false, use epsilon to avoid float error */
-#define ANIMSYS_FLOAT_AS_BOOL(value) ((value) > ((1.0f - FLT_EPSILON)))
+#define ANIMSYS_FLOAT_AS_BOOL(value) ((value) > (1.0f - FLT_EPSILON))
bool BKE_animsys_read_from_rna_path(PathResolvedRNA *anim_rna, float *r_value)
{
@@ -2625,7 +2625,7 @@ static void animsys_create_action_track_strip(const AnimData *adt,
bAction *action = adt->action;
- if ((adt->flag & ADT_NLA_EDIT_ON)) {
+ if (adt->flag & ADT_NLA_EDIT_ON) {
action = adt->tmpact;
}
diff --git a/source/blender/blenkernel/intern/autoexec.c b/source/blender/blenkernel/intern/autoexec.c
index 07b096af941..3aec646b024 100644
--- a/source/blender/blenkernel/intern/autoexec.c
+++ b/source/blender/blenkernel/intern/autoexec.c
@@ -56,7 +56,7 @@ bool BKE_autoexec_match(const char *path)
if (path_cmp->path[0] == '\0') {
/* pass */
}
- else if ((path_cmp->flag & USER_PATHCMP_GLOB)) {
+ else if (path_cmp->flag & USER_PATHCMP_GLOB) {
if (fnmatch(path_cmp->path, path, fnmatch_flags) == 0) {
return true;
}
diff --git a/source/blender/blenkernel/intern/fluid.c b/source/blender/blenkernel/intern/fluid.c
index 92fd220549a..d33697d551e 100644
--- a/source/blender/blenkernel/intern/fluid.c
+++ b/source/blender/blenkernel/intern/fluid.c
@@ -4153,7 +4153,7 @@ static void BKE_fluid_modifier_process(
{
const int scene_framenr = (int)DEG_get_ctime(depsgraph);
- if ((fmd->type & MOD_FLUID_TYPE_FLOW)) {
+ if (fmd->type & MOD_FLUID_TYPE_FLOW) {
BKE_fluid_modifier_processFlow(fmd, depsgraph, scene, ob, me, scene_framenr);
}
else if (fmd->type & MOD_FLUID_TYPE_EFFEC) {
diff --git a/source/blender/blenkernel/intern/lib_override.c b/source/blender/blenkernel/intern/lib_override.c
index 38687fa47b2..072304566e5 100644
--- a/source/blender/blenkernel/intern/lib_override.c
+++ b/source/blender/blenkernel/intern/lib_override.c
@@ -571,7 +571,7 @@ static void lib_override_linked_group_tag_recursive(LibOverrideGroupTagData *dat
* would use one of those.
* NOTE: missing IDs (aka placeholders) are never overridden. */
if (ELEM(GS(to_id->name), ID_OB, ID_GR)) {
- if ((to_id->tag & LIB_TAG_MISSING)) {
+ if (to_id->tag & LIB_TAG_MISSING) {
to_id->tag |= missing_tag;
}
else {
@@ -604,7 +604,7 @@ static void lib_override_linked_group_tag(LibOverrideGroupTagData *data)
const bool is_resync = data->is_resync;
BLI_assert(!data->is_override);
- if ((id_root->tag & LIB_TAG_MISSING)) {
+ if (id_root->tag & LIB_TAG_MISSING) {
id_root->tag |= data->missing_tag;
}
else {
@@ -654,7 +654,7 @@ static void lib_override_linked_group_tag(LibOverrideGroupTagData *data)
if (instantiating_collection == NULL &&
instantiating_collection_override_candidate != NULL) {
- if ((instantiating_collection_override_candidate->id.tag & LIB_TAG_MISSING)) {
+ if (instantiating_collection_override_candidate->id.tag & LIB_TAG_MISSING) {
instantiating_collection_override_candidate->id.tag |= data->missing_tag;
}
else {
@@ -730,7 +730,7 @@ static void lib_override_overrides_group_tag(LibOverrideGroupTagData *data)
BLI_assert(ID_IS_OVERRIDE_LIBRARY_REAL(id_root));
BLI_assert(data->is_override);
- if ((id_root->override_library->reference->tag & LIB_TAG_MISSING)) {
+ if (id_root->override_library->reference->tag & LIB_TAG_MISSING) {
id_root->tag |= data->missing_tag;
}
else {
diff --git a/source/blender/blenkernel/intern/pbvh.c b/source/blender/blenkernel/intern/pbvh.c
index 461ffa7765e..ca1fada8c76 100644
--- a/source/blender/blenkernel/intern/pbvh.c
+++ b/source/blender/blenkernel/intern/pbvh.c
@@ -1026,7 +1026,7 @@ static void pbvh_update_normals_accum_task_cb(void *__restrict userdata,
PBVHNode *node = data->nodes[n];
float(*vnors)[3] = data->vnors;
- if ((node->flag & PBVH_UpdateNormals)) {
+ if (node->flag & PBVH_UpdateNormals) {
unsigned int mpoly_prev = UINT_MAX;
float fn[3];
diff --git a/source/blender/blenkernel/intern/pointcache.c b/source/blender/blenkernel/intern/pointcache.c
index a6adff35a7f..57225872c7e 100644
--- a/source/blender/blenkernel/intern/pointcache.c
+++ b/source/blender/blenkernel/intern/pointcache.c
@@ -3369,7 +3369,7 @@ void BKE_ptcache_bake(PTCacheBaker *baker)
}
/* NOTE: breaking baking should leave calculated frames in cache, not clear it */
- if ((cancel || G.is_break)) {
+ if (cancel || G.is_break) {
break;
}
diff --git a/source/blender/blenkernel/intern/scene.c b/source/blender/blenkernel/intern/scene.c
index 6d60f5e91b4..9dab276af95 100644
--- a/source/blender/blenkernel/intern/scene.c
+++ b/source/blender/blenkernel/intern/scene.c
@@ -2178,7 +2178,7 @@ int BKE_scene_base_iter_next(
/* exception: empty scene layer */
while ((*scene)->set) {
(*scene) = (*scene)->set;
- ViewLayer *view_layer_set = BKE_view_layer_default_render((*scene));
+ ViewLayer *view_layer_set = BKE_view_layer_default_render(*scene);
if (view_layer_set->object_bases.first) {
*base = view_layer_set->object_bases.first;
*ob = (*base)->object;
@@ -2199,7 +2199,7 @@ int BKE_scene_base_iter_next(
/* (*scene) is finished, now do the set */
while ((*scene)->set) {
(*scene) = (*scene)->set;
- ViewLayer *view_layer_set = BKE_view_layer_default_render((*scene));
+ ViewLayer *view_layer_set = BKE_view_layer_default_render(*scene);
if (view_layer_set->object_bases.first) {
*base = view_layer_set->object_bases.first;
*ob = (*base)->object;
@@ -2898,7 +2898,7 @@ Base *_setlooper_base_step(Scene **sce_iter, ViewLayer *view_layer, Base *base)
next_set:
/* Reached the end, get the next base in the set. */
while ((*sce_iter = (*sce_iter)->set)) {
- ViewLayer *view_layer_set = BKE_view_layer_default_render((*sce_iter));
+ ViewLayer *view_layer_set = BKE_view_layer_default_render(*sce_iter);
base = (Base *)view_layer_set->object_bases.first;
if (base) {
@@ -3118,7 +3118,7 @@ bool BKE_scene_multiview_is_render_view_active(const RenderData *rd, const Scene
return false;
}
- if ((srv->viewflag & SCE_VIEW_DISABLE)) {
+ if (srv->viewflag & SCE_VIEW_DISABLE) {
return false;
}
diff --git a/source/blender/blenkernel/intern/studiolight.c b/source/blender/blenkernel/intern/studiolight.c
index dc5162f201e..95436372a65 100644
--- a/source/blender/blenkernel/intern/studiolight.c
+++ b/source/blender/blenkernel/intern/studiolight.c
@@ -475,7 +475,7 @@ static void studiolight_load_equirect_image(StudioLight *sl)
NULL, (failed || (specular_ibuf == NULL)) ? magenta : black, 1, 1, 4);
}
- if ((sl->flag & STUDIOLIGHT_TYPE_MATCAP)) {
+ if (sl->flag & STUDIOLIGHT_TYPE_MATCAP) {
sl->matcap_diffuse.ibuf = diffuse_ibuf;
sl->matcap_specular.ibuf = specular_ibuf;
if (specular_ibuf != NULL) {
@@ -1192,7 +1192,7 @@ static void studiolight_add_files_from_datafolder(const int folder_id,
uint totfile = BLI_filelist_dir_contents(folder, &dir);
int i;
for (i = 0; i < totfile; i++) {
- if ((dir[i].type & S_IFREG)) {
+ if (dir[i].type & S_IFREG) {
studiolight_add_file(dir[i].path, flag);
}
}
@@ -1473,7 +1473,7 @@ struct StudioLight *BKE_studiolight_find_default(int flag)
}
LISTBASE_FOREACH (StudioLight *, sl, &studiolights) {
- if ((sl->flag & flag)) {
+ if (sl->flag & flag) {
return sl;
}
}
@@ -1484,7 +1484,7 @@ struct StudioLight *BKE_studiolight_find(const char *name, int flag)
{
LISTBASE_FOREACH (StudioLight *, sl, &studiolights) {
if (STREQLEN(sl->name, name, FILE_MAXFILE)) {
- if ((sl->flag & flag)) {
+ if (sl->flag & flag) {
return sl;
}
@@ -1542,32 +1542,32 @@ void BKE_studiolight_ensure_flag(StudioLight *sl, int flag)
return;
}
- if ((flag & STUDIOLIGHT_EXTERNAL_IMAGE_LOADED)) {
+ if (flag & STUDIOLIGHT_EXTERNAL_IMAGE_LOADED) {
studiolight_load_equirect_image(sl);
}
- if ((flag & STUDIOLIGHT_RADIANCE_BUFFERS_CALCULATED)) {
+ if (flag & STUDIOLIGHT_RADIANCE_BUFFERS_CALCULATED) {
studiolight_calculate_radiance_cubemap_buffers(sl);
}
- if ((flag & STUDIOLIGHT_SPHERICAL_HARMONICS_COEFFICIENTS_CALCULATED)) {
+ if (flag & STUDIOLIGHT_SPHERICAL_HARMONICS_COEFFICIENTS_CALCULATED) {
if (!studiolight_load_spherical_harmonics_coefficients(sl)) {
studiolight_calculate_diffuse_light(sl);
}
}
- if ((flag & STUDIOLIGHT_EQUIRECT_RADIANCE_GPUTEXTURE)) {
+ if (flag & STUDIOLIGHT_EQUIRECT_RADIANCE_GPUTEXTURE) {
studiolight_create_equirect_radiance_gputexture(sl);
}
- if ((flag & STUDIOLIGHT_EQUIRECT_IRRADIANCE_GPUTEXTURE)) {
+ if (flag & STUDIOLIGHT_EQUIRECT_IRRADIANCE_GPUTEXTURE) {
studiolight_create_equirect_irradiance_gputexture(sl);
}
- if ((flag & STUDIOLIGHT_EQUIRECT_IRRADIANCE_IMAGE_CALCULATED)) {
+ if (flag & STUDIOLIGHT_EQUIRECT_IRRADIANCE_IMAGE_CALCULATED) {
if (!studiolight_load_irradiance_equirect_image(sl)) {
studiolight_calculate_irradiance_equirect_image(sl);
}
}
- if ((flag & STUDIOLIGHT_MATCAP_DIFFUSE_GPUTEXTURE)) {
+ if (flag & STUDIOLIGHT_MATCAP_DIFFUSE_GPUTEXTURE) {
studiolight_create_matcap_diffuse_gputexture(sl);
}
- if ((flag & STUDIOLIGHT_MATCAP_SPECULAR_GPUTEXTURE)) {
+ if (flag & STUDIOLIGHT_MATCAP_SPECULAR_GPUTEXTURE) {
studiolight_create_matcap_specular_gputexture(sl);
}
}
diff --git a/source/blender/blenkernel/intern/tracking_auto.c b/source/blender/blenkernel/intern/tracking_auto.c
index f107fc4d6bc..92ff0911cf3 100644
--- a/source/blender/blenkernel/intern/tracking_auto.c
+++ b/source/blender/blenkernel/intern/tracking_auto.c
@@ -322,7 +322,7 @@ static bool tracking_check_marker_margin(const libmv_Marker *libmv_marker,
static bool autotrack_is_marker_usable(const MovieTrackingMarker *marker)
{
- if ((marker->flag & MARKER_DISABLED)) {
+ if (marker->flag & MARKER_DISABLED) {
return false;
}
return true;
@@ -797,7 +797,7 @@ void BKE_autotrack_context_finish(AutoTrackContext *context)
clip, context->start_scene_frame);
LISTBASE_FOREACH (MovieTrackingPlaneTrack *, plane_track, plane_tracks_base) {
- if ((plane_track->flag & PLANE_TRACK_AUTOKEY)) {
+ if (plane_track->flag & PLANE_TRACK_AUTOKEY) {
continue;
}
for (int track_index = 0; track_index < context->num_all_tracks; track_index++) {
diff --git a/source/blender/blenkernel/intern/writeffmpeg.c b/source/blender/blenkernel/intern/writeffmpeg.c
index 9b3103a638b..32057709c38 100644
--- a/source/blender/blenkernel/intern/writeffmpeg.c
+++ b/source/blender/blenkernel/intern/writeffmpeg.c
@@ -741,7 +741,7 @@ static AVStream *alloc_video_stream(FFMpegContext *context,
}
}
- if ((of->oformat->flags & AVFMT_GLOBALHEADER)) {
+ if (of->oformat->flags & AVFMT_GLOBALHEADER) {
PRINT("Using global header\n");
c->flags |= AV_CODEC_FLAG_GLOBAL_HEADER;
}