MCPcopy Create free account
hub / github.com/davisking/dlib / free_callback_resources

Function free_callback_resources

dlib/matlab/mex_wrapper.cpp:3256–3274  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3254
3255 template <typename T1>
3256 void free_callback_resources (
3257 int nlhs,
3258 mxArray* plhs[],
3259 int nrhs,
3260 mxArray* prhs[]
3261 )
3262 {
3263 // free resources
3264 for (int i = 0; i < nlhs; ++i)
3265 mxDestroyArray(plhs[i]);
3266
3267 for (int i = 0; i < nrhs; ++i)
3268 {
3269 // don't call mxDestroyArray() on function handles (which should only ever be in prhs[0])
3270 if (i == 0 && dlib::is_same_type<T1,function_handle>::value)
3271 continue;
3272 mxDestroyArray(prhs[i]);
3273 }
3274 }
3275
3276 template <
3277 typename T1

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected