Closed ZL-Su closed 1 year ago
Hi @ZL-Su,
According to the link error, the code is trying to use the hdf5::datatype::create<class cv::Mat >(class cv::Mat const &)
which doesn't exist in your code, at least not in the snippet. You've only implemented the TypeTrait for cv::Mat in hdf5::dataspace.
You may have a look at this example. https://github.com/ess-dmsc/h5cpp/blob/master/src/h5cpp/contrib/stl/vector.hpp
Hi@yuelongyu,
I have addressed this problem, thx.
I have tried to write and read data from an OpenCV container
cv::Mat
by "Using dataspaces with custom types". However it always reported the Link error of "unresolved external symbol" as:LNK2019 unresolved external symbol "public: static class hdf5::datatype::Datatype cdecl hdf5::datatype::TypeTrait<class cv::Mat >::create(class cv::Mat const &)" (?create@?$TypeTrait@V?$Mat@M@cv@@@datatype@hdf5@@SA?AVDatatype@23@AEBV?$Mat@M@cv@@@Z) referenced in function "class hdf5::datatype::Datatype cdecl hdf5::datatype::create<class cv::Mat >(class cv::Mat const &)" (??$create@V?$Mat@M@cv@@@datatype@hdf5@@YA?AVDatatype@01@AEBV?$Mat@M@cv@@@Z)
I am here looking for ur response. Thx a lot.
Here is the code snippet: