本文整理汇总了C++中ArrayType::get方法的典型用法代码示例。如果您正苦于以下问题:C++ ArrayType::get方法的具体用法?C++ ArrayType::get怎么用?C++ ArrayType::get使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ArrayType
的用法示例。
在下文中一共展示了ArrayType::get方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: generateRepresentation
void generateRepresentation(ConvertOrientations* filter, typename DataArray<T>::Pointer inputOrientations,
typename DataArray<T>::Pointer outputOrientations)
{
typedef typename DataArray<T>::Pointer ArrayType;
typedef OrientationConverter<T> OCType;
QVector<typename OCType::Pointer> converters(7);
converters[0] = EulerConverter<T>::New();
converters[1] = OrientationMatrixConverter<T>::New();
converters[2] = QuaternionConverter<T>::New();
converters[3] = AxisAngleConverter<T>::New();
converters[4] = RodriguesConverter<T>::New();
converters[5] = HomochoricConverter<T>::New();
converters[6] = CubochoricConverter<T>::New();
QVector<typename OCType::OrientationType> ocTypes = OCType::GetOrientationTypes();
converters[filter->getInputType()]->setInputData(inputOrientations);
converters[filter->getInputType()]->convertRepresentationTo(ocTypes[filter->getOutputType()]);
ArrayType output = converters[filter->getInputType()]->getOutputData();
if(NULL == output.get())
{
QString ss = QObject::tr("There was an error converting the input data using convertor %1").arg(converters[filter->getInputType()]->getNameOfClass());
filter->setErrorCondition(-1004);
filter->notifyErrorMessage(filter->getHumanLabel(), ss, filter->getErrorCondition());
return;
}
if(!output->copyIntoArray(outputOrientations) )
{
QString ss = QObject::tr("There was an error copying the final results into the output array.");
filter->setErrorCondition(-1003);
filter->notifyErrorMessage(filter->getHumanLabel(), ss, filter->getErrorCondition());
}
}