X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=plugins%2FImageSources%2FRandomImageSource.cxx;h=0246a19363d11dace969286d48a81c9cce4783d7;hb=db0a767418f78b371c1e4fb0db00e6b75df74ff3;hp=d726feda2f81dcec37ed80065dc011b7b12ddc0f;hpb=49d2d7db538d60008b9a5701ea8f26bb19997a82;p=cpPlugins.git diff --git a/plugins/ImageSources/RandomImageSource.cxx b/plugins/ImageSources/RandomImageSource.cxx index d726fed..0246a19 100644 --- a/plugins/ImageSources/RandomImageSource.cxx +++ b/plugins/ImageSources/RandomImageSource.cxx @@ -30,12 +30,12 @@ RandomImageSource( ) pixels.push_back( "long" ); pixels.push_back( "ulong" ); #endif // cpPlugins_CONFIG_INTEGER_TYPES_long -#ifdef cpPlugins_CONFIG_INTEGER_TYPES_float +#ifdef cpPlugins_CONFIG_REAL_TYPES_float pixels.push_back( "float" ); -#endif // cpPlugins_CONFIG_INTEGER_TYPES_float -#ifdef cpPlugins_CONFIG_INTEGER_TYPES_double +#endif // cpPlugins_CONFIG_REAL_TYPES_float +#ifdef cpPlugins_CONFIG_REAL_TYPES_double pixels.push_back( "double" ); -#endif // cpPlugins_CONFIG_INTEGER_TYPES_double +#endif // cpPlugins_CONFIG_REAL_TYPES_double this->m_Parameters.ConfigureAsChoices( "PixelType", pixels ); std::vector< std::string > dims; @@ -67,27 +67,27 @@ _GenerateData( ) bool success = false; auto pixel = this->m_Parameters.GetSelectedChoice( "PixelType" ); #ifdef cpPlugins_CONFIG_INTEGER_TYPES_char - if( pixel == "char" ) success = this->_GD0< char >( ); - if( pixel == "uchar" ) success = this->_GD0< unsigned char >( ); + if( pixel == "char" ) success = this->_GD0< char >( ); + if( pixel == "uchar" ) success = this->_GD0< unsigned char >( ); #endif // cpPlugins_CONFIG_INTEGER_TYPES_char #ifdef cpPlugins_CONFIG_INTEGER_TYPES_short - if( pixel == "short" ) success = this->_GD0< short >( ); + if( pixel == "short" ) success = this->_GD0< short >( ); if( pixel == "ushort" ) success = this->_GD0< unsigned short >( ); #endif // cpPlugins_CONFIG_INTEGER_TYPES_short #ifdef cpPlugins_CONFIG_INTEGER_TYPES_int - if( pixel == "int" ) success = this->_GD0< int >( ); - if( pixel == "uint" ) success = this->_GD0< unsigned int >( ); + if( pixel == "int" ) success = this->_GD0< int >( ); + if( pixel == "uint" ) success = this->_GD0< unsigned int >( ); #endif // cpPlugins_CONFIG_INTEGER_TYPES_int #ifdef cpPlugins_CONFIG_INTEGER_TYPES_long - if( pixel == "long" ) success = this->_GD0< long >( ); - if( pixel == "ulong" ) success = this->_GD0< unsigned long >( ); + if( pixel == "long" ) success = this->_GD0< long >( ); + if( pixel == "ulong" ) success = this->_GD0< unsigned long >( ); #endif // cpPlugins_CONFIG_INTEGER_TYPES_long -#ifdef cpPlugins_CONFIG_INTEGER_TYPES_float - if( pixel == "float" ) success = this->_GD0< float >( ); -#endif // cpPlugins_CONFIG_INTEGER_TYPES_float -#ifdef cpPlugins_CONFIG_INTEGER_TYPES_double +#ifdef cpPlugins_CONFIG_REAL_TYPES_float + if( pixel == "float" ) success = this->_GD0< float >( ); +#endif // cpPlugins_CONFIG_REAL_TYPES_float +#ifdef cpPlugins_CONFIG_REAL_TYPES_double if( pixel == "double" ) success = this->_GD0< double >( ); -#endif // cpPlugins_CONFIG_INTEGER_TYPES_double +#endif // cpPlugins_CONFIG_REAL_TYPES_double if( !success ) this->_Error( "Invalid pixel type." ); }