GithubHelp home page GithubHelp logo

Comments (4)

ptitSeb avatar ptitSeb commented on June 21, 2024 1

It can, but not directly. Create a special wrapper for a lib is possible, as long as you now the API.
It's not straightforward for now, but if you have the libs in question and it's API to wrap, I can work on that, OpenSteamClient looks like an interesting project.

from box64.

Rosentti avatar Rosentti commented on June 21, 2024

Well that might be a problem. We don't know it's api 100%, and all the interop is done through C#. Are there docs for that feature anywhere?

from box64.

ptitSeb avatar ptitSeb commented on June 21, 2024

No, no doc.

Basicaly, the idea is to build box64 as a library that expose the needed API, and wrapped calls to execute the underlying x86_64 code.
If the API is C (and not C++), that can be done. If the API get enriched later by other function call, that's not an issue, but it would need code change and new build. I still need to create the mecanism, but never did it becasue I never had a concrete lib to wrap...

from box64.

Rosentti avatar Rosentti commented on June 21, 2024

So libbox64 (as a library, let's call it libbox64 for now), could expose, say:

  • dlopen
  • dlsym
  • dlclose

If it's possible, that'd effectively be enough for our use case.

The first function we call from the lib is called CreateInterface (via dlsym/dlopen), which returns a pointer to a C++ class with a specified name (as const char*).

The actual calling of the functions in the C++ class is done with some math to calculate each function's offset in the vtable, so no problem there with box64?

The second one is a callback system (also retrieved with dlsym), called rapidly every ~5ms. This returns a struct to some callback data. I presume this is also not an issue with box64, since the data comes from the lib.

I know one possible problem area though, the lib spawns other x64 (and in some cases x86) processes for some (optional) features, like shader management.

from box64.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.