mirror of
https://github.com/paulscherrerinstitute/sf_daq_buffer.git
synced 2026-05-13 01:25:36 +02:00
Passing the output file as a string
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
#include <H5version.h>
|
||||
#include <iostream>
|
||||
#include <utility>
|
||||
|
||||
#include "JFH5Writer.hpp"
|
||||
#include "live_writer_config.hpp"
|
||||
@@ -15,10 +16,8 @@ using namespace std;
|
||||
using namespace buffer_config;
|
||||
using namespace live_writer_config;
|
||||
|
||||
JFH5Writer::JFH5Writer(
|
||||
const std::string detector_name, const std::string root_folder):
|
||||
detector_name_(detector_name),
|
||||
root_folder_(root_folder)
|
||||
JFH5Writer::JFH5Writer(std::string detector_name):
|
||||
detector_name_(std::move(detector_name))
|
||||
{
|
||||
}
|
||||
|
||||
@@ -42,7 +41,8 @@ hid_t JFH5Writer::get_datatype(const int bits_per_pixel)
|
||||
}
|
||||
}
|
||||
|
||||
void JFH5Writer::open_run(const int64_t run_id,
|
||||
void JFH5Writer::open_run(const string& output_file,
|
||||
const int64_t run_id,
|
||||
const uint32_t n_images,
|
||||
const uint32_t image_y_size,
|
||||
const uint32_t image_x_size,
|
||||
@@ -50,10 +50,6 @@ void JFH5Writer::open_run(const int64_t run_id,
|
||||
{
|
||||
close_run();
|
||||
|
||||
const string output_folder = root_folder_ + "/" + OUTPUT_FOLDER_SYMLINK;
|
||||
// TODO: Maybe add leading zeros to filename?
|
||||
const string output_file = output_folder + to_string(run_id) + ".h5";
|
||||
|
||||
current_run_id_ = run_id;
|
||||
image_y_size_ = image_y_size;
|
||||
image_x_size_ = image_x_size;
|
||||
|
||||
Reference in New Issue
Block a user