init
This commit is contained in:
49
expkg/src/EXPKG/EXPKG.h
Normal file
49
expkg/src/EXPKG/EXPKG.h
Normal file
@ -0,0 +1,49 @@
|
||||
//
|
||||
// Created by sfd on 25-8-4.
|
||||
//
|
||||
|
||||
#ifndef EXPKG_H
|
||||
#define EXPKG_H
|
||||
#include <filesystem>
|
||||
#include <memory>
|
||||
|
||||
#include "BinaryOPT/BinaryReader.h"
|
||||
#include "Tex/Tex.h"
|
||||
|
||||
|
||||
typedef struct CommandArgs
|
||||
{
|
||||
int argc;
|
||||
char** argv;
|
||||
} CommandArgs;
|
||||
|
||||
namespace PKG
|
||||
{
|
||||
enum class FILE_EXTENSION;
|
||||
|
||||
class PKG_API EXPKG
|
||||
{
|
||||
public:
|
||||
EXPKG(const CommandArgs& commandArgs);
|
||||
EXPKG(const std::filesystem::path& filePath, const std::filesystem::path& outDir = "out");
|
||||
|
||||
|
||||
private:
|
||||
static FILE_EXTENSION checkExtension(const std::filesystem::path& filePath);
|
||||
|
||||
void ExtractTex(const std::filesystem::path& path = "");
|
||||
|
||||
void ExtractPkg();
|
||||
void Run();
|
||||
|
||||
private:
|
||||
std::shared_ptr<BinaryReader> m_Reader;
|
||||
std::shared_ptr<Tex> m_Tex;
|
||||
std::filesystem::path m_OutDir;
|
||||
|
||||
|
||||
std::vector<Entry> m_Entries;
|
||||
};
|
||||
}
|
||||
|
||||
#endif //EXPKG_H
|
||||
Reference in New Issue
Block a user