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
3b719f3f
Commit
3b719f3f
authored
8 years ago
by
Mikhail Rachinskiy
Browse files
Options
Downloads
Patches
Plain Diff
Bool Tool: Fix T49205
parent
1d3abec5
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
object_boolean_tools.py
+21
-21
21 additions, 21 deletions
object_boolean_tools.py
with
21 additions
and
21 deletions
object_boolean_tools.py
+
21
−
21
View file @
3b719f3f
...
...
@@ -188,6 +188,7 @@ def Operation(context, _operation):
selObj
[
"
BoolTool_FTransform
"
]
=
"
False
"
"""
# Do Direct Union, Difference and Intersection Operations
def Operation_Direct(context, _operation):
actObj = context.active_object
...
...
@@ -224,6 +225,7 @@ def Operation_Direct(context, _operation):
bpy.ops.object.select_all(action=
'
DESELECT
'
)
# selObj.select = True
# bpy.ops.object.delete()
"""
# Remove Obejcts form the BoolTool System
...
...
@@ -260,19 +262,20 @@ def Remove(context, thisObj_name, Prop):
# Remove the Brush Property
if
Prop
==
"
BRUSH
"
:
Canvas
=
FindCanvas
(
actObj
)
for
mod
in
Canvas
.
modifiers
:
if
(
"
BTool_
"
in
mod
.
name
):
if
(
actObj
.
name
in
mod
.
name
):
Canvas
.
modifiers
.
remove
(
mod
)
cyclesVis
=
actObj
.
cycles_visibility
actObj
.
draw_type
=
"
TEXTURED
"
del
actObj
[
"
BoolToolBrush
"
]
del
actObj
[
"
BoolTool_FTransform
"
]
cyclesVis
.
camera
=
True
cyclesVis
.
diffuse
=
True
cyclesVis
.
glossy
=
True
cyclesVis
.
shadow
=
True
cyclesVis
.
transmission
=
True
if
Canvas
:
for
mod
in
Canvas
.
modifiers
:
if
(
"
BTool_
"
in
mod
.
name
):
if
(
actObj
.
name
in
mod
.
name
):
Canvas
.
modifiers
.
remove
(
mod
)
cyclesVis
=
actObj
.
cycles_visibility
actObj
.
draw_type
=
"
TEXTURED
"
del
actObj
[
"
BoolToolBrush
"
]
del
actObj
[
"
BoolTool_FTransform
"
]
cyclesVis
.
camera
=
True
cyclesVis
.
diffuse
=
True
cyclesVis
.
glossy
=
True
cyclesVis
.
shadow
=
True
cyclesVis
.
transmission
=
True
if
Prop
==
"
CANVAS
"
:
for
mod
in
actObj
.
modifiers
:
...
...
@@ -347,22 +350,19 @@ def ApplyAll(context, list):
except
:
# if fails the means it is multiuser data
context
.
active_object
.
data
=
context
.
active_object
.
data
.
copy
()
# so just make data unique
bpy
.
ops
.
object
.
modifier_apply
(
modifier
=
mod
.
name
)
del
selObj
[
'
BoolToolRoot
'
]
# bpy.ops.object.select_all(action='TOGGLE')
# bpy.ops.object.select_all(action='DESELECT')
# for obj in deleteList:
# obj.select = True
# bpy.ops.object.delete()
for
obj
in
context
.
scene
.
objects
:
if
isCanvas
(
obj
):
for
mod
in
obj
.
modifiers
:
if
mod
.
type
==
'
BOOLEAN
'
:
if
mod
.
object
in
objDeleteList
:
# do not delete brush that is used by another canvas
objDeleteList
.
remove
(
mod
.
object
)
# remove it from deletion
bpy
.
ops
.
object
.
select_all
(
action
=
'
DESELECT
'
)
#
for obj in objDeleteList:
#
obj.select = True
#
bpy.ops.object.delete()
for
obj
in
objDeleteList
:
obj
.
select
=
True
bpy
.
ops
.
object
.
delete
()
# Apply This Brush to the Canvas
...
...
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