namreeb / namigator

An intelligent navigation API for World of Warcraft Alpha, Vanilla, TBC and WotLK
MIT License
49 stars 32 forks source link

Create C++ command line program that can smoke test loading/line of sight/etc #66

Closed gtker closed 4 months ago

gtker commented 9 months ago

When reproducing errors it would be nice to have an upstream program that can be used to verify that the problem is within the library and not in the Python bindings/C API/my application code.

It could make sense to just include this as part of the MapBuilder executable.

I know the MapViewer executable can do this, but it doesn't run on Linux/Mac.

namreeb commented 4 months ago

I don't think I'm going to do this. The Python bindings should give all that's needed for a command-line sandbox. I don't think I've encountered a bug that is present in the Python bindings but not in the library itself. If someone wanted to get fancy, they could use a Jupyter notebook with the Python bindings.

gtker commented 4 months ago

It might be worth refactoring the Python API/C API/Main functions to have the same logic then, since right now there's some duplication. Don't remember all the places, but to build BVHs there's

Not sure how much can be done since Main and the others are pretty different, but it might be worth it to make the Python API a thin wrapper over the C API.

namreeb commented 4 months ago

From strictly an engineering perspective I would agree. Standardizing with something like FastAPI would be one way to do it, where the Python and C bindings as well as command-line interfaces are all just different auto-generated clients of the API.

Realistically, I just don't have time to do this.

I also think it's maybe premature in the sense that the library is not actually feature complete, and until it is the implementation of this would probably unstable.