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
8b9e2e0f
Commit
8b9e2e0f
authored
13 years ago
by
Kalle-Samuli Riihikoski
Browse files
Options
Downloads
Patches
Plain Diff
-complete applink dynamic menu.
-fixed the bug when two or more objects dosen't have materials.
parent
40786f09
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
io_coat3D/coat.py
+38
-3
38 additions, 3 deletions
io_coat3D/coat.py
io_coat3D/tex.py
+1
-1
1 addition, 1 deletion
io_coat3D/tex.py
with
39 additions
and
4 deletions
io_coat3D/coat.py
+
38
−
3
View file @
8b9e2e0f
...
@@ -294,13 +294,14 @@ class SCENE_OT_import(bpy.types.Operator):
...
@@ -294,13 +294,14 @@ class SCENE_OT_import(bpy.types.Operator):
act_first
=
bpy
.
context
.
scene
.
objects
.
active
act_first
=
bpy
.
context
.
scene
.
objects
.
active
for
act_name
in
test
:
for
act_name
in
test
:
if
act_name
.
type
==
'
MESH
'
and
os
.
path
.
isfile
(
act_name
.
coat3D
.
objectdir
):
if
act_name
.
type
==
'
MESH
'
and
os
.
path
.
isfile
(
act_name
.
coat3D
.
objectdir
):
print
(
'
eihan tanne voi tulla
'
)
activeobj
=
act_name
.
name
activeobj
=
act_name
.
name
mat_list
=
[]
mat_list
=
[]
scene
.
objects
[
activeobj
].
select
=
True
scene
.
objects
[
activeobj
].
select
=
True
objekti
=
scene
.
objects
[
activeobj
]
objekti
=
scene
.
objects
[
activeobj
]
coat3D
.
loca
=
objekti
.
location
coat3D
.
loca
=
objekti
.
location
coat3D
.
rota
=
objekti
.
rotation_euler
coat3D
.
rota
=
objekti
.
rotation_euler
coa
=
bpy
.
context
.
scene
.
objects
.
activ
e
.
coat3D
coa
=
act_nam
e
.
coat3D
exportfile
=
coat3D
.
exchangedir
exportfile
=
coat3D
.
exchangedir
path3b_n
=
coat3D
.
exchangedir
path3b_n
=
coat3D
.
exchangedir
...
@@ -550,18 +551,52 @@ class VIEW3D_MT_Coat_Dynamic_Menu(bpy.types.Menu):
...
@@ -550,18 +551,52 @@ class VIEW3D_MT_Coat_Dynamic_Menu(bpy.types.Menu):
ob
=
context
ob
=
context
if
ob
.
mode
==
'
OBJECT
'
:
if
ob
.
mode
==
'
OBJECT
'
:
layout
.
operator
(
"
import_applink.pilgway_3d_coat
"
,
text
=
"
Import
"
)
layout
.
operator
(
"
import_applink.pilgway_3d_coat
"
,
text
=
"
Import
"
)
layout
.
separator
()
layout
.
separator
()
layout
.
operator
(
"
export_applink.pilgway_3d_coat
"
,
text
=
"
Export
"
)
layout
.
operator
(
"
export_applink.pilgway_3d_coat
"
,
text
=
"
Export
"
)
layout
.
separator
()
layout
.
separator
()
layout
.
menu
(
"
VIEW3D_MT_ImportMenu
"
)
layout
.
separator
()
layout
.
menu
(
"
VIEW3D_MT_ExportMenu
"
)
layout
.
separator
()
layout
.
operator
(
"
import_applink.pilgway_3d_deltex
"
,
text
=
"
Delete Textures
"
)
layout
.
operator
(
"
import_applink.pilgway_3d_deltex
"
,
text
=
"
Delete Textures
"
)
layout
.
separator
()
layout
.
separator
()
layout
.
separator
()
class
VIEW3D_MT_ImportMenu
(
bpy
.
types
.
Menu
):
bl_label
=
"
Import Settings
"
def
draw
(
self
,
context
):
layout
=
self
.
layout
coat3D
=
bpy
.
context
.
scene
.
coat3D
settings
=
context
.
tool_settings
layout
.
operator_context
=
'
INVOKE_REGION_WIN
'
layout
.
prop
(
coat3D
,
"
importmesh
"
)
layout
.
prop
(
coat3D
,
"
importmod
"
)
layout
.
prop
(
coat3D
,
"
smooth_on
"
)
layout
.
prop
(
coat3D
,
"
importtextures
"
)
class
VIEW3D_MT_ExportMenu
(
bpy
.
types
.
Menu
):
bl_label
=
"
Export Settings
"
def
draw
(
self
,
context
):
layout
=
self
.
layout
coat3D
=
bpy
.
context
.
scene
.
coat3D
settings
=
context
.
tool_settings
layout
.
operator_context
=
'
INVOKE_REGION_WIN
'
layout
.
prop
(
coat3D
,
"
exportover
"
)
if
(
coat3D
.
exportover
):
layout
.
prop
(
coat3D
,
"
exportmod
"
)
layout
.
prop
(
coat3D
,
"
exportfile
"
)
layout
.
prop
(
coat3D
,
"
export_pos
"
)
def
register
():
def
register
():
bpy
.
utils
.
register_module
(
__name__
)
bpy
.
utils
.
register_module
(
__name__
)
...
...
This diff is collapsed.
Click to expand it.
io_coat3D/tex.py
+
1
−
1
View file @
8b9e2e0f
...
@@ -68,7 +68,7 @@ def gettex(mat_list, objekti, scene,export):
...
@@ -68,7 +68,7 @@ def gettex(mat_list, objekti, scene,export):
if
tex_slot
.
texture
.
image
is
not
None
:
if
tex_slot
.
texture
.
image
is
not
None
:
tex_slot
.
texture
.
image
.
reload
()
tex_slot
.
texture
.
image
.
reload
()
else
:
else
:
coa
=
bpy
.
context
.
scene
.
objects
.
active
.
coat3D
coa
=
objekti
.
coat3D
nimi
=
objname
(
coa
.
objectdir
)
nimi
=
objname
(
coa
.
objectdir
)
if
(
coa
.
texturefolder
):
if
(
coa
.
texturefolder
):
osoite
=
os
.
path
.
dirname
(
coa
.
texturefolder
)
+
os
.
sep
osoite
=
os
.
path
.
dirname
(
coa
.
texturefolder
)
+
os
.
sep
...
...
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