[Bf-blender-cvs] [9df1e540793] blender2.8: Cleanup: style
Campbell Barton
noreply at git.blender.org
Thu Jul 19 08:07:11 CEST 2018
Commit: 9df1e54079344ed4e2becef9e57cf1b925b46dff
Author: Campbell Barton
Date: Thu Jul 19 16:06:37 2018 +1000
Branches: blender2.8
https://developer.blender.org/rB9df1e54079344ed4e2becef9e57cf1b925b46dff
Cleanup: style
===================================================================
M release/scripts/modules/rna_prop_ui.py
M release/scripts/startup/bl_operators/wm.py
M release/scripts/startup/bl_ui/properties_physics_common.py
M release/scripts/startup/bl_ui/properties_scene.py
M source/blender/blenkernel/intern/subdiv_converter.h
M source/blender/blenkernel/intern/subdiv_mesh.c
M source/blender/blenlib/intern/hash_mm3.c
M source/blender/compositor/nodes/COM_CryptomatteNode.cpp
M source/blender/compositor/operations/COM_CryptomatteOperation.cpp
M source/blender/depsgraph/DEG_depsgraph.h
M source/blender/depsgraph/intern/builder/deg_builder_map.cc
M source/blender/depsgraph/intern/builder/deg_builder_nodes.h
M source/blender/draw/engines/workbench/workbench_data.c
M source/blender/draw/engines/workbench/workbench_volume.c
M source/blender/draw/intern/draw_cache.c
M source/blender/editors/render/render_preview.c
M source/blender/gpu/GPU_common.h
M source/blender/gpu/intern/gpu_attr_binding.c
M source/blender/gpu/intern/gpu_attr_binding_private.h
M source/blender/gpu/intern/gpu_batch_private.h
M source/blender/gpu/intern/gpu_buffer_id.cpp
M source/blender/gpu/intern/gpu_immediate.c
M source/blender/gpu/intern/gpu_immediate_util.c
M source/blender/gpu/intern/gpu_shader_interface.c
M source/blender/gpu/intern/gpu_vertex_array_id.cpp
M source/blender/gpu/intern/gpu_vertex_format.c
M source/blender/gpu/intern/gpu_vertex_format_private.h
M source/blender/makesrna/intern/rna_nodetree.c
M source/blender/nodes/composite/nodes/node_composite_cryptomatte.c
M source/blender/nodes/shader/nodes/node_shader_bsdf_hair_principled.c
M source/blender/python/gpu/gpu_py_types.c
===================================================================
diff --git a/release/scripts/modules/rna_prop_ui.py b/release/scripts/modules/rna_prop_ui.py
index 8453077be85..0d17c11456e 100644
--- a/release/scripts/modules/rna_prop_ui.py
+++ b/release/scripts/modules/rna_prop_ui.py
@@ -170,7 +170,7 @@ def draw(layout, context, context_member, property_type, use_edit=True):
else:
row = box.row(align=True)
- row.alignment = "RIGHT"
+ row.alignment = 'RIGHT'
row.label(text=key, translate=False)
diff --git a/release/scripts/startup/bl_operators/wm.py b/release/scripts/startup/bl_operators/wm.py
index 3f0cdfa606b..0ccdd3cf5c6 100644
--- a/release/scripts/startup/bl_operators/wm.py
+++ b/release/scripts/startup/bl_operators/wm.py
@@ -2440,9 +2440,9 @@ class WM_OT_studiolight_install(Operator):
)
orientation: EnumProperty(
items=(
- ("MATCAP", "MatCap", ""),
- ("WORLD", "World", ""),
- ("CAMERA", "Camera", ""),
+ ('MATCAP', "MatCap", ""),
+ ('WORLD', "World", ""),
+ ('CAMERA', "Camera", ""),
)
)
diff --git a/release/scripts/startup/bl_ui/properties_physics_common.py b/release/scripts/startup/bl_ui/properties_physics_common.py
index bed5617c76c..2da84ad84da 100644
--- a/release/scripts/startup/bl_ui/properties_physics_common.py
+++ b/release/scripts/startup/bl_ui/properties_physics_common.py
@@ -132,7 +132,7 @@ def point_cache_ui(self, context, cache, enabled, cachetype):
cache_info = cache.info
if cache_info:
col = layout.column()
- col.alignment = "RIGHT"
+ col.alignment = 'RIGHT'
col.label(text=cache_info)
else:
if cachetype in {'SMOKE', 'DYNAMIC_PAINT'}:
@@ -156,7 +156,7 @@ def point_cache_ui(self, context, cache, enabled, cachetype):
cache_info = cache.info
if cachetype != 'SMOKE' and cache_info: # avoid empty space.
col = layout.column(align=True)
- col.alignment = "RIGHT"
+ col.alignment = 'RIGHT'
col.label(text=cache_info)
can_bake = True
@@ -186,7 +186,7 @@ def point_cache_ui(self, context, cache, enabled, cachetype):
can_bake = False
col = layout.column(align=True)
- col.alignment = "RIGHT"
+ col.alignment = 'RIGHT'
col.separator()
diff --git a/release/scripts/startup/bl_ui/properties_scene.py b/release/scripts/startup/bl_ui/properties_scene.py
index 1b21ac8fcdf..38bfc6ad294 100644
--- a/release/scripts/startup/bl_ui/properties_scene.py
+++ b/release/scripts/startup/bl_ui/properties_scene.py
@@ -215,7 +215,7 @@ class SCENE_PT_keyframing_settings(SceneButtonsPanel, SceneKeyingSetsPanel, Pane
flow = layout.grid_flow(row_major=True, columns=0, even_columns=False, even_rows=False, align=True)
col = flow.column(align=True)
- col.alignment = "RIGHT"
+ col.alignment = 'RIGHT'
col.label(text="General Override")
self.draw_keyframing_settings(context, col, ks, None)
@@ -225,7 +225,7 @@ class SCENE_PT_keyframing_settings(SceneButtonsPanel, SceneKeyingSetsPanel, Pane
col.separator()
col = flow.column(align=True)
- col.alignment = "RIGHT"
+ col.alignment = 'RIGHT'
col.label(text="Active Set Override")
self.draw_keyframing_settings(context, col, ks, ksp)
@@ -272,7 +272,7 @@ class SCENE_PT_keying_set_paths(SceneButtonsPanel, SceneKeyingSetsPanel, Panel):
ksp = ks.paths.active
if ksp:
col = flow.column(align=True)
- col.alignment = "RIGHT"
+ col.alignment = 'RIGHT'
col.template_any_ID(ksp, "id", "id_type", text="Target ID-Block")
diff --git a/source/blender/blenkernel/intern/subdiv_converter.h b/source/blender/blenkernel/intern/subdiv_converter.h
index 748d97f4178..4c552a9164e 100644
--- a/source/blender/blenkernel/intern/subdiv_converter.h
+++ b/source/blender/blenkernel/intern/subdiv_converter.h
@@ -23,8 +23,8 @@
* ***** END GPL LICENSE BLOCK *****
*/
-#ifndef __BKE_SUBDIV_CONVERTER_H__
-#define __BKE_SUBDIV_CONVERTER_H__
+#ifndef __SUBDIV_CONVERTER_H__
+#define __SUBDIV_CONVERTER_H__
#include "BKE_subdiv.h"
@@ -54,4 +54,4 @@ void BKE_subdiv_converter_free(struct OpenSubdiv_Converter *converter);
int BKE_subdiv_converter_fvar_linear_from_settings(
const SubdivSettings *settings);
-#endif /* __BKE_SUBDIV_CONVERTER_H__ */
+#endif /* __SUBDIV_CONVERTER_H__ */
diff --git a/source/blender/blenkernel/intern/subdiv_mesh.c b/source/blender/blenkernel/intern/subdiv_mesh.c
index 8a58605ba19..c2a10483e26 100644
--- a/source/blender/blenkernel/intern/subdiv_mesh.c
+++ b/source/blender/blenkernel/intern/subdiv_mesh.c
@@ -152,7 +152,7 @@ static void edges_of_ptex_get(
typedef struct VerticesForInterpolation {
/* This field points to a vertex data which is to be used for interpolation.
* The idea is to avoid unnecessary allocations for regular faces, where
- * we can simply
+ * we can simply
*/
const CustomData *vertex_data;
/* Vertices data calculated for ptex corners. There are always 4 elements
@@ -176,7 +176,7 @@ typedef struct VerticesForInterpolation {
static void vertex_interpolation_init(
const SubdivMeshContext *ctx,
VerticesForInterpolation *vertex_interpolation,
- const MPoly *coarse_poly)
+ const MPoly *coarse_poly)
{
const Mesh *coarse_mesh = ctx->coarse_mesh;
const MLoop *coarse_mloop = coarse_mesh->mloop;
@@ -234,7 +234,8 @@ static void vertex_interpolation_from_ptex(
{
if (coarse_poly->totloop == 4) {
/* Nothing to do, all indices and data is already assigned. */
- } else {
+ }
+ else {
const CustomData *vertex_data = &ctx->coarse_mesh->vdata;
const Mesh *coarse_mesh = ctx->coarse_mesh;
const MLoop *coarse_mloop = coarse_mesh->mloop;
@@ -287,7 +288,7 @@ static void vertex_interpolation_end(
typedef struct LoopsForInterpolation {
/* This field points to a loop data which is to be used for interpolation.
* The idea is to avoid unnecessary allocations for regular faces, where
- * we can simply
+ * we can simply
*/
const CustomData *loop_data;
/* Loops data calculated for ptex corners. There are always 4 elements
@@ -311,7 +312,7 @@ typedef struct LoopsForInterpolation {
static void loop_interpolation_init(
const SubdivMeshContext *ctx,
LoopsForInterpolation *loop_interpolation,
- const MPoly *coarse_poly)
+ const MPoly *coarse_poly)
{
const Mesh *coarse_mesh = ctx->coarse_mesh;
if (coarse_poly->totloop == 4) {
@@ -363,7 +364,8 @@ static void loop_interpolation_from_ptex(
{
if (coarse_poly->totloop == 4) {
/* Nothing to do, all indices and data is already assigned. */
- } else {
+ }
+ else {
const CustomData *loop_data = &ctx->coarse_mesh->ldata;
const Mesh *coarse_mesh = ctx->coarse_mesh;
const MLoop *coarse_mloop = coarse_mesh->mloop;
@@ -481,9 +483,10 @@ static void subdiv_evaluate_vertices(SubdivMeshContext *ctx,
vertex_interpolation_end(&vertex_interpolation);
}
-static void subdiv_copy_edge_data(SubdivMeshContext *ctx,
- MEdge *subdiv_edge,
- const MEdge *coarse_edge)
+static void subdiv_copy_edge_data(
+ SubdivMeshContext *ctx,
+ MEdge *subdiv_edge,
+ const MEdge *coarse_edge)
{
if (coarse_edge == NULL) {
subdiv_edge->crease = 0;
@@ -586,11 +589,12 @@ static void subdiv_create_edges(SubdivMeshContext *ctx, int poly_index)
EdgesOfPtex edges_of_ptex;
edges_of_ptex_get(ctx, &edges_of_ptex, coarse_poly, i);
/* Create bottom row of edges (0-1, 1-2). */
- subdiv_edge = subdiv_create_edges_row(ctx,
- subdiv_edge,
- edges_of_ptex.first_edge,
- start_ptex_face_vertex_index,
- resolution);
+ subdiv_edge = subdiv_create_edges_row(
+ ctx,
+ subdiv_edge,
+ edges_of_ptex.first_edge,
+ start_ptex_face_vertex_index,
+ resolution);
/* Create remaining edges. */
for (int row = 0; row < resolution - 1; row++) {
const int start_row_vertex_index =
diff --git a/source/blender/blenlib/intern/hash_mm3.c b/source/blender/blenlib/intern/hash_mm3.c
index 5ead9ceca63..105c1f46832 100644
--- a/source/blender/blenlib/intern/hash_mm3.c
+++ b/source/blender/blenlib/intern/hash_mm3.c
@@ -92,7 +92,7 @@ BLI_INLINE uint64_t fmix64(uint64_t k)
uint32_t BLI_hash_mm3(const unsigned char *in, size_t len, uint32_t seed)
{
- const uint8_t *data = (const uint8_t*)in;
+ const uint8_t *data = (const uint8_t *)in;
const int nblocks = len / 4;
uint32_t h1 = seed;
@@ -102,23 +102,23 @@ uint32_t BLI_hash_mm3(const unsigned char *in, size_t len, uint32_t seed)
/* body */
- const uint32_t *blocks = (const uint32_t *)(data + nblocks*4);
+ const uint32_t *blocks = (const uint32_t *)(data + nblocks * 4);
for (int i = -nblocks; i; i++) {
- uint32_t k1 = getblock32(blocks,i);
+ uint32_t k1 = getblock32(blocks, i);
k1 *= c1;
- k1 = ROTL32(k1,15);
+ k1 = ROTL32(k1, 15);
k1 *= c2;
h1 ^= k1;
- h1 = ROTL32(h1,13);
- h1 = h1*5+0xe6546b64;
+ h1 = ROTL32(h1, 13);
+ h1 = h1 * 5 + 0xe6546b64;
}
/* tail */
- const uint8_t *tail = (const uint8_t*)(data + nblocks*4);
+ const uint8_t *tail = (const uint8_t *)(data + nblocks * 4);
uint32_t k1 = 0;
@@ -132,10 +132,10 @@ uint32_t BLI_hash_mm3(const unsigned char *in, size_t len, uint32_t seed)
case 1:
k1 ^= tail[0];
k1 *= c1;
- k1 = ROTL32(k1,15);
+ k1 = ROTL32(k1, 15);
k1 *= c2;
h1 ^= k1;
- };
+ }
/* finalization */
diff --git a/source/blender/compositor/nodes/COM_CryptomatteNode.cpp b/source/blender/compositor/nodes/COM_CryptomatteNode.cpp
index bc115e66c20..648ea4556ad 100644
--- a/source/blender/compositor/nodes/COM_CryptomatteNode.cpp
+++ b/source/blender/compositor/nodes/COM_CryptomatteNode.cpp
@@ -62,7 +62,7 @@ void CryptomatteNode::convertToOperations(NodeConverter &converter, const Compos
bNo
@@ Diff output truncated at 10240 characters. @@
More information about the Bf-blender-cvs
mailing list