aboutsummaryrefslogtreecommitdiff
path: root/libcrystfel/src/image-cbf.c
AgeCommit message (Collapse)Author
2023-05-05Move is_{hdf5,cbf,cbfgz}_file() to image.cThomas White
This also improves is_hdf5_file() to use the proper file signature, not just the extension. See 9040220452a9cc02706159c21c78e43b374446cf.
2023-03-03libcrystfel: don't use fmemopen on aarch64-darwinPhilipp Middendorf
2022-12-08image_cbf_read: Abort if panel unpack failsThomas White
2022-08-18Restructure image data array creationThomas White
This adds a central procedure (image_create_dp_bad_sat) to create all the arrays. Then it's up to the loading procedure to put the values into the arrays. This also makes the loading procedures responsible for marking NaN/inf pixels in the bad pixel map. This avoids an additional sweep through the image data, and makes it possible to skip the NaN/inf check altogether if the image data comes, as it often does, in format which can't represent NaN/inf anyway. Finally, it removes quite a lot of duplicated code.
2021-10-13Make zlib dependency optionalThomas White
2021-09-17Warn if in-memory CBF is attemptedThomas White
2021-09-17Avoid pointless passing of image/eventThomas White
2021-07-21read_cbf_data: Fix typesThomas White
'buf' has to be char *, otherwise "buf+len" isn't portable. 'len_read' has to be int, because that's the return type of gzread. If the value is immediately put into a size_t, the sign information is lost and we can no longer tell if gzread() failed.
2021-07-21Make sure that memory gets freed on realloc failureThomas White
2021-07-21Add missing cleanup on error pathsThomas White
2021-05-17Resolve FIXMEs and TODOsThomas White
Prompted by the article linked below, for each FIXME/TODO I've either referenced an issue in the tracker, or removed it if it's not worth fixing. https://schleiss.io/plotting-source-code-todos-for-open-source-projects
2021-05-12Rework header caching layerThomas White
This clears up multiple layering violations which were starting to get in the way. It enables "string" headers to be stored directly, and it will make it much simpler to add new header types in the future. Along the way, this changes all the floating point header stuff to use double precision. This is needed for EuXFEL event IDs. Closes: https://gitlab.desy.de/thomas.white/crystfel/-/issues/34
2021-04-27Rename libcrystfel's config.h to libcrystfel-config.hThomas White
This removes the big potential for confusion, which has happened several times (see e.g. 095cbebaf6). It also fixes in-tree builds with CMake (but seriously, always use out-of-tree builds). Fixes #2.
2021-03-05Mass update of copyright dates in source code commentsThomas White
2020-09-17Add missing includeThomas White
2020-07-30Add missing config.h includesThomas White
2020-07-29const-cleaningThomas White
2020-07-29Move image structure creation up to image_read()Thomas White
2020-07-29Remove events.c, part 2Thomas White
New event parsing, done at the last minute in image-hdf5.c
2020-07-29Remove events.c, part 1Thomas White
2020-07-29Remove references to old headersThomas White
2020-07-29Move HDF5 and CBF stuff into separate filesThomas White