Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

Hi there.

 

I want to write a managed c++.net wrapper for the physics engine Tokamak. The problem is i had no experience in c++ except c#.

 

I want to write a wrapper for tokamak so that my c# samples can reference to that dll and implement together with Directx 9.

 

The problem is i don't know how to start?

 

Should i choose c++.net at the first place or i should go to unmanaged c++ to do all this.

 

Can you guys tell me what are the tutorials which i need to pick up along the way to achieve that?

 

I had the time and willing to learn. Just no idea how to start.

 

Thanks.

 

Regards,

Chua Wen Ching :p

  • 5 weeks later...
Posted

First Learn c++ I recomend reading one of those in 21 days books or similar to get you familliar with the syntax and oop in c++ and take some classes at a local college (There usualy pretty good and cheap). C# and C++ .Net are quite a bit different than C++ 6, The advantage is your code wil be reusable and most large projects are in C++ .Then you will see that there is no advantage (in this case) using C++ .Net. If you need more help getting started seek the help of a local guru, you probably know one and dont know it.

 

VSNT

BABCS

  • *Experts*
Posted

Have you considered other engine, such as ODE, to handle your physics? It may have the same compiling/language problems, but at least you get the source code...

 

I haven't worked with Tokamak so I can't say how it works. If it just exposes functions, you can probably work with C# by creating all the propery DllImport lines in your C# code.

 

Of course the easiest way to use that engine would be to use C++, but that means learning C++ which is generally a LOT more than just the language. This is different than C#, which you can learn relatively quickly. If you want to learn C++, I'd first go through a C++ book, NOT a Visual Studio C++ book. You'll really want to learn C++ before you learn C++ in .NET.

 

After you feel comfortable with C++ (maybe as soon as week or two, depending on how much time you have and how fast you learn), you can use a Visual Studio C++ or C++ .NET book to learn about C++ in .NET, or just read through some online tutorials and MSDN. The big issue is setting up include directories, library directories, excluding libraries, etc.

 

If Tokamak is made for standard C++ libraries, you might also run into issues using managed C++ if you're using .NET 2003. They moved a bunch of the standard libraries, such as iostream, to a new namespace and it means pretty much NO compatability with older C++ code. It's a pain.

 

If you get that far, ask lots of questions, maybe we can help :)

 

-Nerseus

"I want to stand as close to the edge as I can without going over. Out on the edge you see all the kinds of things you can't see from the center." - Kurt Vonnegut
Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...