Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/compositor/nodes/COM_BoxMaskNode.cpp')
-rw-r--r--source/blender/compositor/nodes/COM_BoxMaskNode.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/source/blender/compositor/nodes/COM_BoxMaskNode.cpp b/source/blender/compositor/nodes/COM_BoxMaskNode.cpp
index ef62536595c..fe59bd32939 100644
--- a/source/blender/compositor/nodes/COM_BoxMaskNode.cpp
+++ b/source/blender/compositor/nodes/COM_BoxMaskNode.cpp
@@ -52,13 +52,14 @@ void BoxMaskNode::convertToOperations(NodeConverter &converter,
/* Scale that image up to render resolution */
const RenderData *rd = context.getRenderData();
+ const float render_size_factor = context.getRenderPercentageAsFactor();
ScaleFixedSizeOperation *scaleOperation = new ScaleFixedSizeOperation();
scaleOperation->setIsAspect(false);
scaleOperation->setIsCrop(false);
scaleOperation->setOffset(0.0f, 0.0f);
- scaleOperation->setNewWidth(rd->xsch * rd->size / 100.0f);
- scaleOperation->setNewHeight(rd->ysch * rd->size / 100.0f);
+ scaleOperation->setNewWidth(rd->xsch * render_size_factor);
+ scaleOperation->setNewHeight(rd->ysch * render_size_factor);
scaleOperation->getInputSocket(0)->setResizeMode(COM_SC_NO_RESIZE);
converter.addOperation(scaleOperation);