Messy #include <Box2D*> etc.

Hello,


I'm using many libs but the Box2d one was always a bit tricky to install, because it is the only one that requires me to configure Visual Studio to have Box2d as an include folder.

This is because all the source files want to include using a search:
#include <Box2D/Collision/Shapes/b2Shape.h>

Instead of simply using relative paths:
#include "b2Shape.h"

And this creates problems when a project includes the header files.

I know this is a low priority issue, but after a few years of annoyance I thought I'd finally post it.


Thanks again for all the great work!! Love your engine!
Visual Studio has "Additional Include Directories" on a project-level. Go into the project settings, you'll see it in C/C++ < General. It also has Additional Library Directories somewhere under Linker.

You should never modify the global include directories in the VS settings for project-level changes, as they can cause collisions.

-P
Alright I see that I must simply wrap the entire Box2d engine then, so the user projects don't have to include the files and require that option that you've just mentioned.
Wrapping or not wrapping the engine has nothing to do with the structure of the include paths.

The structure of the include paths was made at the request of many users. It lets you install Box2D inside standard include paths.

Original thread: https://box2d.org/forum/viewtopic.php?t=6094