/*
- * Copyright (c) 2022 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2023 Samsung Electronics Co., Ltd.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
// INTERNAL INCLUDES
#include <dali-scene3d/internal/controls/model/model-impl.h>
+#include <dali-scene3d/public-api/model-components/model-node.h>
-namespace Dali
+namespace Dali::Scene3D
{
-namespace Scene3D
-{
-Model::Model()
-{
-}
+Model::Model() = default;
Model::Model(const Model& model) = default;
-Model::Model(Model&& rhs) = default;
+Model::Model(Model&& rhs) noexcept = default;
Model& Model::operator=(const Model& model) = default;
-Model& Model::operator=(Model&& rhs) = default;
+Model& Model::operator=(Model&& rhs) noexcept = default;
-Model::~Model()
-{
-}
+Model::~Model() = default;
Model Model::New(const std::string& modelUrl, const std::string& resourceDirectoryUrl)
{
VerifyCustomActorPointer<Internal::Model>(internal);
}
-const Actor Model::GetModelRoot() const
+const ModelNode Model::GetModelRoot() const
{
return GetImpl(*this).GetModelRoot();
}
+void Model::AddModelNode(ModelNode modelNode)
+{
+ return GetImpl(*this).AddModelNode(modelNode);
+}
+
+void Model::RemoveModelNode(ModelNode modelNode)
+{
+ return GetImpl(*this).RemoveModelNode(modelNode);
+}
+
void Model::SetChildrenSensitive(bool enable)
{
GetImpl(*this).SetChildrenSensitive(enable);
return GetImpl(*this).GetChildrenSensitive();
}
-void Model::SetImageBasedLightSource(const std::string& diffuseUrl, const std::string& specularUrl, float scaleFactor)
+void Model::SetChildrenFocusable(bool enable)
{
- GetImpl(*this).SetImageBasedLightSource(diffuseUrl, specularUrl, scaleFactor);
+ GetImpl(*this).SetChildrenFocusable(enable);
}
-void Model::SetImageBasedLightTexture(Texture diffuseTexture, Texture specularTexture, float scaleFactor)
+bool Model::GetChildrenFocusable() const
{
- GetImpl(*this).SetImageBasedLightTexture(diffuseTexture, specularTexture, scaleFactor);
+ return GetImpl(*this).GetChildrenFocusable();
+}
+
+void Model::SetImageBasedLightSource(const std::string& diffuseUrl, const std::string& specularUrl, float scaleFactor)
+{
+ GetImpl(*this).SetImageBasedLightSource(diffuseUrl, specularUrl, scaleFactor);
}
void Model::SetImageBasedLightScaleFactor(float scaleFactor)
return GetImpl(*this).GetAnimation(name);
}
-} // namespace Scene3D
+uint32_t Model::GetCameraCount() const
+{
+ return GetImpl(*this).GetCameraCount();
+}
+
+Dali::CameraActor Model::GenerateCamera(uint32_t index) const
+{
+ return GetImpl(*this).GenerateCamera(index);
+}
+
+bool Model::ApplyCamera(uint32_t index, Dali::CameraActor camera) const
+{
+ return GetImpl(*this).ApplyCamera(index, camera);
+}
+
+ModelNode Model::FindChildModelNodeByName(std::string_view nodeName)
+{
+ return GetImpl(*this).FindChildModelNodeByName(nodeName);
+}
+
+void Model::RetrieveBlendShapeNames(std::vector<std::string>& blendShapeNames) const
+{
+ GetImpl(*this).RetrieveBlendShapeNames(blendShapeNames);
+}
+
+void Model::RetrieveModelNodesByBlendShapeName(std::string_view blendShapeName, std::vector<ModelNode>& modelNodes) const
+{
+ GetImpl(*this).RetrieveModelNodesByBlendShapeName(blendShapeName, modelNodes);
+}
+
+Dali::Animation Model::GenerateMotionDataAnimation(MotionData motionData)
+{
+ return GetImpl(*this).GenerateMotionDataAnimation(motionData);
+}
+
+void Model::SetMotionData(MotionData motionData)
+{
+ GetImpl(*this).SetMotionData(motionData);
+}
+
+Model::MeshHitSignalType& Model::MeshHitSignal()
+{
+ return GetImpl(*this).MeshHitSignal();
+}
-} // namespace Dali
+} // namespace Dali::Scene3D