move bps patch to core/common

This commit is contained in:
scawful
2024-08-06 02:06:07 -04:00
parent 0d1fda488e
commit 3a57264b67
5 changed files with 226 additions and 251 deletions

View File

@@ -1,8 +1,6 @@
#ifndef YAZE_CORE_COMMON_H
#define YAZE_CORE_COMMON_H
#include "imgui/imgui.h"
#include <chrono>
#include <cstdint>
#include <fstream>
@@ -12,6 +10,8 @@
#include <stack>
#include <string>
#include "imgui/imgui.h"
namespace yaze {
namespace app {
@@ -227,6 +227,16 @@ typedef struct FolderItem FolderItem;
uint32_t Get24LocalFromPC(uint8_t *data, int addr, bool pc = true);
uint32_t crc32(const std::vector<uint8_t> &data);
void CreateBpsPatch(const std::vector<uint8_t> &source,
const std::vector<uint8_t> &target,
std::vector<uint8_t> &patch);
void ApplyBpsPatch(const std::vector<uint8_t> &source,
const std::vector<uint8_t> &patch,
std::vector<uint8_t> &target);
} // namespace core
} // namespace app
} // namespace yaze