There is a function which takes a float** parameter.
I have the values in a variable of type std::vector<std::vector<float>>.
Is it possible to make such a conversion without allocating a temporary float*[] ?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Not directly, but you don’t have to copy the data from the “inner” vectors. Instead, you can create an array of pointers to the
data()attributes of each inner vector.