Changeset View
Changeset View
Standalone View
Standalone View
source/blender/compositor/nodes/COM_EllipseMaskNode.cc
| Show First 20 Lines • Show All 56 Lines • ▼ Show 20 Lines | else { | ||||
| const float render_size_factor = context.getRenderPercentageAsFactor(); | const float render_size_factor = context.getRenderPercentageAsFactor(); | ||||
| ScaleFixedSizeOperation *scaleOperation = new ScaleFixedSizeOperation(); | ScaleFixedSizeOperation *scaleOperation = new ScaleFixedSizeOperation(); | ||||
| scaleOperation->setIsAspect(false); | scaleOperation->setIsAspect(false); | ||||
| scaleOperation->setIsCrop(false); | scaleOperation->setIsCrop(false); | ||||
| scaleOperation->setOffset(0.0f, 0.0f); | scaleOperation->setOffset(0.0f, 0.0f); | ||||
| scaleOperation->setNewWidth(rd->xsch * render_size_factor); | scaleOperation->setNewWidth(rd->xsch * render_size_factor); | ||||
| scaleOperation->setNewHeight(rd->ysch * render_size_factor); | scaleOperation->setNewHeight(rd->ysch * render_size_factor); | ||||
| scaleOperation->getInputSocket(0)->setResizeMode(ResizeMode::None); | scaleOperation->getInputSocket(0)->setResizeMode(ResizeMode::Align); | ||||
| converter.addOperation(scaleOperation); | converter.addOperation(scaleOperation); | ||||
| converter.addLink(valueOperation->getOutputSocket(0), scaleOperation->getInputSocket(0)); | converter.addLink(valueOperation->getOutputSocket(0), scaleOperation->getInputSocket(0)); | ||||
| converter.addLink(scaleOperation->getOutputSocket(0), operation->getInputSocket(0)); | converter.addLink(scaleOperation->getOutputSocket(0), operation->getInputSocket(0)); | ||||
| converter.mapOutputSocket(outputSocket, operation->getOutputSocket(0)); | converter.mapOutputSocket(outputSocket, operation->getOutputSocket(0)); | ||||
| } | } | ||||
| converter.mapInputSocket(getInputSocket(1), operation->getInputSocket(1)); | converter.mapInputSocket(getInputSocket(1), operation->getInputSocket(1)); | ||||
| } | } | ||||
| } // namespace blender::compositor | } // namespace blender::compositor | ||||