2009-11-01 15:21:20 +00:00
|
|
|
# ##### BEGIN GPL LICENSE BLOCK #####
|
|
|
|
#
|
|
|
|
# This program is free software; you can redistribute it and/or
|
|
|
|
# modify it under the terms of the GNU General Public License
|
|
|
|
# as published by the Free Software Foundation; either version 2
|
|
|
|
# of the License, or (at your option) any later version.
|
2009-11-03 07:23:02 +00:00
|
|
|
#
|
2009-11-01 15:21:20 +00:00
|
|
|
# This program is distributed in the hope that it will be useful,
|
|
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
# GNU General Public License for more details.
|
2009-11-03 07:23:02 +00:00
|
|
|
#
|
2009-11-01 15:21:20 +00:00
|
|
|
# You should have received a copy of the GNU General Public License
|
|
|
|
# along with this program; if not, write to the Free Software Foundation,
|
2010-02-12 13:34:04 +00:00
|
|
|
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
2009-11-01 15:21:20 +00:00
|
|
|
#
|
|
|
|
# ##### END GPL LICENSE BLOCK #####
|
2009-10-31 20:16:59 +00:00
|
|
|
|
2009-10-31 23:35:56 +00:00
|
|
|
# <pep8 compliant>
|
2009-06-08 16:48:12 +00:00
|
|
|
import bpy
|
2019-05-19 20:44:28 +10:00
|
|
|
from bpy.types import (
|
|
|
|
Header,
|
|
|
|
Menu,
|
|
|
|
Panel,
|
|
|
|
)
|
|
|
|
from bpy.app.translations import (
|
|
|
|
contexts as i18n_contexts,
|
|
|
|
pgettext_iface as iface_,
|
|
|
|
)
|
2019-06-11 16:08:32 +10:00
|
|
|
from bl_ui.properties_grease_pencil_common import (
|
2018-08-22 16:59:04 +02:00
|
|
|
AnnotationDataPanel,
|
2017-10-09 13:47:05 +11:00
|
|
|
)
|
2019-05-19 20:44:28 +10:00
|
|
|
from rna_prop_ui import PropertyPanel
|
2013-02-10 09:09:26 +00:00
|
|
|
|
2010-05-16 12:15:04 +00:00
|
|
|
|
2009-06-08 16:48:12 +00:00
|
|
|
def act_strip(context):
|
2009-10-31 23:35:56 +00:00
|
|
|
try:
|
|
|
|
return context.scene.sequence_editor.active_strip
|
2009-11-21 00:05:43 +00:00
|
|
|
except AttributeError:
|
2009-10-31 23:35:56 +00:00
|
|
|
return None
|
|
|
|
|
2009-06-08 16:48:12 +00:00
|
|
|
|
2019-01-23 16:58:37 +01:00
|
|
|
def selected_sequences_len(context):
|
2019-01-23 16:56:23 +01:00
|
|
|
selected_sequences = getattr(context, "selected_sequences", None)
|
2019-03-13 13:12:57 +11:00
|
|
|
if selected_sequences is None:
|
2019-01-23 16:56:23 +01:00
|
|
|
return 0
|
|
|
|
return len(selected_sequences)
|
2018-11-09 11:53:09 +01:00
|
|
|
|
|
|
|
|
2012-08-19 15:41:56 +00:00
|
|
|
def draw_color_balance(layout, color_balance):
|
2019-05-16 13:58:04 +02:00
|
|
|
|
|
|
|
layout.use_property_split = False
|
|
|
|
|
|
|
|
flow = layout.grid_flow(row_major=True, columns=0, even_columns=True, even_rows=False, align=False)
|
|
|
|
col = flow.column()
|
|
|
|
|
|
|
|
box = col.box()
|
2018-08-28 12:38:54 +10:00
|
|
|
split = box.split(factor=0.35)
|
2017-05-07 18:13:50 -04:00
|
|
|
col = split.column(align=True)
|
2012-08-19 15:41:56 +00:00
|
|
|
col.label(text="Lift:")
|
2017-05-07 18:13:50 -04:00
|
|
|
col.separator()
|
|
|
|
col.separator()
|
2017-05-22 14:56:08 +02:00
|
|
|
col.prop(color_balance, "lift", text="")
|
2017-09-02 15:42:29 +10:00
|
|
|
col.prop(color_balance, "invert_lift", text="Invert", icon='ARROW_LEFTRIGHT')
|
2017-10-09 13:47:05 +11:00
|
|
|
split.template_color_picker(color_balance, "lift", value_slider=True, cubic=True)
|
2017-05-07 18:13:50 -04:00
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
col = flow.column()
|
|
|
|
|
|
|
|
box = col.box()
|
2018-08-28 12:38:54 +10:00
|
|
|
split = box.split(factor=0.35)
|
2017-05-07 18:13:50 -04:00
|
|
|
col = split.column(align=True)
|
2012-08-19 15:41:56 +00:00
|
|
|
col.label(text="Gamma:")
|
2017-05-07 18:13:50 -04:00
|
|
|
col.separator()
|
|
|
|
col.separator()
|
2017-05-22 14:56:08 +02:00
|
|
|
col.prop(color_balance, "gamma", text="")
|
2017-09-02 15:42:29 +10:00
|
|
|
col.prop(color_balance, "invert_gamma", text="Invert", icon='ARROW_LEFTRIGHT')
|
2017-05-07 18:13:50 -04:00
|
|
|
split.template_color_picker(color_balance, "gamma", value_slider=True, lock_luminosity=True, cubic=True)
|
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
col = flow.column()
|
|
|
|
|
|
|
|
box = col.box()
|
2018-08-28 12:38:54 +10:00
|
|
|
split = box.split(factor=0.35)
|
2017-05-07 18:13:50 -04:00
|
|
|
col = split.column(align=True)
|
2012-08-19 15:41:56 +00:00
|
|
|
col.label(text="Gain:")
|
2017-05-07 18:13:50 -04:00
|
|
|
col.separator()
|
|
|
|
col.separator()
|
2017-05-09 14:36:00 -04:00
|
|
|
col.prop(color_balance, "gain", text="")
|
2017-09-02 15:42:29 +10:00
|
|
|
col.prop(color_balance, "invert_gain", text="Invert", icon='ARROW_LEFTRIGHT')
|
2017-05-07 18:13:50 -04:00
|
|
|
split.template_color_picker(color_balance, "gain", value_slider=True, lock_luminosity=True, cubic=True)
|
2012-08-19 15:41:56 +00:00
|
|
|
|
|
|
|
|
2011-08-12 06:57:00 +00:00
|
|
|
class SEQUENCER_HT_header(Header):
|
2009-10-31 19:31:45 +00:00
|
|
|
bl_space_type = 'SEQUENCE_EDITOR'
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
|
|
|
|
|
|
|
st = context.space_data
|
|
|
|
|
2019-04-21 04:49:19 +10:00
|
|
|
layout.template_header()
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2018-05-01 18:47:26 +02:00
|
|
|
layout.prop(st, "view_type", text="")
|
|
|
|
|
2014-01-27 18:38:53 +11:00
|
|
|
SEQUENCER_MT_editor_menus.draw_collapsible(context, layout)
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2018-06-28 08:27:03 +02:00
|
|
|
layout.separator_spacer()
|
|
|
|
|
2018-07-02 14:48:40 +02:00
|
|
|
if st.view_type in {'PREVIEW', 'SEQUENCER_PREVIEW'}:
|
2018-10-08 19:10:10 +02:00
|
|
|
layout.prop(st, "display_mode", text="", icon_only=True)
|
2012-09-22 17:40:08 +00:00
|
|
|
|
2018-07-02 14:48:40 +02:00
|
|
|
if st.view_type != 'SEQUENCER':
|
2018-10-08 19:10:10 +02:00
|
|
|
layout.prop(st, "preview_channels", text="", icon_only=True)
|
2012-08-12 13:24:29 +00:00
|
|
|
|
Grease Pencil - Storyboarding Features (merge from GPencil_EditStrokes branch)
This merge-commit brings in a number of new features and workflow/UI improvements for
working with Grease Pencil. While these were originally targetted at improving
the workflow for creating 3D storyboards in Blender using the Grease Pencil,
many of these changes should also prove useful in other workflows too.
The main highlights here are:
1) It is now possible to edit Grease Pencil strokes
- Use D Tab, or toggle the "Enable Editing" toggles in the Toolbar/Properties regions
to enter "Stroke Edit Mode". In this mode, many common editing tools will
operate on Grease Pencil stroke points instead.
- Tools implemented include Select, Select All/Border/Circle/Linked/More/Less,
Grab, Rotate, Scale, Bend, Shear, To Sphere, Mirror, Duplicate, Delete.
- Proportional Editing works when using the transform tools
2) Grease Pencil stroke settings can now be animated
NOTE: Currently drivers don't work, but if time allows, this may still be
added before the release.
3) Strokes can be drawn with "filled" interiors, using a separate set of
colour/opacity settings to the ones used for the lines themselves.
This makes use of OpenGL filled polys, which has the limitation of only
being able to fill convex shapes. Some artifacts may be visible on concave
shapes (e.g. pacman's mouth will be overdrawn)
4) "Volumetric Strokes" - An alternative drawing technique for stroke drawing
has been added which draws strokes as a series of screen-aligned discs.
While this was originally a partial experimental technique at getting better
quality 3D lines, the effects possible using this technique were interesting
enough to warrant making this a dedicated feature. Best results when partial
opacity and large stroke widths are used.
5) Improved Onion Skinning Support
- Different colours can be selected for the before/after ghosts. To do so,
enable the "colour wheel" toggle beside the Onion Skinning toggle, and set
the colours accordingly.
- Different numbers of ghosts can be shown before/after the current frame
6) Grease Pencil datablocks are now attached to the scene by default instead of
the active object.
- For a long time, the object-attachment has proved to be quite problematic
for users to keep track of. Now that this is done at scene level, it is
easier for most users to use.
- An exception for old files (and for any addons which may benefit from object
attachment instead), is that if the active object has a Grease Pencil datablock,
that will be used instead.
- It is not currently possible to choose object-attachment from the UI, but
it is simple to do this from the console instead, by doing:
context.active_object.grease_pencil = bpy.data.grease_pencil["blah"]
7) Various UI Cleanups
- The layers UI has been cleaned up to use a list instead of the nested-panels
design. Apart from saving space, this is also much nicer to look at now.
- The UI code is now all defined in Python. To support this, it has been necessary
to add some new context properties to make it easier to access these settings.
e.g. "gpencil_data" for the datablock
"active_gpencil_layer" and "active_gpencil_frame" for active data,
"editable_gpencil_strokes" for the strokes that can be edited
- The "stroke placement/alignment" settings (previously "Drawing Settings" at the
bottom of the Grease Pencil panel in the Properties Region) is now located in
the toolbar. These were more toolsettings than properties for how GPencil got drawn.
- "Use Sketching Sessions" has been renamed "Continuous Drawing", as per a
suggestion for an earlier discussion on developer.blender.org
- By default, the painting operator will wait for a mouse button to be pressed
before it starts creating the stroke. This is to make it easier to include
this operator in various toolbars/menus/etc. To get it immediately starting
(as when you hold down DKEy to draw), set "wait_for_input" to False.
- GPencil Layers can be rearranged in the "Grease Pencil" mode of the Action Editor
- Toolbar panels have been added to all the other editors which support these.
8) Pie menus for quick-access to tools
A set of experimental pie menus has been included for quick access to many
tools and settings. It is not necessary to use these to get things done,
but they have been designed to help make certain common tasks easier.
- Ctrl-D = The main pie menu. Reveals tools in a context sensitive and
spatially stable manner.
- D Q = "Quick Settings" pie. This allows quick access to the active
layer's settings. Notably, colours, thickness, and turning
onion skinning on/off.
2014-12-01 01:52:06 +13:00
|
|
|
if st.view_type in {'PREVIEW', 'SEQUENCER_PREVIEW'}:
|
|
|
|
gpd = context.gpencil_data
|
2018-12-17 17:20:24 +11:00
|
|
|
tool_settings = context.tool_settings
|
Grease Pencil - Storyboarding Features (merge from GPencil_EditStrokes branch)
This merge-commit brings in a number of new features and workflow/UI improvements for
working with Grease Pencil. While these were originally targetted at improving
the workflow for creating 3D storyboards in Blender using the Grease Pencil,
many of these changes should also prove useful in other workflows too.
The main highlights here are:
1) It is now possible to edit Grease Pencil strokes
- Use D Tab, or toggle the "Enable Editing" toggles in the Toolbar/Properties regions
to enter "Stroke Edit Mode". In this mode, many common editing tools will
operate on Grease Pencil stroke points instead.
- Tools implemented include Select, Select All/Border/Circle/Linked/More/Less,
Grab, Rotate, Scale, Bend, Shear, To Sphere, Mirror, Duplicate, Delete.
- Proportional Editing works when using the transform tools
2) Grease Pencil stroke settings can now be animated
NOTE: Currently drivers don't work, but if time allows, this may still be
added before the release.
3) Strokes can be drawn with "filled" interiors, using a separate set of
colour/opacity settings to the ones used for the lines themselves.
This makes use of OpenGL filled polys, which has the limitation of only
being able to fill convex shapes. Some artifacts may be visible on concave
shapes (e.g. pacman's mouth will be overdrawn)
4) "Volumetric Strokes" - An alternative drawing technique for stroke drawing
has been added which draws strokes as a series of screen-aligned discs.
While this was originally a partial experimental technique at getting better
quality 3D lines, the effects possible using this technique were interesting
enough to warrant making this a dedicated feature. Best results when partial
opacity and large stroke widths are used.
5) Improved Onion Skinning Support
- Different colours can be selected for the before/after ghosts. To do so,
enable the "colour wheel" toggle beside the Onion Skinning toggle, and set
the colours accordingly.
- Different numbers of ghosts can be shown before/after the current frame
6) Grease Pencil datablocks are now attached to the scene by default instead of
the active object.
- For a long time, the object-attachment has proved to be quite problematic
for users to keep track of. Now that this is done at scene level, it is
easier for most users to use.
- An exception for old files (and for any addons which may benefit from object
attachment instead), is that if the active object has a Grease Pencil datablock,
that will be used instead.
- It is not currently possible to choose object-attachment from the UI, but
it is simple to do this from the console instead, by doing:
context.active_object.grease_pencil = bpy.data.grease_pencil["blah"]
7) Various UI Cleanups
- The layers UI has been cleaned up to use a list instead of the nested-panels
design. Apart from saving space, this is also much nicer to look at now.
- The UI code is now all defined in Python. To support this, it has been necessary
to add some new context properties to make it easier to access these settings.
e.g. "gpencil_data" for the datablock
"active_gpencil_layer" and "active_gpencil_frame" for active data,
"editable_gpencil_strokes" for the strokes that can be edited
- The "stroke placement/alignment" settings (previously "Drawing Settings" at the
bottom of the Grease Pencil panel in the Properties Region) is now located in
the toolbar. These were more toolsettings than properties for how GPencil got drawn.
- "Use Sketching Sessions" has been renamed "Continuous Drawing", as per a
suggestion for an earlier discussion on developer.blender.org
- By default, the painting operator will wait for a mouse button to be pressed
before it starts creating the stroke. This is to make it easier to include
this operator in various toolbars/menus/etc. To get it immediately starting
(as when you hold down DKEy to draw), set "wait_for_input" to False.
- GPencil Layers can be rearranged in the "Grease Pencil" mode of the Action Editor
- Toolbar panels have been added to all the other editors which support these.
8) Pie menus for quick-access to tools
A set of experimental pie menus has been included for quick access to many
tools and settings. It is not necessary to use these to get things done,
but they have been designed to help make certain common tasks easier.
- Ctrl-D = The main pie menu. Reveals tools in a context sensitive and
spatially stable manner.
- D Q = "Quick Settings" pie. This allows quick access to the active
layer's settings. Notably, colours, thickness, and turning
onion skinning on/off.
2014-12-01 01:52:06 +13:00
|
|
|
|
|
|
|
# Proportional editing
|
|
|
|
if gpd and gpd.use_stroke_edit_mode:
|
|
|
|
row = layout.row(align=True)
|
2019-04-30 13:42:18 +10:00
|
|
|
row.prop(tool_settings, "use_proportional_edit", icon_only=True)
|
|
|
|
if tool_settings.use_proportional_edit:
|
2018-12-17 17:20:24 +11:00
|
|
|
row.prop(tool_settings, "proportional_edit_falloff", icon_only=True)
|
2015-01-29 15:35:06 +11:00
|
|
|
|
2018-06-28 08:27:03 +02:00
|
|
|
|
2014-01-27 18:38:53 +11:00
|
|
|
class SEQUENCER_MT_editor_menus(Menu):
|
|
|
|
bl_idname = "SEQUENCER_MT_editor_menus"
|
|
|
|
bl_label = ""
|
|
|
|
|
|
|
|
def draw(self, context):
|
2018-12-20 12:02:21 +11:00
|
|
|
layout = self.layout
|
2014-01-27 18:38:53 +11:00
|
|
|
st = context.space_data
|
|
|
|
|
|
|
|
layout.menu("SEQUENCER_MT_view")
|
|
|
|
|
|
|
|
if st.view_type in {'SEQUENCER', 'SEQUENCER_PREVIEW'}:
|
|
|
|
layout.menu("SEQUENCER_MT_select")
|
|
|
|
layout.menu("SEQUENCER_MT_marker")
|
|
|
|
layout.menu("SEQUENCER_MT_add")
|
|
|
|
layout.menu("SEQUENCER_MT_strip")
|
|
|
|
|
|
|
|
|
2011-08-12 06:57:00 +00:00
|
|
|
class SEQUENCER_MT_view_toggle(Menu):
|
2011-09-15 13:20:18 +00:00
|
|
|
bl_label = "View Type"
|
2009-12-14 21:42:25 +00:00
|
|
|
|
2019-04-19 07:32:24 +02:00
|
|
|
def draw(self, _context):
|
2009-12-14 21:42:25 +00:00
|
|
|
layout = self.layout
|
2009-12-16 13:27:30 +00:00
|
|
|
|
2009-12-14 21:42:25 +00:00
|
|
|
layout.operator("sequencer.view_toggle").type = 'SEQUENCER'
|
|
|
|
layout.operator("sequencer.view_toggle").type = 'PREVIEW'
|
|
|
|
layout.operator("sequencer.view_toggle").type = 'SEQUENCER_PREVIEW'
|
|
|
|
|
2009-10-31 23:35:56 +00:00
|
|
|
|
2019-04-28 14:13:41 -07:00
|
|
|
class SEQUENCER_MT_view_cache(Menu):
|
|
|
|
bl_label = "Cache"
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
|
|
|
|
|
|
|
ed = context.scene.sequence_editor
|
|
|
|
layout.prop(ed, "show_cache")
|
|
|
|
layout.separator()
|
|
|
|
|
|
|
|
col = layout.column()
|
|
|
|
col.enabled = ed.show_cache
|
|
|
|
|
|
|
|
col.prop(ed, "show_cache_final_out")
|
|
|
|
col.prop(ed, "show_cache_raw")
|
|
|
|
col.prop(ed, "show_cache_preprocessed")
|
|
|
|
col.prop(ed, "show_cache_composite")
|
|
|
|
|
|
|
|
|
2019-05-20 18:04:35 +02:00
|
|
|
class SEQUENCER_MT_range(Menu):
|
|
|
|
bl_label = "Range"
|
|
|
|
|
2019-05-28 16:22:21 +10:00
|
|
|
def draw(self, _context):
|
2019-05-20 18:04:35 +02:00
|
|
|
layout = self.layout
|
|
|
|
|
2019-05-22 00:27:01 +10:00
|
|
|
layout.operator("anim.previewrange_set", text="Set Preview Range")
|
|
|
|
layout.operator("anim.previewrange_clear", text="Clear Preview Range")
|
2019-05-20 18:04:35 +02:00
|
|
|
|
|
|
|
layout.separator()
|
|
|
|
|
2019-05-22 00:27:01 +10:00
|
|
|
layout.operator("anim.start_frame_set", text="Set Start Frame")
|
|
|
|
layout.operator("anim.end_frame_set", text="Set End Frame")
|
2019-05-20 18:04:35 +02:00
|
|
|
|
|
|
|
|
2019-08-09 15:35:42 +02:00
|
|
|
class SEQUENCER_MT_preview_zoom(Menu):
|
|
|
|
bl_label = "Fractional Zoom"
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
|
|
|
layout.operator_context = 'INVOKE_REGION_PREVIEW'
|
|
|
|
|
|
|
|
ratios = ((1, 8), (1, 4), (1, 2), (1, 1), (2, 1), (4, 1), (8, 1))
|
|
|
|
|
|
|
|
for i, (a, b) in enumerate(ratios):
|
|
|
|
if i in {3, 4}: # Draw separators around Zoom 1:1.
|
|
|
|
layout.separator()
|
|
|
|
|
|
|
|
layout.operator(
|
|
|
|
"sequencer.view_zoom_ratio",
|
2019-08-20 17:26:46 +02:00
|
|
|
text=iface_("Zoom %d:%d") % (a, b),
|
2019-08-09 15:35:42 +02:00
|
|
|
translate=False,
|
|
|
|
).ratio = a / b
|
|
|
|
layout.operator_context = 'INVOKE_DEFAULT'
|
|
|
|
|
|
|
|
|
2011-08-12 06:57:00 +00:00
|
|
|
class SEQUENCER_MT_view(Menu):
|
2011-09-15 13:20:18 +00:00
|
|
|
bl_label = "View"
|
2009-10-31 19:31:45 +00:00
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
|
|
|
|
|
|
|
st = context.space_data
|
2014-12-18 13:47:04 +01:00
|
|
|
is_preview = st.view_type in {'PREVIEW', 'SEQUENCER_PREVIEW'}
|
|
|
|
is_sequencer_view = st.view_type in {'SEQUENCER', 'SEQUENCER_PREVIEW'}
|
2019-08-09 15:35:42 +02:00
|
|
|
scene = context.scene
|
|
|
|
ed = scene.sequence_editor
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2014-12-18 13:47:04 +01:00
|
|
|
if st.view_type == 'PREVIEW':
|
2012-09-21 13:29:38 +00:00
|
|
|
# Specifying the REGION_PREVIEW context is needed in preview-only
|
|
|
|
# mode, else the lookup for the shortcut will fail in
|
|
|
|
# wm_keymap_item_find_props() (see #32595).
|
|
|
|
layout.operator_context = 'INVOKE_REGION_PREVIEW'
|
2019-04-18 12:16:03 +02:00
|
|
|
layout.prop(st, "show_region_ui")
|
2012-09-21 13:29:38 +00:00
|
|
|
layout.operator_context = 'INVOKE_DEFAULT'
|
2019-05-17 00:28:22 +10:00
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
if st.view_type == 'SEQUENCER':
|
2019-05-16 14:38:44 +02:00
|
|
|
layout.prop(st, "show_backdrop", text="Preview as Backdrop")
|
2010-09-07 15:17:42 +00:00
|
|
|
|
2010-07-30 14:56:17 +00:00
|
|
|
layout.separator()
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2014-12-18 13:47:04 +01:00
|
|
|
if is_sequencer_view:
|
2015-09-10 15:31:37 +10:00
|
|
|
layout.operator_context = 'INVOKE_REGION_WIN'
|
2019-05-16 14:38:44 +02:00
|
|
|
layout.operator("sequencer.view_selected", text="Frame Selected")
|
2019-05-20 18:04:35 +02:00
|
|
|
layout.operator("sequencer.view_all", text="Frame All")
|
2019-05-22 00:27:01 +10:00
|
|
|
layout.operator("view2d.zoom_border", text="Zoom")
|
2019-05-20 18:04:35 +02:00
|
|
|
|
2019-08-09 15:35:42 +02:00
|
|
|
if is_preview:
|
|
|
|
layout.operator_context = 'INVOKE_REGION_PREVIEW'
|
|
|
|
layout.separator()
|
|
|
|
|
|
|
|
layout.operator("sequencer.view_all_preview", text="Fit Preview in Window")
|
|
|
|
|
2019-08-10 00:21:47 +10:00
|
|
|
if is_sequencer_view:
|
2019-08-09 15:35:42 +02:00
|
|
|
layout.menu("SEQUENCER_MT_preview_zoom", text="Fractional Preview Zoom")
|
2019-08-10 00:21:47 +10:00
|
|
|
else:
|
|
|
|
layout.operator("view2d.zoom_border", text="Zoom")
|
2019-08-09 15:35:42 +02:00
|
|
|
layout.menu("SEQUENCER_MT_preview_zoom")
|
|
|
|
|
|
|
|
layout.operator_context = 'INVOKE_DEFAULT'
|
|
|
|
|
|
|
|
if is_sequencer_view:
|
2019-05-20 18:04:35 +02:00
|
|
|
layout.separator()
|
2019-05-18 10:05:13 +02:00
|
|
|
|
2015-09-10 15:31:37 +10:00
|
|
|
layout.operator_context = 'INVOKE_DEFAULT'
|
2019-05-18 10:05:13 +02:00
|
|
|
layout.menu("SEQUENCER_MT_navigation")
|
2019-05-20 18:04:35 +02:00
|
|
|
layout.menu("SEQUENCER_MT_range")
|
2019-05-18 10:05:13 +02:00
|
|
|
|
|
|
|
layout.separator()
|
2019-07-10 12:55:15 +02:00
|
|
|
layout.operator_context = 'INVOKE_REGION_WIN'
|
2019-06-25 10:00:20 +02:00
|
|
|
layout.operator("sequencer.refresh_all", icon='FILE_REFRESH', text="Refresh All")
|
|
|
|
|
|
|
|
layout.separator()
|
2019-07-10 12:55:15 +02:00
|
|
|
layout.operator_context = 'INVOKE_DEFAULT'
|
2019-06-25 10:00:20 +02:00
|
|
|
|
2019-08-09 15:35:42 +02:00
|
|
|
layout.prop(st, "show_strip_offset")
|
|
|
|
layout.prop(st, "show_marker_lines")
|
2014-07-22 12:03:15 +10:00
|
|
|
|
2019-08-09 15:35:42 +02:00
|
|
|
if is_preview:
|
2014-04-27 22:59:30 +02:00
|
|
|
layout.separator()
|
2019-08-09 15:35:42 +02:00
|
|
|
if st.display_mode == 'IMAGE':
|
|
|
|
layout.prop(ed, "show_overlay", text="Show Frame Overlay")
|
|
|
|
layout.prop(st, "show_safe_areas", text="Show Safe Areas")
|
|
|
|
layout.prop(st, "show_metadata", text="Show Metadata")
|
|
|
|
layout.prop(st, "show_annotation", text="Show Annotations")
|
|
|
|
elif st.display_mode == 'WAVEFORM':
|
|
|
|
layout.prop(st, "show_separate_color", text="Show Separate Color Channels")
|
2014-07-22 12:03:15 +10:00
|
|
|
|
2014-12-18 13:47:04 +01:00
|
|
|
if is_sequencer_view:
|
2019-05-18 10:05:13 +02:00
|
|
|
layout.separator()
|
|
|
|
|
|
|
|
layout.menu("SEQUENCER_MT_view_cache")
|
2018-09-03 18:58:41 +02:00
|
|
|
layout.prop_menu_enum(st, "waveform_display_type")
|
2014-12-18 13:47:04 +01:00
|
|
|
|
2009-12-03 16:28:50 +00:00
|
|
|
layout.separator()
|
2012-09-21 15:19:26 +00:00
|
|
|
|
2019-03-19 21:41:12 +01:00
|
|
|
layout.operator("render.opengl", text="Sequence Render Image", icon='RENDER_STILL').sequencer = True
|
2018-11-05 15:12:27 +01:00
|
|
|
props = layout.operator("render.opengl", text="Sequence Render Animation", icon='RENDER_ANIMATION')
|
2018-10-08 19:10:10 +02:00
|
|
|
props.animation = True
|
|
|
|
props.sequencer = True
|
|
|
|
|
2019-08-09 14:08:20 +02:00
|
|
|
layout.separator()
|
|
|
|
layout.operator("sequencer.export_subtitles", text="Export Subtitles", icon="EXPORT")
|
|
|
|
|
2018-11-05 15:12:27 +01:00
|
|
|
layout.separator()
|
|
|
|
|
2018-05-24 18:35:19 +02:00
|
|
|
layout.menu("INFO_MT_area")
|
2009-10-31 23:35:56 +00:00
|
|
|
|
2009-12-04 17:54:48 +00:00
|
|
|
|
2019-05-20 18:04:35 +02:00
|
|
|
class SEQUENCER_MT_select_handle(Menu):
|
|
|
|
bl_label = "Select Handle"
|
|
|
|
|
2019-05-28 16:22:21 +10:00
|
|
|
def draw(self, _context):
|
2019-05-20 18:04:35 +02:00
|
|
|
layout = self.layout
|
|
|
|
|
2019-05-22 14:59:04 +02:00
|
|
|
layout.operator("sequencer.select_handles", text="Both").side = 'BOTH'
|
2019-05-20 18:04:35 +02:00
|
|
|
layout.operator("sequencer.select_handles", text="Left").side = 'LEFT'
|
|
|
|
layout.operator("sequencer.select_handles", text="Right").side = 'RIGHT'
|
|
|
|
|
|
|
|
|
|
|
|
class SEQUENCER_MT_select_channel(Menu):
|
|
|
|
bl_label = "Select Channel"
|
|
|
|
|
2019-05-28 16:22:21 +10:00
|
|
|
def draw(self, _context):
|
2019-05-20 18:04:35 +02:00
|
|
|
layout = self.layout
|
|
|
|
|
|
|
|
layout.operator("sequencer.select_active_side", text="Left").side = 'LEFT'
|
|
|
|
layout.operator("sequencer.select_active_side", text="Right").side = 'RIGHT'
|
|
|
|
|
|
|
|
|
|
|
|
class SEQUENCER_MT_select_linked(Menu):
|
|
|
|
bl_label = "Select Linked"
|
|
|
|
|
2019-05-28 16:22:21 +10:00
|
|
|
def draw(self, _context):
|
2019-05-20 18:04:35 +02:00
|
|
|
layout = self.layout
|
|
|
|
|
2019-05-22 00:27:01 +10:00
|
|
|
layout.operator("sequencer.select_linked", text="All")
|
|
|
|
layout.operator("sequencer.select_less", text="Less")
|
|
|
|
layout.operator("sequencer.select_more", text="More")
|
|
|
|
|
2019-05-20 18:04:35 +02:00
|
|
|
|
|
|
|
class SEQUENCER_MT_select_playhead(Menu):
|
|
|
|
bl_label = "Select Playhead"
|
|
|
|
|
2019-05-28 16:22:21 +10:00
|
|
|
def draw(self, _context):
|
2019-05-20 18:04:35 +02:00
|
|
|
layout = self.layout
|
2019-05-22 14:59:04 +02:00
|
|
|
|
2019-05-20 18:04:35 +02:00
|
|
|
props = layout.operator("sequencer.select", text="Left")
|
|
|
|
props.left_right = 'LEFT'
|
|
|
|
props.linked_time = True
|
|
|
|
props = layout.operator("sequencer.select", text="Right")
|
|
|
|
props.left_right = 'RIGHT'
|
|
|
|
props.linked_time = True
|
|
|
|
|
|
|
|
|
2011-08-12 06:57:00 +00:00
|
|
|
class SEQUENCER_MT_select(Menu):
|
2011-09-15 13:20:18 +00:00
|
|
|
bl_label = "Select"
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2019-04-19 07:32:24 +02:00
|
|
|
def draw(self, _context):
|
2009-10-31 19:31:45 +00:00
|
|
|
layout = self.layout
|
|
|
|
|
2018-07-03 15:44:56 +02:00
|
|
|
layout.operator("sequencer.select_all", text="All").action = 'SELECT'
|
|
|
|
layout.operator("sequencer.select_all", text="None").action = 'DESELECT'
|
|
|
|
layout.operator("sequencer.select_all", text="Invert").action = 'INVERT'
|
|
|
|
|
|
|
|
layout.separator()
|
|
|
|
|
2019-05-22 00:27:01 +10:00
|
|
|
layout.operator("sequencer.select_box", text="Box Select")
|
2019-05-18 01:11:45 +02:00
|
|
|
|
|
|
|
layout.separator()
|
|
|
|
|
2019-05-22 00:27:01 +10:00
|
|
|
layout.menu("SEQUENCER_MT_select_playhead", text="Playhead")
|
|
|
|
layout.menu("SEQUENCER_MT_select_handle", text="Handle")
|
|
|
|
layout.menu("SEQUENCER_MT_select_channel", text="Channel")
|
|
|
|
layout.menu("SEQUENCER_MT_select_linked", text="Linked")
|
2014-09-17 18:36:17 +10:00
|
|
|
|
2009-11-23 00:27:30 +00:00
|
|
|
layout.separator()
|
2012-03-26 13:45:06 +00:00
|
|
|
layout.operator_menu_enum("sequencer.select_grouped", "type", text="Grouped")
|
2009-06-08 16:48:12 +00:00
|
|
|
|
2009-10-31 23:35:56 +00:00
|
|
|
|
2011-08-12 06:57:00 +00:00
|
|
|
class SEQUENCER_MT_marker(Menu):
|
2011-09-15 13:20:18 +00:00
|
|
|
bl_label = "Marker"
|
2009-10-31 19:31:45 +00:00
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
|
|
|
|
2018-11-05 15:11:18 +01:00
|
|
|
st = context.space_data
|
|
|
|
is_sequencer_view = st.view_type in {'SEQUENCER', 'SEQUENCER_PREVIEW'}
|
|
|
|
|
2019-06-11 16:08:32 +10:00
|
|
|
from bl_ui.space_time import marker_menu_generic
|
2019-03-13 11:52:54 +11:00
|
|
|
marker_menu_generic(layout, context)
|
2009-06-08 16:48:12 +00:00
|
|
|
|
2018-11-05 15:11:18 +01:00
|
|
|
if is_sequencer_view:
|
|
|
|
layout.prop(st, "use_marker_sync")
|
2009-10-31 23:35:56 +00:00
|
|
|
|
2018-11-08 16:01:02 +01:00
|
|
|
|
2019-01-15 18:33:37 +01:00
|
|
|
class SEQUENCER_MT_change(Menu):
|
|
|
|
bl_label = "Change"
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
|
|
|
strip = act_strip(context)
|
|
|
|
|
|
|
|
layout.operator_context = 'INVOKE_REGION_WIN'
|
|
|
|
|
|
|
|
layout.operator_menu_enum("sequencer.change_effect_input", "swap")
|
|
|
|
layout.operator_menu_enum("sequencer.change_effect_type", "type")
|
|
|
|
prop = layout.operator("sequencer.change_path", text="Path/Files")
|
|
|
|
|
|
|
|
if strip:
|
2019-06-22 11:02:33 +10:00
|
|
|
strip_type = strip.type
|
2019-01-15 18:33:37 +01:00
|
|
|
|
2019-06-22 11:02:33 +10:00
|
|
|
if strip_type == 'IMAGE':
|
2019-01-15 18:33:37 +01:00
|
|
|
prop.filter_image = True
|
2019-06-22 11:02:33 +10:00
|
|
|
elif strip_type == 'MOVIE':
|
2019-01-15 18:33:37 +01:00
|
|
|
prop.filter_movie = True
|
2019-06-22 11:02:33 +10:00
|
|
|
elif strip_type == 'SOUND':
|
2019-01-15 18:33:37 +01:00
|
|
|
prop.filter_sound = True
|
|
|
|
|
|
|
|
|
2019-05-18 10:05:13 +02:00
|
|
|
class SEQUENCER_MT_navigation(Menu):
|
|
|
|
bl_label = "Navigation"
|
2014-09-01 14:22:34 +02:00
|
|
|
|
2019-05-28 16:22:21 +10:00
|
|
|
def draw(self, _context):
|
2014-09-01 14:22:34 +02:00
|
|
|
layout = self.layout
|
|
|
|
|
2019-05-20 18:04:35 +02:00
|
|
|
layout.operator("screen.animation_play")
|
|
|
|
|
|
|
|
layout.separator()
|
|
|
|
|
2019-05-18 10:05:13 +02:00
|
|
|
layout.operator("sequencer.view_frame", text="Go to Playhead")
|
2014-09-01 14:22:34 +02:00
|
|
|
|
2016-03-17 10:57:40 +11:00
|
|
|
layout.separator()
|
|
|
|
|
|
|
|
props = layout.operator("sequencer.strip_jump", text="Jump to Previous Strip")
|
|
|
|
props.next = False
|
|
|
|
props.center = False
|
|
|
|
props = layout.operator("sequencer.strip_jump", text="Jump to Next Strip")
|
|
|
|
props.next = True
|
|
|
|
props.center = False
|
|
|
|
|
|
|
|
layout.separator()
|
|
|
|
|
|
|
|
props = layout.operator("sequencer.strip_jump", text="Jump to Previous Strip (Center)")
|
|
|
|
props.next = False
|
|
|
|
props.center = True
|
|
|
|
props = layout.operator("sequencer.strip_jump", text="Jump to Next Strip (Center)")
|
|
|
|
props.next = True
|
|
|
|
props.center = True
|
|
|
|
|
2014-09-17 18:36:17 +10:00
|
|
|
|
2011-08-12 06:57:00 +00:00
|
|
|
class SEQUENCER_MT_add(Menu):
|
2011-09-15 13:20:18 +00:00
|
|
|
bl_label = "Add"
|
2019-05-13 17:27:40 +02:00
|
|
|
bl_translation_context = i18n_contexts.operator_default
|
2009-10-31 19:31:45 +00:00
|
|
|
|
|
|
|
def draw(self, context):
|
2012-07-29 12:07:06 +00:00
|
|
|
|
2018-11-08 16:01:02 +01:00
|
|
|
layout = self.layout
|
2009-10-31 19:31:45 +00:00
|
|
|
layout.operator_context = 'INVOKE_REGION_WIN'
|
|
|
|
|
2018-12-29 10:19:38 +11:00
|
|
|
bpy_data_scenes_len = len(bpy.data.scenes)
|
|
|
|
if bpy_data_scenes_len > 10:
|
2010-12-02 22:58:23 +00:00
|
|
|
layout.operator_context = 'INVOKE_DEFAULT'
|
2018-11-08 16:01:02 +01:00
|
|
|
layout.operator("sequencer.scene_strip_add", text="Scene...", icon='SCENE_DATA')
|
2018-12-29 10:19:38 +11:00
|
|
|
elif bpy_data_scenes_len > 1:
|
2018-11-08 16:01:02 +01:00
|
|
|
layout.operator_menu_enum("sequencer.scene_strip_add", "scene", text="Scene", icon='SCENE_DATA')
|
2010-12-02 22:58:23 +00:00
|
|
|
else:
|
2018-11-08 16:01:02 +01:00
|
|
|
layout.menu("SEQUENCER_MT_add_empty", text="Scene", icon='SCENE_DATA')
|
2018-12-29 10:19:38 +11:00
|
|
|
del bpy_data_scenes_len
|
2010-12-02 22:58:23 +00:00
|
|
|
|
2018-12-29 10:19:38 +11:00
|
|
|
bpy_data_movieclips_len = len(bpy.data.movieclips)
|
|
|
|
if bpy_data_movieclips_len > 10:
|
2012-03-21 18:02:29 +00:00
|
|
|
layout.operator_context = 'INVOKE_DEFAULT'
|
2019-01-02 19:17:30 +11:00
|
|
|
layout.operator("sequencer.movieclip_strip_add", text="Clip...", icon='TRACKER')
|
2018-12-29 10:19:38 +11:00
|
|
|
elif bpy_data_movieclips_len > 0:
|
2019-01-02 19:17:30 +11:00
|
|
|
layout.operator_menu_enum("sequencer.movieclip_strip_add", "clip", text="Clip", icon='TRACKER')
|
2012-03-21 18:02:29 +00:00
|
|
|
else:
|
2019-01-02 19:17:30 +11:00
|
|
|
layout.menu("SEQUENCER_MT_add_empty", text="Clip", icon='TRACKER')
|
2018-12-29 10:19:38 +11:00
|
|
|
del bpy_data_movieclips_len
|
2012-03-21 18:02:29 +00:00
|
|
|
|
2018-12-29 10:19:38 +11:00
|
|
|
bpy_data_masks_len = len(bpy.data.masks)
|
|
|
|
if bpy_data_masks_len > 10:
|
2012-06-07 18:24:36 +00:00
|
|
|
layout.operator_context = 'INVOKE_DEFAULT'
|
2018-11-08 16:01:02 +01:00
|
|
|
layout.operator("sequencer.mask_strip_add", text="Mask...", icon='MOD_MASK')
|
2018-12-29 10:19:38 +11:00
|
|
|
elif bpy_data_masks_len > 0:
|
2018-11-08 16:01:02 +01:00
|
|
|
layout.operator_menu_enum("sequencer.mask_strip_add", "mask", text="Mask", icon='MOD_MASK')
|
2012-06-07 18:24:36 +00:00
|
|
|
else:
|
2018-11-08 16:01:02 +01:00
|
|
|
layout.menu("SEQUENCER_MT_add_empty", text="Mask", icon='MOD_MASK')
|
2018-12-29 10:19:38 +11:00
|
|
|
del bpy_data_masks_len
|
2018-11-08 16:01:02 +01:00
|
|
|
|
|
|
|
layout.separator()
|
|
|
|
|
|
|
|
layout.operator("sequencer.movie_strip_add", text="Movie", icon='FILE_MOVIE')
|
|
|
|
layout.operator("sequencer.sound_strip_add", text="Sound", icon='FILE_SOUND')
|
|
|
|
layout.operator("sequencer.image_strip_add", text="Image/Sequence", icon='FILE_IMAGE')
|
|
|
|
|
|
|
|
layout.separator()
|
|
|
|
|
|
|
|
layout.operator_context = 'INVOKE_REGION_WIN'
|
|
|
|
layout.operator("sequencer.effect_strip_add", text="Color", icon='COLOR').type = 'COLOR'
|
|
|
|
layout.operator("sequencer.effect_strip_add", text="Text", icon='FONT_DATA').type = 'TEXT'
|
|
|
|
|
|
|
|
layout.separator()
|
2012-06-07 18:24:36 +00:00
|
|
|
|
2018-11-08 16:01:02 +01:00
|
|
|
layout.operator("sequencer.effect_strip_add", text="Adjustment Layer", icon='COLOR').type = 'ADJUSTMENT'
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2018-11-08 16:01:02 +01:00
|
|
|
layout.operator_context = 'INVOKE_DEFAULT'
|
2019-05-18 01:11:45 +02:00
|
|
|
layout.menu("SEQUENCER_MT_add_effect", icon='SHADERFX')
|
2009-06-08 16:48:12 +00:00
|
|
|
|
2018-11-08 16:01:02 +01:00
|
|
|
col = layout.column()
|
2019-05-18 01:11:45 +02:00
|
|
|
col.menu("SEQUENCER_MT_add_transitions", icon='ARROW_LEFTRIGHT')
|
2019-01-23 16:58:37 +01:00
|
|
|
col.enabled = selected_sequences_len(context) >= 2
|
2018-11-08 16:01:02 +01:00
|
|
|
|
2009-10-31 23:35:56 +00:00
|
|
|
|
2018-11-08 16:01:02 +01:00
|
|
|
class SEQUENCER_MT_add_empty(Menu):
|
|
|
|
bl_label = "Empty"
|
2018-07-30 16:46:55 +10:00
|
|
|
|
2019-04-19 07:32:24 +02:00
|
|
|
def draw(self, _context):
|
2018-07-30 16:46:55 +10:00
|
|
|
layout = self.layout
|
|
|
|
|
2018-11-08 16:01:02 +01:00
|
|
|
layout.label(text="No Items Available")
|
|
|
|
|
|
|
|
|
|
|
|
class SEQUENCER_MT_add_transitions(Menu):
|
2019-08-12 15:46:07 -04:00
|
|
|
bl_label = "Transition"
|
2018-11-08 16:01:02 +01:00
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
|
|
|
layout = self.layout
|
|
|
|
|
|
|
|
col = layout.column()
|
2019-05-18 01:11:45 +02:00
|
|
|
|
|
|
|
col.operator("sequencer.crossfade_sounds", text="Sound Crossfade")
|
|
|
|
|
|
|
|
col.separator()
|
|
|
|
|
2018-11-08 16:01:02 +01:00
|
|
|
col.operator("sequencer.effect_strip_add", text="Cross").type = 'CROSS'
|
|
|
|
col.operator("sequencer.effect_strip_add", text="Gamma Cross").type = 'GAMMA_CROSS'
|
|
|
|
|
|
|
|
col.separator()
|
|
|
|
|
|
|
|
col.operator("sequencer.effect_strip_add", text="Wipe").type = 'WIPE'
|
2019-01-23 16:58:37 +01:00
|
|
|
col.enabled = selected_sequences_len(context) >= 2
|
2018-07-30 16:46:55 +10:00
|
|
|
|
|
|
|
|
2011-08-12 06:57:00 +00:00
|
|
|
class SEQUENCER_MT_add_effect(Menu):
|
2017-05-28 20:41:23 -04:00
|
|
|
bl_label = "Effect Strip"
|
2009-10-31 19:31:45 +00:00
|
|
|
|
|
|
|
def draw(self, context):
|
2012-07-29 12:07:06 +00:00
|
|
|
|
2018-11-08 16:01:02 +01:00
|
|
|
layout = self.layout
|
2009-10-31 19:31:45 +00:00
|
|
|
layout.operator_context = 'INVOKE_REGION_WIN'
|
|
|
|
|
2018-11-08 16:01:02 +01:00
|
|
|
col = layout.column()
|
|
|
|
col.operator("sequencer.effect_strip_add", text="Add").type = 'ADD'
|
|
|
|
col.operator("sequencer.effect_strip_add", text="Subtract").type = 'SUBTRACT'
|
|
|
|
col.operator("sequencer.effect_strip_add", text="Multiply").type = 'MULTIPLY'
|
|
|
|
col.operator("sequencer.effect_strip_add", text="Over Drop").type = 'OVER_DROP'
|
|
|
|
col.operator("sequencer.effect_strip_add", text="Alpha Over").type = 'ALPHA_OVER'
|
|
|
|
col.operator("sequencer.effect_strip_add", text="Alpha Under").type = 'ALPHA_UNDER'
|
|
|
|
col.operator("sequencer.effect_strip_add", text="Color Mix").type = 'COLORMIX'
|
2019-01-23 16:58:37 +01:00
|
|
|
col.enabled = selected_sequences_len(context) >= 2
|
2018-11-08 16:01:02 +01:00
|
|
|
|
|
|
|
layout.separator()
|
|
|
|
|
2011-09-21 15:18:38 +00:00
|
|
|
layout.operator("sequencer.effect_strip_add", text="Multicam Selector").type = 'MULTICAM'
|
2018-11-08 16:01:02 +01:00
|
|
|
|
|
|
|
layout.separator()
|
|
|
|
|
|
|
|
col = layout.column()
|
|
|
|
col.operator("sequencer.effect_strip_add", text="Transform").type = 'TRANSFORM'
|
|
|
|
col.operator("sequencer.effect_strip_add", text="Speed Control").type = 'SPEED'
|
|
|
|
|
|
|
|
col.separator()
|
|
|
|
|
|
|
|
col.operator("sequencer.effect_strip_add", text="Glow").type = 'GLOW'
|
|
|
|
col.operator("sequencer.effect_strip_add", text="Gaussian Blur").type = 'GAUSSIAN_BLUR'
|
2019-01-23 16:58:37 +01:00
|
|
|
col.enabled = selected_sequences_len(context) != 0
|
2009-06-08 16:48:12 +00:00
|
|
|
|
2009-10-31 23:35:56 +00:00
|
|
|
|
2017-10-09 13:47:05 +11:00
|
|
|
class SEQUENCER_MT_strip_transform(Menu):
|
|
|
|
bl_label = "Transform"
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2019-04-19 07:32:24 +02:00
|
|
|
def draw(self, _context):
|
2009-10-31 19:31:45 +00:00
|
|
|
layout = self.layout
|
|
|
|
|
2019-07-10 12:55:15 +02:00
|
|
|
layout.operator("transform.seq_slide", text="Move")
|
2019-05-18 01:11:45 +02:00
|
|
|
layout.operator("transform.transform", text="Move/Extend from Playhead").mode = 'TIME_EXTEND'
|
2017-10-09 13:47:05 +11:00
|
|
|
layout.operator("sequencer.slip", text="Slip Strip Contents")
|
2013-03-26 15:00:56 +00:00
|
|
|
|
2019-05-18 10:05:13 +02:00
|
|
|
layout.separator()
|
|
|
|
layout.operator("sequencer.snap")
|
|
|
|
layout.operator("sequencer.offset_clear")
|
|
|
|
|
2009-11-23 00:27:30 +00:00
|
|
|
layout.separator()
|
2017-10-09 13:47:05 +11:00
|
|
|
layout.operator_menu_enum("sequencer.swap", "side")
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2009-11-23 00:27:30 +00:00
|
|
|
layout.separator()
|
2017-10-09 13:47:05 +11:00
|
|
|
layout.operator("sequencer.gap_remove").all = False
|
|
|
|
layout.operator("sequencer.gap_insert")
|
2009-10-31 19:31:45 +00:00
|
|
|
|
|
|
|
|
2017-10-09 13:47:05 +11:00
|
|
|
class SEQUENCER_MT_strip_input(Menu):
|
|
|
|
bl_label = "Inputs"
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
2009-10-31 19:31:45 +00:00
|
|
|
strip = act_strip(context)
|
|
|
|
|
2017-10-09 13:47:05 +11:00
|
|
|
layout.operator("sequencer.reload", text="Reload Strips")
|
|
|
|
layout.operator("sequencer.reload", text="Reload Strips and Adjust Length").adjust_length = True
|
|
|
|
prop = layout.operator("sequencer.change_path", text="Change Path/Files")
|
|
|
|
layout.operator("sequencer.swap_data", text="Swap Data")
|
|
|
|
|
2009-10-31 19:31:45 +00:00
|
|
|
if strip:
|
2019-06-22 11:02:33 +10:00
|
|
|
strip_type = strip.type
|
2010-04-17 19:05:53 +00:00
|
|
|
|
2019-06-22 11:02:33 +10:00
|
|
|
if strip_type == 'IMAGE':
|
2017-10-09 13:47:05 +11:00
|
|
|
prop.filter_image = True
|
2019-06-22 11:02:33 +10:00
|
|
|
elif strip_type == 'MOVIE':
|
2017-10-09 13:47:05 +11:00
|
|
|
prop.filter_movie = True
|
2019-06-22 11:02:33 +10:00
|
|
|
elif strip_type == 'SOUND':
|
2017-10-09 13:47:05 +11:00
|
|
|
prop.filter_sound = True
|
2009-10-31 19:31:45 +00:00
|
|
|
|
|
|
|
|
2017-10-09 13:47:05 +11:00
|
|
|
class SEQUENCER_MT_strip_lock_mute(Menu):
|
|
|
|
bl_label = "Lock/Mute"
|
|
|
|
|
2019-04-19 07:32:24 +02:00
|
|
|
def draw(self, _context):
|
2017-10-09 13:47:05 +11:00
|
|
|
layout = self.layout
|
2013-08-23 20:41:21 +00:00
|
|
|
|
2019-05-30 15:26:17 -07:00
|
|
|
layout.operator("sequencer.lock")
|
2009-11-23 00:27:30 +00:00
|
|
|
layout.operator("sequencer.unlock")
|
2018-11-08 16:01:02 +01:00
|
|
|
|
|
|
|
layout.separator()
|
|
|
|
|
2012-01-14 06:30:27 +00:00
|
|
|
layout.operator("sequencer.mute").unselected = False
|
2015-01-29 17:34:05 +01:00
|
|
|
layout.operator("sequencer.unmute").unselected = False
|
2018-11-22 02:02:03 +01:00
|
|
|
layout.operator("sequencer.mute", text="Mute Unselected Strips").unselected = True
|
2019-05-20 18:04:35 +02:00
|
|
|
layout.operator("sequencer.unmute", text="Unmute Deselected Strips").unselected = True
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2017-10-09 13:47:05 +11:00
|
|
|
|
2019-05-22 14:59:04 +02:00
|
|
|
class SEQUENCER_MT_strip_effect(Menu):
|
|
|
|
bl_label = "Effect Strip"
|
|
|
|
|
2019-05-28 16:22:21 +10:00
|
|
|
def draw(self, _context):
|
2019-05-22 14:59:04 +02:00
|
|
|
layout = self.layout
|
|
|
|
|
|
|
|
layout.operator_menu_enum("sequencer.change_effect_input", "swap")
|
|
|
|
layout.operator_menu_enum("sequencer.change_effect_type", "type")
|
|
|
|
layout.operator("sequencer.reassign_inputs")
|
|
|
|
layout.operator("sequencer.swap_inputs")
|
|
|
|
|
|
|
|
|
|
|
|
class SEQUENCER_MT_strip_movie(Menu):
|
|
|
|
bl_label = "Movie Strip"
|
|
|
|
|
2019-05-28 16:22:21 +10:00
|
|
|
def draw(self, _context):
|
2019-05-22 14:59:04 +02:00
|
|
|
layout = self.layout
|
|
|
|
|
|
|
|
layout.operator("sequencer.rendersize")
|
|
|
|
layout.operator("sequencer.deinterlace_selected_movies")
|
|
|
|
|
|
|
|
|
2017-10-09 13:47:05 +11:00
|
|
|
class SEQUENCER_MT_strip(Menu):
|
|
|
|
bl_label = "Strip"
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
|
|
|
|
|
|
|
layout.operator_context = 'INVOKE_REGION_WIN'
|
|
|
|
|
|
|
|
layout.separator()
|
|
|
|
layout.menu("SEQUENCER_MT_strip_transform")
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2019-05-20 18:04:35 +02:00
|
|
|
layout.separator()
|
|
|
|
layout.operator("sequencer.cut", text="Cut").type = 'SOFT'
|
|
|
|
layout.operator("sequencer.cut", text="Hold Cut").type = 'HARD'
|
|
|
|
|
2017-10-09 13:47:05 +11:00
|
|
|
layout.separator()
|
2018-10-08 19:10:10 +02:00
|
|
|
layout.operator("sequencer.copy", text="Copy")
|
|
|
|
layout.operator("sequencer.paste", text="Paste")
|
2017-10-09 13:47:05 +11:00
|
|
|
layout.operator("sequencer.duplicate_move")
|
|
|
|
layout.operator("sequencer.delete", text="Delete...")
|
2009-06-08 16:48:12 +00:00
|
|
|
|
2017-10-09 13:47:05 +11:00
|
|
|
strip = act_strip(context)
|
|
|
|
|
|
|
|
if strip:
|
2019-06-22 11:02:33 +10:00
|
|
|
strip_type = strip.type
|
2017-10-09 13:47:05 +11:00
|
|
|
|
2019-06-22 11:02:33 +10:00
|
|
|
if strip_type != 'SOUND':
|
2019-05-20 18:04:35 +02:00
|
|
|
layout.separator()
|
|
|
|
layout.operator_menu_enum("sequencer.strip_modifier_add", "type", text="Add Modifier")
|
2019-05-22 00:27:01 +10:00
|
|
|
layout.operator("sequencer.strip_modifier_copy", text="Copy Modifiers to Selection")
|
2019-05-20 18:04:35 +02:00
|
|
|
|
2019-06-22 11:02:33 +10:00
|
|
|
if strip_type in {
|
2017-10-09 13:47:05 +11:00
|
|
|
'CROSS', 'ADD', 'SUBTRACT', 'ALPHA_OVER', 'ALPHA_UNDER',
|
|
|
|
'GAMMA_CROSS', 'MULTIPLY', 'OVER_DROP', 'WIPE', 'GLOW',
|
|
|
|
'TRANSFORM', 'COLOR', 'SPEED', 'MULTICAM', 'ADJUSTMENT',
|
2019-08-09 14:08:20 +02:00
|
|
|
'GAUSSIAN_BLUR',
|
2017-10-09 13:47:05 +11:00
|
|
|
}:
|
|
|
|
layout.separator()
|
2019-05-22 14:59:04 +02:00
|
|
|
layout.menu("SEQUENCER_MT_strip_effect")
|
2019-06-22 11:02:33 +10:00
|
|
|
elif strip_type == 'MOVIE':
|
2019-05-22 14:59:04 +02:00
|
|
|
layout.separator()
|
|
|
|
layout.menu("SEQUENCER_MT_strip_movie")
|
2019-06-22 11:02:33 +10:00
|
|
|
elif strip_type == 'IMAGE':
|
2017-10-09 13:47:05 +11:00
|
|
|
layout.separator()
|
|
|
|
layout.operator("sequencer.rendersize")
|
|
|
|
layout.operator("sequencer.images_separate")
|
2019-08-09 14:08:20 +02:00
|
|
|
elif strip_type == 'TEXT':
|
|
|
|
layout.separator()
|
|
|
|
layout.menu("SEQUENCER_MT_strip_effect")
|
2019-06-22 11:02:33 +10:00
|
|
|
elif strip_type == 'META':
|
2017-10-09 13:47:05 +11:00
|
|
|
layout.separator()
|
2019-05-22 14:59:04 +02:00
|
|
|
layout.operator("sequencer.meta_make")
|
2017-10-09 13:47:05 +11:00
|
|
|
layout.operator("sequencer.meta_separate")
|
2019-05-22 14:59:04 +02:00
|
|
|
layout.operator("sequencer.meta_toggle", text="Toggle Meta")
|
2019-06-22 11:02:33 +10:00
|
|
|
if strip_type != 'META':
|
2019-05-22 14:59:04 +02:00
|
|
|
layout.separator()
|
|
|
|
layout.operator("sequencer.meta_make")
|
2019-05-30 15:26:17 -07:00
|
|
|
layout.operator("sequencer.meta_toggle", text="Toggle Meta")
|
|
|
|
|
|
|
|
layout.separator()
|
|
|
|
layout.menu("SEQUENCER_MT_strip_lock_mute")
|
2017-10-09 13:47:05 +11:00
|
|
|
|
|
|
|
layout.separator()
|
|
|
|
layout.menu("SEQUENCER_MT_strip_input")
|
|
|
|
|
|
|
|
layout.separator()
|
2019-05-20 18:04:35 +02:00
|
|
|
layout.operator("sequencer.rebuild_proxy")
|
2010-06-21 17:37:50 +00:00
|
|
|
|
2009-10-31 23:35:56 +00:00
|
|
|
|
2019-05-07 21:07:52 +02:00
|
|
|
class SEQUENCER_MT_context_menu(Menu):
|
|
|
|
bl_label = "Sequencer Context Menu"
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
|
|
|
|
|
|
|
layout.operator_context = 'INVOKE_REGION_WIN'
|
|
|
|
|
2019-05-20 18:04:35 +02:00
|
|
|
layout.operator("sequencer.cut", text="Cut").type = 'SOFT'
|
2019-05-07 21:12:22 +02:00
|
|
|
|
|
|
|
layout.separator()
|
|
|
|
|
2019-05-20 18:04:35 +02:00
|
|
|
layout.operator("sequencer.copy", text="Copy", icon='COPYDOWN')
|
|
|
|
layout.operator("sequencer.paste", text="Paste", icon='PASTEDOWN')
|
2019-05-07 21:07:52 +02:00
|
|
|
layout.operator("sequencer.duplicate_move")
|
|
|
|
layout.operator("sequencer.delete", text="Delete...")
|
|
|
|
|
|
|
|
layout.separator()
|
|
|
|
|
2019-05-20 18:04:35 +02:00
|
|
|
layout.operator("sequencer.slip", text="Slip Strip Contents")
|
|
|
|
layout.operator("sequencer.snap")
|
2019-05-07 21:07:52 +02:00
|
|
|
|
|
|
|
layout.separator()
|
|
|
|
|
2019-05-20 18:04:35 +02:00
|
|
|
layout.operator("sequencer.gap_remove").all = False
|
|
|
|
layout.operator("sequencer.gap_insert")
|
2019-05-07 21:07:52 +02:00
|
|
|
|
|
|
|
strip = act_strip(context)
|
|
|
|
|
|
|
|
if strip:
|
2019-06-22 11:02:33 +10:00
|
|
|
strip_type = strip.type
|
2019-05-07 21:07:52 +02:00
|
|
|
|
2019-06-22 11:02:33 +10:00
|
|
|
if strip_type != 'SOUND':
|
2019-05-22 14:59:04 +02:00
|
|
|
|
2019-05-07 21:07:52 +02:00
|
|
|
layout.separator()
|
2019-05-20 18:04:35 +02:00
|
|
|
layout.operator_menu_enum("sequencer.strip_modifier_add", "type", text="Add Modifier")
|
2019-05-22 00:27:01 +10:00
|
|
|
layout.operator("sequencer.strip_modifier_copy", text="Copy Modifiers to Selection")
|
2019-05-20 18:04:35 +02:00
|
|
|
|
|
|
|
if selected_sequences_len(context) >= 2:
|
|
|
|
layout.separator()
|
|
|
|
col = layout.column()
|
|
|
|
col.menu("SEQUENCER_MT_add_transitions", text="Add Transition")
|
2019-05-22 14:59:04 +02:00
|
|
|
|
2019-05-20 18:04:35 +02:00
|
|
|
elif selected_sequences_len(context) >= 2:
|
2019-05-07 21:07:52 +02:00
|
|
|
layout.separator()
|
2019-05-20 18:04:35 +02:00
|
|
|
layout.operator("sequencer.crossfade_sounds", text="Crossfade Sounds")
|
2019-05-07 21:07:52 +02:00
|
|
|
|
2019-06-22 11:02:33 +10:00
|
|
|
if strip_type in {
|
2019-05-22 14:59:04 +02:00
|
|
|
'CROSS', 'ADD', 'SUBTRACT', 'ALPHA_OVER', 'ALPHA_UNDER',
|
|
|
|
'GAMMA_CROSS', 'MULTIPLY', 'OVER_DROP', 'WIPE', 'GLOW',
|
|
|
|
'TRANSFORM', 'COLOR', 'SPEED', 'MULTICAM', 'ADJUSTMENT',
|
2019-08-09 14:08:20 +02:00
|
|
|
'GAUSSIAN_BLUR',
|
2019-05-22 14:59:04 +02:00
|
|
|
}:
|
|
|
|
layout.separator()
|
|
|
|
layout.menu("SEQUENCER_MT_strip_effect")
|
2019-06-22 11:02:33 +10:00
|
|
|
elif strip_type in 'MOVIE':
|
2019-05-22 14:59:04 +02:00
|
|
|
layout.separator()
|
|
|
|
layout.menu("SEQUENCER_MT_strip_movie")
|
2019-06-22 11:02:33 +10:00
|
|
|
elif strip_type == 'IMAGE':
|
2019-05-22 14:59:04 +02:00
|
|
|
layout.separator()
|
|
|
|
layout.operator("sequencer.rendersize")
|
|
|
|
layout.operator("sequencer.images_separate")
|
2019-08-09 14:08:20 +02:00
|
|
|
elif strip_type == 'TEXT':
|
|
|
|
layout.separator()
|
|
|
|
layout.menu("SEQUENCER_MT_strip_effect")
|
2019-06-22 11:02:33 +10:00
|
|
|
elif strip_type == 'META':
|
2019-05-22 14:59:04 +02:00
|
|
|
layout.separator()
|
|
|
|
layout.operator("sequencer.meta_make")
|
|
|
|
layout.operator("sequencer.meta_separate")
|
|
|
|
layout.operator("sequencer.meta_toggle", text="Toggle Meta")
|
2019-06-22 11:02:33 +10:00
|
|
|
if strip_type != 'META':
|
2019-05-22 14:59:04 +02:00
|
|
|
layout.separator()
|
|
|
|
layout.operator("sequencer.meta_make")
|
|
|
|
layout.operator("sequencer.meta_toggle", text="Toggle Meta")
|
2019-05-07 21:07:52 +02:00
|
|
|
|
|
|
|
layout.separator()
|
|
|
|
|
2019-05-20 18:04:35 +02:00
|
|
|
layout.menu("SEQUENCER_MT_strip_lock_mute")
|
2019-05-07 21:07:52 +02:00
|
|
|
|
|
|
|
|
2015-01-29 15:35:06 +11:00
|
|
|
class SequencerButtonsPanel:
|
2009-10-31 19:31:45 +00:00
|
|
|
bl_space_type = 'SEQUENCE_EDITOR'
|
|
|
|
bl_region_type = 'UI'
|
2009-12-16 13:27:30 +00:00
|
|
|
|
2010-08-05 21:58:57 +00:00
|
|
|
@staticmethod
|
|
|
|
def has_sequencer(context):
|
2011-06-24 03:30:50 +00:00
|
|
|
return (context.space_data.view_type in {'SEQUENCER', 'SEQUENCER_PREVIEW'})
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2010-08-09 01:37:09 +00:00
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
|
|
|
return cls.has_sequencer(context) and (act_strip(context) is not None)
|
2009-06-08 16:48:12 +00:00
|
|
|
|
2009-10-31 23:35:56 +00:00
|
|
|
|
2015-01-29 15:35:06 +11:00
|
|
|
class SequencerButtonsPanel_Output:
|
2009-10-31 19:31:45 +00:00
|
|
|
bl_space_type = 'SEQUENCE_EDITOR'
|
|
|
|
bl_region_type = 'UI'
|
2009-06-09 16:19:34 +00:00
|
|
|
|
2010-08-05 21:58:57 +00:00
|
|
|
@staticmethod
|
|
|
|
def has_preview(context):
|
2015-01-06 12:17:06 +01:00
|
|
|
st = context.space_data
|
|
|
|
return (st.view_type in {'PREVIEW', 'SEQUENCER_PREVIEW'}) or st.show_backdrop
|
2009-12-14 21:42:25 +00:00
|
|
|
|
2010-08-09 01:37:09 +00:00
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
|
|
|
return cls.has_preview(context)
|
2009-06-08 16:48:12 +00:00
|
|
|
|
2019-06-21 21:18:57 +10:00
|
|
|
|
2019-06-21 11:22:56 +02:00
|
|
|
class SEQUENCER_PT_strip(SequencerButtonsPanel, Panel):
|
|
|
|
bl_label = ""
|
|
|
|
bl_options = {'HIDE_HEADER'}
|
|
|
|
bl_category = "Strip"
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
|
|
|
strip = act_strip(context)
|
2019-06-23 00:16:26 +02:00
|
|
|
strip_type = strip.type
|
|
|
|
|
|
|
|
if strip_type in {
|
|
|
|
'ADD', 'SUBTRACT', 'ALPHA_OVER', 'ALPHA_UNDER', 'MULTIPLY',
|
|
|
|
'OVER_DROP', 'GLOW', 'TRANSFORM', 'SPEED', 'MULTICAM',
|
|
|
|
'GAUSSIAN_BLUR', 'COLORMIX',
|
|
|
|
}:
|
2019-06-23 11:33:50 +10:00
|
|
|
icon_header = 'SHADERFX'
|
2019-06-23 00:16:26 +02:00
|
|
|
elif strip_type in {
|
|
|
|
'CROSS', 'GAMMA_CROSS', 'WIPE',
|
|
|
|
}:
|
2019-06-23 11:33:50 +10:00
|
|
|
icon_header = 'ARROW_LEFTRIGHT'
|
2019-06-23 00:16:26 +02:00
|
|
|
elif strip_type == 'SCENE':
|
2019-06-23 11:33:50 +10:00
|
|
|
icon_header = 'SCENE_DATA'
|
2019-06-23 00:16:26 +02:00
|
|
|
elif strip_type == 'MOVIECLIP':
|
2019-06-23 11:33:50 +10:00
|
|
|
icon_header = 'TRACKER'
|
2019-06-23 00:16:26 +02:00
|
|
|
elif strip_type == 'MASK':
|
2019-06-23 11:33:50 +10:00
|
|
|
icon_header = 'MOD_MASK'
|
2019-06-23 00:16:26 +02:00
|
|
|
elif strip_type == 'MOVIE':
|
2019-06-23 11:33:50 +10:00
|
|
|
icon_header = 'FILE_MOVIE'
|
2019-06-23 00:16:26 +02:00
|
|
|
elif strip_type == 'SOUND':
|
2019-06-23 11:33:50 +10:00
|
|
|
icon_header = 'FILE_SOUND'
|
2019-06-23 00:16:26 +02:00
|
|
|
elif strip_type == 'IMAGE':
|
2019-06-23 11:33:50 +10:00
|
|
|
icon_header = 'FILE_IMAGE'
|
2019-06-23 00:16:26 +02:00
|
|
|
elif strip_type == 'COLOR':
|
2019-06-23 11:33:50 +10:00
|
|
|
icon_header = 'COLOR'
|
2019-06-23 00:16:26 +02:00
|
|
|
elif strip_type == 'TEXT':
|
2019-06-23 11:33:50 +10:00
|
|
|
icon_header = 'FONT_DATA'
|
2019-06-23 00:16:26 +02:00
|
|
|
elif strip_type == 'ADJUSTMENT':
|
2019-06-23 11:33:50 +10:00
|
|
|
icon_header = 'COLOR'
|
2019-06-23 00:16:26 +02:00
|
|
|
else:
|
2019-06-23 11:33:50 +10:00
|
|
|
icon_header = 'SEQ_SEQUENCER'
|
2019-06-21 11:22:56 +02:00
|
|
|
|
|
|
|
row = layout.row()
|
2019-06-23 00:16:26 +02:00
|
|
|
row.label(text="", icon=icon_header)
|
2019-06-21 11:22:56 +02:00
|
|
|
row.prop(strip, "name", text="")
|
|
|
|
row.prop(strip, "mute", toggle=True, icon_only=True, emboss=False)
|
|
|
|
|
2009-10-31 23:35:56 +00:00
|
|
|
|
2019-06-20 19:11:39 +02:00
|
|
|
class SEQUENCER_PT_adjust_transform_offset(SequencerButtonsPanel, Panel):
|
2019-05-16 13:58:04 +02:00
|
|
|
bl_label = "Offset"
|
2019-06-20 19:11:39 +02:00
|
|
|
bl_parent_id = "SEQUENCER_PT_adjust_transform"
|
2019-05-16 13:58:04 +02:00
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2019-05-16 15:02:15 +02:00
|
|
|
bl_category = "Strip"
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
|
|
|
strip = act_strip(context)
|
|
|
|
return strip.type != 'SOUND'
|
2017-05-07 18:13:50 -04:00
|
|
|
|
2019-05-19 22:47:14 +02:00
|
|
|
def draw_header(self, context):
|
|
|
|
strip = act_strip(context)
|
|
|
|
self.layout.prop(strip, "use_translation", text="")
|
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
def draw(self, context):
|
2019-05-19 11:29:21 -07:00
|
|
|
strip = act_strip(context)
|
2019-05-16 13:58:04 +02:00
|
|
|
layout = self.layout
|
|
|
|
layout.use_property_split = True
|
2017-05-09 14:36:00 -04:00
|
|
|
|
2019-06-21 11:30:11 +02:00
|
|
|
layout.active = strip.use_translation and (not strip.mute)
|
2019-06-21 11:22:56 +02:00
|
|
|
|
2019-05-23 11:50:15 -07:00
|
|
|
col = layout.column(align=True)
|
|
|
|
col.prop(strip.transform, "offset_x", text="Position X")
|
2019-06-20 19:11:39 +02:00
|
|
|
col.prop(strip.transform, "offset_y", text="Y")
|
2010-11-28 18:23:21 +00:00
|
|
|
|
2011-01-01 07:20:34 +00:00
|
|
|
|
2019-06-20 19:11:39 +02:00
|
|
|
class SEQUENCER_PT_adjust_transform_crop(SequencerButtonsPanel, Panel):
|
2019-05-16 13:58:04 +02:00
|
|
|
bl_label = "Crop"
|
2019-06-20 19:11:39 +02:00
|
|
|
bl_parent_id = "SEQUENCER_PT_adjust_transform"
|
2019-05-16 13:58:04 +02:00
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2019-05-16 15:02:15 +02:00
|
|
|
bl_category = "Strip"
|
2010-11-28 18:23:21 +00:00
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
|
|
|
strip = act_strip(context)
|
|
|
|
return strip.type != 'SOUND'
|
|
|
|
|
2019-05-19 22:47:14 +02:00
|
|
|
def draw_header(self, context):
|
|
|
|
strip = act_strip(context)
|
|
|
|
self.layout.prop(strip, "use_crop", text="")
|
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
def draw(self, context):
|
2019-05-19 11:29:21 -07:00
|
|
|
strip = act_strip(context)
|
2019-05-16 13:58:04 +02:00
|
|
|
layout = self.layout
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
2019-06-21 11:30:11 +02:00
|
|
|
layout.active = strip.use_crop and (not strip.mute)
|
2019-06-21 11:22:56 +02:00
|
|
|
|
2019-05-23 11:50:15 -07:00
|
|
|
col = layout.column(align=True)
|
|
|
|
col.prop(strip.crop, "min_x")
|
|
|
|
col.prop(strip.crop, "max_x")
|
|
|
|
col.prop(strip.crop, "max_y")
|
|
|
|
col.prop(strip.crop, "min_y")
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2009-10-31 23:35:56 +00:00
|
|
|
|
2011-08-12 06:57:00 +00:00
|
|
|
class SEQUENCER_PT_effect(SequencerButtonsPanel, Panel):
|
2011-09-15 13:20:18 +00:00
|
|
|
bl_label = "Effect Strip"
|
2017-01-12 01:03:23 -05:00
|
|
|
bl_category = "Strip"
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2010-08-09 01:37:09 +00:00
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
|
|
|
if not cls.has_sequencer(context):
|
2009-10-31 19:31:45 +00:00
|
|
|
return False
|
|
|
|
|
|
|
|
strip = act_strip(context)
|
|
|
|
if not strip:
|
|
|
|
return False
|
|
|
|
|
2017-10-09 13:47:05 +11:00
|
|
|
return strip.type in {
|
|
|
|
'ADD', 'SUBTRACT', 'ALPHA_OVER', 'ALPHA_UNDER',
|
|
|
|
'CROSS', 'GAMMA_CROSS', 'MULTIPLY', 'OVER_DROP',
|
|
|
|
'WIPE', 'GLOW', 'TRANSFORM', 'COLOR', 'SPEED',
|
2017-11-27 23:33:08 +01:00
|
|
|
'MULTICAM', 'GAUSSIAN_BLUR', 'TEXT', 'COLORMIX'
|
2017-10-09 13:47:05 +11:00
|
|
|
}
|
2009-10-31 19:31:45 +00:00
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
2019-05-16 13:58:04 +02:00
|
|
|
layout.use_property_split = True
|
2009-10-31 19:31:45 +00:00
|
|
|
|
|
|
|
strip = act_strip(context)
|
2012-08-11 14:37:58 +00:00
|
|
|
|
2019-06-21 11:22:56 +02:00
|
|
|
layout.active = not strip.mute
|
|
|
|
|
2010-10-30 12:04:00 +00:00
|
|
|
if strip.input_count > 0:
|
|
|
|
col = layout.column()
|
2015-09-25 10:54:38 +02:00
|
|
|
col.enabled = False
|
2010-10-30 12:04:00 +00:00
|
|
|
col.prop(strip, "input_1")
|
|
|
|
if strip.input_count > 1:
|
|
|
|
col.prop(strip, "input_2")
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2019-06-22 11:02:33 +10:00
|
|
|
strip_type = strip.type
|
|
|
|
|
|
|
|
if strip_type == 'COLOR':
|
2009-11-23 00:27:30 +00:00
|
|
|
layout.prop(strip, "color")
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2019-06-22 11:02:33 +10:00
|
|
|
elif strip_type == 'WIPE':
|
2009-10-31 19:31:45 +00:00
|
|
|
col = layout.column()
|
2009-11-23 00:27:30 +00:00
|
|
|
col.prop(strip, "transition_type")
|
2019-05-22 00:27:01 +10:00
|
|
|
col.alignment = 'RIGHT'
|
2009-11-23 00:27:30 +00:00
|
|
|
col.row().prop(strip, "direction", expand=True)
|
2009-10-31 19:31:45 +00:00
|
|
|
|
|
|
|
col = layout.column()
|
2009-11-23 00:27:30 +00:00
|
|
|
col.prop(strip, "blur_width", slider=True)
|
2011-03-07 13:23:45 +00:00
|
|
|
if strip.transition_type in {'SINGLE', 'DOUBLE'}:
|
2009-11-23 00:27:30 +00:00
|
|
|
col.prop(strip, "angle")
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2019-06-22 11:02:33 +10:00
|
|
|
elif strip_type == 'GLOW':
|
2009-10-31 19:31:45 +00:00
|
|
|
flow = layout.column_flow()
|
2009-11-23 00:27:30 +00:00
|
|
|
flow.prop(strip, "threshold", slider=True)
|
|
|
|
flow.prop(strip, "clamp", slider=True)
|
|
|
|
flow.prop(strip, "boost_factor")
|
2010-08-20 06:09:58 +00:00
|
|
|
flow.prop(strip, "blur_radius")
|
2009-10-31 19:31:45 +00:00
|
|
|
|
|
|
|
row = layout.row()
|
2009-11-23 00:27:30 +00:00
|
|
|
row.prop(strip, "quality", slider=True)
|
2010-08-20 06:09:58 +00:00
|
|
|
row.prop(strip, "use_only_boost")
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2019-06-22 11:02:33 +10:00
|
|
|
elif strip_type == 'SPEED':
|
2018-08-28 13:41:47 +10:00
|
|
|
layout.prop(strip, "use_default_fade", text="Stretch to input strip length")
|
2010-11-21 20:00:31 +00:00
|
|
|
if not strip.use_default_fade:
|
|
|
|
layout.prop(strip, "use_as_speed")
|
|
|
|
if strip.use_as_speed:
|
|
|
|
layout.prop(strip, "speed_factor")
|
|
|
|
else:
|
2017-09-02 15:42:29 +10:00
|
|
|
layout.prop(strip, "speed_factor", text="Frame Number")
|
2019-05-19 11:29:21 -07:00
|
|
|
layout.prop(strip, "use_scale_to_length")
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2019-06-22 11:02:33 +10:00
|
|
|
elif strip_type == 'TRANSFORM':
|
2012-05-20 00:34:54 +00:00
|
|
|
col = layout.column()
|
2012-06-19 22:17:19 +00:00
|
|
|
|
2012-05-20 00:34:54 +00:00
|
|
|
col.prop(strip, "interpolation")
|
|
|
|
col.prop(strip, "translation_unit")
|
2019-06-21 07:32:03 +10:00
|
|
|
col = layout.column(align=True)
|
|
|
|
col.prop(strip, "translate_start_x", text="Position X")
|
|
|
|
col.prop(strip, "translate_start_y", text="Y")
|
2012-05-20 00:34:54 +00:00
|
|
|
|
2019-06-21 07:32:03 +10:00
|
|
|
col.separator()
|
2012-06-19 22:17:19 +00:00
|
|
|
|
2019-06-21 07:32:03 +10:00
|
|
|
colsub = col.column(align=True)
|
|
|
|
colsub.prop(strip, "use_uniform_scale")
|
2012-08-17 18:36:20 +00:00
|
|
|
if strip.use_uniform_scale:
|
2019-06-21 07:32:03 +10:00
|
|
|
colsub = col.column(align=True)
|
|
|
|
colsub.prop(strip, "scale_start_x", text="Scale")
|
2012-05-20 00:34:54 +00:00
|
|
|
else:
|
2019-06-21 07:32:03 +10:00
|
|
|
col.prop(strip, "scale_start_x", text="Scale X")
|
|
|
|
col.prop(strip, "scale_start_y", text="Y")
|
2012-05-20 00:34:54 +00:00
|
|
|
|
2019-06-21 07:32:03 +10:00
|
|
|
col.separator()
|
2012-05-20 00:34:54 +00:00
|
|
|
|
2019-06-21 07:32:03 +10:00
|
|
|
col.prop(strip, "rotation_start", text="Rotation")
|
2010-05-03 16:00:42 +00:00
|
|
|
|
2019-06-22 11:02:33 +10:00
|
|
|
elif strip_type == 'MULTICAM':
|
2017-02-11 11:35:02 -05:00
|
|
|
col = layout.column(align=True)
|
|
|
|
strip_channel = strip.channel
|
|
|
|
|
|
|
|
col.prop(strip, "multicam_source", text="Source Channel")
|
|
|
|
|
|
|
|
# The multicam strip needs at least 2 strips to be useful
|
|
|
|
if strip_channel > 2:
|
|
|
|
BT_ROW = 4
|
2019-05-16 13:58:04 +02:00
|
|
|
col.label(text=" Cut to")
|
2017-02-11 11:35:02 -05:00
|
|
|
row = col.row()
|
|
|
|
|
|
|
|
for i in range(1, strip_channel):
|
|
|
|
if (i % BT_ROW) == 1:
|
|
|
|
row = col.row(align=True)
|
|
|
|
|
2017-03-01 14:12:03 -05:00
|
|
|
# Workaround - .enabled has to have a separate UI block to work
|
2017-02-11 11:35:02 -05:00
|
|
|
if i == strip.multicam_source:
|
|
|
|
sub = row.row(align=True)
|
2017-03-01 13:05:34 -05:00
|
|
|
sub.enabled = False
|
2018-06-28 08:30:54 +02:00
|
|
|
sub.operator("sequencer.cut_multicam", text=f"{i:d}").camera = i
|
2017-02-11 11:35:02 -05:00
|
|
|
else:
|
|
|
|
sub_1 = row.row(align=True)
|
2017-03-01 13:05:34 -05:00
|
|
|
sub_1.enabled = True
|
2018-06-28 08:30:54 +02:00
|
|
|
sub_1.operator("sequencer.cut_multicam", text=f"{i:d}").camera = i
|
2017-02-11 11:35:02 -05:00
|
|
|
|
|
|
|
if strip.channel > BT_ROW and (strip_channel - 1) % BT_ROW:
|
|
|
|
for i in range(strip.channel, strip_channel + ((BT_ROW + 1 - strip_channel) % BT_ROW)):
|
2018-08-28 12:34:51 +10:00
|
|
|
row.label(text="")
|
2017-02-11 11:35:02 -05:00
|
|
|
else:
|
|
|
|
col.separator()
|
2017-09-02 15:42:29 +10:00
|
|
|
col.label(text="Two or more channels are needed below this strip", icon='INFO')
|
2010-05-02 17:36:38 +00:00
|
|
|
|
2019-06-22 11:02:33 +10:00
|
|
|
elif strip_type == 'TEXT':
|
2019-08-09 14:08:20 +02:00
|
|
|
layout = self.layout
|
|
|
|
layout.use_property_split = False
|
|
|
|
layout.prop(strip, "text", text="")
|
|
|
|
layout.use_property_split = True
|
2015-07-01 20:29:18 +02:00
|
|
|
|
2009-11-14 14:58:19 +00:00
|
|
|
col = layout.column(align=True)
|
2019-06-22 11:02:33 +10:00
|
|
|
if strip_type == 'SPEED':
|
2010-09-29 13:38:43 +00:00
|
|
|
col.prop(strip, "multiply_speed")
|
2019-06-22 11:02:33 +10:00
|
|
|
elif strip_type in {'CROSS', 'GAMMA_CROSS', 'WIPE', 'ALPHA_OVER', 'ALPHA_UNDER', 'OVER_DROP'}:
|
2018-08-28 13:41:47 +10:00
|
|
|
col.prop(strip, "use_default_fade", text="Default fade")
|
2011-11-19 16:17:35 +00:00
|
|
|
if not strip.use_default_fade:
|
2017-09-02 15:42:29 +10:00
|
|
|
col.prop(strip, "effect_fader", text="Effect Fader")
|
2019-06-22 11:02:33 +10:00
|
|
|
elif strip_type == 'GAUSSIAN_BLUR':
|
2019-06-21 07:32:03 +10:00
|
|
|
col = layout.column(align=True)
|
|
|
|
col.prop(strip, "size_x", text="Size X")
|
|
|
|
col.prop(strip, "size_y", text="Y")
|
2019-06-22 11:02:33 +10:00
|
|
|
elif strip_type == 'COLORMIX':
|
2019-05-16 13:58:04 +02:00
|
|
|
layout.prop(strip, "blend_effect", text="Blend Mode")
|
2017-11-27 23:33:08 +01:00
|
|
|
row = layout.row(align=True)
|
|
|
|
row.prop(strip, "factor", slider=True)
|
2016-02-01 00:47:10 +11:00
|
|
|
|
2009-10-31 23:35:56 +00:00
|
|
|
|
2019-08-09 14:08:20 +02:00
|
|
|
class SEQUENCER_PT_effect_text_layout(SequencerButtonsPanel, Panel):
|
|
|
|
bl_label = "Layout"
|
|
|
|
bl_parent_id = "SEQUENCER_PT_effect"
|
|
|
|
bl_category = "Strip"
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
|
|
|
strip = act_strip(context)
|
|
|
|
return strip.type == 'TEXT'
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
strip = act_strip(context)
|
|
|
|
layout = self.layout
|
|
|
|
layout.use_property_split = True
|
|
|
|
col = layout.column()
|
|
|
|
col.prop(strip, "location", text="Location")
|
|
|
|
col.prop(strip, "align_x", text="Alignment X")
|
|
|
|
col.prop(strip, "align_y", text="Y")
|
|
|
|
col.prop(strip, "wrap_width", text="Wrap Width")
|
|
|
|
|
|
|
|
|
|
|
|
class SEQUENCER_PT_effect_text_style(SequencerButtonsPanel, Panel):
|
|
|
|
bl_label = "Style"
|
|
|
|
bl_parent_id = "SEQUENCER_PT_effect"
|
|
|
|
bl_category = "Strip"
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
|
|
|
strip = act_strip(context)
|
|
|
|
return strip.type == 'TEXT'
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
strip = act_strip(context)
|
|
|
|
layout = self.layout
|
|
|
|
layout.use_property_split = True
|
|
|
|
col = layout.column()
|
|
|
|
col.template_ID(strip, "font", open="font.open", unlink="font.unlink")
|
|
|
|
col.prop(strip, "font_size")
|
|
|
|
col.prop(strip, "color")
|
|
|
|
|
|
|
|
|
|
|
|
class SEQUENCER_PT_effect_text_style_shadow(SequencerButtonsPanel, Panel):
|
|
|
|
bl_label = "Shadow"
|
|
|
|
bl_parent_id = "SEQUENCER_PT_effect_text_style"
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
|
|
|
bl_category = "Strip"
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
|
|
|
strip = act_strip(context)
|
|
|
|
return strip.type != 'SOUND'
|
|
|
|
|
|
|
|
def draw_header(self, context):
|
|
|
|
strip = act_strip(context)
|
|
|
|
self.layout.prop(strip, "use_shadow", text="")
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
strip = act_strip(context)
|
|
|
|
layout = self.layout
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
|
|
|
layout.active = strip.use_shadow and (not strip.mute)
|
|
|
|
|
|
|
|
col = layout.column(align=True)
|
|
|
|
col.prop(strip, "shadow_color", text="Color")
|
|
|
|
|
|
|
|
|
2019-06-20 19:11:39 +02:00
|
|
|
class SEQUENCER_PT_source(SequencerButtonsPanel, Panel):
|
|
|
|
bl_label = "Source"
|
2019-05-16 13:58:04 +02:00
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2017-01-12 01:03:23 -05:00
|
|
|
bl_category = "Strip"
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2010-08-09 01:37:09 +00:00
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
|
|
|
if not cls.has_sequencer(context):
|
2009-10-31 19:31:45 +00:00
|
|
|
return False
|
|
|
|
|
|
|
|
strip = act_strip(context)
|
|
|
|
if not strip:
|
|
|
|
return False
|
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
return strip.type in {'MOVIE', 'IMAGE', 'SOUND'}
|
|
|
|
|
2009-10-31 19:31:45 +00:00
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
2019-05-16 13:58:04 +02:00
|
|
|
layout.use_property_split = True
|
|
|
|
layout.use_property_decorate = False
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
scene = context.scene
|
2009-10-31 19:31:45 +00:00
|
|
|
strip = act_strip(context)
|
2019-06-22 11:02:33 +10:00
|
|
|
strip_type = strip.type
|
2010-08-02 04:10:16 +00:00
|
|
|
|
2019-06-21 11:22:56 +02:00
|
|
|
layout.active = not strip.mute
|
|
|
|
|
2019-06-22 10:50:10 +10:00
|
|
|
# Draw a filename if we have one.
|
2019-06-22 11:02:33 +10:00
|
|
|
if strip_type == 'SOUND':
|
2019-05-16 13:58:04 +02:00
|
|
|
sound = strip.sound
|
|
|
|
layout.template_ID(strip, "sound", open="sound.open")
|
|
|
|
if sound is not None:
|
|
|
|
|
2019-06-20 19:11:39 +02:00
|
|
|
col = layout.column()
|
|
|
|
col.prop(sound, "filepath", text="")
|
2019-05-16 13:58:04 +02:00
|
|
|
|
2019-06-20 19:11:39 +02:00
|
|
|
col.alignment = 'RIGHT'
|
|
|
|
sub = col.column(align=True)
|
2019-05-16 13:58:04 +02:00
|
|
|
split = sub.split(factor=0.5, align=True)
|
|
|
|
split.alignment = 'RIGHT'
|
|
|
|
if sound.packed_file:
|
|
|
|
split.label(text="Unpack")
|
|
|
|
split.operator("sound.unpack", icon='PACKAGE', text="")
|
|
|
|
else:
|
|
|
|
split.label(text="Pack")
|
|
|
|
split.operator("sound.pack", icon='UGLYPACKAGE', text="")
|
2012-06-19 22:17:19 +00:00
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
layout.prop(sound, "use_memory_cache")
|
2019-06-22 10:50:10 +10:00
|
|
|
else:
|
2019-06-22 11:02:33 +10:00
|
|
|
if strip_type == 'IMAGE':
|
2019-06-22 10:50:10 +10:00
|
|
|
col = layout.column()
|
|
|
|
col.prop(strip, "directory", text="")
|
2010-03-06 01:40:29 +00:00
|
|
|
|
2019-06-22 10:50:10 +10:00
|
|
|
# Current element for the filename.
|
|
|
|
elem = strip.strip_elem_from_frame(scene.frame_current)
|
|
|
|
if elem:
|
|
|
|
col.prop(elem, "filename", text="") # strip.elements[0] could be a fallback
|
2015-04-06 10:40:12 -03:00
|
|
|
|
2019-06-22 10:50:10 +10:00
|
|
|
col.prop(strip.colorspace_settings, "name", text="Color Space")
|
2015-04-06 10:40:12 -03:00
|
|
|
|
2019-06-22 10:50:10 +10:00
|
|
|
col.prop(strip, "alpha_mode", text="Alpha")
|
|
|
|
sub = col.column(align=True)
|
|
|
|
sub.operator("sequencer.change_path", text="Change Data/Files", icon='FILEBROWSER').filter_image = True
|
2019-06-22 11:02:33 +10:00
|
|
|
else: # elif strip_type == 'MOVIE':
|
2019-06-22 10:50:10 +10:00
|
|
|
elem = strip.elements[0]
|
2015-04-06 10:40:12 -03:00
|
|
|
|
2019-06-22 10:50:10 +10:00
|
|
|
col = layout.column()
|
|
|
|
col.prop(strip, "filepath", text="")
|
|
|
|
col.prop(strip.colorspace_settings, "name", text="Color Space")
|
|
|
|
col.prop(strip, "mpeg_preseek")
|
|
|
|
col.prop(strip, "stream_index")
|
|
|
|
col.prop(strip, "use_deinterlace")
|
2015-04-06 10:40:12 -03:00
|
|
|
|
2019-06-22 10:50:10 +10:00
|
|
|
if scene.render.use_multiview:
|
|
|
|
layout.prop(strip, "use_multiview")
|
|
|
|
|
|
|
|
col = layout.column()
|
|
|
|
col.active = strip.use_multiview
|
|
|
|
|
|
|
|
col.row().prop(strip, "views_format", expand=True)
|
|
|
|
|
|
|
|
box = col.box()
|
|
|
|
box.active = strip.views_format == 'STEREO_3D'
|
|
|
|
box.template_image_stereo_3d(strip.stereo_3d_format)
|
2019-06-21 11:22:56 +02:00
|
|
|
|
2019-06-22 10:50:10 +10:00
|
|
|
# Resolution.
|
2019-06-21 11:22:56 +02:00
|
|
|
col = layout.column(align=True)
|
|
|
|
col = col.box()
|
|
|
|
split = col.split(factor=0.5, align=False)
|
|
|
|
split.alignment = 'RIGHT'
|
|
|
|
split.label(text="Resolution")
|
2019-06-22 10:50:10 +10:00
|
|
|
size = (elem.orig_width, elem.orig_height) if elem else (0, 0)
|
|
|
|
if size[0] and size[1]:
|
2019-06-21 11:22:56 +02:00
|
|
|
split.alignment = 'LEFT'
|
2019-06-22 10:50:10 +10:00
|
|
|
split.label(text="%dx%d" % size, translate=False)
|
2019-06-21 11:22:56 +02:00
|
|
|
else:
|
|
|
|
split.label(text="None")
|
|
|
|
|
2010-03-06 01:40:29 +00:00
|
|
|
|
2011-08-12 06:57:00 +00:00
|
|
|
class SEQUENCER_PT_sound(SequencerButtonsPanel, Panel):
|
2011-09-15 13:20:18 +00:00
|
|
|
bl_label = "Sound"
|
2019-05-16 13:58:04 +02:00
|
|
|
bl_parent_id = ""
|
2017-01-12 01:03:23 -05:00
|
|
|
bl_category = "Strip"
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2010-08-09 01:37:09 +00:00
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
|
|
|
if not cls.has_sequencer(context):
|
2009-10-31 19:31:45 +00:00
|
|
|
return False
|
|
|
|
|
|
|
|
strip = act_strip(context)
|
|
|
|
if not strip:
|
|
|
|
return False
|
|
|
|
|
2009-11-22 21:47:55 +00:00
|
|
|
return (strip.type == 'SOUND')
|
2009-10-31 19:31:45 +00:00
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
2019-05-16 13:58:04 +02:00
|
|
|
layout.use_property_split = True
|
2009-10-31 19:31:45 +00:00
|
|
|
|
|
|
|
strip = act_strip(context)
|
2012-01-14 06:30:27 +00:00
|
|
|
sound = strip.sound
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2019-06-21 11:22:56 +02:00
|
|
|
layout.active = not strip.mute
|
|
|
|
|
2016-01-04 21:08:14 +11:00
|
|
|
layout.template_ID(strip, "sound", open="sound.open")
|
2013-07-24 06:51:04 +00:00
|
|
|
if sound is not None:
|
2016-01-04 21:08:14 +11:00
|
|
|
layout.prop(sound, "filepath", text="")
|
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
layout.use_property_split = True
|
|
|
|
layout.use_property_decorate = False
|
|
|
|
|
|
|
|
layout.alignment = 'RIGHT'
|
|
|
|
sub = layout.column(align=True)
|
|
|
|
split = sub.split(factor=0.5, align=True)
|
|
|
|
split.alignment = 'RIGHT'
|
2013-07-24 06:51:04 +00:00
|
|
|
if sound.packed_file:
|
2019-05-16 13:58:04 +02:00
|
|
|
split.label(text="Unpack")
|
|
|
|
split.operator("sound.unpack", icon='PACKAGE', text="")
|
2013-07-24 06:51:04 +00:00
|
|
|
else:
|
2019-05-16 13:58:04 +02:00
|
|
|
split.label(text="Pack")
|
|
|
|
split.operator("sound.pack", icon='UGLYPACKAGE', text="")
|
2009-11-21 00:05:43 +00:00
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
layout.prop(sound, "use_memory_cache")
|
2013-09-30 20:53:53 +00:00
|
|
|
|
2009-11-22 21:16:04 +00:00
|
|
|
|
2011-08-12 06:57:00 +00:00
|
|
|
class SEQUENCER_PT_scene(SequencerButtonsPanel, Panel):
|
2011-09-15 13:20:18 +00:00
|
|
|
bl_label = "Scene"
|
2017-01-12 01:03:23 -05:00
|
|
|
bl_category = "Strip"
|
2009-11-22 21:16:04 +00:00
|
|
|
|
2010-08-09 01:37:09 +00:00
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
|
|
|
if not cls.has_sequencer(context):
|
2009-11-22 21:16:04 +00:00
|
|
|
return False
|
|
|
|
|
|
|
|
strip = act_strip(context)
|
|
|
|
if not strip:
|
|
|
|
return False
|
|
|
|
|
2009-11-22 21:47:55 +00:00
|
|
|
return (strip.type == 'SCENE')
|
2009-11-22 21:16:04 +00:00
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
2019-05-16 13:58:04 +02:00
|
|
|
layout.use_property_split = True
|
2019-06-21 20:01:08 +02:00
|
|
|
layout.use_property_decorate = False
|
2009-11-22 21:16:04 +00:00
|
|
|
|
|
|
|
strip = act_strip(context)
|
2009-11-28 23:37:56 +00:00
|
|
|
|
2019-06-21 11:22:56 +02:00
|
|
|
layout.active = not strip.mute
|
|
|
|
|
2009-11-22 21:16:04 +00:00
|
|
|
layout.template_ID(strip, "scene")
|
2010-03-09 13:52:52 +00:00
|
|
|
|
2011-06-24 03:30:50 +00:00
|
|
|
scene = strip.scene
|
2019-06-21 20:01:08 +02:00
|
|
|
layout.prop(strip, "scene_input")
|
2019-05-17 00:28:22 +10:00
|
|
|
|
2019-05-24 19:08:33 -03:00
|
|
|
if scene:
|
|
|
|
layout.prop(scene, "audio_volume", text="Volume")
|
2011-06-24 03:30:50 +00:00
|
|
|
|
2019-06-25 09:39:40 +02:00
|
|
|
if strip.scene_input == 'CAMERA':
|
2019-05-16 13:58:04 +02:00
|
|
|
layout.alignment = 'RIGHT'
|
|
|
|
sub = layout.column(align=True)
|
|
|
|
split = sub.split(factor=0.5, align=True)
|
|
|
|
split.alignment = 'RIGHT'
|
2019-06-21 20:01:08 +02:00
|
|
|
split.label(text="Camera")
|
2019-05-16 13:58:04 +02:00
|
|
|
split.template_ID(strip, "scene_camera")
|
2010-03-09 13:52:52 +00:00
|
|
|
|
2014-12-10 15:26:41 +01:00
|
|
|
layout.prop(strip, "use_grease_pencil", text="Show Grease Pencil")
|
2014-12-05 16:39:49 +13:00
|
|
|
|
2016-03-18 20:03:24 +11:00
|
|
|
if scene:
|
|
|
|
# Warning, this is not a good convention to follow.
|
|
|
|
# Expose here because setting the alpha from the 'Render' menu is very inconvenient.
|
2019-05-17 00:28:22 +10:00
|
|
|
# layout.label(text="Preview")
|
2019-05-20 18:08:18 +02:00
|
|
|
layout.prop(scene.render, "film_transparent")
|
2016-03-18 20:03:24 +11:00
|
|
|
|
2009-10-31 23:35:56 +00:00
|
|
|
|
2012-06-07 18:24:36 +00:00
|
|
|
class SEQUENCER_PT_mask(SequencerButtonsPanel, Panel):
|
|
|
|
bl_label = "Mask"
|
2017-01-12 01:03:23 -05:00
|
|
|
bl_category = "Strip"
|
2012-06-07 18:24:36 +00:00
|
|
|
|
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
|
|
|
if not cls.has_sequencer(context):
|
|
|
|
return False
|
|
|
|
|
|
|
|
strip = act_strip(context)
|
|
|
|
if not strip:
|
|
|
|
return False
|
|
|
|
|
|
|
|
return (strip.type == 'MASK')
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
2019-05-16 13:58:04 +02:00
|
|
|
layout.use_property_split = True
|
2012-06-07 18:24:36 +00:00
|
|
|
|
|
|
|
strip = act_strip(context)
|
|
|
|
|
2019-06-21 11:22:56 +02:00
|
|
|
layout.active = not strip.mute
|
|
|
|
|
2012-06-07 18:24:36 +00:00
|
|
|
layout.template_ID(strip, "mask")
|
|
|
|
|
|
|
|
mask = strip.mask
|
|
|
|
|
|
|
|
if mask:
|
|
|
|
sta = mask.frame_start
|
|
|
|
end = mask.frame_end
|
2013-02-10 10:29:38 +00:00
|
|
|
layout.label(text=iface_("Original frame range: %d-%d (%d)") % (sta, end, end - sta + 1), translate=False)
|
2012-06-07 18:24:36 +00:00
|
|
|
|
|
|
|
|
2019-06-21 11:22:56 +02:00
|
|
|
class SEQUENCER_PT_time(SequencerButtonsPanel, Panel):
|
|
|
|
bl_label = "Time"
|
2019-06-20 19:11:39 +02:00
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2019-05-16 13:58:04 +02:00
|
|
|
bl_category = "Strip"
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
|
|
|
if not cls.has_sequencer(context):
|
|
|
|
return False
|
|
|
|
|
|
|
|
strip = act_strip(context)
|
|
|
|
if not strip:
|
|
|
|
return False
|
|
|
|
|
|
|
|
return strip.type
|
|
|
|
|
2019-06-21 11:22:56 +02:00
|
|
|
def draw_header_preset(self, context):
|
|
|
|
layout = self.layout
|
|
|
|
layout.alignment = 'RIGHT'
|
|
|
|
strip = act_strip(context)
|
|
|
|
|
|
|
|
layout.prop(strip, "lock", text="", icon_only=True, emboss=False)
|
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
def draw(self, context):
|
2019-06-21 07:32:03 +10:00
|
|
|
from bpy.utils import smpte_from_frame
|
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
layout = self.layout
|
|
|
|
layout.use_property_split = False
|
|
|
|
layout.use_property_decorate = False
|
|
|
|
|
|
|
|
scene = context.scene
|
|
|
|
frame_current = scene.frame_current
|
|
|
|
strip = act_strip(context)
|
|
|
|
|
2019-07-10 13:59:01 +10:00
|
|
|
is_effect = isinstance(strip, bpy.types.EffectSequence)
|
|
|
|
|
|
|
|
# Get once.
|
|
|
|
frame_start = strip.frame_start
|
|
|
|
frame_final_start = strip.frame_final_start
|
|
|
|
frame_final_end = strip.frame_final_end
|
|
|
|
frame_final_duration = strip.frame_final_duration
|
|
|
|
frame_offset_start = strip.frame_offset_start
|
|
|
|
frame_offset_end = strip.frame_offset_end
|
|
|
|
|
2019-05-17 00:28:22 +10:00
|
|
|
length_list = (
|
2019-07-10 13:59:01 +10:00
|
|
|
str(frame_start),
|
|
|
|
str(frame_final_end),
|
|
|
|
str(frame_final_duration),
|
|
|
|
str(frame_offset_start),
|
|
|
|
str(frame_offset_end),
|
2019-05-17 00:28:22 +10:00
|
|
|
)
|
2019-05-19 11:29:21 -07:00
|
|
|
|
2019-07-10 13:59:01 +10:00
|
|
|
if not is_effect:
|
2019-05-19 11:29:21 -07:00
|
|
|
length_list = length_list + (
|
|
|
|
str(strip.animation_offset_start),
|
|
|
|
str(strip.animation_offset_end),
|
|
|
|
)
|
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
max_length = max(len(x) for x in length_list)
|
2019-05-17 00:28:22 +10:00
|
|
|
max_factor = (1.9 - max_length) / 30
|
2019-05-16 13:58:04 +02:00
|
|
|
|
2019-06-21 11:22:56 +02:00
|
|
|
layout.enabled = not strip.lock
|
|
|
|
layout.active = not strip.mute
|
2019-06-20 19:11:39 +02:00
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
sub = layout.row(align=True)
|
2019-05-17 00:28:22 +10:00
|
|
|
split = sub.split(factor=0.5 + max_factor)
|
2019-05-16 13:58:04 +02:00
|
|
|
split.alignment = 'RIGHT'
|
2019-07-10 13:39:56 +10:00
|
|
|
split.label(text="Channel")
|
2019-05-16 13:58:04 +02:00
|
|
|
split.prop(strip, "channel", text="")
|
|
|
|
|
|
|
|
sub = layout.column(align=True)
|
2019-06-13 15:54:45 +02:00
|
|
|
split = sub.split(factor=0.5 + max_factor, align=True)
|
2019-05-16 13:58:04 +02:00
|
|
|
split.alignment = 'RIGHT'
|
|
|
|
split.label(text="Start")
|
2019-07-10 13:59:01 +10:00
|
|
|
split.prop(strip, "frame_start", text=smpte_from_frame(frame_start))
|
2019-06-13 15:54:45 +02:00
|
|
|
|
|
|
|
split = sub.split(factor=0.5 + max_factor, align=True)
|
2019-05-16 13:58:04 +02:00
|
|
|
split.alignment = 'RIGHT'
|
2019-07-10 13:48:03 +10:00
|
|
|
split.label(text="Duration")
|
2019-07-10 13:59:01 +10:00
|
|
|
split.prop(strip, "frame_final_duration", text=smpte_from_frame(frame_final_duration))
|
2019-06-13 15:54:45 +02:00
|
|
|
|
2019-07-10 13:48:03 +10:00
|
|
|
# Use label, editing this value from the UI allows negative values,
|
|
|
|
# users can adjust duration.
|
2019-06-13 15:54:45 +02:00
|
|
|
split = sub.split(factor=0.5 + max_factor, align=True)
|
2019-05-16 13:58:04 +02:00
|
|
|
split.alignment = 'RIGHT'
|
2019-07-10 13:48:03 +10:00
|
|
|
split.label(text="End")
|
|
|
|
split = split.split(factor=0.8 + max_factor, align=True)
|
2019-07-10 13:59:01 +10:00
|
|
|
split.label(text="{:>14}".format(smpte_from_frame(frame_final_end) + ":"))
|
2019-07-10 13:48:03 +10:00
|
|
|
split.alignment = 'RIGHT'
|
2019-07-10 13:59:01 +10:00
|
|
|
split.label(text=str(frame_final_end) + " ")
|
2019-05-16 13:58:04 +02:00
|
|
|
|
2019-07-10 13:59:01 +10:00
|
|
|
if not is_effect:
|
2019-06-13 15:54:45 +02:00
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
layout.alignment = 'RIGHT'
|
|
|
|
sub = layout.column(align=True)
|
2019-06-13 15:54:45 +02:00
|
|
|
|
2019-05-17 00:28:22 +10:00
|
|
|
split = sub.split(factor=0.5 + max_factor, align=True)
|
2019-05-16 13:58:04 +02:00
|
|
|
split.alignment = 'RIGHT'
|
2019-06-13 15:54:45 +02:00
|
|
|
split.label(text="Strip Offset Start")
|
2019-07-10 13:59:01 +10:00
|
|
|
split.prop(strip, "frame_offset_start", text=smpte_from_frame(frame_offset_start))
|
2019-06-13 15:54:45 +02:00
|
|
|
|
2019-05-19 20:44:28 +10:00
|
|
|
split = sub.split(factor=0.5 + max_factor, align=True)
|
2019-05-16 13:58:04 +02:00
|
|
|
split.alignment = 'RIGHT'
|
2019-07-10 13:39:56 +10:00
|
|
|
split.label(text="End")
|
2019-07-10 13:59:01 +10:00
|
|
|
split.prop(strip, "frame_offset_end", text=smpte_from_frame(frame_offset_end))
|
2019-05-16 13:58:04 +02:00
|
|
|
|
|
|
|
layout.alignment = 'RIGHT'
|
|
|
|
sub = layout.column(align=True)
|
2019-06-13 15:54:45 +02:00
|
|
|
|
2019-06-21 07:32:03 +10:00
|
|
|
split = sub.split(factor=0.5 + max_factor, align=True)
|
2019-05-16 13:58:04 +02:00
|
|
|
split.alignment = 'RIGHT'
|
2019-06-13 15:54:45 +02:00
|
|
|
split.label(text="Hold Offset Start")
|
2019-06-21 07:32:03 +10:00
|
|
|
split.prop(strip, "animation_offset_start", text=smpte_from_frame(strip.animation_offset_start))
|
2019-06-13 15:54:45 +02:00
|
|
|
|
2019-05-17 00:28:22 +10:00
|
|
|
split = sub.split(factor=0.5 + max_factor, align=True)
|
2019-05-16 13:58:04 +02:00
|
|
|
split.alignment = 'RIGHT'
|
2019-07-10 13:39:56 +10:00
|
|
|
split.label(text="End")
|
2019-06-21 07:32:03 +10:00
|
|
|
split.prop(strip, "animation_offset_end", text=smpte_from_frame(strip.animation_offset_end))
|
2019-05-16 13:58:04 +02:00
|
|
|
|
|
|
|
col = layout.column(align=True)
|
|
|
|
col = col.box()
|
2019-05-22 00:27:01 +10:00
|
|
|
col.active = (
|
2019-07-10 13:59:01 +10:00
|
|
|
(frame_current >= frame_final_start) and
|
|
|
|
(frame_current <= frame_final_start + frame_final_duration)
|
2019-05-22 00:27:01 +10:00
|
|
|
)
|
2019-06-13 15:54:45 +02:00
|
|
|
|
|
|
|
split = col.split(factor=0.5 + max_factor, align=True)
|
2019-05-16 13:58:04 +02:00
|
|
|
split.alignment = 'RIGHT'
|
|
|
|
split.label(text="Playhead")
|
2019-06-13 15:54:45 +02:00
|
|
|
split = split.split(factor=0.8 + max_factor, align=True)
|
2019-07-10 13:59:01 +10:00
|
|
|
playhead = frame_current - frame_final_start
|
2019-07-10 13:39:56 +10:00
|
|
|
split.label(text="{:>14}".format(smpte_from_frame(playhead) + ":"))
|
2019-06-13 15:54:45 +02:00
|
|
|
split.alignment = 'RIGHT'
|
2019-06-21 07:32:03 +10:00
|
|
|
split.label(text=str(playhead) + " ")
|
2019-05-16 13:58:04 +02:00
|
|
|
|
2019-05-22 00:27:01 +10:00
|
|
|
if strip.type == 'SCENE':
|
2019-05-16 13:58:04 +02:00
|
|
|
scene = strip.scene
|
|
|
|
|
|
|
|
if scene:
|
|
|
|
sta = scene.frame_start
|
|
|
|
end = scene.frame_end
|
2019-05-17 00:28:22 +10:00
|
|
|
split = col.split(factor=0.5 + max_factor)
|
2019-05-16 13:58:04 +02:00
|
|
|
split.alignment = 'RIGHT'
|
|
|
|
split.label(text="Original Frame Range")
|
|
|
|
split.alignment = 'LEFT'
|
|
|
|
split.label(text="%d-%d (%d)" % (sta, end, end - sta + 1), translate=False)
|
|
|
|
|
|
|
|
|
|
|
|
class SEQUENCER_PT_adjust(SequencerButtonsPanel, Panel):
|
|
|
|
bl_label = "Adjust"
|
|
|
|
bl_category = "Strip"
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
pass
|
|
|
|
|
|
|
|
|
|
|
|
class SEQUENCER_PT_adjust_sound(SequencerButtonsPanel, Panel):
|
|
|
|
bl_label = "Sound"
|
|
|
|
bl_parent_id = "SEQUENCER_PT_adjust"
|
2019-05-16 15:02:15 +02:00
|
|
|
bl_category = "Strip"
|
2019-05-16 13:58:04 +02:00
|
|
|
|
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
|
|
|
strip = act_strip(context)
|
|
|
|
return strip.type == 'SOUND'
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
|
|
|
st = context.space_data
|
|
|
|
strip = act_strip(context)
|
|
|
|
sound = strip.sound
|
|
|
|
|
2019-06-21 11:22:56 +02:00
|
|
|
layout.active = not strip.mute
|
2019-05-16 13:58:04 +02:00
|
|
|
|
2019-06-21 11:22:56 +02:00
|
|
|
col = layout.column()
|
2019-05-16 13:58:04 +02:00
|
|
|
|
2019-06-21 11:22:56 +02:00
|
|
|
col.prop(strip, "volume", text="Volume")
|
2019-05-16 13:58:04 +02:00
|
|
|
col.prop(strip, "pitch")
|
|
|
|
col.prop(strip, "pan")
|
|
|
|
|
|
|
|
if sound is not None:
|
|
|
|
|
|
|
|
if st.waveform_display_type == 'DEFAULT_WAVEFORMS':
|
|
|
|
col.prop(strip, "show_waveform")
|
|
|
|
col.prop(sound, "use_mono")
|
|
|
|
|
|
|
|
|
|
|
|
class SEQUENCER_PT_adjust_comp(SequencerButtonsPanel, Panel):
|
|
|
|
bl_label = "Compositing"
|
|
|
|
bl_parent_id = "SEQUENCER_PT_adjust"
|
2019-05-16 15:02:15 +02:00
|
|
|
bl_category = "Strip"
|
2019-05-16 13:58:04 +02:00
|
|
|
|
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
|
|
|
strip = act_strip(context)
|
|
|
|
return strip.type != 'SOUND'
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
|
|
|
strip = act_strip(context)
|
|
|
|
|
2019-06-21 11:22:56 +02:00
|
|
|
layout.active = not strip.mute
|
2019-05-16 13:58:04 +02:00
|
|
|
|
2019-06-21 11:22:56 +02:00
|
|
|
col = layout.column()
|
|
|
|
col.prop(strip, "blend_type", text="Blend")
|
|
|
|
col.prop(strip, "blend_alpha", text="Opacity", slider=True)
|
2019-05-16 13:58:04 +02:00
|
|
|
|
|
|
|
|
2019-06-20 19:11:39 +02:00
|
|
|
class SEQUENCER_PT_adjust_transform(SequencerButtonsPanel, Panel):
|
|
|
|
bl_label = "Transform"
|
|
|
|
bl_parent_id = "SEQUENCER_PT_adjust"
|
|
|
|
bl_category = "Strip"
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
|
|
|
if not cls.has_sequencer(context):
|
|
|
|
return False
|
|
|
|
|
|
|
|
strip = act_strip(context)
|
|
|
|
if not strip:
|
|
|
|
return False
|
|
|
|
|
|
|
|
return strip.type in {
|
|
|
|
'MOVIE', 'IMAGE', 'SCENE', 'MOVIECLIP', 'MASK',
|
|
|
|
'META', 'ADD', 'SUBTRACT', 'ALPHA_OVER',
|
|
|
|
'ALPHA_UNDER', 'CROSS', 'GAMMA_CROSS', 'MULTIPLY',
|
|
|
|
'OVER_DROP', 'WIPE', 'GLOW', 'TRANSFORM', 'COLOR',
|
|
|
|
'MULTICAM', 'SPEED', 'ADJUSTMENT', 'COLORMIX'
|
|
|
|
}
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
|
|
|
strip = act_strip(context)
|
|
|
|
|
2019-06-21 11:22:56 +02:00
|
|
|
layout.active = not strip.mute
|
|
|
|
|
2019-06-20 19:11:39 +02:00
|
|
|
split = layout.split()
|
|
|
|
|
|
|
|
col = split.column()
|
|
|
|
col.alignment = 'RIGHT'
|
|
|
|
col.label(text="Mirror")
|
|
|
|
|
|
|
|
col = split.column()
|
|
|
|
row = col.row(align=True)
|
|
|
|
row.prop(strip, "use_flip_x", text="X", toggle=True)
|
|
|
|
row.prop(strip, "use_flip_y", text="Y", toggle=True)
|
|
|
|
|
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
class SEQUENCER_PT_adjust_video(SequencerButtonsPanel, Panel):
|
|
|
|
bl_label = "Video"
|
|
|
|
bl_parent_id = "SEQUENCER_PT_adjust"
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2017-01-12 01:03:23 -05:00
|
|
|
bl_category = "Strip"
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2010-08-09 01:37:09 +00:00
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
|
|
|
if not cls.has_sequencer(context):
|
2009-10-31 19:31:45 +00:00
|
|
|
return False
|
|
|
|
|
|
|
|
strip = act_strip(context)
|
|
|
|
if not strip:
|
|
|
|
return False
|
|
|
|
|
2017-10-09 13:47:05 +11:00
|
|
|
return strip.type in {
|
|
|
|
'MOVIE', 'IMAGE', 'SCENE', 'MOVIECLIP', 'MASK',
|
|
|
|
'META', 'ADD', 'SUBTRACT', 'ALPHA_OVER',
|
|
|
|
'ALPHA_UNDER', 'CROSS', 'GAMMA_CROSS', 'MULTIPLY',
|
|
|
|
'OVER_DROP', 'WIPE', 'GLOW', 'TRANSFORM', 'COLOR',
|
2017-11-27 23:33:08 +01:00
|
|
|
'MULTICAM', 'SPEED', 'ADJUSTMENT', 'COLORMIX'
|
2017-10-09 13:47:05 +11:00
|
|
|
}
|
2009-10-31 19:31:45 +00:00
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
2019-06-20 19:11:39 +02:00
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
layout.use_property_split = True
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2019-06-20 19:11:39 +02:00
|
|
|
col = layout.column()
|
|
|
|
|
2009-10-31 19:31:45 +00:00
|
|
|
strip = act_strip(context)
|
|
|
|
|
2019-06-21 11:22:56 +02:00
|
|
|
layout.active = not strip.mute
|
|
|
|
|
2009-11-23 00:27:30 +00:00
|
|
|
col.prop(strip, "strobe")
|
2010-04-18 13:05:17 +00:00
|
|
|
|
2012-03-21 18:02:29 +00:00
|
|
|
if strip.type == 'MOVIECLIP':
|
|
|
|
col = layout.column()
|
2019-05-16 13:58:04 +02:00
|
|
|
col.label(text="Tracker")
|
2012-03-21 18:02:29 +00:00
|
|
|
col.prop(strip, "stabilize2d")
|
|
|
|
|
|
|
|
col = layout.column()
|
2019-05-16 13:58:04 +02:00
|
|
|
col.label(text="Distortion")
|
2012-03-21 18:02:29 +00:00
|
|
|
col.prop(strip, "undistort")
|
2019-05-16 13:58:04 +02:00
|
|
|
col.separator()
|
2012-06-19 22:17:19 +00:00
|
|
|
|
2019-06-20 19:11:39 +02:00
|
|
|
col.prop(strip, "playback_direction")
|
2019-03-20 10:44:13 +11:00
|
|
|
|
2019-06-21 07:32:03 +10:00
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
class SEQUENCER_PT_adjust_color(SequencerButtonsPanel, Panel):
|
|
|
|
bl_label = "Color"
|
|
|
|
bl_parent_id = "SEQUENCER_PT_adjust"
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
|
|
|
bl_category = "Strip"
|
2019-04-28 14:13:41 -07:00
|
|
|
|
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
2019-05-16 13:58:04 +02:00
|
|
|
if not cls.has_sequencer(context):
|
|
|
|
return False
|
2019-04-28 14:13:41 -07:00
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
strip = act_strip(context)
|
|
|
|
if not strip:
|
|
|
|
return False
|
2019-04-28 14:13:41 -07:00
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
return strip.type in {
|
|
|
|
'MOVIE', 'IMAGE', 'SCENE', 'MOVIECLIP', 'MASK',
|
|
|
|
'META', 'ADD', 'SUBTRACT', 'ALPHA_OVER',
|
|
|
|
'ALPHA_UNDER', 'CROSS', 'GAMMA_CROSS', 'MULTIPLY',
|
|
|
|
'OVER_DROP', 'WIPE', 'GLOW', 'TRANSFORM', 'COLOR',
|
|
|
|
'MULTICAM', 'SPEED', 'ADJUSTMENT', 'COLORMIX'
|
|
|
|
}
|
2009-10-31 23:35:56 +00:00
|
|
|
|
2019-02-28 15:10:19 -08:00
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
2019-05-16 13:58:04 +02:00
|
|
|
layout.use_property_split = True
|
2019-02-28 15:10:19 -08:00
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
strip = act_strip(context)
|
2019-02-28 15:10:19 -08:00
|
|
|
|
2019-06-21 11:22:56 +02:00
|
|
|
layout.active = not strip.mute
|
|
|
|
|
2019-02-28 15:10:19 -08:00
|
|
|
col = layout.column()
|
2019-05-16 13:58:04 +02:00
|
|
|
col.prop(strip, "color_saturation", text="Saturation")
|
|
|
|
col.prop(strip, "color_multiply", text="Multiply")
|
|
|
|
col.prop(strip, "use_float", text="Convert to Float")
|
2019-02-28 15:10:19 -08:00
|
|
|
|
|
|
|
|
2019-05-17 11:31:49 +02:00
|
|
|
class SEQUENCER_PT_cache_settings(SequencerButtonsPanel, Panel):
|
|
|
|
bl_label = "Cache Settings"
|
2019-05-17 13:27:21 +02:00
|
|
|
bl_category = "Proxy & Cache"
|
2019-05-17 11:31:49 +02:00
|
|
|
|
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
2019-05-20 18:09:25 +02:00
|
|
|
return cls.has_sequencer(context) and context.scene.sequence_editor
|
2019-05-17 11:31:49 +02:00
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
2019-06-20 19:11:39 +02:00
|
|
|
layout.use_property_split = True
|
|
|
|
layout.use_property_decorate = False
|
|
|
|
|
2019-05-17 11:31:49 +02:00
|
|
|
ed = context.scene.sequence_editor
|
|
|
|
|
2019-06-20 19:11:39 +02:00
|
|
|
col = layout.column()
|
|
|
|
|
|
|
|
col.prop(ed, "use_cache_raw")
|
|
|
|
col.prop(ed, "use_cache_preprocessed")
|
|
|
|
col.prop(ed, "use_cache_composite")
|
|
|
|
col.prop(ed, "use_cache_final")
|
|
|
|
col.separator()
|
|
|
|
col.prop(ed, "recycle_max_cost")
|
2019-05-17 11:31:49 +02:00
|
|
|
|
|
|
|
|
|
|
|
class SEQUENCER_PT_proxy_settings(SequencerButtonsPanel, Panel):
|
2019-05-19 11:29:21 -07:00
|
|
|
bl_label = "Proxy Settings"
|
|
|
|
bl_category = "Proxy & Cache"
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
2019-05-20 18:09:25 +02:00
|
|
|
return cls.has_sequencer(context) and context.scene.sequence_editor
|
2019-05-19 11:29:21 -07:00
|
|
|
|
|
|
|
def draw(self, context):
|
2019-06-20 19:11:39 +02:00
|
|
|
layout = self.layout
|
|
|
|
layout.use_property_split = True
|
|
|
|
layout.use_property_decorate = False
|
|
|
|
|
2019-05-19 11:29:21 -07:00
|
|
|
ed = context.scene.sequence_editor
|
|
|
|
flow = layout.column_flow()
|
|
|
|
flow.prop(ed, "proxy_storage", text="Storage")
|
|
|
|
|
|
|
|
if ed.proxy_storage == 'PROJECT':
|
|
|
|
flow.prop(ed, "proxy_dir", text="Directory")
|
|
|
|
|
|
|
|
col = layout.column()
|
|
|
|
col.operator("sequencer.enable_proxies")
|
|
|
|
col.operator("sequencer.rebuild_proxy")
|
|
|
|
|
|
|
|
|
|
|
|
class SEQUENCER_PT_strip_proxy(SequencerButtonsPanel, Panel):
|
|
|
|
bl_label = "Strip Proxy & Timecode"
|
2019-05-17 13:27:21 +02:00
|
|
|
bl_category = "Proxy & Cache"
|
2019-05-17 11:31:49 +02:00
|
|
|
|
2010-08-09 01:37:09 +00:00
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
2019-05-20 18:09:25 +02:00
|
|
|
if not cls.has_sequencer(context) and context.scene.sequence_editor:
|
2009-10-31 19:31:45 +00:00
|
|
|
return False
|
|
|
|
|
|
|
|
strip = act_strip(context)
|
|
|
|
if not strip:
|
|
|
|
return False
|
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
return strip.type in {'MOVIE', 'IMAGE', 'SCENE', 'META', 'MULTICAM'}
|
2009-10-31 19:31:45 +00:00
|
|
|
|
|
|
|
def draw_header(self, context):
|
|
|
|
strip = act_strip(context)
|
|
|
|
|
2009-11-23 00:27:30 +00:00
|
|
|
self.layout.prop(strip, "use_proxy", text="")
|
2009-10-31 19:31:45 +00:00
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
2019-05-16 13:58:04 +02:00
|
|
|
layout.use_property_split = True
|
|
|
|
layout.use_property_decorate = False
|
2009-10-31 19:31:45 +00:00
|
|
|
|
2018-02-19 22:32:41 +11:00
|
|
|
ed = context.scene.sequence_editor
|
2015-03-26 17:54:16 +01:00
|
|
|
|
2009-10-31 19:31:45 +00:00
|
|
|
strip = act_strip(context)
|
|
|
|
|
== Sequencer ==
This patch adds:
* support for proxy building again (missing feature from Blender 2.49)
additionally to the way, Blender 2.49 worked, you can select several
strips at once and make Blender build proxies in the background (using
the job system)
Also a new thing: movie proxies are now build into AVI files, and
the proxy system is moved into ImBuf-library, so that other parts
of blender can also benefit from it.
* Timecode support: to fix seeking issues with files, that have
a) varying frame rates
b) very large GOP lengths
c) are broken inbetween
d) use different time code tracks
the proxy builder can now also build timecode indices, which are
used (optionally) for seeking.
For the first time, it is possible, to do frame exact seeking on
all file types.
* Support for different video-streams in one video file (can be
selected in sequencer, other parts of blender can also use it,
but UI has to be added accordingly)
* IMPORTANT: this patch *requires* ffmpeg 0.7 or newer, since
older versions don't support the pkt_pts field, that is essential
for building timecode indices.
Windows and Mac libs are already updated, Linux-users have to build
their own ffmpeg verions until distros keep up.
2011-08-28 14:46:03 +00:00
|
|
|
if strip.proxy:
|
2015-03-24 12:24:30 +01:00
|
|
|
proxy = strip.proxy
|
|
|
|
|
|
|
|
flow = layout.column_flow()
|
2019-05-19 11:29:21 -07:00
|
|
|
if ed.proxy_storage == 'PER_STRIP':
|
2015-03-26 17:54:16 +01:00
|
|
|
flow.prop(proxy, "use_proxy_custom_directory")
|
|
|
|
flow.prop(proxy, "use_proxy_custom_file")
|
2015-03-24 12:24:30 +01:00
|
|
|
|
2015-03-26 17:54:16 +01:00
|
|
|
if proxy.use_proxy_custom_directory and not proxy.use_proxy_custom_file:
|
|
|
|
flow.prop(proxy, "directory")
|
|
|
|
if proxy.use_proxy_custom_file:
|
|
|
|
flow.prop(proxy, "filepath")
|
2015-03-26 15:44:51 +01:00
|
|
|
|
2019-06-21 07:32:03 +10:00
|
|
|
box = layout.box()
|
|
|
|
row = box.row(align=True)
|
2019-05-16 13:58:04 +02:00
|
|
|
row.prop(strip.proxy, "build_25")
|
|
|
|
row.prop(strip.proxy, "build_75")
|
2019-06-21 07:32:03 +10:00
|
|
|
row = box.row(align=True)
|
2019-05-16 13:58:04 +02:00
|
|
|
row.prop(strip.proxy, "build_50")
|
|
|
|
row.prop(strip.proxy, "build_100")
|
|
|
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
layout.use_property_decorate = False
|
2015-04-21 11:57:31 +02:00
|
|
|
|
|
|
|
layout.prop(proxy, "use_overwrite")
|
== Sequencer ==
This patch adds:
* support for proxy building again (missing feature from Blender 2.49)
additionally to the way, Blender 2.49 worked, you can select several
strips at once and make Blender build proxies in the background (using
the job system)
Also a new thing: movie proxies are now build into AVI files, and
the proxy system is moved into ImBuf-library, so that other parts
of blender can also benefit from it.
* Timecode support: to fix seeking issues with files, that have
a) varying frame rates
b) very large GOP lengths
c) are broken inbetween
d) use different time code tracks
the proxy builder can now also build timecode indices, which are
used (optionally) for seeking.
For the first time, it is possible, to do frame exact seeking on
all file types.
* Support for different video-streams in one video file (can be
selected in sequencer, other parts of blender can also use it,
but UI has to be added accordingly)
* IMPORTANT: this patch *requires* ffmpeg 0.7 or newer, since
older versions don't support the pkt_pts field, that is essential
for building timecode indices.
Windows and Mac libs are already updated, Linux-users have to build
their own ffmpeg verions until distros keep up.
2011-08-28 14:46:03 +00:00
|
|
|
|
|
|
|
col = layout.column()
|
2017-09-02 15:42:29 +10:00
|
|
|
col.prop(proxy, "quality", text="Build JPEG Quality")
|
== Sequencer ==
This patch adds:
* support for proxy building again (missing feature from Blender 2.49)
additionally to the way, Blender 2.49 worked, you can select several
strips at once and make Blender build proxies in the background (using
the job system)
Also a new thing: movie proxies are now build into AVI files, and
the proxy system is moved into ImBuf-library, so that other parts
of blender can also benefit from it.
* Timecode support: to fix seeking issues with files, that have
a) varying frame rates
b) very large GOP lengths
c) are broken inbetween
d) use different time code tracks
the proxy builder can now also build timecode indices, which are
used (optionally) for seeking.
For the first time, it is possible, to do frame exact seeking on
all file types.
* Support for different video-streams in one video file (can be
selected in sequencer, other parts of blender can also use it,
but UI has to be added accordingly)
* IMPORTANT: this patch *requires* ffmpeg 0.7 or newer, since
older versions don't support the pkt_pts field, that is essential
for building timecode indices.
Windows and Mac libs are already updated, Linux-users have to build
their own ffmpeg verions until distros keep up.
2011-08-28 14:46:03 +00:00
|
|
|
|
2012-07-04 21:41:05 +00:00
|
|
|
if strip.type == 'MOVIE':
|
== Sequencer ==
This patch adds:
* support for proxy building again (missing feature from Blender 2.49)
additionally to the way, Blender 2.49 worked, you can select several
strips at once and make Blender build proxies in the background (using
the job system)
Also a new thing: movie proxies are now build into AVI files, and
the proxy system is moved into ImBuf-library, so that other parts
of blender can also benefit from it.
* Timecode support: to fix seeking issues with files, that have
a) varying frame rates
b) very large GOP lengths
c) are broken inbetween
d) use different time code tracks
the proxy builder can now also build timecode indices, which are
used (optionally) for seeking.
For the first time, it is possible, to do frame exact seeking on
all file types.
* Support for different video-streams in one video file (can be
selected in sequencer, other parts of blender can also use it,
but UI has to be added accordingly)
* IMPORTANT: this patch *requires* ffmpeg 0.7 or newer, since
older versions don't support the pkt_pts field, that is essential
for building timecode indices.
Windows and Mac libs are already updated, Linux-users have to build
their own ffmpeg verions until distros keep up.
2011-08-28 14:46:03 +00:00
|
|
|
col = layout.column()
|
2009-10-31 23:35:56 +00:00
|
|
|
|
2019-05-16 13:58:04 +02:00
|
|
|
col.prop(proxy, "timecode", text="Timecode Index")
|
2019-04-28 14:13:41 -07:00
|
|
|
|
|
|
|
|
2019-05-17 12:01:45 +02:00
|
|
|
class SEQUENCER_PT_strip_cache(SequencerButtonsPanel, Panel):
|
|
|
|
bl_label = "Strip Cache"
|
2019-05-17 13:27:21 +02:00
|
|
|
bl_category = "Proxy & Cache"
|
2019-05-17 12:01:45 +02:00
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
|
|
|
if not cls.has_sequencer(context):
|
|
|
|
return False
|
|
|
|
if act_strip(context) is not None:
|
|
|
|
return True
|
2019-06-21 07:32:03 +10:00
|
|
|
return False
|
2019-05-17 12:01:45 +02:00
|
|
|
|
|
|
|
def draw_header(self, context):
|
|
|
|
strip = act_strip(context)
|
|
|
|
self.layout.prop(strip, "override_cache_settings", text="")
|
|
|
|
|
|
|
|
def draw(self, context):
|
2019-06-20 19:11:39 +02:00
|
|
|
layout = self.layout
|
|
|
|
layout.use_property_split = True
|
|
|
|
layout.use_property_decorate = False
|
|
|
|
|
2019-05-17 12:01:45 +02:00
|
|
|
strip = act_strip(context)
|
|
|
|
layout.active = strip.override_cache_settings
|
2019-06-21 07:32:03 +10:00
|
|
|
|
2019-06-20 19:11:39 +02:00
|
|
|
col = layout.column()
|
|
|
|
col.prop(strip, "use_cache_raw")
|
|
|
|
col.prop(strip, "use_cache_preprocessed")
|
|
|
|
col.prop(strip, "use_cache_composite")
|
2019-05-17 12:01:45 +02:00
|
|
|
|
|
|
|
|
2011-08-12 06:57:00 +00:00
|
|
|
class SEQUENCER_PT_preview(SequencerButtonsPanel_Output, Panel):
|
2019-05-16 13:58:04 +02:00
|
|
|
bl_label = "Scene Preview/Render"
|
2010-07-28 07:52:05 +00:00
|
|
|
bl_space_type = 'SEQUENCE_EDITOR'
|
|
|
|
bl_region_type = 'UI'
|
2019-05-17 13:38:34 +02:00
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2019-05-17 11:31:49 +02:00
|
|
|
bl_category = "View"
|
2010-07-28 07:52:05 +00:00
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
2019-05-16 13:58:04 +02:00
|
|
|
layout.use_property_split = True
|
|
|
|
layout.use_property_decorate = False
|
2019-06-21 07:32:03 +10:00
|
|
|
|
2010-07-28 07:52:05 +00:00
|
|
|
render = context.scene.render
|
|
|
|
|
|
|
|
col = layout.column()
|
2019-05-17 13:38:34 +02:00
|
|
|
col.prop(render, "sequencer_gl_preview", text="Preview Shading")
|
2010-07-28 07:52:05 +00:00
|
|
|
|
2019-04-25 16:24:06 +02:00
|
|
|
if render.sequencer_gl_preview in ['SOLID', 'WIREFRAME']:
|
|
|
|
col.prop(render, "use_sequencer_override_scene_strip")
|
2017-11-24 12:19:26 +01:00
|
|
|
|
2010-07-28 07:52:05 +00:00
|
|
|
|
2011-08-12 06:57:00 +00:00
|
|
|
class SEQUENCER_PT_view(SequencerButtonsPanel_Output, Panel):
|
2011-09-15 13:20:18 +00:00
|
|
|
bl_label = "View Settings"
|
2019-05-16 15:02:15 +02:00
|
|
|
bl_category = "View"
|
2009-10-31 19:31:45 +00:00
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
2019-05-16 13:58:04 +02:00
|
|
|
layout.use_property_split = True
|
|
|
|
layout.use_property_decorate = False
|
2009-06-09 16:19:34 +00:00
|
|
|
|
2009-10-31 19:31:45 +00:00
|
|
|
st = context.space_data
|
2009-06-09 16:19:34 +00:00
|
|
|
|
2009-10-31 19:31:45 +00:00
|
|
|
col = layout.column()
|
2019-05-17 13:38:34 +02:00
|
|
|
col.prop(st, "display_channel", text="Channel")
|
|
|
|
|
2010-04-11 18:37:49 +00:00
|
|
|
if st.display_mode == 'IMAGE':
|
2018-09-03 18:58:41 +02:00
|
|
|
col.prop(st, "show_overexposed")
|
2015-01-19 16:30:35 +11:00
|
|
|
|
2012-05-20 00:34:54 +00:00
|
|
|
elif st.display_mode == 'WAVEFORM':
|
2010-08-17 07:49:53 +00:00
|
|
|
col.prop(st, "show_separate_color")
|
2015-01-19 16:30:35 +11:00
|
|
|
|
2010-04-17 19:05:53 +00:00
|
|
|
col.prop(st, "proxy_render_size")
|
2011-04-04 10:13:04 +00:00
|
|
|
|
2012-08-19 15:41:56 +00:00
|
|
|
|
2019-05-17 13:38:34 +02:00
|
|
|
class SEQUENCER_PT_frame_overlay(SequencerButtonsPanel_Output, Panel):
|
|
|
|
bl_label = "Frame Overlay"
|
|
|
|
bl_category = "View"
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
|
|
|
|
|
|
|
def draw_header(self, context):
|
|
|
|
scene = context.scene
|
|
|
|
ed = scene.sequence_editor
|
|
|
|
|
|
|
|
self.layout.prop(ed, "show_overlay", text="")
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
2019-08-06 16:56:14 +10:00
|
|
|
|
|
|
|
layout.operator_context = 'INVOKE_REGION_PREVIEW'
|
|
|
|
layout.operator("sequencer.view_ghost_border", text="Set Overlay Region")
|
|
|
|
layout.operator_context = 'INVOKE_DEFAULT'
|
|
|
|
|
2019-05-17 13:38:34 +02:00
|
|
|
layout.use_property_split = True
|
|
|
|
layout.use_property_decorate = False
|
|
|
|
|
|
|
|
st = context.space_data
|
|
|
|
scene = context.scene
|
|
|
|
ed = scene.sequence_editor
|
|
|
|
|
|
|
|
layout.active = ed.show_overlay
|
|
|
|
|
|
|
|
col = layout.column()
|
|
|
|
col.prop(ed, "overlay_frame", text="Frame Offset")
|
|
|
|
col.prop(st, "overlay_type")
|
|
|
|
col.prop(ed, "use_overlay_lock")
|
|
|
|
|
|
|
|
|
2015-01-19 16:30:35 +11:00
|
|
|
class SEQUENCER_PT_view_safe_areas(SequencerButtonsPanel_Output, Panel):
|
|
|
|
bl_label = "Safe Areas"
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2019-05-17 11:31:49 +02:00
|
|
|
bl_category = "View"
|
2015-01-19 16:30:35 +11:00
|
|
|
|
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
|
|
|
st = context.space_data
|
|
|
|
is_preview = st.view_type in {'PREVIEW', 'SEQUENCER_PREVIEW'}
|
|
|
|
return is_preview and (st.display_mode == 'IMAGE')
|
|
|
|
|
|
|
|
def draw_header(self, context):
|
|
|
|
st = context.space_data
|
|
|
|
|
|
|
|
self.layout.prop(st, "show_safe_areas", text="")
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
2019-05-16 14:14:13 +02:00
|
|
|
layout.use_property_split = True
|
|
|
|
st = context.space_data
|
|
|
|
safe_data = context.scene.safe_areas
|
|
|
|
|
|
|
|
layout.active = st.show_safe_areas
|
|
|
|
|
|
|
|
col = layout.column()
|
|
|
|
|
|
|
|
sub = col.column()
|
|
|
|
sub.prop(safe_data, "title", slider=True)
|
|
|
|
sub.prop(safe_data, "action", slider=True)
|
|
|
|
|
|
|
|
|
|
|
|
class SEQUENCER_PT_view_safe_areas_center_cut(SequencerButtonsPanel_Output, Panel):
|
|
|
|
bl_label = "Center-Cut Safe Areas"
|
|
|
|
bl_parent_id = "SEQUENCER_PT_view_safe_areas"
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2019-05-17 11:31:49 +02:00
|
|
|
bl_category = "View"
|
2019-05-16 13:58:04 +02:00
|
|
|
|
2019-05-16 14:14:13 +02:00
|
|
|
def draw_header(self, context):
|
2015-01-19 16:30:35 +11:00
|
|
|
st = context.space_data
|
2019-05-16 14:14:13 +02:00
|
|
|
|
|
|
|
layout = self.layout
|
|
|
|
layout.active = st.show_safe_areas
|
|
|
|
layout.prop(st, "show_safe_center", text="")
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
|
|
|
layout.use_property_split = True
|
2015-01-27 17:46:07 +11:00
|
|
|
safe_data = context.scene.safe_areas
|
2019-05-16 14:14:13 +02:00
|
|
|
st = context.space_data
|
2015-01-19 16:30:35 +11:00
|
|
|
|
2019-05-16 14:14:13 +02:00
|
|
|
layout.active = st.show_safe_areas and st.show_safe_center
|
|
|
|
|
|
|
|
col = layout.column()
|
|
|
|
col.prop(safe_data, "title_center", slider=True)
|
2015-01-19 16:30:35 +11:00
|
|
|
|
|
|
|
|
2012-08-19 15:41:56 +00:00
|
|
|
class SEQUENCER_PT_modifiers(SequencerButtonsPanel, Panel):
|
|
|
|
bl_label = "Modifiers"
|
2017-01-12 01:03:23 -05:00
|
|
|
bl_category = "Modifiers"
|
2012-08-19 15:41:56 +00:00
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
layout = self.layout
|
2019-05-16 13:58:04 +02:00
|
|
|
layout.use_property_split = True
|
2012-08-19 15:41:56 +00:00
|
|
|
|
|
|
|
strip = act_strip(context)
|
2018-02-19 22:32:41 +11:00
|
|
|
ed = context.scene.sequence_editor
|
2012-08-19 15:41:56 +00:00
|
|
|
|
Color Management, Stage 2: Switch color pipeline to use OpenColorIO
Replace old color pipeline which was supporting linear/sRGB color spaces
only with OpenColorIO-based pipeline.
This introduces two configurable color spaces:
- Input color space for images and movie clips. This space is used to convert
images/movies from color space in which file is saved to Blender's linear
space (for float images, byte images are not internally converted, only input
space is stored for such images and used later).
This setting could be found in image/clip data block settings.
- Display color space which defines space in which particular display is working.
This settings could be found in scene's Color Management panel.
When render result is being displayed on the screen, apart from converting image
to display space, some additional conversions could happen.
This conversions are:
- View, which defines tone curve applying before display transformation.
These are different ways to view the image on the same display device.
For example it could be used to emulate film view on sRGB display.
- Exposure affects on image exposure before tone map is applied.
- Gamma is post-display gamma correction, could be used to match particular
display gamma.
- RGB curves are user-defined curves which are applying before display
transformation, could be used for different purposes.
All this settings by default are only applying on render result and does not
affect on other images. If some particular image needs to be affected by this
transformation, "View as Render" setting of image data block should be set to
truth. Movie clips are always affected by all display transformations.
This commit also introduces configurable color space in which sequencer is
working. This setting could be found in scene's Color Management panel and
it should be used if such stuff as grading needs to be done in color space
different from sRGB (i.e. when Film view on sRGB display is use, using VD16
space as sequencer's internal space would make grading working in space
which is close to the space using for display).
Some technical notes:
- Image buffer's float buffer is now always in linear space, even if it was
created from 16bit byte images.
- Space of byte buffer is stored in image buffer's rect_colorspace property.
- Profile of image buffer was removed since it's not longer meaningful.
- OpenGL and GLSL is supposed to always work in sRGB space. It is possible
to support other spaces, but it's quite large project which isn't so
much important.
- Legacy Color Management option disabled is emulated by using None display.
It could have some regressions, but there's no clear way to avoid them.
- If OpenColorIO is disabled on build time, it should make blender behaving
in the same way as previous release with color management enabled.
More details could be found at this page (more details would be added soon):
http://wiki.blender.org/index.php/Dev:Ref/Release_Notes/2.64/Color_Management
--
Thanks to Xavier Thomas, Lukas Toene for initial work on OpenColorIO
integration and to Brecht van Lommel for some further development and code/
usecase review!
2012-09-15 10:05:07 +00:00
|
|
|
layout.prop(strip, "use_linear_modifiers")
|
|
|
|
|
2012-08-19 15:41:56 +00:00
|
|
|
layout.operator_menu_enum("sequencer.strip_modifier_add", "type")
|
2015-06-15 21:23:09 +02:00
|
|
|
layout.operator("sequencer.strip_modifier_copy")
|
2012-08-19 15:41:56 +00:00
|
|
|
|
|
|
|
for mod in strip.modifiers:
|
|
|
|
box = layout.box()
|
|
|
|
|
|
|
|
row = box.row()
|
|
|
|
row.prop(mod, "show_expanded", text="", emboss=False)
|
2012-08-23 09:04:30 +00:00
|
|
|
row.prop(mod, "name", text="")
|
2012-08-19 15:41:56 +00:00
|
|
|
|
|
|
|
row.prop(mod, "mute", text="")
|
2012-08-23 09:04:30 +00:00
|
|
|
|
|
|
|
sub = row.row(align=True)
|
|
|
|
props = sub.operator("sequencer.strip_modifier_move", text="", icon='TRIA_UP')
|
|
|
|
props.name = mod.name
|
|
|
|
props.direction = 'UP'
|
|
|
|
props = sub.operator("sequencer.strip_modifier_move", text="", icon='TRIA_DOWN')
|
|
|
|
props.name = mod.name
|
|
|
|
props.direction = 'DOWN'
|
|
|
|
|
2013-08-23 20:41:21 +00:00
|
|
|
row.operator("sequencer.strip_modifier_remove", text="", icon='X', emboss=False).name = mod.name
|
2012-08-19 15:41:56 +00:00
|
|
|
|
|
|
|
if mod.show_expanded:
|
|
|
|
row = box.row()
|
|
|
|
row.prop(mod, "input_mask_type", expand=True)
|
|
|
|
|
|
|
|
if mod.input_mask_type == 'STRIP':
|
2018-02-19 22:32:41 +11:00
|
|
|
sequences_object = ed
|
|
|
|
if ed.meta_stack:
|
|
|
|
sequences_object = ed.meta_stack[-1]
|
2014-02-18 16:01:16 +06:00
|
|
|
box.prop_search(mod, "input_mask_strip", sequences_object, "sequences", text="Mask")
|
2012-08-19 15:41:56 +00:00
|
|
|
else:
|
|
|
|
box.prop(mod, "input_mask_id")
|
2016-01-25 11:16:49 +01:00
|
|
|
row = box.row()
|
|
|
|
row.prop(mod, "mask_time", expand=True)
|
2012-08-19 15:41:56 +00:00
|
|
|
|
|
|
|
if mod.type == 'COLOR_BALANCE':
|
|
|
|
box.prop(mod, "color_multiply")
|
|
|
|
draw_color_balance(box, mod.color_balance)
|
|
|
|
elif mod.type == 'CURVES':
|
2018-08-23 10:25:54 +02:00
|
|
|
box.template_curve_mapping(mod, "curve_mapping", type='COLOR', show_tone=True)
|
2012-08-19 15:41:56 +00:00
|
|
|
elif mod.type == 'HUE_CORRECT':
|
|
|
|
box.template_curve_mapping(mod, "curve_mapping", type='HUE')
|
2012-08-24 09:07:04 +00:00
|
|
|
elif mod.type == 'BRIGHT_CONTRAST':
|
|
|
|
col = box.column()
|
|
|
|
col.prop(mod, "bright")
|
|
|
|
col.prop(mod, "contrast")
|
2015-12-28 11:55:14 +01:00
|
|
|
elif mod.type == 'WHITE_BALANCE':
|
|
|
|
col = box.column()
|
|
|
|
col.prop(mod, "white_value")
|
2016-01-19 15:53:43 +01:00
|
|
|
elif mod.type == 'TONEMAP':
|
|
|
|
col = box.column()
|
|
|
|
col.prop(mod, "tonemap_type")
|
|
|
|
if mod.tonemap_type == 'RD_PHOTORECEPTOR':
|
|
|
|
col.prop(mod, "intensity")
|
|
|
|
col.prop(mod, "contrast")
|
|
|
|
col.prop(mod, "adaptation")
|
|
|
|
col.prop(mod, "correction")
|
|
|
|
elif mod.tonemap_type == 'RH_SIMPLE':
|
|
|
|
col.prop(mod, "key")
|
|
|
|
col.prop(mod, "offset")
|
|
|
|
col.prop(mod, "gamma")
|
2012-08-19 15:41:56 +00:00
|
|
|
|
2016-02-01 00:47:10 +11:00
|
|
|
|
2019-07-29 12:39:19 +02:00
|
|
|
class SEQUENCER_PT_annotation(AnnotationDataPanel, SequencerButtonsPanel_Output, Panel):
|
Grease Pencil - Storyboarding Features (merge from GPencil_EditStrokes branch)
This merge-commit brings in a number of new features and workflow/UI improvements for
working with Grease Pencil. While these were originally targetted at improving
the workflow for creating 3D storyboards in Blender using the Grease Pencil,
many of these changes should also prove useful in other workflows too.
The main highlights here are:
1) It is now possible to edit Grease Pencil strokes
- Use D Tab, or toggle the "Enable Editing" toggles in the Toolbar/Properties regions
to enter "Stroke Edit Mode". In this mode, many common editing tools will
operate on Grease Pencil stroke points instead.
- Tools implemented include Select, Select All/Border/Circle/Linked/More/Less,
Grab, Rotate, Scale, Bend, Shear, To Sphere, Mirror, Duplicate, Delete.
- Proportional Editing works when using the transform tools
2) Grease Pencil stroke settings can now be animated
NOTE: Currently drivers don't work, but if time allows, this may still be
added before the release.
3) Strokes can be drawn with "filled" interiors, using a separate set of
colour/opacity settings to the ones used for the lines themselves.
This makes use of OpenGL filled polys, which has the limitation of only
being able to fill convex shapes. Some artifacts may be visible on concave
shapes (e.g. pacman's mouth will be overdrawn)
4) "Volumetric Strokes" - An alternative drawing technique for stroke drawing
has been added which draws strokes as a series of screen-aligned discs.
While this was originally a partial experimental technique at getting better
quality 3D lines, the effects possible using this technique were interesting
enough to warrant making this a dedicated feature. Best results when partial
opacity and large stroke widths are used.
5) Improved Onion Skinning Support
- Different colours can be selected for the before/after ghosts. To do so,
enable the "colour wheel" toggle beside the Onion Skinning toggle, and set
the colours accordingly.
- Different numbers of ghosts can be shown before/after the current frame
6) Grease Pencil datablocks are now attached to the scene by default instead of
the active object.
- For a long time, the object-attachment has proved to be quite problematic
for users to keep track of. Now that this is done at scene level, it is
easier for most users to use.
- An exception for old files (and for any addons which may benefit from object
attachment instead), is that if the active object has a Grease Pencil datablock,
that will be used instead.
- It is not currently possible to choose object-attachment from the UI, but
it is simple to do this from the console instead, by doing:
context.active_object.grease_pencil = bpy.data.grease_pencil["blah"]
7) Various UI Cleanups
- The layers UI has been cleaned up to use a list instead of the nested-panels
design. Apart from saving space, this is also much nicer to look at now.
- The UI code is now all defined in Python. To support this, it has been necessary
to add some new context properties to make it easier to access these settings.
e.g. "gpencil_data" for the datablock
"active_gpencil_layer" and "active_gpencil_frame" for active data,
"editable_gpencil_strokes" for the strokes that can be edited
- The "stroke placement/alignment" settings (previously "Drawing Settings" at the
bottom of the Grease Pencil panel in the Properties Region) is now located in
the toolbar. These were more toolsettings than properties for how GPencil got drawn.
- "Use Sketching Sessions" has been renamed "Continuous Drawing", as per a
suggestion for an earlier discussion on developer.blender.org
- By default, the painting operator will wait for a mouse button to be pressed
before it starts creating the stroke. This is to make it easier to include
this operator in various toolbars/menus/etc. To get it immediately starting
(as when you hold down DKEy to draw), set "wait_for_input" to False.
- GPencil Layers can be rearranged in the "Grease Pencil" mode of the Action Editor
- Toolbar panels have been added to all the other editors which support these.
8) Pie menus for quick-access to tools
A set of experimental pie menus has been included for quick access to many
tools and settings. It is not necessary to use these to get things done,
but they have been designed to help make certain common tasks easier.
- Ctrl-D = The main pie menu. Reveals tools in a context sensitive and
spatially stable manner.
- D Q = "Quick Settings" pie. This allows quick access to the active
layer's settings. Notably, colours, thickness, and turning
onion skinning on/off.
2014-12-01 01:52:06 +13:00
|
|
|
bl_space_type = 'SEQUENCE_EDITOR'
|
|
|
|
bl_region_type = 'UI'
|
2019-05-16 15:02:15 +02:00
|
|
|
bl_category = "View"
|
2018-11-28 19:19:01 +01:00
|
|
|
|
2019-07-29 22:43:09 +02:00
|
|
|
@staticmethod
|
|
|
|
def has_preview(context):
|
|
|
|
st = context.space_data
|
|
|
|
return st.view_type in {'PREVIEW', 'SEQUENCER_PREVIEW'}
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
def poll(cls, context):
|
|
|
|
return cls.has_preview(context)
|
|
|
|
|
2018-11-28 19:19:01 +01:00
|
|
|
# NOTE: this is just a wrapper around the generic GP Panel
|
|
|
|
# But, it should only show up when there are images in the preview region
|
|
|
|
|
|
|
|
|
2015-04-02 21:05:12 +11:00
|
|
|
class SEQUENCER_PT_custom_props(SequencerButtonsPanel, PropertyPanel, Panel):
|
2018-11-26 19:00:01 +01:00
|
|
|
COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_EEVEE', 'BLENDER_WORKBENCH'}
|
2015-04-02 21:05:12 +11:00
|
|
|
_context_path = "scene.sequence_editor.active_strip"
|
|
|
|
_property_type = (bpy.types.Sequence,)
|
2017-01-12 01:03:23 -05:00
|
|
|
bl_category = "Strip"
|
2015-04-02 21:05:12 +11:00
|
|
|
|
|
|
|
|
2017-03-18 20:03:24 +11:00
|
|
|
classes = (
|
2019-01-15 18:33:37 +01:00
|
|
|
SEQUENCER_MT_change,
|
2017-03-18 20:03:24 +11:00
|
|
|
SEQUENCER_HT_header,
|
|
|
|
SEQUENCER_MT_editor_menus,
|
2019-05-20 18:04:35 +02:00
|
|
|
SEQUENCER_MT_range,
|
2017-03-18 20:03:24 +11:00
|
|
|
SEQUENCER_MT_view,
|
2019-04-28 14:13:41 -07:00
|
|
|
SEQUENCER_MT_view_cache,
|
2017-03-18 20:03:24 +11:00
|
|
|
SEQUENCER_MT_view_toggle,
|
2019-08-09 15:35:42 +02:00
|
|
|
SEQUENCER_MT_preview_zoom,
|
2019-05-20 18:04:35 +02:00
|
|
|
SEQUENCER_MT_select_playhead,
|
|
|
|
SEQUENCER_MT_select_handle,
|
|
|
|
SEQUENCER_MT_select_channel,
|
|
|
|
SEQUENCER_MT_select_linked,
|
2017-03-20 02:34:32 +11:00
|
|
|
SEQUENCER_MT_select,
|
|
|
|
SEQUENCER_MT_marker,
|
2019-05-18 10:05:13 +02:00
|
|
|
SEQUENCER_MT_navigation,
|
2017-03-20 02:34:32 +11:00
|
|
|
SEQUENCER_MT_add,
|
|
|
|
SEQUENCER_MT_add_effect,
|
2018-11-08 16:01:02 +01:00
|
|
|
SEQUENCER_MT_add_transitions,
|
|
|
|
SEQUENCER_MT_add_empty,
|
2019-05-22 14:59:04 +02:00
|
|
|
SEQUENCER_MT_strip_effect,
|
|
|
|
SEQUENCER_MT_strip_movie,
|
2017-03-20 02:34:32 +11:00
|
|
|
SEQUENCER_MT_strip,
|
2017-10-09 13:47:05 +11:00
|
|
|
SEQUENCER_MT_strip_transform,
|
|
|
|
SEQUENCER_MT_strip_input,
|
|
|
|
SEQUENCER_MT_strip_lock_mute,
|
2019-05-07 21:07:52 +02:00
|
|
|
SEQUENCER_MT_context_menu,
|
2019-05-16 13:58:04 +02:00
|
|
|
|
2019-06-21 11:22:56 +02:00
|
|
|
SEQUENCER_PT_strip,
|
|
|
|
|
2019-08-19 20:50:52 +10:00
|
|
|
SEQUENCER_PT_effect,
|
2019-05-16 13:58:04 +02:00
|
|
|
SEQUENCER_PT_adjust,
|
|
|
|
SEQUENCER_PT_adjust_comp,
|
2019-06-20 19:11:39 +02:00
|
|
|
SEQUENCER_PT_adjust_transform,
|
|
|
|
SEQUENCER_PT_adjust_transform_offset,
|
|
|
|
SEQUENCER_PT_adjust_transform_crop,
|
2019-05-16 13:58:04 +02:00
|
|
|
SEQUENCER_PT_adjust_video,
|
|
|
|
SEQUENCER_PT_adjust_color,
|
|
|
|
SEQUENCER_PT_adjust_sound,
|
|
|
|
|
2017-03-20 02:34:32 +11:00
|
|
|
SEQUENCER_PT_scene,
|
2017-03-18 20:03:24 +11:00
|
|
|
SEQUENCER_PT_mask,
|
2019-08-09 14:08:20 +02:00
|
|
|
SEQUENCER_PT_effect_text_style,
|
|
|
|
SEQUENCER_PT_effect_text_layout,
|
|
|
|
SEQUENCER_PT_effect_text_style_shadow,
|
2019-05-16 13:58:04 +02:00
|
|
|
|
2019-06-21 20:01:08 +02:00
|
|
|
SEQUENCER_PT_time,
|
|
|
|
SEQUENCER_PT_source,
|
|
|
|
|
2019-06-20 19:11:39 +02:00
|
|
|
SEQUENCER_PT_modifiers,
|
|
|
|
|
2019-05-17 11:31:49 +02:00
|
|
|
SEQUENCER_PT_cache_settings,
|
2019-05-17 12:01:45 +02:00
|
|
|
SEQUENCER_PT_strip_cache,
|
2019-05-19 11:29:21 -07:00
|
|
|
SEQUENCER_PT_proxy_settings,
|
|
|
|
SEQUENCER_PT_strip_proxy,
|
2019-05-17 11:31:49 +02:00
|
|
|
|
|
|
|
SEQUENCER_PT_custom_props,
|
|
|
|
|
2017-03-20 02:34:32 +11:00
|
|
|
SEQUENCER_PT_preview,
|
2017-03-18 20:03:24 +11:00
|
|
|
SEQUENCER_PT_view,
|
2019-05-17 13:38:34 +02:00
|
|
|
SEQUENCER_PT_frame_overlay,
|
2017-03-18 20:03:24 +11:00
|
|
|
SEQUENCER_PT_view_safe_areas,
|
2019-05-16 14:14:13 +02:00
|
|
|
SEQUENCER_PT_view_safe_areas_center_cut,
|
2019-05-17 00:28:22 +10:00
|
|
|
|
2019-07-29 12:39:19 +02:00
|
|
|
SEQUENCER_PT_annotation,
|
2017-03-18 20:03:24 +11:00
|
|
|
)
|
|
|
|
|
2011-04-04 10:13:04 +00:00
|
|
|
if __name__ == "__main__": # only for live edit.
|
2017-03-18 20:03:24 +11:00
|
|
|
from bpy.utils import register_class
|
|
|
|
for cls in classes:
|
|
|
|
register_class(cls)
|