| 300 | } |
| 301 | |
| 302 | bool mitk::DataNode::GetDoubleProperty(const char *propertyKey, |
| 303 | double &doubleValue, |
| 304 | const mitk::BaseRenderer *renderer) const |
| 305 | { |
| 306 | mitk::DoubleProperty::Pointer doubleprop = dynamic_cast<mitk::DoubleProperty *>(GetProperty(propertyKey, renderer)); |
| 307 | if (doubleprop.IsNull()) |
| 308 | { |
| 309 | // try float instead |
| 310 | float floatValue = 0; |
| 311 | if (this->GetFloatProperty(propertyKey, floatValue, renderer)) |
| 312 | { |
| 313 | doubleValue = floatValue; |
| 314 | return true; |
| 315 | } |
| 316 | return false; |
| 317 | } |
| 318 | |
| 319 | doubleValue = doubleprop->GetValue(); |
| 320 | return true; |
| 321 | } |
| 322 | |
| 323 | bool mitk::DataNode::GetStringProperty(const char *propertyKey, |
| 324 | std::string &string, |