Hey baby girl
This commit is contained in:
parent
cfa0638b94
commit
be8aa3691e
4
.vscode/settings.json
vendored
Normal file
4
.vscode/settings.json
vendored
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
{
|
||||||
|
"workbench.colorTheme": "Default Dark Modern",
|
||||||
|
"workbench.startupEditor": "none"
|
||||||
|
}
|
||||||
63
app/app.pro
63
app/app.pro
@ -6,66 +6,9 @@ SUBDIRS += app
|
|||||||
|
|
||||||
CONFIG += c++17
|
CONFIG += c++17
|
||||||
|
|
||||||
SOURCES += \
|
SOURCES += $$files($$PWD/*.cpp)
|
||||||
aboutdialog.cpp \
|
HEADERS += $$files($$PWD/*.h)
|
||||||
ddsviewer.cpp \
|
FORMS += $$files($$PWD/*.ui)
|
||||||
fastfileviewer.cpp \
|
|
||||||
imagewidget.cpp \
|
|
||||||
iwiviewer.cpp \
|
|
||||||
localstringviewer.cpp \
|
|
||||||
main.cpp \
|
|
||||||
mainwindow.cpp \
|
|
||||||
materialviewer.cpp \
|
|
||||||
preferenceeditor.cpp \
|
|
||||||
reportissuedialog.cpp \
|
|
||||||
soundviewer.cpp \
|
|
||||||
stringtableviewer.cpp \
|
|
||||||
rumblegraphviewer.cpp \
|
|
||||||
rumblefileviewer.cpp \
|
|
||||||
techsetviewer.cpp \
|
|
||||||
xtreewidget.cpp \
|
|
||||||
xtreewidgetitem.cpp \
|
|
||||||
zonefileviewer.cpp
|
|
||||||
|
|
||||||
HEADERS += \
|
|
||||||
aboutdialog.h \
|
|
||||||
d3dbsp_structs.h \
|
|
||||||
ddsviewer.h \
|
|
||||||
fastfileviewer.h \
|
|
||||||
imagewidget.h \
|
|
||||||
iwiviewer.h \
|
|
||||||
localstringviewer.h \
|
|
||||||
mainwindow.h \
|
|
||||||
materialviewer.h \
|
|
||||||
preferenceeditor.h \
|
|
||||||
reportissuedialog.h \
|
|
||||||
soundviewer.h \
|
|
||||||
stringtableviewer.h \
|
|
||||||
rumblegraphviewer.h \
|
|
||||||
rumblefileviewer.h \
|
|
||||||
techsetviewer.h \
|
|
||||||
xtreewidget.h \
|
|
||||||
xtreewidgetitem.h \
|
|
||||||
zonefileviewer.h
|
|
||||||
|
|
||||||
FORMS += \
|
|
||||||
aboutdialog.ui \
|
|
||||||
ddsviewer.ui \
|
|
||||||
fastfileviewer.ui \
|
|
||||||
imagewidget.ui \
|
|
||||||
iwiviewer.ui \
|
|
||||||
localstringviewer.ui \
|
|
||||||
mainwindow.ui \
|
|
||||||
materialviewer.ui \
|
|
||||||
modelviewer.ui \
|
|
||||||
preferenceeditor.ui \
|
|
||||||
soundviewer.ui \
|
|
||||||
stringtableviewer.ui \
|
|
||||||
rumblegraphviewer.ui \
|
|
||||||
rumblefileviewer.ui \
|
|
||||||
techsetviewer.ui \
|
|
||||||
zonefileviewer.ui \
|
|
||||||
reportissuedialog.ui
|
|
||||||
|
|
||||||
RESOURCES += ../data/data.qrc
|
RESOURCES += ../data/data.qrc
|
||||||
|
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
#ifndef RUMBLEFILEVIEWER_H
|
#ifndef RUMBLEFILEVIEWER_H
|
||||||
#define RUMBLEFILEVIEWER_H
|
#define RUMBLEFILEVIEWER_H
|
||||||
|
|
||||||
#include "rawfile.h"
|
#include "xrawfile.h"
|
||||||
|
|
||||||
#include <QWidget>
|
#include <QWidget>
|
||||||
|
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
#ifndef STRINGTABLEVIEWER_H
|
#ifndef STRINGTABLEVIEWER_H
|
||||||
#define STRINGTABLEVIEWER_H
|
#define STRINGTABLEVIEWER_H
|
||||||
|
|
||||||
#include "stringtable.h"
|
#include "xstringtable.h"
|
||||||
|
|
||||||
#include <QWidget>
|
#include <QWidget>
|
||||||
|
|
||||||
|
|||||||
@ -7,9 +7,9 @@
|
|||||||
#include "fastfile.h"
|
#include "fastfile.h"
|
||||||
#include "xtreewidgetitem.h"
|
#include "xtreewidgetitem.h"
|
||||||
#include "zonefile.h"
|
#include "zonefile.h"
|
||||||
#include "rawfile.h"
|
#include "xrawfile.h"
|
||||||
#include "gfximage.h"
|
#include "gfximage.h"
|
||||||
#include "stringtable.h"
|
#include "xstringtable.h"
|
||||||
#include "menudef.h"
|
#include "menudef.h"
|
||||||
|
|
||||||
#include <QTreeWidget>
|
#include <QTreeWidget>
|
||||||
|
|||||||
@ -1 +0,0 @@
|
|||||||
#include "asset.h"
|
|
||||||
@ -1,112 +0,0 @@
|
|||||||
#ifndef ASSET_H
|
|
||||||
#define ASSET_H
|
|
||||||
|
|
||||||
#include "animparts.h"
|
|
||||||
#include "model.h"
|
|
||||||
#include "material.h"
|
|
||||||
#include "materialpixelshader.h"
|
|
||||||
#include "materialtechset.h"
|
|
||||||
#include "gfximage.h"
|
|
||||||
#include "soundalias.h"
|
|
||||||
#include "soundcurve.h"
|
|
||||||
#include "loadedsound.h"
|
|
||||||
#include "clipmap.h"
|
|
||||||
#include "comworld.h"
|
|
||||||
#include "gameworld.h"
|
|
||||||
#include "mapent.h"
|
|
||||||
#include "gfxworld.h"
|
|
||||||
#include "gfxlightdef.h"
|
|
||||||
#include "gfximage.h"
|
|
||||||
#include "font.h"
|
|
||||||
#include "menulist.h"
|
|
||||||
#include "menudef.h"
|
|
||||||
#include "localizeentry.h"
|
|
||||||
#include "weapondef.h"
|
|
||||||
#include "sounddriver.h"
|
|
||||||
#include "effectdef.h"
|
|
||||||
#include "effecttable.h"
|
|
||||||
#include "rawfile.h"
|
|
||||||
#include "stringtable.h"
|
|
||||||
|
|
||||||
enum XAssetType : qint32
|
|
||||||
{
|
|
||||||
ASSET_TYPE_XMODELPIECES = 0x0,
|
|
||||||
ASSET_TYPE_PHYSPRESET = 0x1,
|
|
||||||
ASSET_TYPE_XANIMPARTS = 0x2,
|
|
||||||
ASSET_TYPE_XMODEL = 0x3,
|
|
||||||
ASSET_TYPE_MATERIAL = 0x4,
|
|
||||||
ASSET_TYPE_PIXELSHADER = 0x5,
|
|
||||||
ASSET_TYPE_TECHNIQUE_SET = 0x6,
|
|
||||||
ASSET_TYPE_IMAGE = 0x7,
|
|
||||||
ASSET_TYPE_SOUND = 0x8,
|
|
||||||
ASSET_TYPE_SOUND_CURVE = 0x9,
|
|
||||||
ASSET_TYPE_LOADED_SOUND = 0xA,
|
|
||||||
ASSET_TYPE_CLIPMAP = 0xB,
|
|
||||||
ASSET_TYPE_CLIPMAP_PVS = 0xC,
|
|
||||||
ASSET_TYPE_COMWORLD = 0xD,
|
|
||||||
ASSET_TYPE_GAMEWORLD_SP = 0xE,
|
|
||||||
ASSET_TYPE_GAMEWORLD_MP = 0xF,
|
|
||||||
ASSET_TYPE_MAP_ENTS = 0x10,
|
|
||||||
ASSET_TYPE_GFXWORLD = 0x11,
|
|
||||||
ASSET_TYPE_LIGHT_DEF = 0x12,
|
|
||||||
ASSET_TYPE_UI_MAP = 0x13,
|
|
||||||
ASSET_TYPE_FONT = 0x14,
|
|
||||||
ASSET_TYPE_MENULIST = 0x15,
|
|
||||||
ASSET_TYPE_MENU = 0x16,
|
|
||||||
ASSET_TYPE_LOCALIZE_ENTRY = 0x17,
|
|
||||||
ASSET_TYPE_WEAPON = 0x18,
|
|
||||||
ASSET_TYPE_SNDDRIVER_GLOBALS = 0x19,
|
|
||||||
ASSET_TYPE_FX = 0x1A,
|
|
||||||
ASSET_TYPE_IMPACT_FX = 0x1B,
|
|
||||||
ASSET_TYPE_AITYPE = 0x1C,
|
|
||||||
ASSET_TYPE_MPTYPE = 0x1D,
|
|
||||||
ASSET_TYPE_CHARACTER = 0x1E,
|
|
||||||
ASSET_TYPE_XMODELALIAS = 0x1F,
|
|
||||||
ASSET_TYPE_RAWFILE = 0x20,
|
|
||||||
ASSET_TYPE_STRINGTABLE = 0x21,
|
|
||||||
ASSET_TYPE_COUNT = 0x22,
|
|
||||||
ASSET_TYPE_STRING = 0x22,
|
|
||||||
ASSET_TYPE_ASSETLIST = 0x23,
|
|
||||||
};
|
|
||||||
|
|
||||||
union XAssetHeader
|
|
||||||
{
|
|
||||||
XModelPieces *xmodelPieces;
|
|
||||||
PhysPreset *physPreset;
|
|
||||||
XAnimParts *parts;
|
|
||||||
Model *model;
|
|
||||||
Material *material;
|
|
||||||
MaterialPixelShader *pixelShader;
|
|
||||||
MaterialVertexShader *vertexShader;
|
|
||||||
MaterialTechSet *techniqueSet;
|
|
||||||
GfxImage *image;
|
|
||||||
SoundAliasList *sound;
|
|
||||||
SoundCurve *sndCurve;
|
|
||||||
LoadedSound *loadSnd;
|
|
||||||
ClipMap *clipMap;
|
|
||||||
ComWorld *comWorld;
|
|
||||||
GameWorldSp *gameWorldSp;
|
|
||||||
GameWorldMp *gameWorldMp;
|
|
||||||
MapEnts *mapEnts;
|
|
||||||
GfxWorld *gfxWorld;
|
|
||||||
GfxLightDef *lightDef;
|
|
||||||
GameFont *font;
|
|
||||||
MenuList *menuList;
|
|
||||||
MenuDef *menu;
|
|
||||||
LocalizeEntry *localize;
|
|
||||||
WeaponDef *weapon;
|
|
||||||
SoundDriver *sndDriverGlobals;
|
|
||||||
const EffectDef *fx;
|
|
||||||
ImpactTable *impactFx;
|
|
||||||
RawFile *rawfile;
|
|
||||||
StringTable *stringTable;
|
|
||||||
void *data;
|
|
||||||
};
|
|
||||||
|
|
||||||
struct XAsset
|
|
||||||
{
|
|
||||||
XAssetType type;
|
|
||||||
XAssetHeader header;
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif // ASSET_H
|
|
||||||
@ -1,7 +1,7 @@
|
|||||||
#ifndef ASSETLIST_H
|
#ifndef ASSETLIST_H
|
||||||
#define ASSETLIST_H
|
#define ASSETLIST_H
|
||||||
|
|
||||||
#include "asset.h"
|
#include "xasset.h"
|
||||||
#include "scriptstringlist.h"
|
#include "scriptstringlist.h"
|
||||||
|
|
||||||
struct XAssetList
|
struct XAssetList
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
#define ASSETMAP_H
|
#define ASSETMAP_H
|
||||||
|
|
||||||
#include "animparts.h"
|
#include "animparts.h"
|
||||||
#include "model.h"
|
#include "xmodel.h"
|
||||||
#include "material.h"
|
#include "material.h"
|
||||||
#include "materialpixelshader.h"
|
#include "materialpixelshader.h"
|
||||||
#include "materialtechset.h"
|
#include "materialtechset.h"
|
||||||
@ -20,13 +20,13 @@
|
|||||||
#include "font.h"
|
#include "font.h"
|
||||||
#include "menulist.h"
|
#include "menulist.h"
|
||||||
#include "menudef.h"
|
#include "menudef.h"
|
||||||
#include "localizeentry.h"
|
#include "xlocalizeentry.h"
|
||||||
#include "weapondef.h"
|
#include "weapondef.h"
|
||||||
#include "sounddriver.h"
|
#include "xsounddriverglobals.h"
|
||||||
#include "effectdef.h"
|
#include "effectdef.h"
|
||||||
#include "effecttable.h"
|
#include "effecttable.h"
|
||||||
#include "rawfile.h"
|
#include "xrawfile.h"
|
||||||
#include "stringtable.h"
|
#include "xstringtable.h"
|
||||||
|
|
||||||
struct AssetMap {
|
struct AssetMap {
|
||||||
QVector<Animation> animations;
|
QVector<Animation> animations;
|
||||||
|
|||||||
@ -1065,14 +1065,14 @@ GfxVertexBuffer Assets::Load_GfxVertexBuffer(QDataStream *aStream)
|
|||||||
GfxVertexBuffer result;
|
GfxVertexBuffer result;
|
||||||
|
|
||||||
*aStream
|
*aStream
|
||||||
>> result.Format.__s0.Type
|
>> result.Format.request.Type
|
||||||
>> result.Format.__s0.BaseAddress
|
>> result.Format.request.BaseAddress
|
||||||
>> result.Format.__s0.Endian
|
>> result.Format.request.Endian
|
||||||
>> result.Format.__s0.Size
|
>> result.Format.request.Size
|
||||||
>> result.Format.__s0.AddressClamp
|
>> result.Format.request.AddressClamp
|
||||||
>> result.Format.__s0.
|
>> result.Format.request.
|
||||||
>> result.Format.__s0.RequestSize
|
>> result.Format.request.RequestSize
|
||||||
>> result.Format.__s0.ClampDisable
|
>> result.Format.request.ClampDisable
|
||||||
>> result.Format.dword[0]
|
>> result.Format.dword[0]
|
||||||
>> result.Format.dword[1]
|
>> result.Format.dword[1]
|
||||||
>> result.Common
|
>> result.Common
|
||||||
@ -1110,11 +1110,6 @@ QVector<XSurfaceCollisionNode> Assets::Load_XSurfaceCollisionNodeArray(QDataStre
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
struct XSurfaceCollisionLeaf
|
|
||||||
{
|
|
||||||
unsigned __int16 triangleBeginIndex;
|
|
||||||
};
|
|
||||||
|
|
||||||
// ?Load_XSurfaceCollisionLeafArray@@YAX_NH@Z at 0x822a4fb8
|
// ?Load_XSurfaceCollisionLeafArray@@YAX_NH@Z at 0x822a4fb8
|
||||||
QVector<XSurfaceCollisionLeaf> Assets::Load_XSurfaceCollisionLeafArray(QDataStream *aStream, int count)
|
QVector<XSurfaceCollisionLeaf> Assets::Load_XSurfaceCollisionLeafArray(QDataStream *aStream, int count)
|
||||||
{
|
{
|
||||||
@ -1258,12 +1253,12 @@ StreamFileNamePacked Assets::Load_StreamFileNamePacked(QDataStream *aStream)
|
|||||||
|
|
||||||
|
|
||||||
// ?Load_XaReverbSettingsArray@@YAX_NH@Z at 0x822a5048
|
// ?Load_XaReverbSettingsArray@@YAX_NH@Z at 0x822a5048
|
||||||
QVector<XaReverbSettings> Assets::Load_XaReverbSettingsArray(QDataStream *aStream, int count)
|
QVector<XAudioReverbSettings> Assets::Load_XaReverbSettingsArray(QDataStream *aStream, int count)
|
||||||
{
|
{
|
||||||
QVector<XaReverbSettings> result;
|
QVector<XAudioReverbSettings> result;
|
||||||
|
|
||||||
for (int i = 0; i < count; i++) {
|
for (int i = 0; i < count; i++) {
|
||||||
XaReverbSettings xaReverbSettings;
|
XAudioReverbSettings xaReverbSettings;
|
||||||
|
|
||||||
*aStream
|
*aStream
|
||||||
>> xaReverbSettings.presetOverridden
|
>> xaReverbSettings.presetOverridden
|
||||||
@ -2497,9 +2492,9 @@ RawFile Assets::Load_RawFile(QDataStream *aStream)
|
|||||||
|
|
||||||
|
|
||||||
// ?Load_LocalizeEntry@@YAX_N@Z at 0x822a5ef0
|
// ?Load_LocalizeEntry@@YAX_N@Z at 0x822a5ef0
|
||||||
LocalizeEntry Assets::Load_LocalizeEntry(QDataStream *aStream)
|
XLocalizeEntry Assets::Load_LocalizeEntry(QDataStream *aStream)
|
||||||
{
|
{
|
||||||
LocalizeEntry result;
|
XLocalizeEntry result;
|
||||||
|
|
||||||
*aStream
|
*aStream
|
||||||
>> result.valuePtr
|
>> result.valuePtr
|
||||||
@ -3240,9 +3235,9 @@ StreamFileNameRaw Assets::Load_StreamFileNameRaw(QDataStream *aStream)
|
|||||||
|
|
||||||
|
|
||||||
// ?Load_SndDriverGlobals@@YAX_N@Z at 0x822a6f48
|
// ?Load_SndDriverGlobals@@YAX_N@Z at 0x822a6f48
|
||||||
SndDriverGlobals Assets::Load_SndDriverGlobals(QDataStream *aStream)
|
XSoundDriverGlobals Assets::Load_SndDriverGlobals(QDataStream *aStream)
|
||||||
{
|
{
|
||||||
SndDriverGlobals result;
|
XSoundDriverGlobals result;
|
||||||
|
|
||||||
*aStream
|
*aStream
|
||||||
>> result.reverbSettingsPtr
|
>> result.reverbSettingsPtr
|
||||||
@ -3250,7 +3245,7 @@ SndDriverGlobals Assets::Load_SndDriverGlobals(QDataStream *aStream)
|
|||||||
|
|
||||||
if (result.reverbSettingsPtr)
|
if (result.reverbSettingsPtr)
|
||||||
{
|
{
|
||||||
XaReverbSettings xaReverbSettings;
|
XAudioReverbSettings xaReverbSettings;
|
||||||
|
|
||||||
*aStream
|
*aStream
|
||||||
>> xaReverbSettings.presetOverridden
|
>> xaReverbSettings.presetOverridden
|
||||||
@ -3555,9 +3550,9 @@ RawFile Assets::Load_RawFilePtr(QDataStream *aStream)
|
|||||||
|
|
||||||
|
|
||||||
// ?Load_LocalizeEntryPtr@@YAX_N@Z at 0x822a77d0
|
// ?Load_LocalizeEntryPtr@@YAX_N@Z at 0x822a77d0
|
||||||
LocalizeEntry Assets::Load_LocalizeEntryPtr(QDataStream *aStream)
|
XLocalizeEntry Assets::Load_LocalizeEntryPtr(QDataStream *aStream)
|
||||||
{
|
{
|
||||||
LocalizeEntry result;
|
XLocalizeEntry result;
|
||||||
qint32 localizeEntryPtr;
|
qint32 localizeEntryPtr;
|
||||||
|
|
||||||
*aStream >> localizeEntryPtr;
|
*aStream >> localizeEntryPtr;
|
||||||
@ -4203,7 +4198,7 @@ void Assets::Load_StreamFileInfo(QDataStream *aStream)
|
|||||||
// ?Load_SndDriverGlobalsPtr@@YAX_N@Z at 0x822a8640
|
// ?Load_SndDriverGlobalsPtr@@YAX_N@Z at 0x822a8640
|
||||||
void Assets::Load_SndDriverGlobalsPtr(QDataStream *aStream)
|
void Assets::Load_SndDriverGlobalsPtr(QDataStream *aStream)
|
||||||
{
|
{
|
||||||
SndDriverGlobals result;
|
XSoundDriverGlobals result;
|
||||||
qint32 sndDriverGlobalsPtr;
|
qint32 sndDriverGlobalsPtr;
|
||||||
|
|
||||||
*aStream >> sndDriverGlobalsPtr;
|
*aStream >> sndDriverGlobalsPtr;
|
||||||
@ -9350,7 +9345,7 @@ clipMap_t Assets::Load_clipMap_t(QDataStream *aStream)
|
|||||||
if (result.planesPtr == -1)
|
if (result.planesPtr == -1)
|
||||||
{
|
{
|
||||||
for (int i = 0; i < result.planeCount; i++) {
|
for (int i = 0; i < result.planeCount; i++) {
|
||||||
result.planes << Asset::Load_cplane_s(aStream);
|
result.planes << XAsset::Load_cplane_s(aStream);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
#ifndef ASSETS_H
|
#ifndef ASSETS_H
|
||||||
#define ASSETS_H
|
#define ASSETS_H
|
||||||
|
|
||||||
#include "model.h"
|
#include "xmodel.h"
|
||||||
#include <QDebug>
|
#include <QDebug>
|
||||||
#include <QObject>
|
#include <QObject>
|
||||||
|
|
||||||
@ -2089,7 +2089,7 @@ struct MenuList
|
|||||||
QVector<menuDef_t> menus;
|
QVector<menuDef_t> menus;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct LocalizeEntry
|
struct XLocalizeEntry
|
||||||
{
|
{
|
||||||
qint32 valuePtr;
|
qint32 valuePtr;
|
||||||
QString value;
|
QString value;
|
||||||
@ -2817,7 +2817,7 @@ struct WeaponDef
|
|||||||
float adsDofEnd;
|
float adsDofEnd;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct XAUDIOREVERBSETTINGS
|
struct XReverbSettings
|
||||||
{
|
{
|
||||||
uint ReflectionsDelay;
|
uint ReflectionsDelay;
|
||||||
quint8 ReverbDelay;
|
quint8 ReverbDelay;
|
||||||
@ -2842,16 +2842,16 @@ struct XAUDIOREVERBSETTINGS
|
|||||||
float RoomSize;
|
float RoomSize;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct XaReverbSettings
|
struct XAudioReverbSettings
|
||||||
{
|
{
|
||||||
int presetOverridden;
|
int presetOverridden;
|
||||||
XAUDIOREVERBSETTINGS reverbSettings;
|
XReverbSettings reverbSettings;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct SndDriverGlobals
|
struct XSoundDriverGlobals
|
||||||
{
|
{
|
||||||
qint32 reverbSettingsPtr;
|
qint32 reverbSettingsPtr;
|
||||||
XaReverbSettings reverbSettings;
|
XAudioReverbSettings reverbSettings;
|
||||||
qint32 namePtr;
|
qint32 namePtr;
|
||||||
QString name;
|
QString name;
|
||||||
};
|
};
|
||||||
@ -2915,9 +2915,9 @@ union XAssetHeader
|
|||||||
Font_s *font;
|
Font_s *font;
|
||||||
MenuList *menuList;
|
MenuList *menuList;
|
||||||
menuDef_t *menu;
|
menuDef_t *menu;
|
||||||
LocalizeEntry *localize;
|
XLocalizeEntry *localize;
|
||||||
WeaponDef *weapon;
|
WeaponDef *weapon;
|
||||||
SndDriverGlobals *sndDriverGlobals;
|
XSoundDriverGlobals *sndDriverGlobals;
|
||||||
const FxEffectDef *fx;
|
const FxEffectDef *fx;
|
||||||
FxImpactTable *impactFx;
|
FxImpactTable *impactFx;
|
||||||
RawFile *rawfile;
|
RawFile *rawfile;
|
||||||
@ -3000,7 +3000,7 @@ private:
|
|||||||
void Load_GfxWorldVertex0Array(QDataStream *aStream, int count);
|
void Load_GfxWorldVertex0Array(QDataStream *aStream, int count);
|
||||||
QVector<XAUDIOCHANNELMAPENTRY> Load_XAUDIOCHANNELMAPENTRYArray(QDataStream *aStream, int count);
|
QVector<XAUDIOCHANNELMAPENTRY> Load_XAUDIOCHANNELMAPENTRYArray(QDataStream *aStream, int count);
|
||||||
StreamFileNamePacked Load_StreamFileNamePacked(QDataStream *aStream);
|
StreamFileNamePacked Load_StreamFileNamePacked(QDataStream *aStream);
|
||||||
QVector<XaReverbSettings> Load_XaReverbSettingsArray(QDataStream *aStream, int count);
|
QVector<XAudioReverbSettings> Load_XaReverbSettingsArray(QDataStream *aStream, int count);
|
||||||
QVector<char> Load_char2048Array(QDataStream *aStream, size_t count);
|
QVector<char> Load_char2048Array(QDataStream *aStream, size_t count);
|
||||||
QVector<DObjAnimMat> Load_DObjAnimMatArray(QDataStream *aStream, int count);
|
QVector<DObjAnimMat> Load_DObjAnimMatArray(QDataStream *aStream, int count);
|
||||||
QVector<XBoneInfo> Load_XBoneInfoArray(QDataStream *aStream, int count);
|
QVector<XBoneInfo> Load_XBoneInfoArray(QDataStream *aStream, int count);
|
||||||
@ -3049,7 +3049,7 @@ private:
|
|||||||
QString Load_XStringCustom(QDataStream *aStream);
|
QString Load_XStringCustom(QDataStream *aStream);
|
||||||
QString Load_XString(QDataStream *aStream);
|
QString Load_XString(QDataStream *aStream);
|
||||||
RawFile Load_RawFile(QDataStream *aStream);
|
RawFile Load_RawFile(QDataStream *aStream);
|
||||||
LocalizeEntry Load_LocalizeEntry(QDataStream *aStream);
|
XLocalizeEntry Load_LocalizeEntry(QDataStream *aStream);
|
||||||
void Load_operandInternalDataUnion(QDataStream *aStream);
|
void Load_operandInternalDataUnion(QDataStream *aStream);
|
||||||
ComPrimaryLight Load_ComPrimaryLight(QDataStream *aStream);
|
ComPrimaryLight Load_ComPrimaryLight(QDataStream *aStream);
|
||||||
CollisionPartition Load_CollisionPartition(QDataStream *aStream);
|
CollisionPartition Load_CollisionPartition(QDataStream *aStream);
|
||||||
@ -3075,7 +3075,7 @@ private:
|
|||||||
XAUDIOCHANNELMAP Load_XAUDIOCHANNELMAP(QDataStream *aStream);
|
XAUDIOCHANNELMAP Load_XAUDIOCHANNELMAP(QDataStream *aStream);
|
||||||
SndCurve Load_SndCurve(QDataStream *aStream);
|
SndCurve Load_SndCurve(QDataStream *aStream);
|
||||||
StreamFileNameRaw Load_StreamFileNameRaw(QDataStream *aStream);
|
StreamFileNameRaw Load_StreamFileNameRaw(QDataStream *aStream);
|
||||||
SndDriverGlobals Load_SndDriverGlobals(QDataStream *aStream);
|
XSoundDriverGlobals Load_SndDriverGlobals(QDataStream *aStream);
|
||||||
XaSeekTable Load_XaSeekTable(QDataStream *aStream);
|
XaSeekTable Load_XaSeekTable(QDataStream *aStream);
|
||||||
XAUDIOPACKET_ALIGNED Load_XAUDIOPACKET_ALIGNED(QDataStream *aStream);
|
XAUDIOPACKET_ALIGNED Load_XAUDIOPACKET_ALIGNED(QDataStream *aStream);
|
||||||
XAnimNotifyInfo Load_XAnimNotifyInfo(QDataStream *aStream);
|
XAnimNotifyInfo Load_XAnimNotifyInfo(QDataStream *aStream);
|
||||||
|
|||||||
@ -2,150 +2,8 @@ QT += core widgets
|
|||||||
TEMPLATE = lib
|
TEMPLATE = lib
|
||||||
CONFIG += staticlib c++17
|
CONFIG += staticlib c++17
|
||||||
|
|
||||||
SOURCES += \
|
SOURCES += $$files($$PWD/*.cpp, true)
|
||||||
# Base class
|
HEADERS += $$files($$PWD/*.h, true)
|
||||||
assets.cpp \
|
|
||||||
animparts.cpp \
|
|
||||||
asset.cpp \
|
|
||||||
assetlist.cpp \
|
|
||||||
clipmap.cpp \
|
|
||||||
comworld.cpp \
|
|
||||||
d3dresource.cpp \
|
|
||||||
effectdef.cpp \
|
|
||||||
effecttable.cpp \
|
|
||||||
file.cpp \
|
|
||||||
font.cpp \
|
|
||||||
gameworld.cpp \
|
|
||||||
gfximage.cpp \
|
|
||||||
gfxlightdef.cpp \
|
|
||||||
gfxworld.cpp \
|
|
||||||
loadedsound.cpp \
|
|
||||||
localizeentry.cpp \
|
|
||||||
mapent.cpp \
|
|
||||||
material.cpp \
|
|
||||||
materialpixelshader.cpp \
|
|
||||||
materialtechset.cpp \
|
|
||||||
menudef.cpp \
|
|
||||||
menulist.cpp \
|
|
||||||
model.cpp \
|
|
||||||
rawfile.cpp \
|
|
||||||
scriptstringlist.cpp \
|
|
||||||
soundalias.cpp \
|
|
||||||
soundcurve.cpp \
|
|
||||||
sounddriver.cpp \
|
|
||||||
stringtable.cpp \
|
|
||||||
weapondef.cpp \
|
|
||||||
# 360 classes
|
|
||||||
360/assets_cod2_360.cpp \
|
|
||||||
360/assets_cod4_360.cpp \
|
|
||||||
360/assets_cod5_360.cpp \
|
|
||||||
360/assets_cod6_360.cpp \
|
|
||||||
360/assets_cod7_360.cpp \
|
|
||||||
360/assets_cod8_360.cpp \
|
|
||||||
360/assets_cod9_360.cpp \
|
|
||||||
360/assets_cod10_360.cpp \
|
|
||||||
360/assets_cod11_360.cpp \
|
|
||||||
360/assets_cod12_360.cpp \
|
|
||||||
# PS3 classes
|
|
||||||
PS3/assets_cod4_ps3.cpp \
|
|
||||||
PS3/assets_cod5_ps3.cpp \
|
|
||||||
PS3/assets_cod6_ps3.cpp \
|
|
||||||
PS3/assets_cod7_ps3.cpp \
|
|
||||||
PS3/assets_cod8_ps3.cpp \
|
|
||||||
PS3/assets_cod9_ps3.cpp \
|
|
||||||
PS3/assets_cod10_ps3.cpp \
|
|
||||||
PS3/assets_cod11_ps3.cpp \
|
|
||||||
PS3/assets_cod12_ps3.cpp \
|
|
||||||
# PC classes
|
|
||||||
PC/assets_cod4_pc.cpp \
|
|
||||||
PC/assets_cod5_pc.cpp \
|
|
||||||
PC/assets_cod6_pc.cpp \
|
|
||||||
PC/assets_cod7_pc.cpp \
|
|
||||||
PC/assets_cod8_pc.cpp \
|
|
||||||
PC/assets_cod9_pc.cpp \
|
|
||||||
PC/assets_cod10_pc.cpp \
|
|
||||||
PC/assets_cod11_pc.cpp \
|
|
||||||
PC/assets_cod12_pc.cpp \
|
|
||||||
# Wii classes
|
|
||||||
Wii/assets_cod4_wii.cpp \
|
|
||||||
Wii/assets_cod7_wii.cpp \
|
|
||||||
Wii/assets_cod8_wii.cpp \
|
|
||||||
# WiiU classes
|
|
||||||
WiiU/assets_cod9_wiiu.cpp \
|
|
||||||
WiiU/assets_cod10_wiiu.cpp
|
|
||||||
|
|
||||||
HEADERS += \
|
|
||||||
# Base class
|
|
||||||
animparts.h \
|
|
||||||
asset.h \
|
|
||||||
assetlist.h \
|
|
||||||
assetmap.h \
|
|
||||||
assets.h \
|
|
||||||
# 360 classes
|
|
||||||
360/assets_cod2_360.h \
|
|
||||||
360/assets_cod4_360.h \
|
|
||||||
360/assets_cod5_360.h \
|
|
||||||
360/assets_cod6_360.h \
|
|
||||||
360/assets_cod7_360.h \
|
|
||||||
360/assets_cod8_360.h \
|
|
||||||
360/assets_cod9_360.h \
|
|
||||||
360/assets_cod10_360.h \
|
|
||||||
360/assets_cod11_360.h \
|
|
||||||
360/assets_cod12_360.h \
|
|
||||||
# PS3 classes
|
|
||||||
PS3/assets_cod4_ps3.h \
|
|
||||||
PS3/assets_cod5_ps3.h \
|
|
||||||
PS3/assets_cod6_ps3.h \
|
|
||||||
PS3/assets_cod7_ps3.h \
|
|
||||||
PS3/assets_cod8_ps3.h \
|
|
||||||
PS3/assets_cod9_ps3.h \
|
|
||||||
PS3/assets_cod10_ps3.h \
|
|
||||||
PS3/assets_cod11_ps3.h \
|
|
||||||
PS3/assets_cod12_ps3.h \
|
|
||||||
# PC classes
|
|
||||||
PC/assets_cod4_pc.h \
|
|
||||||
PC/assets_cod5_pc.h \
|
|
||||||
PC/assets_cod6_pc.h \
|
|
||||||
PC/assets_cod7_pc.h \
|
|
||||||
PC/assets_cod8_pc.h \
|
|
||||||
PC/assets_cod9_pc.h \
|
|
||||||
PC/assets_cod10_pc.h \
|
|
||||||
PC/assets_cod11_pc.h \
|
|
||||||
PC/assets_cod12_pc.h \
|
|
||||||
# Wii classes
|
|
||||||
Wii/assets_cod4_wii.h \
|
|
||||||
Wii/assets_cod7_wii.h \
|
|
||||||
Wii/assets_cod8_wii.h \
|
|
||||||
# WiiU classes
|
|
||||||
WiiU/assets_cod9_wiiu.h \
|
|
||||||
WiiU/assets_cod10_wiiu.h \
|
|
||||||
clipmap.h \
|
|
||||||
comworld.h \
|
|
||||||
d3dresource.h \
|
|
||||||
effectdef.h \
|
|
||||||
effecttable.h \
|
|
||||||
file.h \
|
|
||||||
font.h \
|
|
||||||
gameworld.h \
|
|
||||||
gfximage.h \
|
|
||||||
gfxlightdef.h \
|
|
||||||
gfxworld.h \
|
|
||||||
loadedsound.h \
|
|
||||||
localizeentry.h \
|
|
||||||
mapent.h \
|
|
||||||
material.h \
|
|
||||||
materialpixelshader.h \
|
|
||||||
materialtechset.h \
|
|
||||||
menudef.h \
|
|
||||||
menulist.h \
|
|
||||||
model.h \
|
|
||||||
rawfile.h \
|
|
||||||
scriptstringlist.h \
|
|
||||||
soundalias.h \
|
|
||||||
soundcurve.h \
|
|
||||||
sounddriver.h \
|
|
||||||
stringtable.h \
|
|
||||||
weapondef.h
|
|
||||||
|
|
||||||
LIBS += \
|
LIBS += \
|
||||||
-L$$OUT_PWD/../libs/core -lcore
|
-L$$OUT_PWD/../libs/core -lcore
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
#ifndef CLIPMAP_H
|
#ifndef CLIPMAP_H
|
||||||
#define CLIPMAP_H
|
#define CLIPMAP_H
|
||||||
|
|
||||||
#include "model.h"
|
#include "xmodel.h"
|
||||||
#include "mapent.h"
|
#include "mapent.h"
|
||||||
#include "effectdef.h"
|
#include "effectdef.h"
|
||||||
|
|
||||||
|
|||||||
208
libs/assets/comprimarylight.cpp
Normal file
208
libs/assets/comprimarylight.cpp
Normal file
@ -0,0 +1,208 @@
|
|||||||
|
#include "comprimarylight.h"
|
||||||
|
|
||||||
|
ComPrimaryLight::ComPrimaryLight(QObject *aParent)
|
||||||
|
: XAsset(aParent)
|
||||||
|
, mType(-1)
|
||||||
|
, mCanUseShadowMap(-1)
|
||||||
|
, mExponent(-1)
|
||||||
|
, mUnused(-1)
|
||||||
|
, mColor(0, 0, 0)
|
||||||
|
, mDir(0, 0, 0)
|
||||||
|
, mOrigin(0, 0, 0)
|
||||||
|
, mRadius(0.0)
|
||||||
|
, mCosHalfFovOuter(0.0)
|
||||||
|
, mCosHalfFovInner(0.0)
|
||||||
|
, mCosHalfFovExpanded(0.0)
|
||||||
|
, mRotationLimit(0.0)
|
||||||
|
, mTranslationLimit(0.0)
|
||||||
|
, mDefName(new XString(this))
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComPrimaryLight::Clear()
|
||||||
|
{
|
||||||
|
delete mDefName;
|
||||||
|
}
|
||||||
|
|
||||||
|
ComPrimaryLightArray *ComPrimaryLight::ParseArray(QDataStream *aStream, int aCount)
|
||||||
|
{
|
||||||
|
ComPrimaryLightArray* result = new ComPrimaryLightArray();
|
||||||
|
|
||||||
|
for (int i = 0; i < aCount; i++)
|
||||||
|
{
|
||||||
|
ComPrimaryLight* comPrimaryLight = new ComPrimaryLight();
|
||||||
|
comPrimaryLight->ParseData(aStream);
|
||||||
|
|
||||||
|
result->append(comPrimaryLight);
|
||||||
|
}
|
||||||
|
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComPrimaryLight::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
*aStream
|
||||||
|
>> mType
|
||||||
|
>> mCanUseShadowMap
|
||||||
|
>> mExponent
|
||||||
|
>> mUnused
|
||||||
|
>> mColor
|
||||||
|
>> mDir
|
||||||
|
>> mOrigin
|
||||||
|
>> mRadius
|
||||||
|
>> mCosHalfFovOuter
|
||||||
|
>> mCosHalfFovInner
|
||||||
|
>> mCosHalfFovExpanded
|
||||||
|
>> mRotationLimit
|
||||||
|
>> mTranslationLimit;
|
||||||
|
|
||||||
|
mDefName->ParseData(aStream);
|
||||||
|
}
|
||||||
|
|
||||||
|
quint8 ComPrimaryLight::GetType() const
|
||||||
|
{
|
||||||
|
return mType;
|
||||||
|
}
|
||||||
|
|
||||||
|
quint8 ComPrimaryLight::GetCanUseShadowMap() const
|
||||||
|
{
|
||||||
|
return mCanUseShadowMap;
|
||||||
|
}
|
||||||
|
|
||||||
|
quint8 ComPrimaryLight::GetExponent() const
|
||||||
|
{
|
||||||
|
return mExponent;
|
||||||
|
}
|
||||||
|
|
||||||
|
quint8 ComPrimaryLight::GetUnused() const
|
||||||
|
{
|
||||||
|
return mUnused;
|
||||||
|
}
|
||||||
|
|
||||||
|
QColor ComPrimaryLight::GetColor() const
|
||||||
|
{
|
||||||
|
return mColor;
|
||||||
|
}
|
||||||
|
|
||||||
|
QVector3D ComPrimaryLight::GetDir() const
|
||||||
|
{
|
||||||
|
return mDir;
|
||||||
|
}
|
||||||
|
|
||||||
|
QVector3D ComPrimaryLight::GetOrigin() const
|
||||||
|
{
|
||||||
|
return mOrigin;
|
||||||
|
}
|
||||||
|
|
||||||
|
float ComPrimaryLight::GetRadius() const
|
||||||
|
{
|
||||||
|
return mRadius;
|
||||||
|
}
|
||||||
|
|
||||||
|
float ComPrimaryLight::GetCosHalfFovOuter() const
|
||||||
|
{
|
||||||
|
return mCosHalfFovOuter;
|
||||||
|
}
|
||||||
|
|
||||||
|
float ComPrimaryLight::GetCosHalfFovInner() const
|
||||||
|
{
|
||||||
|
return mCosHalfFovInner;
|
||||||
|
}
|
||||||
|
|
||||||
|
float ComPrimaryLight::GetCosHalfFovExpanded() const
|
||||||
|
{
|
||||||
|
return mCosHalfFovExpanded;
|
||||||
|
}
|
||||||
|
|
||||||
|
float ComPrimaryLight::GetRotationLimit() const
|
||||||
|
{
|
||||||
|
return mRotationLimit;
|
||||||
|
}
|
||||||
|
|
||||||
|
float ComPrimaryLight::GetTranslationLimit() const
|
||||||
|
{
|
||||||
|
return mTranslationLimit;
|
||||||
|
}
|
||||||
|
|
||||||
|
XString* ComPrimaryLight::GetDefName() const
|
||||||
|
{
|
||||||
|
return mDefName;
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComPrimaryLight::SetType(quint8 aType)
|
||||||
|
{
|
||||||
|
mType = aType;
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComPrimaryLight::SetCanUseShadowMap(quint8 aCanUseShadowMap)
|
||||||
|
{
|
||||||
|
mCanUseShadowMap = aCanUseShadowMap;
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComPrimaryLight::SetExponent(quint8 aExponent)
|
||||||
|
{
|
||||||
|
mExponent = aExponent;
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComPrimaryLight::SetUnused(quint8 aUnused)
|
||||||
|
{
|
||||||
|
mUnused = aUnused;
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComPrimaryLight::SetColor(const QColor aColor)
|
||||||
|
{
|
||||||
|
mColor = aColor;
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComPrimaryLight::SetDir(const QVector3D aDir)
|
||||||
|
{
|
||||||
|
mDir = aDir;
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComPrimaryLight::SetOrigin(const QVector3D aOrigin)
|
||||||
|
{
|
||||||
|
mOrigin = aOrigin;
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComPrimaryLight::SetRadius(float aRadius)
|
||||||
|
{
|
||||||
|
mRadius = aRadius;
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComPrimaryLight::SetCosHalfFovOuter(float aCosHalfFovOuter)
|
||||||
|
{
|
||||||
|
mCosHalfFovOuter = aCosHalfFovOuter;
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComPrimaryLight::SetCosHalfFovInner(float aCosHalfFovInner)
|
||||||
|
{
|
||||||
|
mCosHalfFovInner = aCosHalfFovInner;
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComPrimaryLight::SetCosHalfFovExpanded(float aCosHalfFovExpanded)
|
||||||
|
{
|
||||||
|
mCosHalfFovExpanded = aCosHalfFovExpanded;
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComPrimaryLight::SetRotationLimit(float aRotationLimit)
|
||||||
|
{
|
||||||
|
mRotationLimit = aRotationLimit;
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComPrimaryLight::SetTranslationLimit(float aTranslationLimit)
|
||||||
|
{
|
||||||
|
mTranslationLimit = aTranslationLimit;
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComPrimaryLight::SetDefName(XString* aDefName)
|
||||||
|
{
|
||||||
|
mDefName = aDefName;
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComPrimaryLight::SetDefName(const QString aDefName)
|
||||||
|
{
|
||||||
|
if (mDefName != nullptr) {
|
||||||
|
mDefName->SetString(aDefName);
|
||||||
|
}
|
||||||
|
}
|
||||||
74
libs/assets/comprimarylight.h
Normal file
74
libs/assets/comprimarylight.h
Normal file
@ -0,0 +1,74 @@
|
|||||||
|
#ifndef COMPRIMARYLIGHT_H
|
||||||
|
#define COMPRIMARYLIGHT_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
#include "xstring.h"
|
||||||
|
|
||||||
|
#include <QVector3D>
|
||||||
|
#include <QColor>
|
||||||
|
|
||||||
|
class ComPrimaryLight;
|
||||||
|
typedef QVector<ComPrimaryLight*> ComPrimaryLightArray;
|
||||||
|
|
||||||
|
class ComPrimaryLight : public XAsset
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
|
||||||
|
public:
|
||||||
|
explicit ComPrimaryLight(QObject *aParent = nullptr);
|
||||||
|
|
||||||
|
quint8 GetType() const;
|
||||||
|
quint8 GetCanUseShadowMap() const;
|
||||||
|
quint8 GetExponent() const;
|
||||||
|
quint8 GetUnused() const;
|
||||||
|
QColor GetColor() const;
|
||||||
|
QVector3D GetDir() const;
|
||||||
|
QVector3D GetOrigin() const;
|
||||||
|
float GetRadius() const;
|
||||||
|
float GetCosHalfFovOuter() const;
|
||||||
|
float GetCosHalfFovInner() const;
|
||||||
|
float GetCosHalfFovExpanded() const;
|
||||||
|
float GetRotationLimit() const;
|
||||||
|
float GetTranslationLimit() const;
|
||||||
|
XString* GetDefName() const;
|
||||||
|
|
||||||
|
static ComPrimaryLightArray* ParseArray(QDataStream *aStream, int aCount);
|
||||||
|
|
||||||
|
virtual void Clear() override;
|
||||||
|
virtual void ParseData(QDataStream *aStream) override;
|
||||||
|
|
||||||
|
public slots:
|
||||||
|
void SetType(quint8 aType);
|
||||||
|
void SetCanUseShadowMap(quint8 aCanUseShadowMap);
|
||||||
|
void SetExponent(quint8 aExponent);
|
||||||
|
void SetUnused(quint8 aUnused);
|
||||||
|
void SetColor(const QColor aColor);
|
||||||
|
void SetDir(const QVector3D aDir);
|
||||||
|
void SetOrigin(const QVector3D aOrigin);
|
||||||
|
void SetRadius(float aRadius);
|
||||||
|
void SetCosHalfFovOuter(float aCosHalfFovOuter);
|
||||||
|
void SetCosHalfFovInner(float aCosHalfFovInner);
|
||||||
|
void SetCosHalfFovExpanded(float aCosHalfFovExpanded);
|
||||||
|
void SetRotationLimit(float aRotationLimit);
|
||||||
|
void SetTranslationLimit(float aTranslationLimit);
|
||||||
|
void SetDefName(XString* aDefName);
|
||||||
|
void SetDefName(const QString aDefName);
|
||||||
|
|
||||||
|
private:
|
||||||
|
quint8 mType;
|
||||||
|
quint8 mCanUseShadowMap;
|
||||||
|
quint8 mExponent;
|
||||||
|
quint8 mUnused;
|
||||||
|
QColor mColor;
|
||||||
|
QVector3D mDir;
|
||||||
|
QVector3D mOrigin;
|
||||||
|
float mRadius;
|
||||||
|
float mCosHalfFovOuter;
|
||||||
|
float mCosHalfFovInner;
|
||||||
|
float mCosHalfFovExpanded;
|
||||||
|
float mRotationLimit;
|
||||||
|
float mTranslationLimit;
|
||||||
|
XString* mDefName;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // COMPRIMARYLIGHT_H
|
||||||
@ -1 +1,92 @@
|
|||||||
#include "comworld.h"
|
#include "comworld.h"
|
||||||
|
|
||||||
|
#include "comprimarylight.h"
|
||||||
|
|
||||||
|
ComWorldAsset::ComWorldAsset(QObject *aParent)
|
||||||
|
: XAsset(aParent)
|
||||||
|
, mName(new XString(aParent))
|
||||||
|
, mInUse(false)
|
||||||
|
, mPrimaryLightCount(-1)
|
||||||
|
, mPrimaryLights(new ComPrimaryLightArray())
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComWorldAsset::Clear()
|
||||||
|
{
|
||||||
|
for (int i = 0; i < mPrimaryLights->size(); i++)
|
||||||
|
{
|
||||||
|
delete mPrimaryLights->at(i);
|
||||||
|
}
|
||||||
|
|
||||||
|
delete mPrimaryLights;
|
||||||
|
delete mName;
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComWorldAsset::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
mName->ParsePtr(aStream, false);
|
||||||
|
|
||||||
|
quint32 primaryLightPtr;
|
||||||
|
*aStream
|
||||||
|
>> mInUse
|
||||||
|
>> mPrimaryLightCount
|
||||||
|
>> primaryLightPtr;
|
||||||
|
|
||||||
|
mName->ParseData(aStream);
|
||||||
|
|
||||||
|
if (primaryLightPtr)
|
||||||
|
{
|
||||||
|
if (mPrimaryLights != nullptr)
|
||||||
|
{
|
||||||
|
delete mPrimaryLights;
|
||||||
|
}
|
||||||
|
mPrimaryLights = ComPrimaryLight::ParseArray(aStream, mPrimaryLightCount);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
QString ComWorldAsset::GetName() const
|
||||||
|
{
|
||||||
|
return mName->GetString();
|
||||||
|
}
|
||||||
|
|
||||||
|
bool ComWorldAsset::IsInUse() const
|
||||||
|
{
|
||||||
|
return mInUse;
|
||||||
|
}
|
||||||
|
|
||||||
|
quint32 ComWorldAsset::GetPrimaryLightCount() const
|
||||||
|
{
|
||||||
|
return mPrimaryLightCount;
|
||||||
|
}
|
||||||
|
|
||||||
|
ComPrimaryLight *ComWorldAsset::GetPrimaryLight(quint32 aIndex) const
|
||||||
|
{
|
||||||
|
return mPrimaryLights->at(aIndex);
|
||||||
|
}
|
||||||
|
|
||||||
|
ComPrimaryLightArray *ComWorldAsset::GetPrimaryLights() const
|
||||||
|
{
|
||||||
|
return mPrimaryLights;
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComWorldAsset::SetName(const QString &aName)
|
||||||
|
{
|
||||||
|
if (aName != nullptr)
|
||||||
|
{
|
||||||
|
mName->SetString(aName);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComWorldAsset::SetName(XString* aName)
|
||||||
|
{
|
||||||
|
if (aName != nullptr)
|
||||||
|
{
|
||||||
|
mName = aName;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void ComWorldAsset::SetInUse(bool aInUse)
|
||||||
|
{
|
||||||
|
mInUse = aInUse;
|
||||||
|
}
|
||||||
|
|||||||
@ -1,30 +1,39 @@
|
|||||||
#ifndef COMWORLD_H
|
#ifndef COMWORLD_H
|
||||||
#define COMWORLD_H
|
#define COMWORLD_H
|
||||||
|
|
||||||
struct ComPrimaryLight
|
#include "xasset.h"
|
||||||
{
|
#include "xstring.h"
|
||||||
unsigned __int8 type;
|
#include "comprimarylight.h"
|
||||||
unsigned __int8 canUseShadowMap;
|
|
||||||
unsigned __int8 exponent;
|
|
||||||
unsigned __int8 unused;
|
|
||||||
float color[3];
|
|
||||||
float dir[3];
|
|
||||||
float origin[3];
|
|
||||||
float radius;
|
|
||||||
float cosHalfFovOuter;
|
|
||||||
float cosHalfFovInner;
|
|
||||||
float cosHalfFovExpanded;
|
|
||||||
float rotationLimit;
|
|
||||||
float translationLimit;
|
|
||||||
const char *defName;
|
|
||||||
};
|
|
||||||
|
|
||||||
struct ComWorld
|
#include <QColor>
|
||||||
|
#include <QVector3D>
|
||||||
|
|
||||||
|
class ComWorldAsset : public XAsset
|
||||||
{
|
{
|
||||||
const char *name;
|
Q_OBJECT
|
||||||
int isInUse;
|
|
||||||
unsigned int primaryLightCount;
|
public:
|
||||||
ComPrimaryLight *primaryLights;
|
explicit ComWorldAsset(QObject *aParent = nullptr);
|
||||||
|
|
||||||
|
virtual void Clear() override;
|
||||||
|
virtual void ParseData(QDataStream *aStream) override;
|
||||||
|
|
||||||
|
QString GetName() const;
|
||||||
|
bool IsInUse() const;
|
||||||
|
quint32 GetPrimaryLightCount() const;
|
||||||
|
ComPrimaryLight* GetPrimaryLight(quint32 aIndex) const;
|
||||||
|
ComPrimaryLightArray* GetPrimaryLights() const;
|
||||||
|
|
||||||
|
public slots:
|
||||||
|
void SetName(const QString &aName);
|
||||||
|
void SetName(XString* aName);
|
||||||
|
void SetInUse(bool aInUse);
|
||||||
|
|
||||||
|
private:
|
||||||
|
XString* mName;
|
||||||
|
bool mInUse;
|
||||||
|
quint32 mPrimaryLightCount;
|
||||||
|
ComPrimaryLightArray* mPrimaryLights;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // COMWORLD_H
|
#endif // COMWORLD_H
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
#define EFFECTDEF_H
|
#define EFFECTDEF_H
|
||||||
|
|
||||||
#include "material.h"
|
#include "material.h"
|
||||||
#include "model.h"
|
#include "xmodel.h"
|
||||||
|
|
||||||
struct FxSpawnDefLooping
|
struct FxSpawnDefLooping
|
||||||
{
|
{
|
||||||
|
|||||||
@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
#include "gfximage.h"
|
#include "gfximage.h"
|
||||||
#include "gfxlightdef.h"
|
#include "gfxlightdef.h"
|
||||||
#include "model.h"
|
#include "xmodel.h"
|
||||||
|
|
||||||
struct GfxStreamingAabbTree
|
struct GfxStreamingAabbTree
|
||||||
{
|
{
|
||||||
|
|||||||
@ -1 +0,0 @@
|
|||||||
#include "localizeentry.h"
|
|
||||||
@ -1,18 +0,0 @@
|
|||||||
#ifndef LOCALIZEENTRY_H
|
|
||||||
#define LOCALIZEENTRY_H
|
|
||||||
|
|
||||||
#include <QString>
|
|
||||||
|
|
||||||
struct p_LocalizeEntry
|
|
||||||
{
|
|
||||||
const char *value;
|
|
||||||
const char *name;
|
|
||||||
};
|
|
||||||
|
|
||||||
struct LocalizeEntry : p_LocalizeEntry
|
|
||||||
{
|
|
||||||
QString value;
|
|
||||||
QString name;
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif // LOCALIZEENTRY_H
|
|
||||||
@ -1 +0,0 @@
|
|||||||
#include "model.h"
|
|
||||||
@ -1 +0,0 @@
|
|||||||
#include "rawfile.h"
|
|
||||||
@ -1,17 +0,0 @@
|
|||||||
#ifndef RAWFILE_H
|
|
||||||
#define RAWFILE_H
|
|
||||||
|
|
||||||
#include <QString>
|
|
||||||
|
|
||||||
struct RawFile
|
|
||||||
{
|
|
||||||
qint32 namePtr;
|
|
||||||
QString name;
|
|
||||||
|
|
||||||
quint32 length;
|
|
||||||
|
|
||||||
qint32 bufferPtr;
|
|
||||||
QByteArray buffer;
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif // RAWFILE_H
|
|
||||||
@ -1 +0,0 @@
|
|||||||
#include "sounddriver.h"
|
|
||||||
@ -1,46 +0,0 @@
|
|||||||
#ifndef SoundDriver_H
|
|
||||||
#define SoundDriver_H
|
|
||||||
|
|
||||||
#include <QString>
|
|
||||||
|
|
||||||
struct XAUDIOREVERBSETTINGS
|
|
||||||
{
|
|
||||||
unsigned int ReflectionsDelay;
|
|
||||||
unsigned __int8 ReverbDelay;
|
|
||||||
unsigned __int8 RearDelay;
|
|
||||||
unsigned __int8 PositionLeft;
|
|
||||||
unsigned __int8 PositionRight;
|
|
||||||
unsigned __int8 PositionMatrixLeft;
|
|
||||||
unsigned __int8 PositionMatrixRight;
|
|
||||||
unsigned __int8 EarlyDiffusion;
|
|
||||||
unsigned __int8 LateDiffusion;
|
|
||||||
unsigned __int8 LowEQGain;
|
|
||||||
unsigned __int8 LowEQCutoff;
|
|
||||||
unsigned __int8 HighEQGain;
|
|
||||||
unsigned __int8 HighEQCutoff;
|
|
||||||
float RoomFilterFreq;
|
|
||||||
float RoomFilterMain;
|
|
||||||
float RoomFilterHF;
|
|
||||||
float ReflectionsGain;
|
|
||||||
float ReverbGain;
|
|
||||||
float DecayTime;
|
|
||||||
float Density;
|
|
||||||
float RoomSize;
|
|
||||||
};
|
|
||||||
|
|
||||||
struct XaReverbSettings
|
|
||||||
{
|
|
||||||
int presetOverridden;
|
|
||||||
XAUDIOREVERBSETTINGS reverbSettings;
|
|
||||||
};
|
|
||||||
|
|
||||||
struct SoundDriver
|
|
||||||
{
|
|
||||||
qint32 namePtr;
|
|
||||||
QString name;
|
|
||||||
|
|
||||||
qint32 reverbPtr;
|
|
||||||
XaReverbSettings *reverbSettings;
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif // SoundDriver_H
|
|
||||||
@ -1 +0,0 @@
|
|||||||
#include "stringtable.h"
|
|
||||||
@ -1,19 +0,0 @@
|
|||||||
#ifndef STRINGTABLESH_H
|
|
||||||
#define STRINGTABLESH_H
|
|
||||||
|
|
||||||
#include <QString>
|
|
||||||
#include <QList>
|
|
||||||
|
|
||||||
struct StringTable
|
|
||||||
{
|
|
||||||
qint32 namePtr;
|
|
||||||
QString name;
|
|
||||||
|
|
||||||
int columnCount;
|
|
||||||
int rowCount;
|
|
||||||
|
|
||||||
qint32 valuesPtr;
|
|
||||||
QStringList values;
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif // STRINGTABLESH_H
|
|
||||||
@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
#include "clipmap.h"
|
#include "clipmap.h"
|
||||||
#include "soundalias.h"
|
#include "soundalias.h"
|
||||||
#include "model.h"
|
#include "xmodel.h"
|
||||||
|
|
||||||
enum WeaponType : __int32
|
enum WeaponType : __int32
|
||||||
{
|
{
|
||||||
|
|||||||
28
libs/assets/xasset.cpp
Normal file
28
libs/assets/xasset.cpp
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
#include "xasset.h"
|
||||||
|
|
||||||
|
XAsset::XAsset()
|
||||||
|
: mPtr(0) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XAsset::~XAsset()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XAsset::SetPtr(qint32 aPtr) {
|
||||||
|
mPtr = aPtr;
|
||||||
|
}
|
||||||
|
|
||||||
|
qint32 XAsset::GetPtr() {
|
||||||
|
return mPtr;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XAsset::ParsePtr(QDataStream *aStream, bool aDataFlag) {
|
||||||
|
*aStream >> mPtr;
|
||||||
|
|
||||||
|
if (aDataFlag && mPtr == -1)
|
||||||
|
{
|
||||||
|
ParseData(aStream);
|
||||||
|
}
|
||||||
|
}
|
||||||
24
libs/assets/xasset.h
Normal file
24
libs/assets/xasset.h
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
#ifndef XASSET_H
|
||||||
|
#define XASSET_H
|
||||||
|
|
||||||
|
#include <QObject>
|
||||||
|
|
||||||
|
class XAsset
|
||||||
|
{
|
||||||
|
|
||||||
|
public:
|
||||||
|
XAsset();
|
||||||
|
virtual ~XAsset();
|
||||||
|
|
||||||
|
void SetPtr(qint32 aPtr);
|
||||||
|
qint32 GetPtr();
|
||||||
|
|
||||||
|
virtual void Clear();
|
||||||
|
virtual void ParsePtr(QDataStream *aStream, bool aDataFlag = true);
|
||||||
|
virtual void ParseData(QDataStream *aStream) = 0;
|
||||||
|
|
||||||
|
private:
|
||||||
|
qint32 mPtr;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XASSET_H
|
||||||
21
libs/assets/xaudioformatinfo.cpp
Normal file
21
libs/assets/xaudioformatinfo.cpp
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#include "xaudioformatinfo.h"
|
||||||
|
|
||||||
|
XAudioFormatInfo::XAudioFormatInfo()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XAudioFormatInfo::~XAudioFormatInfo()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XAudioFormatInfo::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XAudioFormatInfo::Clear()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
21
libs/assets/xaudioformatinfo.h
Normal file
21
libs/assets/xaudioformatinfo.h
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#ifndef XAUDIOFORMATINFO_H
|
||||||
|
#define XAUDIOFORMATINFO_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
|
||||||
|
class XAudioXmaFormat;
|
||||||
|
|
||||||
|
class XAudioFormatInfo : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XAudioFormatInfo();
|
||||||
|
~XAudioFormatInfo();
|
||||||
|
|
||||||
|
virtual void ParseData(QDataStream* aStream) override;
|
||||||
|
virtual void Clear() override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
QVector<XAudioXmaFormat*> mStream;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XAUDIOFORMATINFO_H
|
||||||
21
libs/assets/xaudiopacketaligned.cpp
Normal file
21
libs/assets/xaudiopacketaligned.cpp
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#include "xsoundfile.h"
|
||||||
|
|
||||||
|
XSoundFile::XSoundFile()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XSoundFile::~XSoundFile()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XSoundFile::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XSoundFile::Clear()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
25
libs/assets/xaudiopacketaligned.h
Normal file
25
libs/assets/xaudiopacketaligned.h
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
#ifndef XAUDIOPACKETALIGNED_H
|
||||||
|
#define XAUDIOPACKETALIGNED_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
|
||||||
|
class XAudioXmaLoopRegion;
|
||||||
|
|
||||||
|
class XAudioPacketAligned : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XAudioPacketAligned();
|
||||||
|
~XAudioPacketAligned();
|
||||||
|
|
||||||
|
virtual void ParseData(QDataStream* aStream) override;
|
||||||
|
virtual void Clear() override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
QByteArray mBuffer;
|
||||||
|
quint32 mBufferSize;
|
||||||
|
quint32 mLoopCount;
|
||||||
|
QVector<XAudioXmaLoopRegion> aXmaLoop;
|
||||||
|
char* mContext;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XAUDIOPACKETALIGNED_H
|
||||||
49
libs/assets/xaudioreverbsettings.cpp
Normal file
49
libs/assets/xaudioreverbsettings.cpp
Normal file
@ -0,0 +1,49 @@
|
|||||||
|
#include "xaudioreverbsettings.h"
|
||||||
|
|
||||||
|
XAudioReverbSettings::XAudioReverbSettings()
|
||||||
|
: XAsset()
|
||||||
|
, mPresetOverridden(0)
|
||||||
|
, mReverbSettings(new XReverbSettings())
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XAudioReverbSettings::Clear()
|
||||||
|
{
|
||||||
|
mPresetOverridden = 0;
|
||||||
|
mReverbSettings->Clear();
|
||||||
|
}
|
||||||
|
|
||||||
|
int XAudioReverbSettings::GetPresetOverridden() const
|
||||||
|
{
|
||||||
|
return mPresetOverridden;
|
||||||
|
}
|
||||||
|
|
||||||
|
XReverbSettings* XAudioReverbSettings::GetReverbSettings() const
|
||||||
|
{
|
||||||
|
return mReverbSettings;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XAudioReverbSettings::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
if (GetPtr())
|
||||||
|
{
|
||||||
|
*aStream
|
||||||
|
>> mPresetOverridden;
|
||||||
|
|
||||||
|
if (mReverbSettings != nullptr)
|
||||||
|
{
|
||||||
|
mReverbSettings->ParseData(aStream);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void XAudioReverbSettings::SetPresetOverridden(int aPresetOveridden)
|
||||||
|
{
|
||||||
|
mPresetOverridden = aPresetOveridden;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XAudioReverbSettings::SetReverbSettings(XReverbSettings* aReverbSettings)
|
||||||
|
{
|
||||||
|
mReverbSettings = aReverbSettings;
|
||||||
|
}
|
||||||
26
libs/assets/xaudioreverbsettings.h
Normal file
26
libs/assets/xaudioreverbsettings.h
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
#ifndef XAUDIOREVERBSETTINGS_H
|
||||||
|
#define XAUDIOREVERBSETTINGS_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
#include "xreverbsettings.h"
|
||||||
|
|
||||||
|
class XAudioReverbSettings : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XAudioReverbSettings();
|
||||||
|
|
||||||
|
int GetPresetOverridden() const;
|
||||||
|
void SetPresetOverridden(int aPresetOveridden);
|
||||||
|
|
||||||
|
XReverbSettings* GetReverbSettings() const;
|
||||||
|
void SetReverbSettings(XReverbSettings* aReverbSettings);
|
||||||
|
|
||||||
|
virtual void Clear() override;
|
||||||
|
virtual void ParseData(QDataStream *aStream) override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
int mPresetOverridden;
|
||||||
|
XReverbSettings* mReverbSettings;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XAUDIOREVERBSETTINGS_H
|
||||||
21
libs/assets/xaudioseektable.cpp
Normal file
21
libs/assets/xaudioseektable.cpp
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#include "xaudioseektable.h"
|
||||||
|
|
||||||
|
XAudioSeekTable::XAudioSeekTable()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XAudioSeekTable::~XAudioSeekTable()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XAudioSeekTable::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XAudioSeekTable::Clear()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
22
libs/assets/xaudioseektable.h
Normal file
22
libs/assets/xaudioseektable.h
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
#ifndef XAUDIOSEEKTABLE_H
|
||||||
|
#define XAUDIOSEEKTABLE_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
|
||||||
|
class XSoundFileRef;
|
||||||
|
|
||||||
|
class XAudioSeekTable : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XAudioSeekTable();
|
||||||
|
~XAudioSeekTable();
|
||||||
|
|
||||||
|
virtual void ParseData(QDataStream* aStream) override;
|
||||||
|
virtual void Clear() override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
int mSize;
|
||||||
|
QByteArray mData;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XAUDIOSEEKTABLE_H
|
||||||
21
libs/assets/xaudiosound.cpp
Normal file
21
libs/assets/xaudiosound.cpp
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#include "xaudiosound.h"
|
||||||
|
|
||||||
|
XAudioSound::XAudioSound()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XAudioSound::~XAudioSound()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XAudioSound::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XAudioSound::Clear()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
27
libs/assets/xaudiosound.h
Normal file
27
libs/assets/xaudiosound.h
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
#ifndef XAUDIOSOUND_H
|
||||||
|
#define XAUDIOSOUND_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
#include "xaudiopacketaligned.h"
|
||||||
|
#include "xaudioseektable.h"
|
||||||
|
|
||||||
|
class XAudioSourceFormat;
|
||||||
|
class XAudioXmaDataInfo;
|
||||||
|
|
||||||
|
class XAudioSound : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XAudioSound();
|
||||||
|
~XAudioSound();
|
||||||
|
|
||||||
|
virtual void ParseData(QDataStream* aStream) override;
|
||||||
|
virtual void Clear() override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
XAudioPacketAligned* mPacket;
|
||||||
|
XAudioSourceFormat* mFormat;
|
||||||
|
XAudioXmaDataInfo* mXmaDataInfo;
|
||||||
|
XAudioSeekTable *mSeekTable;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XAUDIOSOUND_H
|
||||||
21
libs/assets/xaudiosourceformat.cpp
Normal file
21
libs/assets/xaudiosourceformat.cpp
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#include "xaudiosourceformat.h"
|
||||||
|
|
||||||
|
XAudioSourceFormat::XAudioSourceFormat()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XAudioSourceFormat::~XAudioSourceFormat()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XAudioSourceFormat::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XAudioSourceFormat::Clear()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
24
libs/assets/xaudiosourceformat.h
Normal file
24
libs/assets/xaudiosourceformat.h
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
#ifndef XAUDIOSOURCEFORMAT_H
|
||||||
|
#define XAUDIOSOURCEFORMAT_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
#include "xaudioformatinfo.h"
|
||||||
|
|
||||||
|
class XAudioStreamInfo;
|
||||||
|
|
||||||
|
class XAudioSourceFormat : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XAudioSourceFormat();
|
||||||
|
~XAudioSourceFormat();
|
||||||
|
|
||||||
|
virtual void ParseData(QDataStream* aStream) override;
|
||||||
|
virtual void Clear() override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
quint8 mSampleType;
|
||||||
|
XAudioStreamInfo* mStreamInfo;
|
||||||
|
XAudioFormatInfo* mAudioFormatInfo;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XAUDIOSOURCEFORMAT_H
|
||||||
21
libs/assets/xaudiostreaminfo.cpp
Normal file
21
libs/assets/xaudiostreaminfo.cpp
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#include "xaudiostreaminfo.h"
|
||||||
|
|
||||||
|
XAudioStreamInfo::XAudioStreamInfo()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XAudioStreamInfo::~XAudioStreamInfo()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XAudioStreamInfo::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XAudioStreamInfo::Clear()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
22
libs/assets/xaudiostreaminfo.h
Normal file
22
libs/assets/xaudiostreaminfo.h
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
#ifndef XAUDIOSTREAMINFO_H
|
||||||
|
#define XAUDIOSTREAMINFO_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
|
||||||
|
class XSoundFileRef;
|
||||||
|
|
||||||
|
class XAudioStreamInfo : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XAudioStreamInfo();
|
||||||
|
~XAudioStreamInfo();
|
||||||
|
|
||||||
|
virtual void ParseData(QDataStream* aStream) override;
|
||||||
|
virtual void Clear() override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
quint8 mNumStreams;
|
||||||
|
quint8 mChannelCount;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XAUDIOSTREAMINFO_H
|
||||||
21
libs/assets/xaudioxmadatainfo.cpp
Normal file
21
libs/assets/xaudioxmadatainfo.cpp
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#include "xaudioxmadatainfo.h"
|
||||||
|
|
||||||
|
XAudioXmaDataInfo::XAudioXmaDataInfo()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XAudioXmaDataInfo::~XAudioXmaDataInfo()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XAudioXmaDataInfo::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XAudioXmaDataInfo::Clear()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
21
libs/assets/xaudioxmadatainfo.h
Normal file
21
libs/assets/xaudioxmadatainfo.h
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#ifndef XAUDIOXMADATAINFO_H
|
||||||
|
#define XAUDIOXMADATAINFO_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
|
||||||
|
class XSoundFileRef;
|
||||||
|
|
||||||
|
class XAudioXmaDataInfo : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XAudioXmaDataInfo();
|
||||||
|
~XAudioXmaDataInfo();
|
||||||
|
|
||||||
|
virtual void ParseData(QDataStream* aStream) override;
|
||||||
|
virtual void Clear() override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
int mTotalMsec;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XAUDIOXMADATAINFO_H
|
||||||
21
libs/assets/xaudioxmaformat.cpp
Normal file
21
libs/assets/xaudioxmaformat.cpp
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#include "xaudioxmaformat.h"
|
||||||
|
|
||||||
|
XAudioXmaFormat::XAudioXmaFormat()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XAudioXmaFormat::~XAudioXmaFormat()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XAudioXmaFormat::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XAudioXmaFormat::Clear()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
21
libs/assets/xaudioxmaformat.h
Normal file
21
libs/assets/xaudioxmaformat.h
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#ifndef XAUDIOXMAFORMAT_H
|
||||||
|
#define XAUDIOXMAFORMAT_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
|
||||||
|
class XAudioXmaFormat : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XAudioXmaFormat();
|
||||||
|
~XAudioXmaFormat();
|
||||||
|
|
||||||
|
virtual void ParseData(QDataStream* aStream) override;
|
||||||
|
virtual void Clear() override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
unsigned int mSampleRate;
|
||||||
|
quint8 mChannelCount;
|
||||||
|
quint8 mDecodeBufferSize;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XAUDIOXMAFORMAT_H
|
||||||
21
libs/assets/xaudioxmaloopregion.cpp
Normal file
21
libs/assets/xaudioxmaloopregion.cpp
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#include "xsoundfile.h"
|
||||||
|
|
||||||
|
XSoundFile::XSoundFile()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XSoundFile::~XSoundFile()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XSoundFile::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XSoundFile::Clear()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
23
libs/assets/xaudioxmaloopregion.h
Normal file
23
libs/assets/xaudioxmaloopregion.h
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
#ifndef XSOUNDFILE_H
|
||||||
|
#define XSOUNDFILE_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
|
||||||
|
class XSoundFileRef;
|
||||||
|
|
||||||
|
class XSoundFile : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XSoundFile();
|
||||||
|
~XSoundFile();
|
||||||
|
|
||||||
|
virtual void ParseData(QDataStream* aStream) override;
|
||||||
|
virtual void Clear() override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
quint8 mType;
|
||||||
|
quint8 mExists;
|
||||||
|
XSoundFileRef* mRef;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XSOUNDFILE_H
|
||||||
118
libs/assets/xeditfielddefinition.cpp
Normal file
118
libs/assets/xeditfielddefinition.cpp
Normal file
@ -0,0 +1,118 @@
|
|||||||
|
#include "xeditfielddefinition.h"
|
||||||
|
|
||||||
|
XEditFieldDefinition::XEditFieldDefinition()
|
||||||
|
: XAsset()
|
||||||
|
, mMinVal(0)
|
||||||
|
, mMaxVal(0)
|
||||||
|
, mDefVal(0)
|
||||||
|
, mRange(0)
|
||||||
|
, mMaxChars(0)
|
||||||
|
, mMaxCharsGotoNext(0)
|
||||||
|
, mMaxPaintChars(0)
|
||||||
|
, mPaintOffset(0)
|
||||||
|
{}
|
||||||
|
|
||||||
|
float XEditFieldDefinition::GetMinVal() const
|
||||||
|
{
|
||||||
|
return mMinVal;
|
||||||
|
}
|
||||||
|
|
||||||
|
float XEditFieldDefinition::GetMaxVal() const
|
||||||
|
{
|
||||||
|
return mMaxVal;
|
||||||
|
}
|
||||||
|
|
||||||
|
float XEditFieldDefinition::GetDefVal() const
|
||||||
|
{
|
||||||
|
return mDefVal;
|
||||||
|
}
|
||||||
|
|
||||||
|
float XEditFieldDefinition::GetRange() const
|
||||||
|
{
|
||||||
|
return mRange;
|
||||||
|
}
|
||||||
|
|
||||||
|
int XEditFieldDefinition::GetMaxChars() const
|
||||||
|
{
|
||||||
|
return mMaxChars;
|
||||||
|
}
|
||||||
|
|
||||||
|
int XEditFieldDefinition::GetMaxCharsGotoNext() const
|
||||||
|
{
|
||||||
|
return mMaxCharsGotoNext;
|
||||||
|
}
|
||||||
|
|
||||||
|
int XEditFieldDefinition::GetMaxPaintChars() const
|
||||||
|
{
|
||||||
|
return mMaxPaintChars;
|
||||||
|
}
|
||||||
|
|
||||||
|
int XEditFieldDefinition::GetPaintOffset() const
|
||||||
|
{
|
||||||
|
return mPaintOffset;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XEditFieldDefinition::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
*aStream
|
||||||
|
>> mMinVal
|
||||||
|
>> mMaxVal
|
||||||
|
>> mDefVal
|
||||||
|
>> mRange
|
||||||
|
>> mMaxChars
|
||||||
|
>> mMaxCharsGotoNext
|
||||||
|
>> mMaxPaintChars
|
||||||
|
>> mPaintOffset;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XEditFieldDefinition::Clear()
|
||||||
|
{
|
||||||
|
mMinVal = 0;
|
||||||
|
mMaxVal = 0;
|
||||||
|
mDefVal = 0;
|
||||||
|
mRange = 0;
|
||||||
|
mMaxChars = 0;
|
||||||
|
mMaxCharsGotoNext = 0;
|
||||||
|
mMaxPaintChars = 0;
|
||||||
|
mPaintOffset = 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XEditFieldDefinition::SetMinVal(float aMinVal)
|
||||||
|
{
|
||||||
|
mMinVal = aMinVal;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XEditFieldDefinition::SetMaxVal(float aMaxVal)
|
||||||
|
{
|
||||||
|
mMaxVal = aMaxVal;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XEditFieldDefinition::SetDefVal(float aDefVal)
|
||||||
|
{
|
||||||
|
mDefVal = aDefVal;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XEditFieldDefinition::SetRange(float aRange)
|
||||||
|
{
|
||||||
|
mRange = aRange;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XEditFieldDefinition::SetMaxChars(int aMaxChars)
|
||||||
|
{
|
||||||
|
mMaxChars = aMaxChars;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XEditFieldDefinition::SetMaxCharsGotoNext(int aMaxCharsGotoNext)
|
||||||
|
{
|
||||||
|
mMaxCharsGotoNext = aMaxCharsGotoNext;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XEditFieldDefinition::SetMaxPaintChars(int aMaxPaintChars)
|
||||||
|
{
|
||||||
|
mMaxPaintChars = aMaxPaintChars;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XEditFieldDefinition::SetPaintOffset(int aPaintOffset)
|
||||||
|
{
|
||||||
|
mPaintOffset = aPaintOffset;
|
||||||
|
}
|
||||||
49
libs/assets/xeditfielddefinition.h
Normal file
49
libs/assets/xeditfielddefinition.h
Normal file
@ -0,0 +1,49 @@
|
|||||||
|
#ifndef XEDITFIELDDEFINITION_H
|
||||||
|
#define XEDITFIELDDEFINITION_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
|
||||||
|
class XEditFieldDefinition : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XEditFieldDefinition();
|
||||||
|
|
||||||
|
float GetMinVal() const;
|
||||||
|
void SetMinVal(float aMinVal);
|
||||||
|
|
||||||
|
float GetMaxVal() const;
|
||||||
|
void SetMaxVal(float aMaxVal);
|
||||||
|
|
||||||
|
float GetDefVal() const;
|
||||||
|
void SetDefVal(float aDefVal);
|
||||||
|
|
||||||
|
float GetRange() const;
|
||||||
|
void SetRange(float aRange);
|
||||||
|
|
||||||
|
int GetMaxChars() const;
|
||||||
|
void SetMaxChars(int aMaxChars);
|
||||||
|
|
||||||
|
int GetMaxCharsGotoNext() const;
|
||||||
|
void SetMaxCharsGotoNext(int aMaxCharsGotoNext);
|
||||||
|
|
||||||
|
int GetMaxPaintChars() const;
|
||||||
|
void SetMaxPaintChars(int aMaxPaintChars);
|
||||||
|
|
||||||
|
int GetPaintOffset() const;
|
||||||
|
void SetPaintOffset(int aPaintOffset);
|
||||||
|
|
||||||
|
virtual void ParseData(QDataStream* aStream);
|
||||||
|
virtual void Clear();
|
||||||
|
|
||||||
|
private:
|
||||||
|
float mMinVal;
|
||||||
|
float mMaxVal;
|
||||||
|
float mDefVal;
|
||||||
|
float mRange;
|
||||||
|
int mMaxChars;
|
||||||
|
int mMaxCharsGotoNext;
|
||||||
|
int mMaxPaintChars;
|
||||||
|
int mPaintOffset;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XEDITFIELDDEFINITION_H
|
||||||
21
libs/assets/xloadedsound.cpp
Normal file
21
libs/assets/xloadedsound.cpp
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#include "xsoundfile.h"
|
||||||
|
|
||||||
|
XSoundFile::XSoundFile()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XSoundFile::~XSoundFile()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XSoundFile::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XSoundFile::Clear()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
24
libs/assets/xloadedsound.h
Normal file
24
libs/assets/xloadedsound.h
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
#ifndef XLOADEDSOUND_H
|
||||||
|
#define XLOADEDSOUND_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
#include "xaudiosound.h"
|
||||||
|
#include "xstring.h"
|
||||||
|
|
||||||
|
class XSoundFileRef;
|
||||||
|
|
||||||
|
class XLoadedSound : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XLoadedSound();
|
||||||
|
~XLoadedSound();
|
||||||
|
|
||||||
|
virtual void ParseData(QDataStream* aStream) override;
|
||||||
|
virtual void Clear() override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
XString* mName;
|
||||||
|
XAudioSound* mSound;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XLOADEDSOUND_H
|
||||||
60
libs/assets/xlocalizeentry.cpp
Normal file
60
libs/assets/xlocalizeentry.cpp
Normal file
@ -0,0 +1,60 @@
|
|||||||
|
#include "xlocalizeentry.h"
|
||||||
|
|
||||||
|
XLocalizeEntry::XLocalizeEntry()
|
||||||
|
: XAsset()
|
||||||
|
, mValue(new XString())
|
||||||
|
, mName(new XString())
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XLocalizeEntry::~XLocalizeEntry()
|
||||||
|
{
|
||||||
|
delete mValue;
|
||||||
|
delete mName;
|
||||||
|
}
|
||||||
|
|
||||||
|
XString* XLocalizeEntry::GetValue() const
|
||||||
|
{
|
||||||
|
return mValue;
|
||||||
|
}
|
||||||
|
|
||||||
|
XString* XLocalizeEntry::GetName() const
|
||||||
|
{
|
||||||
|
return mName;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XLocalizeEntry::Clear()
|
||||||
|
{
|
||||||
|
mValue->Clear();
|
||||||
|
mName->Clear();
|
||||||
|
}
|
||||||
|
|
||||||
|
void XLocalizeEntry::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
mValue->ParsePtr(aStream, false);
|
||||||
|
mName->ParsePtr(aStream, false);
|
||||||
|
|
||||||
|
mValue->ParseData(aStream);
|
||||||
|
mName->ParseData(aStream);
|
||||||
|
}
|
||||||
|
|
||||||
|
void XLocalizeEntry::SetValue(XString* aValue)
|
||||||
|
{
|
||||||
|
mValue = aValue;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XLocalizeEntry::SetValue(QString aValue)
|
||||||
|
{
|
||||||
|
mValue->SetString(aValue);
|
||||||
|
}
|
||||||
|
|
||||||
|
void XLocalizeEntry::SetName(XString* aName)
|
||||||
|
{
|
||||||
|
mName = aName;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XLocalizeEntry::SetName(QString aName)
|
||||||
|
{
|
||||||
|
mName->SetString(aName);
|
||||||
|
}
|
||||||
30
libs/assets/xlocalizeentry.h
Normal file
30
libs/assets/xlocalizeentry.h
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
#ifndef XLOCALIZEENTRY_H
|
||||||
|
#define XLOCALIZEENTRY_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
#include "xstring.h"
|
||||||
|
|
||||||
|
class XLocalizeEntry : public XAsset
|
||||||
|
{
|
||||||
|
|
||||||
|
public:
|
||||||
|
XLocalizeEntry();
|
||||||
|
~XLocalizeEntry();
|
||||||
|
|
||||||
|
void SetValue(XString* aValue);
|
||||||
|
void SetValue(QString aValue);
|
||||||
|
XString* GetValue() const;
|
||||||
|
|
||||||
|
void SetName(XString* aName);
|
||||||
|
void SetName(QString aName);
|
||||||
|
XString* GetName() const;
|
||||||
|
|
||||||
|
virtual void Clear() override;
|
||||||
|
virtual void ParseData(QDataStream *aStream) override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
XString* mValue;
|
||||||
|
XString* mName;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XLOCALIZEENTRY_H
|
||||||
7
libs/assets/xmapents.cpp
Normal file
7
libs/assets/xmapents.cpp
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
#include "xmapents.h"
|
||||||
|
|
||||||
|
XMapEnts::XMapEnts()
|
||||||
|
: XAsset()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
15
libs/assets/xmapents.h
Normal file
15
libs/assets/xmapents.h
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
#ifndef XMAPENTS_H
|
||||||
|
#define XMAPENTS_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
|
||||||
|
class XMapEnts : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XMapEnts();
|
||||||
|
|
||||||
|
private:
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XMAPENTS_H
|
||||||
207
libs/assets/xmodel.cpp
Normal file
207
libs/assets/xmodel.cpp
Normal file
@ -0,0 +1,207 @@
|
|||||||
|
#include "xmodel.h"
|
||||||
|
|
||||||
|
XModel::XModel()
|
||||||
|
: XAsset() {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XModel::ParseData(QDataStream *aStream) {
|
||||||
|
qint32 namePtr, boneNamesPtr;
|
||||||
|
|
||||||
|
const char *name;
|
||||||
|
unsigned __int8 numBones;
|
||||||
|
unsigned __int8 numRootBones;
|
||||||
|
unsigned __int8 numsurfs;
|
||||||
|
unsigned __int8 lodRampType;
|
||||||
|
unsigned __int16 *boneNames;
|
||||||
|
unsigned __int8 *parentList;
|
||||||
|
__int16 *quats;
|
||||||
|
float *trans;
|
||||||
|
unsigned __int8 *partClassification;
|
||||||
|
DObjAnimMat *baseMat;
|
||||||
|
XSurface *surfs;
|
||||||
|
Material **materialHandles;
|
||||||
|
XModelLodInfo lodInfo[4];
|
||||||
|
XModelCollSurf_s *collSurfs;
|
||||||
|
int numCollSurfs;
|
||||||
|
int contents;
|
||||||
|
XBoneInfo *boneInfo;
|
||||||
|
float radius;
|
||||||
|
float mins[3];
|
||||||
|
float maxs[3];
|
||||||
|
__int16 numLods;
|
||||||
|
__int16 collLod;
|
||||||
|
XModelStreamInfo streamInfo;
|
||||||
|
int memUsage;
|
||||||
|
unsigned __int8 flags;
|
||||||
|
PhysPreset *physPreset;
|
||||||
|
PhysGeomList *physGeoms;
|
||||||
|
|
||||||
|
*aStream
|
||||||
|
>> namePtr;
|
||||||
|
|
||||||
|
mName = Load_XString(aStream);
|
||||||
|
if (boneNamesPtr == -1)
|
||||||
|
{
|
||||||
|
Load_ScriptStringArray(1, numBones);
|
||||||
|
}
|
||||||
|
if ( parentList )
|
||||||
|
{
|
||||||
|
if ( parentList == (unsigned __int8 *)-1 )
|
||||||
|
{
|
||||||
|
v5 = g_streamPos;
|
||||||
|
v6 = v1->numBones - v1->numRootBones;
|
||||||
|
varbyte = g_streamPos;
|
||||||
|
v1->parentList = g_streamPos;
|
||||||
|
Load_Stream(1, v5, v6);
|
||||||
|
v1 = varXModel;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
v1->parentList = &(*(unsigned __int8 **)((char *)&g_streamBlocks->data
|
||||||
|
+ (((unsigned int)(v1->parentList - 1) >> 26) & 0x38)))[(int)(v1->parentList - 1) & 0x1FFFFFFF];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
quats = v1->quats;
|
||||||
|
if ( quats )
|
||||||
|
{
|
||||||
|
if ( quats == (__int16 *)-1 )
|
||||||
|
{
|
||||||
|
v8 = (unsigned __int8 *)((unsigned int)(g_streamPos + 1) & 0xFFFFFFFE);
|
||||||
|
v9 = 8 * (v1->numBones - v1->numRootBones);
|
||||||
|
g_streamPos = v8;
|
||||||
|
v1->quats = (__int16 *)v8;
|
||||||
|
varshort = (__int16 *)v8;
|
||||||
|
Load_Stream(1, v8, v9);
|
||||||
|
v1 = varXModel;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
v1->quats = (__int16 *)&(*(unsigned __int8 **)((char *)&g_streamBlocks->data
|
||||||
|
+ ((((unsigned int)v1->quats - 1) >> 26) & 0x38)))[((int)v1->quats - 1) & 0x1FFFFFFF];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
trans = v1->trans;
|
||||||
|
if ( trans )
|
||||||
|
{
|
||||||
|
if ( trans == (float *)-1 )
|
||||||
|
{
|
||||||
|
v11 = (unsigned __int8 *)((unsigned int)(g_streamPos + 3) & 0xFFFFFFFC);
|
||||||
|
v12 = 16 * (v1->numBones - v1->numRootBones);
|
||||||
|
g_streamPos = v11;
|
||||||
|
v1->trans = (float *)v11;
|
||||||
|
varfloat = (float *)v11;
|
||||||
|
Load_Stream(1, v11, v12);
|
||||||
|
v1 = varXModel;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
v1->trans = (float *)&(*(unsigned __int8 **)((char *)&g_streamBlocks->data
|
||||||
|
+ ((((unsigned int)v1->trans - 1) >> 26) & 0x38)))[((int)v1->trans - 1) & 0x1FFFFFFF];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
partClassification = v1->partClassification;
|
||||||
|
if ( partClassification )
|
||||||
|
{
|
||||||
|
if ( partClassification == (unsigned __int8 *)-1 )
|
||||||
|
{
|
||||||
|
v14 = g_streamPos;
|
||||||
|
v15 = v1->numBones;
|
||||||
|
varbyte = g_streamPos;
|
||||||
|
v1->partClassification = g_streamPos;
|
||||||
|
Load_Stream(1, v14, v15);
|
||||||
|
v1 = varXModel;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
v1->partClassification = &(*(unsigned __int8 **)((char *)&g_streamBlocks->data
|
||||||
|
+ (((unsigned int)(v1->partClassification - 1) >> 26) & 0x38)))[(int)(v1->partClassification - 1) & 0x1FFFFFFF];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
baseMat = v1->baseMat;
|
||||||
|
if ( baseMat )
|
||||||
|
{
|
||||||
|
if ( baseMat == (DObjAnimMat *)-1 )
|
||||||
|
{
|
||||||
|
v17 = __ROL4__(v1->numBones, 5);
|
||||||
|
v18 = (unsigned __int8 *)((unsigned int)(g_streamPos + 3) & 0xFFFFFFFC);
|
||||||
|
g_streamPos = v18;
|
||||||
|
varDObjAnimMat = (DObjAnimMat *)v18;
|
||||||
|
v1->baseMat = (DObjAnimMat *)v18;
|
||||||
|
Load_Stream(1, v18, v17);
|
||||||
|
v1 = varXModel;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
v1->baseMat = (DObjAnimMat *)&(*(unsigned __int8 **)((char *)&g_streamBlocks->data
|
||||||
|
+ ((((unsigned int)&v1->baseMat[-1].transWeight + 3) >> 26) & 0x38)))[((int)&v1->baseMat[-1].transWeight + 3) & 0x1FFFFFFF];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if ( v1->surfs )
|
||||||
|
{
|
||||||
|
numsurfs = v1->numsurfs;
|
||||||
|
g_streamPos = (unsigned __int8 *)((unsigned int)(g_streamPos + 3) & 0xFFFFFFFC);
|
||||||
|
varXSurface = (XSurface *)g_streamPos;
|
||||||
|
v1->surfs = (XSurface *)g_streamPos;
|
||||||
|
Load_XSurfaceArray(1, numsurfs);
|
||||||
|
v1 = varXModel;
|
||||||
|
}
|
||||||
|
if ( v1->materialHandles )
|
||||||
|
{
|
||||||
|
v20 = v1->numsurfs;
|
||||||
|
g_streamPos = (unsigned __int8 *)((unsigned int)(g_streamPos + 3) & 0xFFFFFFFC);
|
||||||
|
varMaterialHandle = (Material **)g_streamPos;
|
||||||
|
v1->materialHandles = (Material **)g_streamPos;
|
||||||
|
Load_MaterialHandleArray(1, v20);
|
||||||
|
v1 = varXModel;
|
||||||
|
}
|
||||||
|
if ( v1->collSurfs )
|
||||||
|
{
|
||||||
|
numCollSurfs = v1->numCollSurfs;
|
||||||
|
g_streamPos = (unsigned __int8 *)((unsigned int)(g_streamPos + 3) & 0xFFFFFFFC);
|
||||||
|
varXModelCollSurf = (XModelCollSurf_s *)g_streamPos;
|
||||||
|
v1->collSurfs = (XModelCollSurf_s *)g_streamPos;
|
||||||
|
Load_XModelCollSurfArray(1, numCollSurfs);
|
||||||
|
v1 = varXModel;
|
||||||
|
}
|
||||||
|
if ( v1->boneInfo )
|
||||||
|
{
|
||||||
|
v22 = v1->numBones;
|
||||||
|
v23 = (unsigned __int8 *)((unsigned int)(g_streamPos + 3) & 0xFFFFFFFC);
|
||||||
|
v1->boneInfo = (XBoneInfo *)v23;
|
||||||
|
g_streamPos = v23;
|
||||||
|
varXBoneInfo = (XBoneInfo *)v23;
|
||||||
|
Load_Stream(1, v23, 8 * (v22 + __ROL4__(v22, 2)));
|
||||||
|
v1 = varXModel;
|
||||||
|
}
|
||||||
|
varXModelStreamInfo = &v1->streamInfo;
|
||||||
|
Load_Stream(0, &v1->streamInfo, 4u);
|
||||||
|
if ( varXModelStreamInfo->highMipBounds )
|
||||||
|
{
|
||||||
|
v24 = (XModelHighMipBounds *)((unsigned int)(g_streamPos + 3) & 0xFFFFFFFC);
|
||||||
|
varXModelStreamInfo->highMipBounds = v24;
|
||||||
|
varXModelHighMipBounds = v24;
|
||||||
|
g_streamPos = (unsigned __int8 *)v24;
|
||||||
|
Load_Stream(1, v24, 8 * (varXModel->lodInfo[0].numsurfs + __ROL4__(varXModel->lodInfo[0].numsurfs, 1)));
|
||||||
|
}
|
||||||
|
varPhysPresetPtr = &varXModel->physPreset;
|
||||||
|
Load_PhysPresetPtr(0);
|
||||||
|
physGeoms = varXModel->physGeoms;
|
||||||
|
if ( physGeoms )
|
||||||
|
{
|
||||||
|
if ( physGeoms == (PhysGeomList *)-1 )
|
||||||
|
{
|
||||||
|
g_streamPos = (unsigned __int8 *)((unsigned int)(g_streamPos + 3) & 0xFFFFFFFC);
|
||||||
|
varPhysGeomList = (PhysGeomList *)g_streamPos;
|
||||||
|
varXModel->physGeoms = (PhysGeomList *)g_streamPos;
|
||||||
|
Load_PhysGeomList(1);
|
||||||
|
DB_PopStreamPos();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
varXModel->physGeoms = (PhysGeomList *)&(*(unsigned __int8 **)((char *)&g_streamBlocks->data
|
||||||
|
+ ((((unsigned int)&varXModel->physGeoms[-1].mass.productsOfInertia[2]
|
||||||
|
+ 3) >> 26) & 0x38)))[((int)&varXModel->physGeoms[-1].mass.productsOfInertia[2]
|
||||||
|
+ 3) & 0x1FFFFFFF];
|
||||||
|
}
|
||||||
|
DB_PopStreamPos();
|
||||||
|
}
|
||||||
@ -1,5 +1,5 @@
|
|||||||
#ifndef MODEL_H
|
#ifndef XMODEL_H
|
||||||
#define MODEL_H
|
#define XMODEL_H
|
||||||
|
|
||||||
#include "material.h"
|
#include "material.h"
|
||||||
#include "scriptstringlist.h"
|
#include "scriptstringlist.h"
|
||||||
@ -239,64 +239,44 @@ struct PhysGeomList
|
|||||||
PhysMass mass;
|
PhysMass mass;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct Model
|
#include "xasset.h"
|
||||||
|
|
||||||
|
class XModel : public XAsset
|
||||||
{
|
{
|
||||||
QString name;
|
public:
|
||||||
qint32 namePtr;
|
explicit XModel();
|
||||||
|
|
||||||
|
void ParseData(QDataStream *aStream) override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
QString mName;
|
||||||
quint8 numBones;
|
quint8 numBones;
|
||||||
quint8 numRootBones;
|
quint8 numRootBones;
|
||||||
quint8 numsurfs;
|
quint8 numsurfs;
|
||||||
quint8 lodRampType;
|
quint8 lodRampType;
|
||||||
|
|
||||||
quint32 boneNamesPtr;
|
|
||||||
ScriptStringList boneNames;
|
ScriptStringList boneNames;
|
||||||
|
|
||||||
quint32 parentListPtr;
|
|
||||||
quint8 *parentList;
|
quint8 *parentList;
|
||||||
|
|
||||||
qint32 quatsPtr;
|
|
||||||
qint16 *quats;
|
qint16 *quats;
|
||||||
|
|
||||||
qint32 transPtr;
|
|
||||||
float *trans;
|
float *trans;
|
||||||
|
|
||||||
qint32 partClassPtr;
|
|
||||||
quint8 *partClassification;
|
quint8 *partClassification;
|
||||||
|
|
||||||
qint32 baseMatPtr;
|
|
||||||
DObjAnimMat *baseMat;
|
DObjAnimMat *baseMat;
|
||||||
|
|
||||||
qint32 surfsPtr;
|
|
||||||
XSurface *surfs;
|
XSurface *surfs;
|
||||||
|
|
||||||
qint32 matHandlesPtr;
|
|
||||||
Material **materialHandles;
|
Material **materialHandles;
|
||||||
|
|
||||||
XModelLodInfo lodInfo[4];
|
XModelLodInfo lodInfo[4];
|
||||||
|
|
||||||
qint32 collSurfsPtr;
|
|
||||||
XModelCollSurf *collSurfs;
|
XModelCollSurf *collSurfs;
|
||||||
|
|
||||||
int numCollSurfs;
|
int numCollSurfs;
|
||||||
int contents;
|
int contents;
|
||||||
|
|
||||||
qint32 boneInfoPtr;
|
|
||||||
XBoneInfo *boneInfo;
|
XBoneInfo *boneInfo;
|
||||||
|
|
||||||
float radius;
|
float radius;
|
||||||
float mins[3];
|
float mins[3];
|
||||||
float maxs[3];
|
float maxs[3];
|
||||||
|
|
||||||
qint16 numLods;
|
qint16 numLods;
|
||||||
qint16 collLod;
|
qint16 collLod;
|
||||||
|
|
||||||
XModelStreamInfo streamInfo;
|
XModelStreamInfo streamInfo;
|
||||||
int memUsage;
|
int memUsage;
|
||||||
quint8 flags;
|
quint8 flags;
|
||||||
std::shared_ptr<PhysPreset> physPreset;
|
std::shared_ptr<PhysPreset> physPreset;
|
||||||
|
|
||||||
qint32 physGeomsPtr;
|
|
||||||
PhysGeomList *physGeoms;
|
PhysGeomList *physGeoms;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // MODEL_H
|
#endif // XMODEL_H
|
||||||
92
libs/assets/xrawfile.cpp
Normal file
92
libs/assets/xrawfile.cpp
Normal file
@ -0,0 +1,92 @@
|
|||||||
|
#include "xrawfile.h"
|
||||||
|
|
||||||
|
XRawFile::XRawFile()
|
||||||
|
: XAsset()
|
||||||
|
, mName(new XString())
|
||||||
|
, mLength(0)
|
||||||
|
, mBuffer()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XRawFile::~XRawFile()
|
||||||
|
{
|
||||||
|
delete mName;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XRawFile::SetName(XString* aName)
|
||||||
|
{
|
||||||
|
if (aName == nullptr)
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
mName = aName;
|
||||||
|
}
|
||||||
|
void XRawFile::SetName(const QString& aName)
|
||||||
|
{
|
||||||
|
if (mName == nullptr)
|
||||||
|
{
|
||||||
|
mName = new XString();
|
||||||
|
}
|
||||||
|
|
||||||
|
mName->SetString(aName);
|
||||||
|
}
|
||||||
|
|
||||||
|
XString* XRawFile::Name() const
|
||||||
|
{
|
||||||
|
return mName;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XRawFile::SetLength(int aLength)
|
||||||
|
{
|
||||||
|
mBuffer = mBuffer.chopped(aLength);
|
||||||
|
mLength = aLength;
|
||||||
|
}
|
||||||
|
|
||||||
|
int XRawFile::Length() const
|
||||||
|
{
|
||||||
|
return mLength;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XRawFile::SetBuffer(const QByteArray& aBuffer)
|
||||||
|
{
|
||||||
|
mBuffer = aBuffer;
|
||||||
|
mLength = mBuffer.length();
|
||||||
|
}
|
||||||
|
|
||||||
|
QByteArray XRawFile::Buffer() const
|
||||||
|
{
|
||||||
|
return mBuffer;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XRawFile::Clear()
|
||||||
|
{
|
||||||
|
mName->Clear();
|
||||||
|
mLength = 0;
|
||||||
|
mBuffer = QByteArray();
|
||||||
|
|
||||||
|
XAsset::Clear();
|
||||||
|
}
|
||||||
|
|
||||||
|
void XRawFile::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
mName->ParsePtr(aStream, false);
|
||||||
|
|
||||||
|
qint32 bufferPtr;
|
||||||
|
*aStream
|
||||||
|
>> mLength
|
||||||
|
>> bufferPtr;
|
||||||
|
|
||||||
|
if (mName == nullptr)
|
||||||
|
{
|
||||||
|
mName = new XString();
|
||||||
|
}
|
||||||
|
mName->ParseData(aStream);
|
||||||
|
|
||||||
|
if (bufferPtr)
|
||||||
|
{
|
||||||
|
mBuffer = QByteArray(mLength + 1, Qt::Uninitialized);
|
||||||
|
aStream->readRawData(mBuffer.data(), mLength + 1);
|
||||||
|
}
|
||||||
|
}
|
||||||
32
libs/assets/xrawfile.h
Normal file
32
libs/assets/xrawfile.h
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
#ifndef XRAWFILE_H
|
||||||
|
#define XRAWFILE_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
#include "xstring.h"
|
||||||
|
|
||||||
|
class XRawFile : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XRawFile();
|
||||||
|
~XRawFile();
|
||||||
|
|
||||||
|
void SetName(XString* aName = nullptr);
|
||||||
|
void SetName(const QString& aName);
|
||||||
|
XString* Name() const;
|
||||||
|
|
||||||
|
void SetLength(int aLength);
|
||||||
|
int Length() const;
|
||||||
|
|
||||||
|
void SetBuffer(const QByteArray& aBuffer);
|
||||||
|
QByteArray Buffer() const;
|
||||||
|
|
||||||
|
virtual void Clear() override;
|
||||||
|
virtual void ParseData(QDataStream *aStream) override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
XString* mName;
|
||||||
|
quint32 mLength;
|
||||||
|
QByteArray mBuffer;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XRAWFILE_H
|
||||||
292
libs/assets/xreverbsettings.cpp
Normal file
292
libs/assets/xreverbsettings.cpp
Normal file
@ -0,0 +1,292 @@
|
|||||||
|
#include "xreverbsettings.h"
|
||||||
|
|
||||||
|
XReverbSettings::XReverbSettings()
|
||||||
|
: XAsset()
|
||||||
|
, mReflectionsDelay(0)
|
||||||
|
, mReverbDelay(0)
|
||||||
|
, mRearDelay(0)
|
||||||
|
, mPositionLeft(0)
|
||||||
|
, mPositionRight(0)
|
||||||
|
, mPositionMatrixLeft(0)
|
||||||
|
, mPositionMatrixRight(0)
|
||||||
|
, mEarlyDiffusion(0)
|
||||||
|
, mLateDiffusion(0)
|
||||||
|
, mLowEQGain(0)
|
||||||
|
, mLowEQCutoff(0)
|
||||||
|
, mHighEQGain(0)
|
||||||
|
, mHighEQCutoff(0)
|
||||||
|
, mRoomFilterFreq(0.0)
|
||||||
|
, mRoomFilterMain(0.0)
|
||||||
|
, mRoomFilterHF(0.0)
|
||||||
|
, mReflectionsGain(0.0)
|
||||||
|
, mReverbGain(0.0)
|
||||||
|
, mDecayTime(0.0)
|
||||||
|
, mDensity(0.0)
|
||||||
|
, mRoomSize(0.0)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
quint32 XReverbSettings::GetReflectionsDelay() const
|
||||||
|
{
|
||||||
|
return mReflectionsDelay;
|
||||||
|
}
|
||||||
|
|
||||||
|
quint8 XReverbSettings::GetReverbDelay() const
|
||||||
|
{
|
||||||
|
return mReverbDelay;
|
||||||
|
}
|
||||||
|
|
||||||
|
quint8 XReverbSettings::GetRearDelay() const
|
||||||
|
{
|
||||||
|
return mRearDelay;
|
||||||
|
}
|
||||||
|
|
||||||
|
quint8 XReverbSettings::GetPositionLeft() const
|
||||||
|
{
|
||||||
|
return mPositionLeft;
|
||||||
|
}
|
||||||
|
|
||||||
|
quint8 XReverbSettings::GetPositionRight() const
|
||||||
|
{
|
||||||
|
return mPositionRight;
|
||||||
|
}
|
||||||
|
|
||||||
|
quint8 XReverbSettings::GetPositionMatrixLeft() const
|
||||||
|
{
|
||||||
|
return mPositionMatrixLeft;
|
||||||
|
}
|
||||||
|
|
||||||
|
quint8 XReverbSettings::GetPositionMatrixRight() const
|
||||||
|
{
|
||||||
|
return mPositionMatrixRight;
|
||||||
|
}
|
||||||
|
|
||||||
|
quint8 XReverbSettings::GetEarlyDiffusion() const
|
||||||
|
{
|
||||||
|
return mEarlyDiffusion;
|
||||||
|
}
|
||||||
|
|
||||||
|
quint8 XReverbSettings::GetLateDiffusion() const
|
||||||
|
{
|
||||||
|
return mLateDiffusion;
|
||||||
|
}
|
||||||
|
|
||||||
|
quint8 XReverbSettings::GetLowEQGain() const
|
||||||
|
{
|
||||||
|
return mLowEQGain;
|
||||||
|
}
|
||||||
|
|
||||||
|
quint8 XReverbSettings::GetLowEQCutoff() const
|
||||||
|
{
|
||||||
|
return mLowEQCutoff;
|
||||||
|
}
|
||||||
|
|
||||||
|
quint8 XReverbSettings::GetHighEQGain() const
|
||||||
|
{
|
||||||
|
return mHighEQGain;
|
||||||
|
}
|
||||||
|
|
||||||
|
quint8 XReverbSettings::GetHighEQCutoff() const
|
||||||
|
{
|
||||||
|
return mHighEQCutoff;
|
||||||
|
}
|
||||||
|
|
||||||
|
float XReverbSettings::GetRoomFilterFreq() const
|
||||||
|
{
|
||||||
|
return mRoomFilterFreq;
|
||||||
|
}
|
||||||
|
|
||||||
|
float XReverbSettings::GetRoomFilterMain() const
|
||||||
|
{
|
||||||
|
return mRoomFilterMain;
|
||||||
|
}
|
||||||
|
|
||||||
|
float XReverbSettings::GetRoomFilterHF() const
|
||||||
|
{
|
||||||
|
return mRoomFilterHF;
|
||||||
|
}
|
||||||
|
|
||||||
|
float XReverbSettings::GetReflectionsGain() const
|
||||||
|
{
|
||||||
|
return mReflectionsGain;
|
||||||
|
}
|
||||||
|
|
||||||
|
float XReverbSettings::GetReverbGain() const
|
||||||
|
{
|
||||||
|
return mReverbGain;
|
||||||
|
}
|
||||||
|
|
||||||
|
float XReverbSettings::GetDecayTime() const
|
||||||
|
{
|
||||||
|
return mDecayTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
float XReverbSettings::GetDensity() const
|
||||||
|
{
|
||||||
|
return mDensity;
|
||||||
|
}
|
||||||
|
|
||||||
|
float XReverbSettings::GetRoomSize() const
|
||||||
|
{
|
||||||
|
return mRoomSize;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::Clear()
|
||||||
|
{
|
||||||
|
mReflectionsDelay = 0;
|
||||||
|
mReverbDelay = 0;
|
||||||
|
mRearDelay = 0;
|
||||||
|
mPositionLeft = 0;
|
||||||
|
mPositionRight = 0;
|
||||||
|
mPositionMatrixLeft = 0;
|
||||||
|
mPositionMatrixRight = 0;
|
||||||
|
mEarlyDiffusion = 0;
|
||||||
|
mLateDiffusion = 0;
|
||||||
|
mLowEQGain = 0;
|
||||||
|
mLowEQCutoff = 0;
|
||||||
|
mHighEQGain = 0;
|
||||||
|
mHighEQCutoff = 0;
|
||||||
|
mRoomFilterFreq = 0.0;
|
||||||
|
mRoomFilterMain = 0.0;
|
||||||
|
mRoomFilterHF = 0.0;
|
||||||
|
mReflectionsGain = 0.0;
|
||||||
|
mReverbGain = 0.0;
|
||||||
|
mDecayTime = 0.0;
|
||||||
|
mDensity = 0.0;
|
||||||
|
mRoomSize = 0.0;
|
||||||
|
|
||||||
|
XAsset::Clear();
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::ParseData(QDataStream* aStream)
|
||||||
|
{
|
||||||
|
*aStream
|
||||||
|
>> mReflectionsDelay
|
||||||
|
>> mReverbDelay
|
||||||
|
>> mRearDelay
|
||||||
|
>> mPositionLeft
|
||||||
|
>> mPositionRight
|
||||||
|
>> mPositionMatrixLeft
|
||||||
|
>> mPositionMatrixRight
|
||||||
|
>> mEarlyDiffusion
|
||||||
|
>> mLateDiffusion
|
||||||
|
>> mLowEQGain
|
||||||
|
>> mLowEQCutoff
|
||||||
|
>> mHighEQGain
|
||||||
|
>> mHighEQCutoff
|
||||||
|
>> mRoomFilterFreq
|
||||||
|
>> mRoomFilterMain
|
||||||
|
>> mRoomFilterHF
|
||||||
|
>> mReflectionsGain
|
||||||
|
>> mReverbGain
|
||||||
|
>> mDecayTime
|
||||||
|
>> mDensity
|
||||||
|
>> mRoomSize;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::SetReflectionsDelay(quint32 aReflectionsDelay)
|
||||||
|
{
|
||||||
|
mReflectionsDelay = aReflectionsDelay;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::SetReverbDelay(quint8 aReverbDelay)
|
||||||
|
{
|
||||||
|
mReverbDelay = aReverbDelay;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::SetRearDelay(quint8 aRearDelay)
|
||||||
|
{
|
||||||
|
mRearDelay = aRearDelay;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::SetPositionLeft(quint8 aPositionLeft)
|
||||||
|
{
|
||||||
|
mPositionLeft = aPositionLeft;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::SetPositionRight(quint8 aPositionRight)
|
||||||
|
{
|
||||||
|
mPositionRight = aPositionRight;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::SetPositionMatrixLeft(quint8 aPositionMatrixLeft)
|
||||||
|
{
|
||||||
|
mPositionMatrixLeft = aPositionMatrixLeft;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::SetPositionMatrixRight(quint8 aPositionMatrixRight)
|
||||||
|
{
|
||||||
|
mPositionMatrixRight = aPositionMatrixRight;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::SetEarlyDiffusion(quint8 aEarlyDiffusion)
|
||||||
|
{
|
||||||
|
mEarlyDiffusion = aEarlyDiffusion;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::SetLateDiffusion(quint8 aLateDiffusion)
|
||||||
|
{
|
||||||
|
mLateDiffusion = aLateDiffusion;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::SetLowEQGain(quint8 aLowEQGain)
|
||||||
|
{
|
||||||
|
mLowEQGain = aLowEQGain;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::SetLowEQCutoff(quint8 aLowEQCutoff)
|
||||||
|
{
|
||||||
|
mLowEQCutoff = aLowEQCutoff;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::SetHighEQGain(quint8 aHighEQGain)
|
||||||
|
{
|
||||||
|
mHighEQGain = aHighEQGain;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::SetHighEQCutoff(quint8 aHighEQCutoff)
|
||||||
|
{
|
||||||
|
mHighEQCutoff = aHighEQCutoff;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::SetRoomFilterFreq(float aRoomFilterFreq)
|
||||||
|
{
|
||||||
|
mRoomFilterFreq = aRoomFilterFreq;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::SetRoomFilterMain(float aRoomFilterMain)
|
||||||
|
{
|
||||||
|
mRoomFilterMain = aRoomFilterMain;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::SetRoomFilterHF(float aRoomFilterHF)
|
||||||
|
{
|
||||||
|
mRoomFilterHF = aRoomFilterHF;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::SetReflectionsGain(float aReflectionsGain)
|
||||||
|
{
|
||||||
|
mReflectionsGain = aReflectionsGain;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::SetReverbGain(float aReverbGain)
|
||||||
|
{
|
||||||
|
mReverbGain = aReverbGain;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::SetDecayTime(float aDecayTime)
|
||||||
|
{
|
||||||
|
mDecayTime = aDecayTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::SetDensity(float aDensity)
|
||||||
|
{
|
||||||
|
mDensity = aDensity;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XReverbSettings::SetRoomSize(float aRoomSize)
|
||||||
|
{
|
||||||
|
mRoomSize = aRoomSize;
|
||||||
|
}
|
||||||
|
|
||||||
83
libs/assets/xreverbsettings.h
Normal file
83
libs/assets/xreverbsettings.h
Normal file
@ -0,0 +1,83 @@
|
|||||||
|
#ifndef XREVERBSETTINGS_H
|
||||||
|
#define XREVERBSETTINGS_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
|
||||||
|
class XReverbSettings : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
explicit XReverbSettings();
|
||||||
|
|
||||||
|
quint32 GetReflectionsDelay() const;
|
||||||
|
quint8 GetReverbDelay() const;
|
||||||
|
quint8 GetRearDelay() const;
|
||||||
|
quint8 GetPositionLeft() const;
|
||||||
|
quint8 GetPositionRight() const;
|
||||||
|
quint8 GetPositionMatrixLeft() const;
|
||||||
|
quint8 GetPositionMatrixRight() const;
|
||||||
|
quint8 GetEarlyDiffusion() const;
|
||||||
|
quint8 GetLateDiffusion() const;
|
||||||
|
quint8 GetLowEQGain() const;
|
||||||
|
quint8 GetLowEQCutoff() const;
|
||||||
|
quint8 GetHighEQGain() const;
|
||||||
|
quint8 GetHighEQCutoff() const;
|
||||||
|
float GetRoomFilterFreq() const;
|
||||||
|
float GetRoomFilterMain() const;
|
||||||
|
float GetRoomFilterHF() const;
|
||||||
|
float GetReflectionsGain() const;
|
||||||
|
float GetReverbGain() const;
|
||||||
|
float GetDecayTime() const;
|
||||||
|
float GetDensity() const;
|
||||||
|
float GetRoomSize() const;
|
||||||
|
|
||||||
|
virtual void Clear() override;
|
||||||
|
virtual void ParseData(QDataStream* aStream) override;
|
||||||
|
|
||||||
|
public slots:
|
||||||
|
void SetReflectionsDelay(quint32 aReflectionsDelay);
|
||||||
|
void SetReverbDelay(quint8 aReverbDelay);
|
||||||
|
void SetRearDelay(quint8 aRearDelay);
|
||||||
|
void SetPositionLeft(quint8 aPositionLeft);
|
||||||
|
void SetPositionRight(quint8 aPositionRight);
|
||||||
|
void SetPositionMatrixLeft(quint8 aPositionMatrixLeft);
|
||||||
|
void SetPositionMatrixRight(quint8 aPositionMatrixRight);
|
||||||
|
void SetEarlyDiffusion(quint8 aEarlyDiffusion);
|
||||||
|
void SetLateDiffusion(quint8 aLateDiffusion);
|
||||||
|
void SetLowEQGain(quint8 aLowEQGain);
|
||||||
|
void SetLowEQCutoff(quint8 aLowEQCutoff);
|
||||||
|
void SetHighEQGain(quint8 aHighEQGain);
|
||||||
|
void SetHighEQCutoff(quint8 aHighEQCutoff);
|
||||||
|
void SetRoomFilterFreq(float aRoomFilterFreq);
|
||||||
|
void SetRoomFilterMain(float aRoomFilterMain);
|
||||||
|
void SetRoomFilterHF(float aRoomFilterHF);
|
||||||
|
void SetReflectionsGain(float aReflectionsGain);
|
||||||
|
void SetReverbGain(float aReverbGain);
|
||||||
|
void SetDecayTime(float aDecayTime);
|
||||||
|
void SetDensity(float aDensity);
|
||||||
|
void SetRoomSize(float aRoomSize);
|
||||||
|
|
||||||
|
private:
|
||||||
|
quint32 mReflectionsDelay;
|
||||||
|
quint8 mReverbDelay;
|
||||||
|
quint8 mRearDelay;
|
||||||
|
quint8 mPositionLeft;
|
||||||
|
quint8 mPositionRight;
|
||||||
|
quint8 mPositionMatrixLeft;
|
||||||
|
quint8 mPositionMatrixRight;
|
||||||
|
quint8 mEarlyDiffusion;
|
||||||
|
quint8 mLateDiffusion;
|
||||||
|
quint8 mLowEQGain;
|
||||||
|
quint8 mLowEQCutoff;
|
||||||
|
quint8 mHighEQGain;
|
||||||
|
quint8 mHighEQCutoff;
|
||||||
|
float mRoomFilterFreq;
|
||||||
|
float mRoomFilterMain;
|
||||||
|
float mRoomFilterHF;
|
||||||
|
float mReflectionsGain;
|
||||||
|
float mReverbGain;
|
||||||
|
float mDecayTime;
|
||||||
|
float mDensity;
|
||||||
|
float mRoomSize;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XREVERBSETTINGS_H
|
||||||
16
libs/assets/xsoundalias.cpp
Normal file
16
libs/assets/xsoundalias.cpp
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
#include "xsoundalias.h"
|
||||||
|
|
||||||
|
XSoundAlias::XSoundAlias()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XSoundAlias::Clear()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XSoundAlias::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
42
libs/assets/xsoundalias.h
Normal file
42
libs/assets/xsoundalias.h
Normal file
@ -0,0 +1,42 @@
|
|||||||
|
#ifndef XSOUNDALIAS_H
|
||||||
|
#define XSOUNDALIAS_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
#include "xstring.h"
|
||||||
|
|
||||||
|
class XSoundAlias : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XSoundAlias();
|
||||||
|
|
||||||
|
virtual void Clear() override;
|
||||||
|
virtual void ParseData(QDataStream* aStream) override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
XString* mAliasName;
|
||||||
|
XString* mSubtitle;
|
||||||
|
XString* mSecondaryAliasName;
|
||||||
|
XString* mChainAliasName;
|
||||||
|
XSoundFile* mSoundFile;
|
||||||
|
int mSequence;
|
||||||
|
float mVolMin;
|
||||||
|
float mVolMax;
|
||||||
|
float mPitchMin;
|
||||||
|
float mPitchMax;
|
||||||
|
float mDistMin;
|
||||||
|
float mDistMax;
|
||||||
|
int mFlags;
|
||||||
|
float mSlavePercentage;
|
||||||
|
float mProbability;
|
||||||
|
float mLfePercentage;
|
||||||
|
float mCenterPercentage;
|
||||||
|
int mStartDelay;
|
||||||
|
XSoundCurve* mVolumeFalloffCurve;
|
||||||
|
float mEnvelopMin;
|
||||||
|
float mEnvelopMax;
|
||||||
|
float mEnvelopPercentage;
|
||||||
|
XSpeakerMap* mSpeakerMap;
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XSOUNDALIAS_H
|
||||||
33
libs/assets/xsounddriverglobals.cpp
Normal file
33
libs/assets/xsounddriverglobals.cpp
Normal file
@ -0,0 +1,33 @@
|
|||||||
|
#include "xsounddriverglobals.h"
|
||||||
|
|
||||||
|
XSoundDriverGlobals::XSoundDriverGlobals()
|
||||||
|
: XAsset()
|
||||||
|
, mAudioReverbSettings(new XAudioReverbSettings())
|
||||||
|
, mName(new XString())
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XSoundDriverGlobals::~XSoundDriverGlobals()
|
||||||
|
{
|
||||||
|
delete mAudioReverbSettings;
|
||||||
|
delete mName;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XSoundDriverGlobals::Clear()
|
||||||
|
{
|
||||||
|
mAudioReverbSettings->Clear();
|
||||||
|
mName->Clear();
|
||||||
|
}
|
||||||
|
|
||||||
|
void XSoundDriverGlobals::ParseData(QDataStream* aStream)
|
||||||
|
{
|
||||||
|
if (GetPtr())
|
||||||
|
{
|
||||||
|
mAudioReverbSettings->ParsePtr(aStream, false);
|
||||||
|
mName->ParsePtr(aStream, false);
|
||||||
|
|
||||||
|
mAudioReverbSettings->ParseData(aStream);
|
||||||
|
mName->ParseData(aStream);
|
||||||
|
}
|
||||||
|
}
|
||||||
22
libs/assets/xsounddriverglobals.h
Normal file
22
libs/assets/xsounddriverglobals.h
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
#ifndef SoundDriver_H
|
||||||
|
#define SoundDriver_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
#include "xaudioreverbsettings.h"
|
||||||
|
#include "xstring.h"
|
||||||
|
|
||||||
|
class XSoundDriverGlobals : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XSoundDriverGlobals();
|
||||||
|
~XSoundDriverGlobals();
|
||||||
|
|
||||||
|
virtual void Clear() override;
|
||||||
|
virtual void ParseData(QDataStream* aStream) override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
XAudioReverbSettings *mAudioReverbSettings;
|
||||||
|
XString *mName;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // SoundDriver_H
|
||||||
21
libs/assets/xsoundfile.cpp
Normal file
21
libs/assets/xsoundfile.cpp
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#include "xsoundfile.h"
|
||||||
|
|
||||||
|
XSoundFile::XSoundFile()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XSoundFile::~XSoundFile()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XSoundFile::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XSoundFile::Clear()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
23
libs/assets/xsoundfile.h
Normal file
23
libs/assets/xsoundfile.h
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
#ifndef XSOUNDFILE_H
|
||||||
|
#define XSOUNDFILE_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
|
||||||
|
class XSoundFileRef;
|
||||||
|
|
||||||
|
class XSoundFile : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XSoundFile();
|
||||||
|
~XSoundFile();
|
||||||
|
|
||||||
|
virtual void ParseData(QDataStream* aStream) override;
|
||||||
|
virtual void Clear() override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
quint8 mType;
|
||||||
|
quint8 mExists;
|
||||||
|
XSoundFileRef* mRef;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XSOUNDFILE_H
|
||||||
3
libs/assets/xsoundfileref.cpp
Normal file
3
libs/assets/xsoundfileref.cpp
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
#include "xsoundfileref.h"
|
||||||
|
|
||||||
|
XSoundFileRef::XSoundFileRef() {}
|
||||||
12
libs/assets/xsoundfileref.h
Normal file
12
libs/assets/xsoundfileref.h
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
#ifndef XSOUNDFILEREF_H
|
||||||
|
#define XSOUNDFILEREF_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
|
||||||
|
class XSoundFileRef : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XSoundFileRef();
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XSOUNDFILEREF_H
|
||||||
21
libs/assets/xstreamedsound.cpp
Normal file
21
libs/assets/xstreamedsound.cpp
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#include "xstreamedsound.h"
|
||||||
|
|
||||||
|
XStreamedSound::XStreamedSound()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XStreamedSound::~XStreamedSound()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XStreamedSound::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XStreamedSound::Clear()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
21
libs/assets/xstreamedsound.h
Normal file
21
libs/assets/xstreamedsound.h
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#ifndef XSTREAMEDSOUND_H
|
||||||
|
#define XSTREAMEDSOUND_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
|
||||||
|
class XStreamedFileName;
|
||||||
|
|
||||||
|
class XStreamedSound : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XStreamedSound();
|
||||||
|
~XStreamedSound();
|
||||||
|
|
||||||
|
virtual void ParseData(QDataStream* aStream) override;
|
||||||
|
virtual void Clear() override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
XStreamedFileName* mStreamed;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XSTREAMEDSOUND_H
|
||||||
21
libs/assets/xstreamfileinfo.cpp
Normal file
21
libs/assets/xstreamfileinfo.cpp
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#include "xstreamfileinfo.h"
|
||||||
|
|
||||||
|
XStreamFileInfo::XStreamFileInfo()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XStreamFileInfo::~XStreamFileInfo()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XStreamFileInfo::Clear()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XStreamFileInfo::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
21
libs/assets/xstreamfileinfo.h
Normal file
21
libs/assets/xstreamfileinfo.h
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#ifndef XSTREAMFILEINFO_H
|
||||||
|
#define XSTREAMFILEINFO_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
|
||||||
|
class XStreamFileName;
|
||||||
|
|
||||||
|
class XStreamFileInfo : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XStreamFileInfo();
|
||||||
|
~XStreamFileInfo();
|
||||||
|
|
||||||
|
virtual void Clear() override;
|
||||||
|
virtual void ParseData(QDataStream* aStream) override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
XStreamFileName* mStream;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XSTREAMFILEINFO_H
|
||||||
21
libs/assets/xstreamfilename.cpp
Normal file
21
libs/assets/xstreamfilename.cpp
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#include "xstreamfileinfo.h"
|
||||||
|
|
||||||
|
XStreamFileInfo::XStreamFileInfo()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XStreamFileInfo::~XStreamFileInfo()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XStreamFileInfo::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XStreamFileInfo::Clear()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
23
libs/assets/xstreamfilename.h
Normal file
23
libs/assets/xstreamfilename.h
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
#ifndef XSTREAMFILEINFO_H
|
||||||
|
#define XSTREAMFILEINFO_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
|
||||||
|
class XStreamFileNameRaw;
|
||||||
|
class XStreamFileNamePacked;
|
||||||
|
|
||||||
|
class XStreamFileInfo : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XStreamFileInfo();
|
||||||
|
~XStreamFileInfo();
|
||||||
|
|
||||||
|
virtual void ParseData(QDataStream* aStream) override;
|
||||||
|
virtual void Clear() override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
XStreamFileNameRaw *mRaw;
|
||||||
|
XStreamFileNamePacked *mPacked;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XSTREAMFILEINFO_H
|
||||||
21
libs/assets/xstreamfilenamepacked.cpp
Normal file
21
libs/assets/xstreamfilenamepacked.cpp
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#include "xstreamfilenamepacked.h"
|
||||||
|
|
||||||
|
XStreamFileNamePacked::XStreamFileNamePacked()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XStreamFileNamePacked::~XStreamFileNamePacked()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XStreamFileNamePacked::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XStreamFileNamePacked::Clear()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
22
libs/assets/xstreamfilenamepacked.h
Normal file
22
libs/assets/xstreamfilenamepacked.h
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
#ifndef XSTREAMFILENAMEPACKED_H
|
||||||
|
#define XSTREAMFILENAMEPACKED_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
|
||||||
|
class XSoundFileRef;
|
||||||
|
|
||||||
|
class XStreamFileNamePacked : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XStreamFileNamePacked();
|
||||||
|
~XStreamFileNamePacked();
|
||||||
|
|
||||||
|
virtual void ParseData(QDataStream* aStream) override;
|
||||||
|
virtual void Clear() override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
unsigned int mOffset;
|
||||||
|
unsigned int mLength;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XSTREAMFILENAMEPACKED_H
|
||||||
21
libs/assets/xstreamfilenameraw.cpp
Normal file
21
libs/assets/xstreamfilenameraw.cpp
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#include "xstreamfilenameraw.h"
|
||||||
|
|
||||||
|
XStreamFileNameRaw::XStreamFileNameRaw()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XStreamFileNameRaw::~XStreamFileNameRaw()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XStreamFileNameRaw::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void XStreamFileNameRaw::Clear()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
21
libs/assets/xstreamfilenameraw.h
Normal file
21
libs/assets/xstreamfilenameraw.h
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#ifndef XSTREAMFILENAMERAW_H
|
||||||
|
#define XSTREAMFILENAMERAW_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
#include "xstring.h"
|
||||||
|
|
||||||
|
class XStreamFileNameRaw : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XStreamFileNameRaw();
|
||||||
|
~XStreamFileNameRaw();
|
||||||
|
|
||||||
|
virtual void ParseData(QDataStream* aStream) override;
|
||||||
|
virtual void Clear() override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
XString* mDir;
|
||||||
|
XString* mName;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XSTREAMFILENAMERAW_H
|
||||||
67
libs/assets/xstring.cpp
Normal file
67
libs/assets/xstring.cpp
Normal file
@ -0,0 +1,67 @@
|
|||||||
|
#include "xstring.h"
|
||||||
|
|
||||||
|
XString::XString()
|
||||||
|
: XAsset()
|
||||||
|
, mString("")
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XString::~XString()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
QString XString::GetString() const
|
||||||
|
{
|
||||||
|
return mString;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XString::SetString(const QString& aString)
|
||||||
|
{
|
||||||
|
mString = aString;
|
||||||
|
}
|
||||||
|
|
||||||
|
QString XString::ParseCustom(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
QString result;
|
||||||
|
char currentChar;
|
||||||
|
|
||||||
|
*aStream >> currentChar;
|
||||||
|
while (currentChar != '\0')
|
||||||
|
{
|
||||||
|
result += currentChar;
|
||||||
|
|
||||||
|
*aStream >> currentChar;
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
XStringArray* XString::ParseArray(QDataStream *aStream, int aCount)
|
||||||
|
{
|
||||||
|
XStringArray* result = new XStringArray();
|
||||||
|
|
||||||
|
for (int i = 0; i < aCount; i++)
|
||||||
|
{
|
||||||
|
XString* string = new XString();
|
||||||
|
string->ParseCustom(aStream);
|
||||||
|
|
||||||
|
result->append(string);
|
||||||
|
}
|
||||||
|
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XString::Clear()
|
||||||
|
{
|
||||||
|
mString = "";
|
||||||
|
}
|
||||||
|
|
||||||
|
void XString::ParseData(QDataStream *aStream)
|
||||||
|
{
|
||||||
|
if (GetPtr() == -1)
|
||||||
|
{
|
||||||
|
mString = ParseCustom(aStream);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
29
libs/assets/xstring.h
Normal file
29
libs/assets/xstring.h
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
#ifndef XSTRING_H
|
||||||
|
#define XSTRING_H
|
||||||
|
|
||||||
|
#include <QObject>
|
||||||
|
#include "xasset.h"
|
||||||
|
|
||||||
|
class XString;
|
||||||
|
typedef QVector<XString*> XStringArray;
|
||||||
|
|
||||||
|
class XString : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XString();
|
||||||
|
virtual ~XString() override;
|
||||||
|
|
||||||
|
void SetString(const QString& aString);
|
||||||
|
QString GetString() const;
|
||||||
|
|
||||||
|
static QString ParseCustom(QDataStream* aStream);
|
||||||
|
static XStringArray* ParseArray(QDataStream* aStream, int aCount);
|
||||||
|
|
||||||
|
virtual void Clear() override;
|
||||||
|
virtual void ParseData(QDataStream* aStream) override;
|
||||||
|
|
||||||
|
private:
|
||||||
|
QString mString;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // XSTRING_H
|
||||||
95
libs/assets/xstringtable.cpp
Normal file
95
libs/assets/xstringtable.cpp
Normal file
@ -0,0 +1,95 @@
|
|||||||
|
#include "xstringtable.h"
|
||||||
|
#include "xstring.h"
|
||||||
|
|
||||||
|
XStringTable::XStringTable()
|
||||||
|
: XAsset()
|
||||||
|
, mName(new XString())
|
||||||
|
, mValues(new XStringArray())
|
||||||
|
, mColumnCount(0)
|
||||||
|
, mRowCount(0) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
XStringTable::~XStringTable()
|
||||||
|
{
|
||||||
|
delete mName;
|
||||||
|
|
||||||
|
for (int i = 0; i < mValues->size(); i++)
|
||||||
|
{
|
||||||
|
delete mValues->at(i);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void XStringTable::SetName(XString *aName) {
|
||||||
|
if (aName == nullptr)
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
mName = aName;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XStringTable::SetName(const QString aName) {
|
||||||
|
mName->SetString(aName);
|
||||||
|
}
|
||||||
|
|
||||||
|
XString *XStringTable::GetName() const {
|
||||||
|
return mName;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XStringTable::SetValues(XStringArray* aValues) {
|
||||||
|
mValues = aValues;
|
||||||
|
}
|
||||||
|
|
||||||
|
XStringArray* XStringTable::GetValues() const {
|
||||||
|
return mValues;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XStringTable::SetColumnCount(int aColumnCount) {
|
||||||
|
mColumnCount = aColumnCount;
|
||||||
|
}
|
||||||
|
|
||||||
|
int XStringTable::GetColumnCount() const {
|
||||||
|
return mColumnCount;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XStringTable::SetRowCount(int aRowCount) {
|
||||||
|
mRowCount = aRowCount;
|
||||||
|
}
|
||||||
|
|
||||||
|
int XStringTable::GetRowCount() const {
|
||||||
|
return mRowCount;
|
||||||
|
}
|
||||||
|
|
||||||
|
void XStringTable::Clear()
|
||||||
|
{
|
||||||
|
mName->Clear();
|
||||||
|
|
||||||
|
for (int i = 0; i < mValues->size(); i++)
|
||||||
|
{
|
||||||
|
delete mValues->at(i);
|
||||||
|
}
|
||||||
|
mValues->clear();
|
||||||
|
|
||||||
|
mColumnCount = 0;
|
||||||
|
mRowCount = 0;
|
||||||
|
|
||||||
|
XAsset::Clear();
|
||||||
|
}
|
||||||
|
|
||||||
|
void XStringTable::ParseData(QDataStream *aStream) {
|
||||||
|
qint32 valuesPtr;
|
||||||
|
|
||||||
|
mName->ParsePtr(aStream, false);
|
||||||
|
|
||||||
|
*aStream
|
||||||
|
>> mColumnCount
|
||||||
|
>> mRowCount
|
||||||
|
>> valuesPtr;
|
||||||
|
|
||||||
|
mName->ParseData(aStream);
|
||||||
|
if (valuesPtr)
|
||||||
|
{
|
||||||
|
mValues = XString::ParseArray(aStream, mRowCount * mColumnCount);
|
||||||
|
}
|
||||||
|
}
|
||||||
35
libs/assets/xstringtable.h
Normal file
35
libs/assets/xstringtable.h
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
#ifndef STRINGTABLESH_H
|
||||||
|
#define STRINGTABLESH_H
|
||||||
|
|
||||||
|
#include "xasset.h"
|
||||||
|
#include "xstring.h"
|
||||||
|
|
||||||
|
class XStringTable : public XAsset
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
XStringTable();
|
||||||
|
~XStringTable();
|
||||||
|
|
||||||
|
XString* GetName() const;
|
||||||
|
XStringArray* GetValues() const;
|
||||||
|
int GetColumnCount() const;
|
||||||
|
int GetRowCount() const;
|
||||||
|
|
||||||
|
virtual void ParseData(QDataStream* aStream) override;
|
||||||
|
virtual void Clear() override;
|
||||||
|
|
||||||
|
public slots:
|
||||||
|
void SetName(QString aName);
|
||||||
|
void SetName(XString* aName);
|
||||||
|
void SetValues(XStringArray *aValues);
|
||||||
|
void SetColumnCount(int aColumnCount);
|
||||||
|
void SetRowCount(int aRowCount);
|
||||||
|
|
||||||
|
private:
|
||||||
|
XString* mName;
|
||||||
|
XStringArray* mValues;
|
||||||
|
int mColumnCount;
|
||||||
|
int mRowCount;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // STRINGTABLESH_H
|
||||||
@ -3,15 +3,8 @@ TEMPLATE = lib
|
|||||||
CONFIG += staticlib c++17
|
CONFIG += staticlib c++17
|
||||||
DEFINES += MINILZO_USE_STATIC
|
DEFINES += MINILZO_USE_STATIC
|
||||||
|
|
||||||
SOURCES += \
|
SOURCES += $$files($$PWD/*.cpp, true)
|
||||||
compression.cpp \
|
HEADERS += $$files($$PWD/*.h, true)
|
||||||
minilzo.c \
|
|
||||||
lzoconf.h \
|
|
||||||
lzodefs.h
|
|
||||||
|
|
||||||
HEADERS += \
|
|
||||||
compression.h \
|
|
||||||
minilzo.h
|
|
||||||
|
|
||||||
LIBS += \
|
LIBS += \
|
||||||
-L$$PWD/../../third_party/xbox_sdk/lib -lxcompress64 \
|
-L$$PWD/../../third_party/xbox_sdk/lib -lxcompress64 \
|
||||||
|
|||||||
@ -2,23 +2,7 @@ QT += core widgets
|
|||||||
TEMPLATE = lib
|
TEMPLATE = lib
|
||||||
CONFIG += staticlib c++17
|
CONFIG += staticlib c++17
|
||||||
|
|
||||||
SOURCES += \
|
SOURCES += $$files($$PWD/*.cpp, true)
|
||||||
highlighter_cfg.cpp \
|
HEADERS += $$files($$PWD/*.h, true)
|
||||||
highlighter_shock.cpp \
|
|
||||||
highlighter_rumble.cpp \
|
|
||||||
highlighter_gsc.cpp \
|
|
||||||
logmanager.cpp \
|
|
||||||
statusbarmanager.cpp
|
|
||||||
|
|
||||||
HEADERS += \
|
|
||||||
enums.h \
|
|
||||||
highlighter_cfg.h \
|
|
||||||
highlighter_shock.h \
|
|
||||||
highlighter_rumble.h \
|
|
||||||
highlighter_gsc.h \
|
|
||||||
logmanager.h \
|
|
||||||
stringutils.h \
|
|
||||||
utils.h \
|
|
||||||
statusbarmanager.h
|
|
||||||
|
|
||||||
DESTDIR = $$OUT_PWD/../
|
DESTDIR = $$OUT_PWD/../
|
||||||
|
|||||||
@ -2,13 +2,8 @@ QT += core
|
|||||||
TEMPLATE = lib
|
TEMPLATE = lib
|
||||||
CONFIG += staticlib c++17
|
CONFIG += staticlib c++17
|
||||||
|
|
||||||
SOURCES += \
|
SOURCES += $$files($$PWD/*.cpp, true)
|
||||||
ddsfile.cpp
|
HEADERS += $$files($$PWD/*.h, true)
|
||||||
|
|
||||||
HEADERS += \
|
|
||||||
dds_structs.h \
|
|
||||||
ddsfile.h \
|
|
||||||
enums.h
|
|
||||||
|
|
||||||
LIBS += \
|
LIBS += \
|
||||||
-L$$PWD/../../third_party/devil_sdk/lib/ -lDevIL \
|
-L$$PWD/../../third_party/devil_sdk/lib/ -lDevIL \
|
||||||
|
|||||||
@ -2,20 +2,8 @@ QT += core
|
|||||||
TEMPLATE = lib
|
TEMPLATE = lib
|
||||||
CONFIG += staticlib c++17
|
CONFIG += staticlib c++17
|
||||||
|
|
||||||
SOURCES += \
|
SOURCES += $$files($$PWD/*.cpp, true)
|
||||||
salsa20.cpp \
|
HEADERS += $$files($$PWD/*.h, true)
|
||||||
sha1.cpp \
|
|
||||||
encryption.cpp
|
|
||||||
|
|
||||||
HEADERS += \
|
|
||||||
ecrypt-config.h \
|
|
||||||
ecrypt-machine.h \
|
|
||||||
ecrypt-portable.h \
|
|
||||||
ecrypt-sync.h \
|
|
||||||
encryption.h \
|
|
||||||
os_types.h \
|
|
||||||
config_win32.h \
|
|
||||||
sha1.h
|
|
||||||
|
|
||||||
app.depends += \
|
app.depends += \
|
||||||
compression
|
compression
|
||||||
|
|||||||
@ -2,90 +2,8 @@ QT += core widgets
|
|||||||
TEMPLATE = lib
|
TEMPLATE = lib
|
||||||
CONFIG += staticlib c++17
|
CONFIG += staticlib c++17
|
||||||
|
|
||||||
SOURCES += \
|
SOURCES += $$files($$PWD/*.cpp, true)
|
||||||
# Base class & factory
|
HEADERS += $$files($$PWD/*.h, true)
|
||||||
fastfile.cpp \
|
|
||||||
# 360 classes
|
|
||||||
360/fastfile_cod2_360.cpp \
|
|
||||||
360/fastfile_cod4_360.cpp \
|
|
||||||
360/fastfile_cod5_360.cpp \
|
|
||||||
360/fastfile_cod6_360.cpp \
|
|
||||||
360/fastfile_cod7_360.cpp \
|
|
||||||
360/fastfile_cod8_360.cpp \
|
|
||||||
360/fastfile_cod9_360.cpp \
|
|
||||||
360/fastfile_cod10_360.cpp \
|
|
||||||
360/fastfile_cod11_360.cpp \
|
|
||||||
360/fastfile_cod12_360.cpp \
|
|
||||||
# PS3 classes
|
|
||||||
PS3/fastfile_cod4_ps3.cpp \
|
|
||||||
PS3/fastfile_cod5_ps3.cpp \
|
|
||||||
PS3/fastfile_cod6_ps3.cpp \
|
|
||||||
PS3/fastfile_cod7_ps3.cpp \
|
|
||||||
PS3/fastfile_cod8_ps3.cpp \
|
|
||||||
PS3/fastfile_cod9_ps3.cpp \
|
|
||||||
PS3/fastfile_cod10_ps3.cpp \
|
|
||||||
PS3/fastfile_cod11_ps3.cpp \
|
|
||||||
PS3/fastfile_cod12_ps3.cpp \
|
|
||||||
# PC classes
|
|
||||||
PC/fastfile_cod4_pc.cpp \
|
|
||||||
PC/fastfile_cod5_pc.cpp \
|
|
||||||
PC/fastfile_cod6_pc.cpp \
|
|
||||||
PC/fastfile_cod7_pc.cpp \
|
|
||||||
PC/fastfile_cod8_pc.cpp \
|
|
||||||
PC/fastfile_cod9_pc.cpp \
|
|
||||||
PC/fastfile_cod10_pc.cpp \
|
|
||||||
PC/fastfile_cod11_pc.cpp \
|
|
||||||
PC/fastfile_cod12_pc.cpp \
|
|
||||||
# Wii Classes
|
|
||||||
Wii/fastfile_cod4_wii.cpp \
|
|
||||||
Wii/fastfile_cod7_wii.cpp \
|
|
||||||
Wii/fastfile_cod8_wii.cpp \
|
|
||||||
# WiiU Classes
|
|
||||||
WiiU/fastfile_cod9_wiiu.cpp \
|
|
||||||
WiiU/fastfile_cod10_wiiu.cpp
|
|
||||||
|
|
||||||
HEADERS += \
|
|
||||||
# Base class & factory
|
|
||||||
fastfile.h \
|
|
||||||
fastfile_factory.h \
|
|
||||||
# 360 classes
|
|
||||||
360/fastfile_cod2_360.h \
|
|
||||||
360/fastfile_cod4_360.h \
|
|
||||||
360/fastfile_cod5_360.h \
|
|
||||||
360/fastfile_cod6_360.h \
|
|
||||||
360/fastfile_cod7_360.h \
|
|
||||||
360/fastfile_cod8_360.h \
|
|
||||||
360/fastfile_cod9_360.h \
|
|
||||||
360/fastfile_cod10_360.h \
|
|
||||||
360/fastfile_cod11_360.h \
|
|
||||||
360/fastfile_cod12_360.h \
|
|
||||||
# PS3 classes
|
|
||||||
PS3/fastfile_cod4_ps3.h \
|
|
||||||
PS3/fastfile_cod5_ps3.h \
|
|
||||||
PS3/fastfile_cod6_ps3.h \
|
|
||||||
PS3/fastfile_cod7_ps3.h \
|
|
||||||
PS3/fastfile_cod8_ps3.h \
|
|
||||||
PS3/fastfile_cod9_ps3.h \
|
|
||||||
PS3/fastfile_cod10_ps3.h \
|
|
||||||
PS3/fastfile_cod11_ps3.h \
|
|
||||||
PS3/fastfile_cod12_ps3.h \
|
|
||||||
# PC classes
|
|
||||||
PC/fastfile_cod4_pc.h \
|
|
||||||
PC/fastfile_cod5_pc.h \
|
|
||||||
PC/fastfile_cod6_pc.h \
|
|
||||||
PC/fastfile_cod7_pc.h \
|
|
||||||
PC/fastfile_cod8_pc.h \
|
|
||||||
PC/fastfile_cod9_pc.h \
|
|
||||||
PC/fastfile_cod10_pc.h \
|
|
||||||
PC/fastfile_cod11_pc.h \
|
|
||||||
PC/fastfile_cod12_pc.h \
|
|
||||||
# Wii Classes
|
|
||||||
Wii/fastfile_cod4_wii.h \
|
|
||||||
Wii/fastfile_cod7_wii.h \
|
|
||||||
Wii/fastfile_cod8_wii.h \
|
|
||||||
# WiiU classes
|
|
||||||
WiiU/fastfile_cod9_wiiu.h \
|
|
||||||
WiiU/fastfile_cod10_wiiu.h
|
|
||||||
|
|
||||||
LIBS += \
|
LIBS += \
|
||||||
-L$$OUT_PWD/../libs/core -lcore \
|
-L$$OUT_PWD/../libs/core -lcore \
|
||||||
|
|||||||
@ -2,10 +2,7 @@ QT += core
|
|||||||
TEMPLATE = lib
|
TEMPLATE = lib
|
||||||
CONFIG += staticlib c++17
|
CONFIG += staticlib c++17
|
||||||
|
|
||||||
SOURCES += \
|
SOURCES += $$files($$PWD/*.cpp, true)
|
||||||
ipakfile.cpp
|
HEADERS += $$files($$PWD/*.h, true)
|
||||||
|
|
||||||
HEADERS += \
|
|
||||||
ipak_structs.h
|
|
||||||
|
|
||||||
DESTDIR = $$OUT_PWD/../
|
DESTDIR = $$OUT_PWD/../
|
||||||
|
|||||||
@ -2,11 +2,8 @@ QT += core
|
|||||||
TEMPLATE = lib
|
TEMPLATE = lib
|
||||||
CONFIG += staticlib c++17
|
CONFIG += staticlib c++17
|
||||||
|
|
||||||
SOURCES += \
|
SOURCES += $$files($$PWD/*.cpp, true)
|
||||||
iwifile.cpp
|
HEADERS += $$files($$PWD/*.h, true)
|
||||||
|
|
||||||
HEADERS += \
|
|
||||||
iwifile.h
|
|
||||||
|
|
||||||
LIBS += \
|
LIBS += \
|
||||||
-L$$PWD/../../third_party/devil_sdk/lib/ -lDevIL \
|
-L$$PWD/../../third_party/devil_sdk/lib/ -lDevIL \
|
||||||
|
|||||||
@ -2,89 +2,8 @@ QT += core widgets
|
|||||||
TEMPLATE = lib
|
TEMPLATE = lib
|
||||||
CONFIG += staticlib c++17
|
CONFIG += staticlib c++17
|
||||||
|
|
||||||
SOURCES += \
|
SOURCES += $$files($$PWD/*.cpp, true)
|
||||||
# Base class
|
HEADERS += $$files($$PWD/*.h, true)
|
||||||
zonefile.cpp \
|
|
||||||
# 360 classes
|
|
||||||
360/zonefile_cod2_360.cpp \
|
|
||||||
360/zonefile_cod4_360.cpp \
|
|
||||||
360/zonefile_cod5_360.cpp \
|
|
||||||
360/zonefile_cod6_360.cpp \
|
|
||||||
360/zonefile_cod7_360.cpp \
|
|
||||||
360/zonefile_cod8_360.cpp \
|
|
||||||
360/zonefile_cod9_360.cpp \
|
|
||||||
360/zonefile_cod10_360.cpp \
|
|
||||||
360/zonefile_cod11_360.cpp \
|
|
||||||
360/zonefile_cod12_360.cpp \
|
|
||||||
# PS3 classes
|
|
||||||
PS3/zonefile_cod4_ps3.cpp \
|
|
||||||
PS3/zonefile_cod5_ps3.cpp \
|
|
||||||
PS3/zonefile_cod6_ps3.cpp \
|
|
||||||
PS3/zonefile_cod7_ps3.cpp \
|
|
||||||
PS3/zonefile_cod8_ps3.cpp \
|
|
||||||
PS3/zonefile_cod9_ps3.cpp \
|
|
||||||
PS3/zonefile_cod10_ps3.cpp \
|
|
||||||
PS3/zonefile_cod11_ps3.cpp \
|
|
||||||
PS3/zonefile_cod12_ps3.cpp \
|
|
||||||
# PC classes
|
|
||||||
PC/zonefile_cod4_pc.cpp \
|
|
||||||
PC/zonefile_cod5_pc.cpp \
|
|
||||||
PC/zonefile_cod6_pc.cpp \
|
|
||||||
PC/zonefile_cod7_pc.cpp \
|
|
||||||
PC/zonefile_cod8_pc.cpp \
|
|
||||||
PC/zonefile_cod9_pc.cpp \
|
|
||||||
PC/zonefile_cod10_pc.cpp \
|
|
||||||
PC/zonefile_cod11_pc.cpp \
|
|
||||||
PC/zonefile_cod12_pc.cpp \
|
|
||||||
# Wii classes
|
|
||||||
Wii/zonefile_cod4_wii.cpp \
|
|
||||||
Wii/zonefile_cod7_wii.cpp \
|
|
||||||
Wii/zonefile_cod8_wii.cpp \
|
|
||||||
# WiiU classes
|
|
||||||
WiiU/zonefile_cod9_wiiu.cpp \
|
|
||||||
WiiU/zonefile_cod10_wiiu.cpp
|
|
||||||
|
|
||||||
HEADERS += \
|
|
||||||
# Base class
|
|
||||||
zonefile.h \
|
|
||||||
# 360 classes
|
|
||||||
360/zonefile_cod2_360.h \
|
|
||||||
360/zonefile_cod4_360.h \
|
|
||||||
360/zonefile_cod5_360.h \
|
|
||||||
360/zonefile_cod6_360.h \
|
|
||||||
360/zonefile_cod7_360.h \
|
|
||||||
360/zonefile_cod8_360.h \
|
|
||||||
360/zonefile_cod9_360.h \
|
|
||||||
360/zonefile_cod10_360.h \
|
|
||||||
360/zonefile_cod11_360.h \
|
|
||||||
360/zonefile_cod12_360.h \
|
|
||||||
# PS3 classes
|
|
||||||
PS3/zonefile_cod4_ps3.h \
|
|
||||||
PS3/zonefile_cod5_ps3.h \
|
|
||||||
PS3/zonefile_cod6_ps3.h \
|
|
||||||
PS3/zonefile_cod7_ps3.h \
|
|
||||||
PS3/zonefile_cod8_ps3.h \
|
|
||||||
PS3/zonefile_cod9_ps3.h \
|
|
||||||
PS3/zonefile_cod10_ps3.h \
|
|
||||||
PS3/zonefile_cod11_ps3.h \
|
|
||||||
PS3/zonefile_cod12_ps3.h \
|
|
||||||
# PC classes
|
|
||||||
PC/zonefile_cod4_pc.h \
|
|
||||||
PC/zonefile_cod5_pc.h \
|
|
||||||
PC/zonefile_cod6_pc.h \
|
|
||||||
PC/zonefile_cod7_pc.h \
|
|
||||||
PC/zonefile_cod8_pc.h \
|
|
||||||
PC/zonefile_cod9_pc.h \
|
|
||||||
PC/zonefile_cod10_pc.h \
|
|
||||||
PC/zonefile_cod11_pc.h \
|
|
||||||
PC/zonefile_cod12_pc.h \
|
|
||||||
# Wii classes
|
|
||||||
Wii/zonefile_cod4_wii.h \
|
|
||||||
Wii/zonefile_cod7_wii.h \
|
|
||||||
Wii/zonefile_cod8_wii.h \
|
|
||||||
# WiiU classes
|
|
||||||
WiiU/zonefile_cod9_wiiu.h \
|
|
||||||
WiiU/zonefile_cod10_wiiu.h
|
|
||||||
|
|
||||||
LIBS += \
|
LIBS += \
|
||||||
-L$$OUT_PWD/../ -lcore -lassets
|
-L$$OUT_PWD/../ -lcore -lassets
|
||||||
|
|||||||
@ -2,63 +2,15 @@ TEMPLATE = app
|
|||||||
CONFIG += no_main
|
CONFIG += no_main
|
||||||
|
|
||||||
# Enable the testlib module
|
# Enable the testlib module
|
||||||
QT += testlib concurrent core-private
|
QT += testlib core-private
|
||||||
|
|
||||||
# Define a test-specific flag
|
# Define a test-specific flag
|
||||||
DEFINES += QT_TESTS
|
DEFINES += QT_TESTS
|
||||||
|
|
||||||
TARGET = tests
|
TARGET = tests
|
||||||
|
|
||||||
# List all test source files
|
SOURCES += $$files($$PWD/*.cpp, true)
|
||||||
SOURCES += \
|
HEADERS += $$files($$PWD/*.h, true)
|
||||||
# 360 autotests
|
|
||||||
360/autotest_cod2_360.cpp \
|
|
||||||
360/autotest_cod4_360.cpp \
|
|
||||||
360/autotest_cod5_360.cpp \
|
|
||||||
360/autotest_cod6_360.cpp \
|
|
||||||
360/autotest_cod7_360.cpp \
|
|
||||||
360/autotest_cod8_360.cpp \
|
|
||||||
360/autotest_cod9_360.cpp \
|
|
||||||
360/autotest_cod10_360.cpp \
|
|
||||||
360/autotest_cod11_360.cpp \
|
|
||||||
360/autotest_cod12_360.cpp \
|
|
||||||
# PC autotests
|
|
||||||
PC/autotest_cod4_pc.cpp \
|
|
||||||
PC/autotest_cod5_pc.cpp \
|
|
||||||
PC/autotest_cod6_pc.cpp \
|
|
||||||
PC/autotest_cod7_pc.cpp \
|
|
||||||
PC/autotest_cod8_pc.cpp \
|
|
||||||
PC/autotest_cod9_pc.cpp \
|
|
||||||
PC/autotest_cod10_pc.cpp \
|
|
||||||
PC/autotest_cod11_pc.cpp \
|
|
||||||
PC/autotest_cod12_pc.cpp \
|
|
||||||
# PS3 autotests
|
|
||||||
PS3/autotest_cod4_ps3.cpp \
|
|
||||||
PS3/autotest_cod5_ps3.cpp \
|
|
||||||
PS3/autotest_cod6_ps3.cpp \
|
|
||||||
PS3/autotest_cod7_ps3.cpp \
|
|
||||||
PS3/autotest_cod8_ps3.cpp \
|
|
||||||
PS3/autotest_cod9_ps3.cpp \
|
|
||||||
PS3/autotest_cod10_ps3.cpp \
|
|
||||||
PS3/autotest_cod11_ps3.cpp \
|
|
||||||
PS3/autotest_cod12_ps3.cpp \
|
|
||||||
# Wii autotests
|
|
||||||
Wii/autotest_cod4_wii.cpp \
|
|
||||||
Wii/autotest_cod7_wii.cpp \
|
|
||||||
Wii/autotest_cod8_wii.cpp \
|
|
||||||
# WiiU autotests
|
|
||||||
WiiU/autotest_cod9_wiiu.cpp \
|
|
||||||
WiiU/autotest_cod10_wiiu.cpp \
|
|
||||||
# XPlor autotests
|
|
||||||
autotest_cod.cpp \
|
|
||||||
autotest_xplor.cpp \
|
|
||||||
# Main test function
|
|
||||||
test_main.cpp
|
|
||||||
|
|
||||||
HEADERS += \
|
|
||||||
autotest_cod.h \
|
|
||||||
autotest_xplor.h
|
|
||||||
|
|
||||||
|
|
||||||
# Prevent tests from being built in release mode (optional)
|
# Prevent tests from being built in release mode (optional)
|
||||||
# CONFIG(debug, debug|release) {
|
# CONFIG(debug, debug|release) {
|
||||||
|
|||||||
@ -4,12 +4,8 @@ RC_ICONS = asset_assess.ico
|
|||||||
|
|
||||||
CONFIG += c++17
|
CONFIG += c++17
|
||||||
|
|
||||||
SOURCES += \
|
SOURCES += $$files($$PWD/*.cpp, true)
|
||||||
main.cpp \
|
HEADERS += $$files($$PWD/*.h, true)
|
||||||
mainwindow.cpp
|
|
||||||
|
|
||||||
HEADERS += \
|
|
||||||
mainwindow.h
|
|
||||||
|
|
||||||
LIBS += \
|
LIBS += \
|
||||||
-L$$OUT_PWD/../../libs -lassets
|
-L$$OUT_PWD/../../libs -lassets
|
||||||
|
|||||||
@ -2,15 +2,9 @@ QT += core widgets gui multimedia
|
|||||||
|
|
||||||
CONFIG += c++17
|
CONFIG += c++17
|
||||||
|
|
||||||
SOURCES += \
|
SOURCES += $$files($$PWD/*.cpp, true)
|
||||||
main.cpp \
|
HEADERS += $$files($$PWD/*.h, true)
|
||||||
mainwindow.cpp
|
FORMS += $$files($$PWD/*.ui, true)
|
||||||
|
|
||||||
HEADERS += \
|
|
||||||
mainwindow.h
|
|
||||||
|
|
||||||
FORMS += \
|
|
||||||
mainwindow.ui
|
|
||||||
|
|
||||||
LIBS += \
|
LIBS += \
|
||||||
-L$$OUT_PWD/../../libs/ -lcompression \
|
-L$$OUT_PWD/../../libs/ -lcompression \
|
||||||
|
|||||||
@ -4,15 +4,9 @@ RC_ICONS = zentry.ico
|
|||||||
|
|
||||||
CONFIG += c++17
|
CONFIG += c++17
|
||||||
|
|
||||||
SOURCES += \
|
SOURCES += $$files($$PWD/*.cpp, true)
|
||||||
main.cpp \
|
HEADERS += $$files($$PWD/*.h, true)
|
||||||
mainwindow.cpp
|
FORMS += $$files($$PWD/*.ui, true)
|
||||||
|
|
||||||
HEADERS += \
|
|
||||||
mainwindow.h
|
|
||||||
|
|
||||||
FORMS += \
|
|
||||||
mainwindow.ui
|
|
||||||
|
|
||||||
LIBS += \
|
LIBS += \
|
||||||
-L$$OUT_PWD/../../libs/ -lcore \
|
-L$$OUT_PWD/../../libs/ -lcore \
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user