Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
B
blender-addons
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
blender
blender-addons
Commits
96e13f19
Commit
96e13f19
authored
13 years ago
by
Kalle-Samuli Riihikoski
Browse files
Options
Downloads
Patches
Plain Diff
3D-Coat Applink version 2 released :)
parent
cc14230c
No related branches found
No related tags found
No related merge requests found
Changes
3
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
io_coat3D/__init__.py
+16
-1
16 additions, 1 deletion
io_coat3D/__init__.py
io_coat3D/coat.py
+172
-190
172 additions, 190 deletions
io_coat3D/coat.py
io_coat3D/tex.py
+10
-8
10 additions, 8 deletions
io_coat3D/tex.py
with
198 additions
and
199 deletions
io_coat3D/__init__.py
+
16
−
1
View file @
96e13f19
...
...
@@ -53,12 +53,17 @@ def register():
class
ObjectCoat3D
(
bpy
.
types
.
PropertyGroup
):
objpath
=
StringProperty
(
name
=
"
Object_Path
"
)
applink_name
=
StringProperty
(
name
=
"
Object_Applink_name
"
)
coatpath
=
StringProperty
(
name
=
"
Coat_Path
"
)
objectdir
=
StringProperty
(
name
=
"
ObjectPath
"
,
subtype
=
"
FILE_PATH
"
)
objecttime
=
StringProperty
(
name
=
"
ObjectTime
"
,
subtype
=
"
FILE_PATH
"
)
texturefolder
=
StringProperty
(
name
=
"
Texture folder:
"
,
subtype
=
"
DIR_PATH
"
)
path3b
=
StringProperty
(
name
=
"
3B Path
"
,
subtype
=
"
FILE_PATH
"
)
export_on
=
BoolProperty
(
name
=
"
Export_On
"
,
description
=
"
Add Modifiers and export
"
,
default
=
False
)
dime
=
FloatVectorProperty
(
name
=
"
dime
"
,
description
=
"
Dimension
"
)
loc
=
FloatVectorProperty
(
name
=
"
Location
"
,
description
=
"
Location
"
)
rot
=
FloatVectorProperty
(
name
=
"
Rotation
"
,
description
=
"
Rotation
"
,
subtype
=
'
EULER
'
)
sca
=
FloatVectorProperty
(
name
=
"
Scale
"
,
description
=
"
Scale
"
)
class
SceneCoat3D
(
bpy
.
types
.
PropertyGroup
):
...
...
@@ -70,6 +75,11 @@ def register():
name
=
"
FilePath
"
,
subtype
=
"
DIR_PATH
"
)
exchangefolder
=
StringProperty
(
name
=
"
FilePath
"
,
subtype
=
"
DIR_PATH
"
)
...
...
@@ -81,6 +91,11 @@ def register():
description
=
"
Allows to skip import dialog
"
,
default
=
True
)
exchange_found
=
BoolProperty
(
name
=
"
Exchange Found
"
,
description
=
"
Alert if Exchange folder is not found
"
,
default
=
True
)
export_box
=
BoolProperty
(
name
=
"
Export window
"
,
description
=
"
Allows to skip export dialog
"
,
...
...
This diff is collapsed.
Click to expand it.
io_coat3D/coat.py
+
172
−
190
View file @
96e13f19
This diff is collapsed.
Click to expand it.
io_coat3D/tex.py
+
10
−
8
View file @
96e13f19
...
...
@@ -31,6 +31,7 @@ def find_index(objekti):
def
gettex
(
mat_list
,
objekti
,
scene
,
export
):
coat3D
=
bpy
.
context
.
scene
.
coat3D
coa
=
objekti
.
coat3D
if
(
bpy
.
context
.
scene
.
render
.
engine
==
'
VRAY_RENDER
'
or
bpy
.
context
.
scene
.
render
.
engine
==
'
VRAY_RENDER_PREVIEW
'
):
vray
=
True
...
...
@@ -57,7 +58,7 @@ def gettex(mat_list, objekti, scene,export):
if
(
export
):
objekti
.
coat3D
.
objpath
=
export
nimi
=
os
.
path
.
split
(
export
)[
1
]
osoite
=
os
.
path
.
dirname
(
export
)
+
os
.
sep
osoite
=
os
.
path
.
dirname
(
export
)
+
os
.
sep
#pitaa ehka muuttaa
for
mate
in
objekti
.
material_slots
:
for
tex_slot
in
mate
.
material
.
texture_slots
:
if
(
hasattr
(
tex_slot
,
'
texture
'
)):
...
...
@@ -65,19 +66,20 @@ def gettex(mat_list, objekti, scene,export):
if
tex_slot
.
texture
.
image
is
not
None
:
tex_slot
.
texture
.
image
.
reload
()
else
:
coa
=
objekti
.
coat3D
nimi
=
os
.
path
.
split
(
coa
.
objectdir
)[
1
]
if
(
coa
.
texturefolder
):
osoite
=
os
.
path
.
dirname
(
coa
.
texturefolder
)
+
os
.
sep
if
(
os
.
sys
.
platform
==
'
win32
'
):
osoite
=
os
.
path
.
expanduser
(
"
~
"
)
+
os
.
sep
+
'
Documents
'
+
os
.
sep
+
'
3DC2Blender
'
+
os
.
sep
+
'
Textures
'
+
os
.
sep
else
:
osoite
=
os
.
path
.
dirname
(
coa
.
objectdir
)
+
os
.
sep
just_nimi
=
os
.
path
.
splitext
(
nimi
)[
0
]
+
'
_
'
osoite
=
os
.
path
.
expanduser
(
"
~
"
)
+
os
.
sep
+
'
3DC2Blender
'
+
os
.
sep
+
'
Textures
'
+
os
.
sep
ki
=
os
.
path
.
split
(
coa
.
applink_name
)[
1
]
ko
=
os
.
path
.
splitext
(
ki
)[
0
]
just_nimi
=
ko
+
'
_
'
just_nimi_len
=
len
(
just_nimi
)
print
(
'
terve:
'
+
coa
.
applink_name
)
if
(
len
(
objekti
.
material_slots
)
!=
0
):
for
obj_tex
in
objekti
.
active_material
.
texture_slots
:
if
(
hasattr
(
obj_tex
,
'
texture
'
)):
if
(
obj_tex
.
texture
):
if
(
obj_tex
.
texture
.
type
==
'
IMAGE
'
):
if
(
obj_tex
.
use_map_color_diffuse
):
bring_color
=
0
;
if
(
obj_tex
.
use_map_specular
):
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment