mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-06-23 10:07:59 +02:00
Make a library for writing and reading tiff, added tests (#347)
* removed Makefile for moench and integrated the build in CMake * broke out tiff reading and writing to its own library * moved tiff includes to include/sls * moved tiffio source to src * removed incorrectly used bps * cleanup and tests for tiffio * removed using namespace std from header * some fixing for moench04 * Program for offline processing renamed Co-authored-by: Anna Bergamaschi <anna.bergamaschi@psi.ch>
This commit is contained in:
16
slsDetectorCalibration/tiffio/include/sls/tiffIO.h
Normal file
16
slsDetectorCalibration/tiffio/include/sls/tiffIO.h
Normal file
@ -0,0 +1,16 @@
|
||||
// SPDX-License-Identifier: LGPL-3.0-or-other
|
||||
// Copyright (C) 2021 Contributors to the SLS Detector Package
|
||||
#pragma once
|
||||
#include <cstdint>
|
||||
|
||||
//Write 32bit float data to tiff file
|
||||
//Always returns nullptr, prints message on failure
|
||||
void *WriteToTiff(float *imgData, const char *imgname, int nrow, int ncol);
|
||||
|
||||
//Read 32bit float data from tiff file, returns pointer to data and sets
|
||||
//image dimensions in the out parameters nrow, ncol.
|
||||
//Returns nullptr on failure
|
||||
//The caller is responsible to deallocate the memory that the returned
|
||||
//pointer points to.
|
||||
float *ReadFromTiff(const char *imgname, uint32_t &nrow, uint32_t &ncol);
|
||||
|
Reference in New Issue
Block a user