mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-06-13 05:17:13 +02:00
rx: moved creating fpath (if it doesnt exist) from setting file path to at the start of acquisition when creating file. This is done here so that it does not fail if fwrite is disabled anyway. Also fixed it in documentation. Changed in documentation that the default for fwrite is disabled (#957)
This commit is contained in:
@ -530,10 +530,7 @@ void Implementation::setFileFormat(const fileFormat f) {
|
||||
std::string Implementation::getFilePath() const { return filePath; }
|
||||
|
||||
void Implementation::setFilePath(const std::string &c) {
|
||||
if (!c.empty()) {
|
||||
mkdir_p(c); // throws if it can't create
|
||||
filePath = c;
|
||||
}
|
||||
filePath = c;
|
||||
LOG(logINFO) << "File path: " << filePath;
|
||||
}
|
||||
|
||||
@ -901,6 +898,9 @@ void Implementation::CreateUDPSockets() {
|
||||
|
||||
void Implementation::SetupWriter() {
|
||||
try {
|
||||
// check if folder exists and throw if it cant create
|
||||
mkdir_p(filePath);
|
||||
// create first files
|
||||
for (unsigned int i = 0; i < dataProcessor.size(); ++i) {
|
||||
std::ostringstream os;
|
||||
os << filePath << "/" << fileName << "_d"
|
||||
|
Reference in New Issue
Block a user