[Bf-extensions-cvs] [b12dd385] master: Cleanup: trailing space

Campbell Barton noreply at git.blender.org
Thu Mar 10 03:21:03 CET 2022


Commit: b12dd385eb428f51d33f4b447a746835e4fd697a
Author: Campbell Barton
Date:   Thu Mar 10 13:19:55 2022 +1100
Branches: master
https://developer.blender.org/rBAb12dd385eb428f51d33f4b447a746835e4fd697a

Cleanup: trailing space

===================================================================

M	io_scene_gltf2/blender/exp/gltf2_blender_gather_animation_channels.py
M	io_scene_gltf2/blender/exp/gltf2_blender_gather_animation_sampler_keyframes.py
M	io_scene_gltf2/blender/exp/gltf2_blender_gather_animations.py
M	io_scene_gltf2/blender/exp/gltf2_blender_gather_materials.py
M	io_scene_gltf2/blender/exp/gltf2_blender_gather_tree.py
M	io_scene_gltf2/blender/exp/gltf2_blender_get.py
M	viewport_vr_preview/action_map_io.py
M	viewport_vr_preview/defaults.py

===================================================================

diff --git a/io_scene_gltf2/blender/exp/gltf2_blender_gather_animation_channels.py b/io_scene_gltf2/blender/exp/gltf2_blender_gather_animation_channels.py
index 87ef7c13..98ae8b82 100755
--- a/io_scene_gltf2/blender/exp/gltf2_blender_gather_animation_channels.py
+++ b/io_scene_gltf2/blender/exp/gltf2_blender_gather_animation_channels.py
@@ -179,7 +179,7 @@ def gather_animation_channels(obj_uuid: int,
                         blender_action.name,
                         None,
                         False #If Object is not animated, don't keep animation for this channel
-                        ) 
+                        )
 
                     if channel is not None:
                         channels.append(channel)
diff --git a/io_scene_gltf2/blender/exp/gltf2_blender_gather_animation_sampler_keyframes.py b/io_scene_gltf2/blender/exp/gltf2_blender_gather_animation_sampler_keyframes.py
index cd836682..66ce11c7 100755
--- a/io_scene_gltf2/blender/exp/gltf2_blender_gather_animation_sampler_keyframes.py
+++ b/io_scene_gltf2/blender/exp/gltf2_blender_gather_animation_sampler_keyframes.py
@@ -138,7 +138,7 @@ def get_object_matrix(blender_obj_uuid: str,
     data = {}
 
     # TODO : bake_range_start & bake_range_end are no more needed here
-    # Because we bake, we don't know exactly the frame range, 
+    # Because we bake, we don't know exactly the frame range,
     # So using min / max of all actions
 
     start_frame = min([v[0] for v in [a.frame_range for a in bpy.data.actions]])
@@ -168,7 +168,7 @@ def get_object_matrix(blender_obj_uuid: str,
                         ((1.0, 0.0, 0.0, 0.0), (0.0, 0.0, 1.0, 0.0), (0.0, -1.0, 0.0, 0.0), (0.0, 0.0, 0.0, 1.0)))
 
                     parent_mat = armature_object.matrix_world @ blender_bone.matrix @ axis_basis_change
-              
+
             #For object inside collection (at root), matrix world is already expressed regarding collection parent
             if export_settings['vtree'].nodes[obj_uuid].parent_uuid is not None and export_settings['vtree'].nodes[export_settings['vtree'].nodes[obj_uuid].parent_uuid].blender_type == VExportNode.COLLECTION:
                 parent_mat = mathutils.Matrix.Identity(4).freeze()
@@ -177,7 +177,7 @@ def get_object_matrix(blender_obj_uuid: str,
 
             if obj_uuid not in data.keys():
                 data[obj_uuid] = {}
-            
+
             if blender_obj.animation_data and blender_obj.animation_data.action:
                 if blender_obj.animation_data.action.name not in data[obj_uuid].keys():
                     data[obj_uuid][blender_obj.animation_data.action.name] = {}
diff --git a/io_scene_gltf2/blender/exp/gltf2_blender_gather_animations.py b/io_scene_gltf2/blender/exp/gltf2_blender_gather_animations.py
index 828d1955..4ad8872e 100755
--- a/io_scene_gltf2/blender/exp/gltf2_blender_gather_animations.py
+++ b/io_scene_gltf2/blender/exp/gltf2_blender_gather_animations.py
@@ -34,11 +34,11 @@ def __gather_channels_baked(obj_uuid, export_settings):
             obj_uuid, # Use obj uuid as action name for caching
             None,
             False #If Object is not animated, don't keep animation for this channel
-            ) 
+            )
         if channel is not None:
             channels.append(channel)
 
-    return channels if len(channels) > 0 else None  
+    return channels if len(channels) > 0 else None
 
 def gather_animations(  obj_uuid: int,
                         tracks: typing.Dict[str, typing.List[int]],
@@ -61,7 +61,7 @@ def gather_animations(  obj_uuid: int,
     if len([a for a in blender_actions if a[2] == "OBJECT"]) == 0:
         # No TRS animation are found for this object.
         # But we need to bake, in case we export selection
-        if export_settings['gltf_selected'] is True and blender_object.type != "ARMATURE": 
+        if export_settings['gltf_selected'] is True and blender_object.type != "ARMATURE":
             channels = __gather_channels_baked(obj_uuid, export_settings)
             if channels is not None:
                 animation = gltf2_io.Animation(
diff --git a/io_scene_gltf2/blender/exp/gltf2_blender_gather_materials.py b/io_scene_gltf2/blender/exp/gltf2_blender_gather_materials.py
index 71aec00d..04129996 100755
--- a/io_scene_gltf2/blender/exp/gltf2_blender_gather_materials.py
+++ b/io_scene_gltf2/blender/exp/gltf2_blender_gather_materials.py
@@ -56,7 +56,7 @@ def gather_material(blender_material, export_settings):
     )
 
     # If emissive is set, from an emissive node (not PBR)
-    # We need to set manually default values for 
+    # We need to set manually default values for
     # pbr_metallic_roughness.baseColor
     if material.emissive_factor is not None and gltf2_blender_get.get_node_socket(blender_material, bpy.types.ShaderNodeBsdfPrincipled, "Base Color") is None:
         material.pbr_metallic_roughness = gltf2_blender_gather_materials_pbr_metallic_roughness.get_default_pbr_for_emissive_node()
diff --git a/io_scene_gltf2/blender/exp/gltf2_blender_gather_tree.py b/io_scene_gltf2/blender/exp/gltf2_blender_gather_tree.py
index 7a5ce2be..d3edd50a 100644
--- a/io_scene_gltf2/blender/exp/gltf2_blender_gather_tree.py
+++ b/io_scene_gltf2/blender/exp/gltf2_blender_gather_tree.py
@@ -365,11 +365,10 @@ class VExportTree:
                 return False
 
         return True
-    
+
     def search_missing_armature(self):
         for n in [n for n in self.nodes.values() if hasattr(n, "armature_needed") is True]:
             candidates = [i for i in self.nodes.values() if i.blender_type == VExportNode.ARMATURE and i.blender_object.name == n.armature_needed]
             if len(candidates) > 0:
                 n.armature = candidates[0].uuid
             del n.armature_needed
-            
\ No newline at end of file
diff --git a/io_scene_gltf2/blender/exp/gltf2_blender_get.py b/io_scene_gltf2/blender/exp/gltf2_blender_get.py
index 75e17b34..e38906e6 100755
--- a/io_scene_gltf2/blender/exp/gltf2_blender_get.py
+++ b/io_scene_gltf2/blender/exp/gltf2_blender_get.py
@@ -72,7 +72,7 @@ def get_socket(blender_material: bpy.types.Material, name: str):
             name = "Color"
         else:
             type = bpy.types.ShaderNodeBsdfPrincipled
-        
+
         return get_node_socket(blender_material, type, name)
 
     return None
diff --git a/viewport_vr_preview/action_map_io.py b/viewport_vr_preview/action_map_io.py
index c4e04581..072947b8 100644
--- a/viewport_vr_preview/action_map_io.py
+++ b/viewport_vr_preview/action_map_io.py
@@ -69,7 +69,7 @@ def ami_args_as_data(ami):
 
 def ami_data_from_args(ami, args):
     ami.type = args["type"]
-    
+
     for path in args["user_paths"]:
         ami.user_paths.new(path)
 
diff --git a/viewport_vr_preview/defaults.py b/viewport_vr_preview/defaults.py
index fe253e10..b8e76743 100644
--- a/viewport_vr_preview/defaults.py
+++ b/viewport_vr_preview/defaults.py
@@ -93,7 +93,7 @@ def vr_defaults_action_add(am,
 
     ami = am.actionmap_items.new(name, True)
     if ami:
-        ami.type = 'FLOAT'		
+        ami.type = 'FLOAT'
         for path in user_paths:
             ami.user_paths.new(path)
         ami.op = op



More information about the Bf-extensions-cvs mailing list