diff options
author | dan miller | 2007-10-19 05:24:38 +0000 |
---|---|---|
committer | dan miller | 2007-10-19 05:24:38 +0000 |
commit | f205de7847da7ae1c10212d82e7042d0100b4ce0 (patch) | |
tree | 9acc9608a6880502aaeda43af52c33e278e95b9c /libraries/ode-0.9/contrib/Ode.NET/README.TXT | |
parent | trying to fix my screwup part deux (diff) | |
download | opensim-SC_OLD-f205de7847da7ae1c10212d82e7042d0100b4ce0.zip opensim-SC_OLD-f205de7847da7ae1c10212d82e7042d0100b4ce0.tar.gz opensim-SC_OLD-f205de7847da7ae1c10212d82e7042d0100b4ce0.tar.bz2 opensim-SC_OLD-f205de7847da7ae1c10212d82e7042d0100b4ce0.tar.xz |
from the start... checking in ode-0.9
Diffstat (limited to 'libraries/ode-0.9/contrib/Ode.NET/README.TXT')
-rw-r--r-- | libraries/ode-0.9/contrib/Ode.NET/README.TXT | 73 |
1 files changed, 73 insertions, 0 deletions
diff --git a/libraries/ode-0.9/contrib/Ode.NET/README.TXT b/libraries/ode-0.9/contrib/Ode.NET/README.TXT new file mode 100644 index 0000000..e6f1262 --- /dev/null +++ b/libraries/ode-0.9/contrib/Ode.NET/README.TXT | |||
@@ -0,0 +1,73 @@ | |||
1 | Ode.NET - .NET bindings for ODE | ||
2 | Jason Perkins (starkos@gmail.com) | ||
3 | |||
4 | THIS IS A WORK IN PROGRESS! I'm not done yet! | ||
5 | |||
6 | |||
7 | --------------------------------------------------------------------- | ||
8 | INSTALLATION | ||
9 | --------------------------------------------------------------------- | ||
10 | |||
11 | Note that this binding uses a C# 2.0 feature (the | ||
12 | UnmanagedFunctionPointer attribute). You will need to use | ||
13 | Visual Studio 2005 (C# Express is fine) or Mono's gmcs | ||
14 | compiler. | ||
15 | |||
16 | Start by getting or building ODE as a shared library (DLL). | ||
17 | |||
18 | The simplest way to build the bindings is probably to create a | ||
19 | new library assembly in your tool of choice and drop in the files | ||
20 | Ode/Ode.cs and Ode/AssemblyInfo.cs. Define the symbol`dDOUBLE` if | ||
21 | you used double-precision math in your ode.dll. Build, done. | ||
22 | |||
23 | For testing purposes, I have also created bindings for the | ||
24 | Drawstuff library and a C# version of the BoxStack demo. You can | ||
25 | throw all of these files into a console executable and run it to | ||
26 | see the demo. | ||
27 | |||
28 | If you happen to have Premake installed (http://premake.sf.net/), | ||
29 | you can generate build scripts for the library with: | ||
30 | |||
31 | premake --target (toolset) # for single precision | ||
32 | premake --with-doubles --target (toolset) # for double precision | ||
33 | |||
34 | To build the test application too, use: | ||
35 | |||
36 | premake --with-tests --target (toolset) | ||
37 | |||
38 | To build with Mono, you must add the --dotnet parameter to enable | ||
39 | support .NET 2.0: | ||
40 | |||
41 | premake --dotnet mono2 --target gnu | ||
42 | |||
43 | |||
44 | --------------------------------------------------------------------- | ||
45 | USAGE | ||
46 | --------------------------------------------------------------------- | ||
47 | |||
48 | I have tried to keep things as close to the original C API as I can, | ||
49 | rather than forcing a class structure on everyone. Everything is | ||
50 | contained within the `Ode.NET` namespace inside a static class | ||
51 | named `d`. All ODE IDs are replaced with IntPtrs. A quick example: | ||
52 | |||
53 | using Ode.NET; | ||
54 | |||
55 | IntPtr world = d.WorldCreate(); | ||
56 | IntPtr body = d.BodyCreate(world); | ||
57 | |||
58 | Take a look at Tests/BoxStack.cs for a more complete example. | ||
59 | |||
60 | |||
61 | --------------------------------------------------------------------- | ||
62 | KNOWN ISSUES | ||
63 | --------------------------------------------------------------------- | ||
64 | |||
65 | I'm not done yet, so many functions are still missing. | ||
66 | |||
67 | It is not possible to implement dBodyGetPosition(), dBodyGetRotation(), | ||
68 | etc. without resorting to unsafe code, which I was trying to avoid. | ||
69 | This binding uses the .NET friendly dBodyCopyPosition(), | ||
70 | dBodyCopyRotation(), etc. instead. | ||
71 | |||
72 | Collision response (contact joints) do not work when built under | ||
73 | Mono as double-precision. I have not tried to track down why. | ||