Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
B
blender-addons-contrib
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
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
blender
blender-addons-contrib
Commits
6298c51c
Commit
6298c51c
authored
Nov 17, 2011
by
Campbell Barton
Browse files
Options
Downloads
Patches
Plain Diff
a bit nicer code for switching scenes
parent
022c9f91
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
space_view3d_add_surround_cameras.py
+8
-6
8 additions, 6 deletions
space_view3d_add_surround_cameras.py
with
8 additions
and
6 deletions
space_view3d_add_surround_cameras.py
+
8
−
6
View file @
6298c51c
...
...
@@ -148,22 +148,24 @@ class AddSurroundScenesOperator(bpy.types.Operator):
return
False
def
execute
(
self
,
context
):
scene_base
=
context
.
scene
numScreens
=
context
.
window_manager
.
previous_num_surround_screens
sceneName
=
context
.
scen
e
.
name
renderpath
=
context
.
scen
e
.
render
.
filepath
sceneName
=
scene_bas
e
.
name
renderpath
=
scene_bas
e
.
render
.
filepath
for
i
in
range
(
0
,
numScreens
):
thisScene
=
sceneName
+
"
-Camera
"
+
str
(
i
)
bpy
.
ops
.
scene
.
new
(
type
=
'
LINK_OBJECTS
'
)
context
.
scene
.
name
=
thisScene
scene_new
=
context
.
scene
scene_new
.
name
=
thisScene
context
.
scene
.
camera
=
bpy
.
data
.
objects
[
"
Camera
"
+
str
(
i
)]
scene
_new
.
camera
=
bpy
.
data
.
objects
[
"
Camera
"
+
str
(
i
)]
context
.
scene
.
render
.
filepath
=
renderpath
+
thisScene
scene
_new
.
render
.
filepath
=
renderpath
+
thisScene
context
.
screen
.
scene
=
bpy
.
data
.
scenes
[
sceneName
]
context
.
screen
.
scene
=
scene_base
context
.
window_manager
.
surround_screens_init
=
True
return
{
'
FINISHED
'
}
...
...
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