32 lines
953 B
C++
32 lines
953 B
C++
#pragma once
|
|
|
|
#include "domain/Project.h"
|
|
|
|
#include <QHash>
|
|
#include <QPointF>
|
|
#include <QString>
|
|
|
|
namespace core {
|
|
|
|
struct AnimationSample {
|
|
QHash<QString, QPointF> entityPosition;
|
|
QHash<QString, double> entityUserScale;
|
|
QHash<QString, double> entityDepthScale01;
|
|
QHash<QString, QByteArray> entitySpritePng;
|
|
QHash<QString, bool> entityVisibility;
|
|
QHash<QString, double> entityPriority;
|
|
|
|
QHash<QString, QPointF> toolPosition;
|
|
QHash<QString, bool> toolVisibility;
|
|
QHash<QString, double> toolPriority;
|
|
|
|
QHash<QString, QPointF> cameraPosition;
|
|
QHash<QString, double> cameraScale;
|
|
};
|
|
|
|
[[nodiscard]] AnimationSample evaluateAnimation(const Project::Animation& animation, int frame);
|
|
[[nodiscard]] QVector<Project::Entity::ImageFrame> spriteFramesForEntity(const Project::Animation& animation,
|
|
const QString& entityId);
|
|
|
|
} // namespace core
|