← Back to the scanner case study
Architecture · Rust · C++ · Python
Interfaces for research and client integration
Python bindings that let research use the production C++/CUDA core, and a C interface for evaluating the Rust reconstruction engine. Each gives other developers access to the algorithms through explicit data and ownership contracts.
One implementation for research and production
Critical system logic had to serve an established C++ production library as well as fast-moving research and prototyping workflows. Separate implementations would have created duplicated logic and different sources of truth.
Bindings and a C interface
The initial Python binding layer covers the C++/CUDA processing stages, including depth computation, frame buffers, registration, and reconstruction. Recorded data could be passed through the same implementations used by the production scanner software, making individual stages available for research and experiments.
The Rust reconstruction engine was delivered for client evaluation as one library and a C header, with no runtime dependencies beyond the platform's system libraries. The caller supplies decoded frames and approximate poses, starts refinement, and reads back the results.
The interface keeps the caller's geometry consistent: depth enters as measured, and poses enter and leave in the same camera convention. The scanner's internal coordinate shift is declared as camera metadata and handled inside the library. Input buffers can be reused as soon as the push call returns; result handles have explicit release functions.
Failures are part of that interface too. Too few frames produce a clear error before processing starts, and a caught worker panic becomes a failed operation with an error message instead of leaving the caller polling forever. A version handshake, host logging callback, and runnable C example give the client a way to check the integration before introducing its own data.
What each interface provides
The Python bindings let research use the same C++/CUDA implementation as production. The Rust deliverable gives the client a documented, versioned interface for evaluating reconstruction on its own data, with coordinate conversion and worker management kept inside the library.
Client work for Planmeca, formerly E4D Technologies, described at a technical level. The work described is my own unless noted otherwise. References are available on request.