mirror of
https://github.com/opencv/opencv.git
synced 2026-07-29 15:23:05 +04:00
add std::string overload for cv::read()
This commit is contained in:
committed by
Vladislav Sovrasov
parent
5b833db558
commit
6dd9e18b2e
@@ -7396,6 +7396,11 @@ void read(const FileNode& node, String& value, const String& default_value)
|
||||
value = !node.node ? default_value : CV_NODE_IS_STRING(node.node->tag) ? String(node.node->data.str.ptr) : String();
|
||||
}
|
||||
|
||||
void read(const FileNode& node, std::string& value, const std::string& default_value)
|
||||
{
|
||||
value = !node.node ? default_value : CV_NODE_IS_STRING(node.node->tag) ? std::string(node.node->data.str.ptr) : default_value;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user