mirror of
https://github.com/ynput/ayon-core.git
synced 2025-12-24 21:04:40 +01:00
Merge pull request #1741 from pypeclub/bugfix/nuke-create-write-no-selection
This commit is contained in:
commit
6764aaae34
2 changed files with 9 additions and 3 deletions
|
|
@ -128,5 +128,4 @@ class CreateWritePrerender(plugin.PypeCreator):
|
|||
w_node["first"].setValue(nuke.root()["first_frame"].value())
|
||||
w_node["last"].setValue(nuke.root()["last_frame"].value())
|
||||
|
||||
|
||||
return write_node
|
||||
|
|
|
|||
|
|
@ -100,6 +100,13 @@ class CreateWriteRender(plugin.PypeCreator):
|
|||
"/{subset}.{frame}.{ext}")})
|
||||
|
||||
# add crop node to cut off all outside of format bounding box
|
||||
# get width and height
|
||||
try:
|
||||
width, height = (selected_node.width(), selected_node.height())
|
||||
except AttributeError:
|
||||
actual_format = nuke.root().knob('format').value()
|
||||
width, height = (actual_format.width(), actual_format.height())
|
||||
|
||||
_prenodes = [
|
||||
{
|
||||
"name": "Crop01",
|
||||
|
|
@ -108,8 +115,8 @@ class CreateWriteRender(plugin.PypeCreator):
|
|||
("box", [
|
||||
0.0,
|
||||
0.0,
|
||||
selected_node.width(),
|
||||
selected_node.height()
|
||||
width,
|
||||
height
|
||||
])
|
||||
],
|
||||
"dependent": None
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue