CppNCorr
C++ ncorr Digital Image Correlation engine
Loading...
Searching...
No Matches
session.cpp File Reference

In-memory NcorrSession implementation backed by the DIC engine. More...

#include "ncorr/session.h"
#include "ncorr.h"
#include <opencv2/opencv.hpp>
#include <cmath>
#include <limits>
#include <sstream>
#include <stdexcept>

Go to the source code of this file.

Classes

struct  ncorr::NcorrSession::Impl
 

Namespaces

namespace  ncorr
 

Detailed Description

In-memory NcorrSession implementation backed by the DIC engine.

Mirrors the file-based pipeline in test/src/proxyncorr.cpp but drives the DIC engine directly from caller-provided in-memory image buffers:

  1. Wrap each ImageBuffer in an owning cv::Mat and build an ncorr::Image2D.
  2. Build a ROI2D from the optional mask (or a full-frame default).
  3. Construct a DIC_analysis_input { ref + def imgs, roi, scalefactor, interp, subregion, radius, num_threads, DIC_analysis_config, debug }.
  4. Run DIC_analysis(...) and copy the resulting Disp2D u/v/cc arrays into the flat DICResult vectors (NaN outside the ROI).

The returned fields are the native Lagrangian displacements in pixels on the reduced analysis grid (their own dims, not necessarily the input image size).

Definition in file session.cpp.