ReconstructMe SDK
2.6.43-0
Real-time 3D reconstruction engine
|
Fundamental building block in reconstruction. More...
Typedefs | |
typedef struct _reme_context * | reme_context_t |
Handle referencing a context object. More... | |
typedef enum _reme_error | reme_error_t |
Status enumeration. More... | |
typedef enum _reme_log_severity | reme_log_severity_t |
Logging severity levels. More... | |
typedef enum _reme_tune_profile | reme_tune_profile_t |
Auto-tuning profiles. More... | |
typedef void(* | reme_log_callback_t) (reme_log_severity_t sev, const char *message, void *user_info) |
Callback function prototype to receive logging information. More... | |
Fundamental building block in reconstruction.
The context is responsible for life-time management of all objects involved in the reconstruction process. It additionally maintains the the communication channel to the OpenCL device used for reconstruction.
typedef struct _reme_context* reme_context_t |
Handle referencing a context object.
A reme_context_t contains the complete state of the current reconstruction process, including sensor objects, reconstruction volumes and surface objects. reme_context_t objects are central to ReconstructMe SDK and all operations always require such a context as input.
typedef enum _reme_error reme_error_t |
Status enumeration.
A reme_error_t contains the available status codes as returned by all methods of ReconstructMe SDK. In case of error, use reme_context_get_last_error to get the latest details.
typedef enum _reme_log_severity reme_log_severity_t |
Logging severity levels.
Defines the severity of a given logging message
typedef enum _reme_tune_profile reme_tune_profile_t |
Auto-tuning profiles.
Defines for target profile to tune reconstruction settings for
typedef void(* reme_log_callback_t) (reme_log_severity_t sev, const char *message, void *user_info) |
Callback function prototype to receive logging information.
Receives logging information consisting of severity level and message. Use reme_context_set_log_callback to register a new callback.
It allows passing of an optional void pointer to user specified data.
sev | severity level |
message | the log message |
user_info | optional pointer as specified by at reme_context_add_log_callback |
enum _reme_error |
Status enumeration.
A reme_error_t contains the available status codes as returned by all methods of ReconstructMe SDK. In case of error, use reme_context_get_last_error to get the latest details.
enum _reme_log_severity |
Logging severity levels.
Defines the severity of a given logging message
enum _reme_tune_profile |
reme_error_t reme_context_create | ( | reme_context_t * | c | ) |
Create a new reme_context_t object.
c | A pointer that will receive the created context handle |
REME_ERROR_SUCCESS | On success |
REME_ERROR_UNSPECIFIED | On failure |
reme_error_t reme_context_destroy | ( | reme_context_t * | c | ) |
Destroy a previously created reme_context_t object.
Destroys all associated handles and memory allocated.
c | A pointer to a valid context object |
REME_ERROR_SUCCESS | On success |
REME_ERROR_UNSPECIFIED | On failure |
reme_error_t reme_context_get_version | ( | reme_context_t | c, |
const char ** | version, | ||
int * | length | ||
) |
Get the ReconstructMe SDK version string.
Format is
<major>.<minor>.<build> - <revision>
c | A valid context object |
version | A mutable pointer that receives the null terminated string |
length | length of string in bytes |
REME_ERROR_SUCCESS | On success |
REME_ERROR_UNSPECIFIED | On failure |
reme_error_t reme_context_set_log_callback | ( | reme_context_t | c, |
reme_log_callback_t | lc, | ||
void * | user_data = 0 |
||
) |
Set the logging callback.
The function pointer must stay valid until the context is destroyed or reme_context_set_log_callback is invoked with a different function pointer.
Invoke with a NULL function pointer to indicate that logging should be disabled.
c | A valid context object |
lc | Logging callback function pointer |
user_data | A pointer to optional user data to be passed to the callback function |
REME_ERROR_SUCCESS | On success |
REME_ERROR_UNSPECIFIED | On failure |
void reme_default_log_callback | ( | reme_log_severity_t | sev, |
const char * | message, | ||
void * | user_info | ||
) |
Default logging callback.
Default logging callback logs infos to STDOUT and everything else to STDERR.
sev | Logging severity |
message | Message to log |
user_info | additional user info. Unused. |
reme_error_t reme_context_bind_reconstruction_options | ( | reme_context_t | c, |
reme_options_t | o | ||
) |
Access the reconstruction options.
The reconstruction options define the behaviour of the reconstruction process. Note that some options can be set during run-time and others require re-compilation by invoking reme_context_compile. The protocol buffer specification documents when a re-compilation is necessary.
c | A valid context object |
o | A valid options binding |
REME_ERROR_SUCCESS | On success |
REME_ERROR_UNSPECIFIED | On failure |
reme_error_t reme_context_bind_opencl_info | ( | reme_context_t | c, |
reme_options_t | o | ||
) |
Access platform OpenCL information.
c | A valid context object |
o | A valid options binding |
REME_ERROR_SUCCESS | On success |
REME_ERROR_UNSPECIFIED | On failure |
reme_error_t reme_context_tune_reconstruction_options | ( | reme_context_t | c, |
reme_tune_profile_t | profile | ||
) |
Auto-tune reconstruction settings.
This function tries to tune the reconstruction settings with respect to a given quality profile (reme_tune_profile_t). It takes into account the specified device limitations and adjusts settings to for single volume scan.
The tuning algorithm reads the following reconstruction fields (see reme_context_bind_reconstruction_options)
device_id
volume.minimum_corner
and volume.maximum_corner
data_integration.use_colors
The tuning algorithm tunes the following reconstruction fields
volume.resolution
data_integration.truncation
depthmap_erosion.*
colormap_erosion.*
c | A valid context object |
profile | Profile to tune for |
REME_ERROR_SUCCESS | On success |
REME_ERROR_UNSPECIFIED | On failure |
reme_error_t reme_context_compile | ( | reme_context_t | c | ) |
Compile OpenCL related kernels.
Based on the compile time settings reme_context_get_compile_options, try to compile for the selected OpenCL compatible device.
In case of error check the last error through reme_context_get_last_error to receive the full build log.
Note that a successful compilation will force all objects that communicate with the computation device to re-initialize. Foremost these are the reme_sensor_t and reme_volume_t objects. Data of these objects will be reset to empty state.
c | A valid context object |
REME_ERROR_SUCCESS | On success |
REME_ERROR_UNSPECIFIED | On failure |
reme_error_t reme_context_bind_error_info | ( | reme_context_t | c, |
reme_options_t | o | ||
) |
Access current error state.
c | A valid context object |
o | A valid options binding |
REME_ERROR_SUCCESS | On success |
REME_ERROR_UNSPECIFIED | On failure |
reme_error_t reme_context_print_errors | ( | reme_context_t | c | ) |
Print all errors to standard error output and reset errors.
c | A valid context object |
REME_ERROR_SUCCESS | On success |
REME_ERROR_UNSPECIFIED | On failure |