You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
50 lines
1.4 KiB
C++
50 lines
1.4 KiB
C++
/*
|
|
* Copyright (c) Contributors to the Open 3D Engine Project.
|
|
* For complete copyright and license terms please see the LICENSE at the root of this distribution.
|
|
*
|
|
* SPDX-License-Identifier: Apache-2.0 OR MIT
|
|
*
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include <AzCore/Component/Component.h>
|
|
|
|
namespace AZ
|
|
{
|
|
class Transform;
|
|
}
|
|
|
|
namespace WhiteBox
|
|
{
|
|
struct WhiteBoxMaterial;
|
|
struct WhiteBoxRenderData;
|
|
|
|
//! A generic interface for the White Box Component to communicate
|
|
//! with regardless of the rendering backend.
|
|
class RenderMeshInterface
|
|
{
|
|
public:
|
|
AZ_RTTI(RenderMeshInterface, "{F3ADF2DC-6A40-4943-95BE-6C7E24605BE9}");
|
|
|
|
virtual ~RenderMeshInterface() = 0;
|
|
|
|
//! Take White Box render data and populate the render mesh from it.
|
|
virtual void BuildMesh(
|
|
const WhiteBoxRenderData& renderData, const AZ::Transform& worldFromLocal,
|
|
AZ::EntityId entityId) = 0; // TODO: LYN-786
|
|
|
|
//! Update the transform of the render mesh.
|
|
virtual void UpdateTransform(const AZ::Transform& worldFromLocal) = 0;
|
|
|
|
//! Update the material of the render mesh.
|
|
virtual void UpdateMaterial(const WhiteBoxMaterial& material) = 0;
|
|
|
|
// Return if the White Box mesh is visible or not.
|
|
virtual bool IsVisible() const = 0;
|
|
|
|
//! Set the White Box mesh visible (true) or invisible (false).
|
|
virtual void SetVisiblity(bool visibility) = 0;
|
|
};
|
|
} // namespace WhiteBox
|