**THIS IS A HIGHLY WORK/DEVELOPMENT IN PROGRESS VERSION**
**THINGS ARE BROKEN AND EVERYTHING IS SUBJECT TO CHANGE**
First cut after massive refactoring with most critical and fundamental changes implemented.
We need to start somewhere, and this might be as good as anything else, so we can get started
with testing, bug fixing and iterating for the next releases.
The following list is non-exhaustive, does not guarantee anything does work, yet, and is supposed
to give a high level idea of what all of this is about. Updated documentation will reflect all of
this at some later point in time in more detail.
* A common "core" now abstracts logging, thread, property and configuration infrastructure and
provides a common interface. This is used by bemanitools internally as well as all tools, hooks
and APIs provided and don't depend on the game, version of the game or AVS version available
anymore
* New bemanitools (public) API
* Versioned API allowing for handling incremental API changes as well as breaking changes by
providing a new/different version when necessary
* Unified interfaces for bemanitools core API, i.e. logging, threads, configuration
* SDK with examples (TBD)
* Dogfooding approach: Bemanitools uses its own (public) API to implement and provide fundamental
features like configurable keyboard implementations for IO or hooks for different games and
versions
* All bemanitools hooks and IO libraries have been or are about to be re-worked to use the new APIs
* New hook API allows for more fine grained runtime control when stages of the hook are to be
executed, i.e. pre AVS, before main game, iat hooking instead of relying purely on DllMain
(which is still a compatible option though)
* launcher as a replacement for bootstrap: Bring it significantly closer to the original bootstrap
by supporting completely vanilla data and bootstrap.xml configurations to run the games. Note
that bemanitools does not include any code or means to run DRM'd data, only decrypted
* inject is also being reworked to use as much of the same "infrastructure" as launcher to provide
a more seamless bootstrapping process for games that keeps pre-eapki data as vanilla as possible
Summary:
Test Plan:
Summary:
Test Plan:
Summary:
Test Plan:
Summary:
Test Plan:
65 lines
1.6 KiB
C
65 lines
1.6 KiB
C
#ifndef ACIOEMU_PIPE_H
|
|
#define ACIOEMU_PIPE_H
|
|
|
|
#include <stddef.h>
|
|
#include <stdint.h>
|
|
#include <stdlib.h>
|
|
|
|
#include "acio/acio.h"
|
|
|
|
#include "iface-core/log.h"
|
|
|
|
#include "util/iobuf.h"
|
|
#include "util/list.h"
|
|
|
|
/* This uses the USB convention where OUT and IN are from the host's (game's)
|
|
perspective. So an OUT transaction comes in to us and vice versa.
|
|
|
|
(I made those terms up, not Konami). */
|
|
|
|
typedef void (*ac_io_in_thunk_t)(void *ctx, struct ac_io_message *msg);
|
|
|
|
struct ac_io_in_queued {
|
|
struct list_node node;
|
|
struct const_iobuf iobuf;
|
|
uint64_t scheduled_time;
|
|
uint64_t delay_us;
|
|
ac_io_in_thunk_t thunk;
|
|
void *thunk_ctx;
|
|
uint8_t bytes[sizeof(struct ac_io_message)];
|
|
};
|
|
|
|
struct ac_io_in {
|
|
struct list queue;
|
|
};
|
|
|
|
struct ac_io_out {
|
|
union {
|
|
uint8_t bytes[sizeof(struct ac_io_message)];
|
|
struct ac_io_message msg;
|
|
};
|
|
|
|
size_t pos;
|
|
bool in_frame;
|
|
bool escape;
|
|
bool have_message;
|
|
};
|
|
|
|
void ac_io_legacy_mode(void);
|
|
|
|
void ac_io_in_init(struct ac_io_in *in);
|
|
void ac_io_in_supply(
|
|
struct ac_io_in *in, const struct ac_io_message *msg, uint64_t delay);
|
|
void ac_io_in_supply_thunk(
|
|
struct ac_io_in *in, ac_io_in_thunk_t thunk, void *ctx, uint64_t delay);
|
|
void ac_io_in_drain(struct ac_io_in *in, struct iobuf *dest);
|
|
bool ac_io_in_is_msg_pending(const struct ac_io_in *in);
|
|
|
|
void ac_io_out_init(struct ac_io_out *out);
|
|
void ac_io_out_supply(struct ac_io_out *out, struct const_iobuf *src);
|
|
bool ac_io_out_have_message(const struct ac_io_out *out);
|
|
const struct ac_io_message *ac_io_out_get_message(const struct ac_io_out *out);
|
|
void ac_io_out_consume_message(struct ac_io_out *out);
|
|
|
|
#endif
|