From 039549900bcb6e17c372c89702529efb28bd7cc0 Mon Sep 17 00:00:00 2001 From: Pablo Vazquez Date: Wed, 24 Sep 2025 15:14:08 +0200 Subject: [PATCH] Templates: Add Storyboarding app template Implements #144061, part of the Story Tools project #135058 Add a new "Storyboarding" app template, as a quick way to start drawing on multiple scenes/shots thanks to the VSE Sync Scene setting. - Created based on the 2D Animation template - Features an additional Sequencer editor with `Sync Scene` enabled. - Adds one `Edit` scene used in the Sequencer. - Adds one Scene asset (`Shot.000`) as example to be used as blueprint, users can edit it and later add/duplicate in VSE to create new shots. - Adds two scenes as example (`Shot.001`, `Shot.002`), based on the included `Shot.000` Scene asset. Default Edit scene length is 10 seconds, while the shots are 2 seconds each. The default of 250 frames for each shot was a bit much and didn't serve as good example in the Sequencer timeline. One aspect missing is the Scene range overlay from !146165, but that can be added via versioning. See PR for details and screenshots. Pull Request: https://projects.blender.org/blender/blender/pulls/146658 --- .../Storyboarding/__init__.py | 59 +++++++++++++++++++ .../Storyboarding/startup.blend | 3 + 2 files changed, 62 insertions(+) create mode 100644 scripts/startup/bl_app_templates_system/Storyboarding/__init__.py create mode 100644 scripts/startup/bl_app_templates_system/Storyboarding/startup.blend diff --git a/scripts/startup/bl_app_templates_system/Storyboarding/__init__.py b/scripts/startup/bl_app_templates_system/Storyboarding/__init__.py new file mode 100644 index 00000000000..1336d7c6150 --- /dev/null +++ b/scripts/startup/bl_app_templates_system/Storyboarding/__init__.py @@ -0,0 +1,59 @@ +# SPDX-FileCopyrightText: 2025 Blender Authors +# +# SPDX-License-Identifier: GPL-2.0-or-later + +# Initialization script for Storyboarding template + +import bpy +from bpy.app.handlers import persistent + + +def update_factory_startup_screens(): + # Storyboarding. + screen = bpy.data.screens["Storyboarding"] + for area in screen.areas: + if area.type == 'PROPERTIES': + # Set Tool settings as default in properties panel. + space = area.spaces.active + space.context = 'TOOL' + elif area.type == 'DOPESHEET_EDITOR': + # Open sidebar in Dope-sheet. + space = area.spaces.active + space.show_region_ui = True + + # 2D Full Canvas. + screen = bpy.data.screens["2D Full Canvas"] + for area in screen.areas: + if area.type == 'VIEW_3D': + space = area.spaces.active + space.shading.type = 'MATERIAL' + space.shading.use_scene_world = True + + +def update_factory_startup_scenes(): + for scene in bpy.data.scenes: + scene.tool_settings.use_keyframe_insert_auto = True + scene.tool_settings.gpencil_sculpt.use_scale_thickness = True + + if scene.name == 'Edit': + scene.tool_settings.use_keyframe_insert_auto = False + + +def update_factory_startup_grease_pencils(): + for grease_pencil in bpy.data.grease_pencils_v3: + grease_pencil.onion_keyframe_type = 'ALL' + + +@persistent +def load_handler(_): + update_factory_startup_screens() + update_factory_startup_scenes() + update_factory_startup_grease_pencils() + + +def register(): + bpy.app.handlers.load_factory_startup_post.append(load_handler) + + +def unregister(): + bpy.app.handlers.load_factory_startup_post.remove(load_handler) diff --git a/scripts/startup/bl_app_templates_system/Storyboarding/startup.blend b/scripts/startup/bl_app_templates_system/Storyboarding/startup.blend new file mode 100644 index 00000000000..764529bad17 --- /dev/null +++ b/scripts/startup/bl_app_templates_system/Storyboarding/startup.blend @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:64326adaa0528ea5f1b532c7509db271c246d3758181edbf1c83fa8d7d52fd6f +size 113453