File tree Expand file tree Collapse file tree 1 file changed +14
-0
lines changed
Modules/Core/Common/include Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -926,6 +926,20 @@ class ITKCommon_EXPORT ProcessObject : public Object
926926 return static_cast <uint32_t >(temp);
927927 };
928928
929+
930+ /* * Sets the required number of outputs, and creates each of them by MakeOutput. */
931+ template <typename TSourceObject>
932+ static void
933+ SetRequiredOutputs (TSourceObject & sourceObject, const DataObjectPointerArraySizeType numberOfRequiredOutputs)
934+ {
935+ sourceObject.ProcessObject ::SetNumberOfRequiredOutputs (numberOfRequiredOutputs);
936+
937+ for (unsigned int i{}; i < numberOfRequiredOutputs; ++i)
938+ {
939+ sourceObject.ProcessObject ::SetNthOutput (i, sourceObject.TSourceObject ::MakeOutput (i));
940+ }
941+ }
942+
929943 /* * These ivars are made protected so filters like itkStreamingImageFilter
930944 * can access them directly. */
931945
You can’t perform that action at this time.
0 commit comments