I’m using P/invoke to interoperate between C# and C++ in this project. I’d like to pass data structures that are symmetrically defined. What’s the best infrastructure to use? Could protocol buffers be useful here?
Share
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.
I would suggest to use C++/CLI since you can use the same header files / definition files in both worlds. One of the main goals for developing C++ CLI was to fill the gap between the managed and the unamanaged world. This article gives you even more advantages.
In the MSDN there is a nice description how C++cli works and how you can use it.
see also here