Skip to content
Snippets Groups Projects
Commit 7688d404 authored by Cyrille Valladeau's avatar Cyrille Valladeau
Browse files

ENH: add otput pixel type get accessor

parent 6ee0f221
No related branches found
No related tags found
No related merge requests found
......@@ -699,6 +699,21 @@ std::string Application::GetParameterAsString(std::string paramKey)
return ret;
}
ImagePixelType Application::GetParameterOutputImagePixelType(std::string parameter)
{
Parameter* param = GetParameterByKey(parameter);
ImagePixelType ret;
if (dynamic_cast<OutputImageParameter*>(param))
{
OutputImageParameter* paramDown = dynamic_cast<OutputImageParameter*>(param);
ret = paramDown->GetPixelType();
}
//TODO: exception if not found ?
return ret;
}
void
Application::AddChoice(std::string paramKey, std::string paramName)
{
......
......@@ -318,6 +318,13 @@ public:
*/
std::vector<std::string> GetParametersKeys(bool recursive = true);
/* Get the pixel type in which the image will be saved
*
* Can be called for types :
* \li ParameterType_OutputImage
*/
ImagePixelType GetParameterOutputImagePixelType(std::string parameter);
itk::Logger* GetLogger();
void AddProcess(itk::ProcessObject* object, std::string description);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment