https://github.com/ho-cooh/osu-db-parser
https://github.com/ho-cooh/osu-db-parser
Last synced: about 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/ho-cooh/osu-db-parser
- Owner: HO-COOH
- Created: 2022-01-03T17:16:21.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2022-01-16T09:37:42.000Z (over 4 years ago)
- Last Synced: 2025-02-10T02:45:30.666Z (over 1 year ago)
- Language: C++
- Size: 5.86 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# osu-db-parser
A small C++17 header-only utility for parsing the binary osu `db` files.
## Usage
Just copy the `OsuDBParser.hpp` to your project.
This small utility include parsing all 3 osu! `db` files. All classes are under `namepsace Db`.
- `Db::Osu` -> `osu!.db`
- `Db::Collections` -> `collection.db`
- `Db::Scores` -> `scores.db`
All the above can be construct in 3 ways:
- Passing in a raw pointer (`unsigned char*`) to the buffer that has content of the files
- Passing in a smart pointer (`std::unique_ptr`) to the buffer that has the content of the files
- Passing in a `std::ifstream`, opened in binary mode
## Example
```cpp
Db::Osu db{ std::ifstream{ "osu!.db", std::ios_base::binary } };
std::cout << "Parsed "<< db.beatmaps.size() << " maps\n";
```