c++ - Boost Multiarray of std::vector -
i'm new boost (and stackoverflow) , want use multiarray of vectors. have done way: typedef boost::multi_array<std::vector<vector3_t>, 2> array_type; array_type* mimage; int mresolution = 1000; mimage = new array_type (boost::extents[mresolution][mresolution]); //works mimage[0][0].origin()->push_back(vector3_t()); //error: abort() mimage[1][1].origin()->push_back(vector3_t()); //error: abort() mimage[500][440].origin()->push_back(vector3_t()); on internet can find examples of multiarray use int,doule , on. possible use std::vector in mutliarray ? know use 3d multiarray, prefer vectors elemet. boost.multiarray supports std::vector elements. in general, boost.multiarray perform concept checking @ compile-time. thus, if code compiles complete type, should supported. with mimage[0][0].origin() : mimage[0][0] returns reference std::vector<vector3_t> . origin() not member function on std::vector<vector3_t> , resulting in erro...