Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender-addons.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2011-07-11 02:57:27 +0400
committerCampbell Barton <ideasman42@gmail.com>2011-07-11 02:57:27 +0400
commit488e1da935d55330be55eb30b4605b993dd65dbd (patch)
treed4437d5e74e962482a4a6aa5336212c257f0245e /io_coat3D
parent8012053e1e178c8cabb133e05dc1e36d52908fa7 (diff)
cleanup
- remove/comment unused variables - remove unused imports - fixed some bugs using incorrect variables
Diffstat (limited to 'io_coat3D')
-rw-r--r--io_coat3D/coat.py7
-rw-r--r--io_coat3D/tex.py51
2 files changed, 29 insertions, 29 deletions
diff --git a/io_coat3D/coat.py b/io_coat3D/coat.py
index 954502f3..4d967ce1 100644
--- a/io_coat3D/coat.py
+++ b/io_coat3D/coat.py
@@ -1,4 +1,3 @@
-
# ***** BEGIN GPL LICENSE BLOCK *****
#
#
@@ -22,8 +21,6 @@ import bpy
from bpy.props import *
from io_coat3D import tex
import os
-import linecache
-import math
bpy.coat3D = dict()
@@ -151,7 +148,6 @@ class SCENE_PT_Settings(ObjectButtonsPanel,bpy.types.Panel):
def draw(self, context):
layout = self.layout
- scene = context.scene
coat3D = bpy.context.scene.coat3D
row = layout.row()
@@ -374,8 +370,7 @@ class SCENE_OT_import(bpy.types.Operator):
if(coat3D.importmod):
- mod_list = []
- for mod_index in objekti.modifiers:
+ for mod_index in objekti.modifiers[:]:
objekti.modifiers.remove(mod_index)
diff --git a/io_coat3D/tex.py b/io_coat3D/tex.py
index d4156e5d..748d1aa0 100644
--- a/io_coat3D/tex.py
+++ b/io_coat3D/tex.py
@@ -1,6 +1,24 @@
+# ***** BEGIN GPL LICENSE BLOCK *****
+#
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License
+# as published by the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software Foundation,
+# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+#
+# ***** END GPL LICENCE BLOCK *****
+
import bpy
import os
-import filecmp
def objname(path):
@@ -40,15 +58,15 @@ def gettex(mat_list, objekti, scene,export):
else:
vray = False
- take_color = 0;
- take_spec = 0;
- take_normal = 0;
- take_disp = 0;
+ take_color = 0
+ take_spec = 0
+ take_normal = 0
+ take_disp = 0
- bring_color = 1;
- bring_spec = 1;
- bring_normal = 1;
- bring_disp = 1;
+ bring_color = 1
+ bring_spec = 1
+ bring_normal = 1
+ bring_disp = 1
texcoat = {}
texcoat['color'] = []
@@ -257,23 +275,16 @@ def gettex(mat_list, objekti, scene,export):
if(bring_spec == 1 and texcoat['specular']):
name_tex ='Specular_'
- num = []
index = find_index(objekti)
-
- tex = bpy.ops.Texture
objekti.active_material.texture_slots.create(index)
- total_mat = len(objekti.active_material.texture_slots.items())
useold = ''
for seekco in bpy.data.textures:
if((seekco.name[:9] == 'Specular_') and (seekco.users_material == ())):
useold = seekco
-
-
-
if(useold == ''):
indexx = 0
@@ -321,24 +332,18 @@ def gettex(mat_list, objekti, scene,export):
if(bring_disp == 1 and texcoat['disp']):
name_tex ='Displacement_'
- num = []
index = find_index(objekti)
- tex = bpy.ops.Texture
objekti.active_material.texture_slots.create(index)
- total_mat = len(objekti.active_material.texture_slots.items())
useold = ''
for seekco in bpy.data.textures:
if((seekco.name[:13] == 'Displacement_') and (seekco.users_material == ())):
useold = seekco
-
-
-
- if(useold == ''):
+ if useold == "":
indexx = 0
tuli = False