Quantcast
Channel: OpenCV Q&A Forum - RSS feed
Viewing all articles
Browse latest Browse all 41027

Issue when write yaml file (C++)

$
0
0
the content of the yaml file I hope is AAA: - BBB: a: 1 b: 2 the code I write is like FileStorage fw("./config.yaml", FileStorage::WRITE); fw << "AAA" << "[" << "{"; fw << "BBB" << "{"; fw << "a" << 1; fw << "b" << 2; fw << "}" << "}" << "]"; while the output of config.yaml is like AAA: - BBB: a: 1 b: 2 the "-" and "BBB" are not in a line. how can I solve this problem?

Viewing all articles
Browse latest Browse all 41027

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>