FLImaging 6.11.25.2
FLImageDisplayUtilities.h
1#pragma once
2#include "FLPoint.h"
3
9
11namespace FLImaging
12{
14 namespace Foundation
15 {
57 typedef struct FL_EXPORT sBufferFormat
58 {
59 sBufferFormat();
60 sBufferFormat(bool _bAlignToDword, bool _bBGR, bool _bBottomUp);
61 bool bAlignToDword;
62 bool bBGR;
63 bool bBottomUp;
65
76 {
77 public:
86
87 static CFLImageDisplayUtilities* GetObject();
88 static bool Initialize();
89 static bool IsInitialized();
90
100 static uint8_t* GetFloatTable();
101
111 static uint32_t* GetIntensitySpectrumTable();
112
136 static uint32_t* GetSegmentationColorTable();
137
165 static int32_t GetAlignedRowStrideBytes(int32_t i32Width, int32_t i32Channel);
166
182 static const CResult GetRangeOfFloatImage(const Base::CFLImage* pFliSrc,
183 double& f64MinVal,
184 double& f64MaxVal);
238 static const CResult ConvertFLImageToBuffer(const Base::CFLImage* pFliSrc,
239 uint8_t* pDstBuffer,
240 int32_t i32DstWidth,
241 int32_t i32DstHeight,
242 const Foundation::CFLPoint<double>* pFlpOffset = nullptr,
243 double f64ScaleX = 1.,
244 double f64ScaleY = 1.,
245 double f64MinVal = 0.,
246 double f64MaxVal = 1.,
247 bool bSegmentationWithColor = false,
248 bool bReductionInterpolation = false,
249 const SBufferFormat& sFormat = SBufferFormat());
250
251 static const CResult ConvertFLImageToBuffer(const Base::CFLImage& fliSrc,
252 uint8_t* pDstBuffer,
253 int32_t i32DstWidth,
254 int32_t i32DstHeight,
255 const Foundation::CFLPoint<double>* pFlpOffset = nullptr,
256 double f64ScaleX = 1.,
257 double f64ScaleY = 1.,
258 double f64MinVal = 0.,
259 double f64MaxVal = 1.,
260 bool bSegmentationWithColor = false,
261 bool bReductionInterpolation = false,
262 const SBufferFormat& sFormat = SBufferFormat());
263
264
265 protected:
266 volatile bool m_bInitialized;
267 };
268 }
269}
FLIMaging's image class.
Definition FLImage.h:35
FLImaging module execution result object.
Definition ResultsDef.h:1631
static uint32_t * GetIntensitySpectrumTable()
Retrieve the color spectrum lookup table used for visualizing intensity values.
static uint32_t * GetSegmentationColorTable()
Returns the predefined segmentation-color lookup table.
static const CResult GetRangeOfFloatImage(const Base::CFLImage *pFliSrc, double &f64MinVal, double &f64MaxVal)
Compute the minimum and maximum pixel values of a floating-point image.
static const CResult ConvertFLImageToBuffer(const Base::CFLImage *pFliSrc, uint8_t *pDstBuffer, int32_t i32DstWidth, int32_t i32DstHeight, const Foundation::CFLPoint< double > *pFlpOffset=nullptr, double f64ScaleX=1., double f64ScaleY=1., double f64MinVal=0., double f64MaxVal=1., bool bSegmentationWithColor=false, bool bReductionInterpolation=false, const SBufferFormat &sFormat=SBufferFormat())
Converts a CFLImage into a display-ready pixel buffer.
static uint8_t * GetFloatTable()
Retrieve the lookup table used to map floating-point pixel values (0.0–1.0) to 8-bit intensity.
static int32_t GetAlignedRowStrideBytes(int32_t i32Width, int32_t i32Channel)
Computes the byte stride (row size in bytes) for an image row, applying 4-byte (DWORD) alignment as u...
A class representing a point.
Definition FLPoint.h:24
Definition AlgorithmBase.h:16
Specifies the output buffer layout for displaying or exporting an FLImage.