mirror of
https://github.com/redstrate/Novus.git
synced 2025-04-25 13:17:46 +00:00
This is a major code overhaul for mdlviewer, which will make it easier to extend and modify in the future (trust me, the old code was garbage). The different views are now split up (SingleGearView, FullModelViewer, and MDLPart) which makes the functionality easier to handle, and less error-prone. Right now bone debugging is disabled (not that it worked that well anyway) but will be brought back in a future commit.
48 lines
No EOL
939 B
C++
48 lines
No EOL
939 B
C++
#pragma once
|
|
|
|
#include <QWidget>
|
|
#include <QPushButton>
|
|
#include "gearview.h"
|
|
|
|
struct GameData;
|
|
|
|
class SingleGearView : public QWidget {
|
|
Q_OBJECT
|
|
public:
|
|
explicit SingleGearView(GameData* data);
|
|
|
|
Q_SIGNALS:
|
|
void gearChanged();
|
|
|
|
void raceChanged();
|
|
void genderChanged();
|
|
void levelOfDetailChanged();
|
|
|
|
void addToFullModelViewer(GearInfo& info);
|
|
|
|
public Q_SLOTS:
|
|
void clear();
|
|
void setGear(GearInfo& info);
|
|
|
|
void setRace(Race race);
|
|
void setGender(Gender gender);
|
|
void setLevelOfDetail(int lod);
|
|
|
|
private Q_SLOTS:
|
|
void reloadGear();
|
|
|
|
private:
|
|
std::optional<GearInfo> currentGear;
|
|
|
|
Race currentRace = Race::Hyur;
|
|
Gender currentGender = Gender::Female;
|
|
int currentLod = 0;
|
|
|
|
GearView* gearView = nullptr;
|
|
QComboBox* raceCombo, *genderCombo, *lodCombo;
|
|
QPushButton* addToFMVButton, *exportButton;
|
|
|
|
bool loadingComboData = false;
|
|
|
|
GameData* data = nullptr;
|
|
}; |