2022-12-03 06:37:15 +00:00
|
|
|
#ifndef DUST3D_APPLICATION_BONE_GENERATOR_H_
|
|
|
|
#define DUST3D_APPLICATION_BONE_GENERATOR_H_
|
|
|
|
|
|
|
|
#include "model_mesh.h"
|
|
|
|
#include <QObject>
|
2022-12-03 16:58:33 +00:00
|
|
|
#include <dust3d/base/snapshot.h>
|
2022-12-03 06:37:15 +00:00
|
|
|
#include <dust3d/rig/bone_generator.h>
|
2022-12-03 12:01:11 +00:00
|
|
|
#include <map>
|
2022-12-03 06:37:15 +00:00
|
|
|
#include <memory>
|
|
|
|
|
|
|
|
class BoneGenerator : public QObject, public dust3d::BoneGenerator {
|
|
|
|
Q_OBJECT
|
2022-12-03 12:01:11 +00:00
|
|
|
public:
|
2022-12-03 16:58:33 +00:00
|
|
|
BoneGenerator(std::unique_ptr<dust3d::Object> object, std::unique_ptr<dust3d::Snapshot> snapshot);
|
2022-12-03 12:01:11 +00:00
|
|
|
std::map<dust3d::Uuid, std::unique_ptr<ModelMesh>>* takeBonePreviewMeshes();
|
2022-12-03 06:37:15 +00:00
|
|
|
public slots:
|
|
|
|
void process();
|
|
|
|
signals:
|
|
|
|
void finished();
|
|
|
|
|
|
|
|
private:
|
|
|
|
std::unique_ptr<std::map<dust3d::Uuid, std::unique_ptr<ModelMesh>>> m_bonePreviewMeshes;
|
2022-12-03 16:58:33 +00:00
|
|
|
std::unique_ptr<dust3d::Object> m_object;
|
|
|
|
std::unique_ptr<dust3d::Snapshot> m_snapshot;
|
2022-12-03 06:37:15 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|