2020-05-05 01:51:13 +02:00
|
|
|
#include "PrimitiveComponent.h"
|
|
|
|
|
#include "Scene/Scene.h"
|
|
|
|
|
#include "Material/MaterialInstance.h"
|
2020-06-08 01:44:47 +02:00
|
|
|
#include "Asset/MeshAsset.h"
|
|
|
|
|
#include "Graphics/RenderPass/VertexFactory.h"
|
2020-05-05 01:51:13 +02:00
|
|
|
|
|
|
|
|
using namespace Seele;
|
|
|
|
|
|
|
|
|
|
PrimitiveComponent::PrimitiveComponent()
|
|
|
|
|
{
|
|
|
|
|
}
|
|
|
|
|
|
2020-06-08 01:44:47 +02:00
|
|
|
PrimitiveComponent::PrimitiveComponent(PMeshAsset asset)
|
|
|
|
|
{
|
|
|
|
|
}
|
|
|
|
|
|
2020-05-05 01:51:13 +02:00
|
|
|
PrimitiveComponent::~PrimitiveComponent()
|
|
|
|
|
{
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void PrimitiveComponent::notifySceneAttach(PScene scene)
|
|
|
|
|
{
|
|
|
|
|
scene->addPrimitiveComponent(this);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
Matrix4 PrimitiveComponent::getRenderMatrix()
|
|
|
|
|
{
|
|
|
|
|
return getTransform().toMatrix();
|
|
|
|
|
}
|