MeshVertexColorDataStub.h 907 B

12345678910111213141516171819202122232425262728293031323334353637
  1. /*
  2. * Copyright (c) Contributors to the Open 3D Engine Project.
  3. * For complete copyright and license terms please see the LICENSE at the root of this distribution.
  4. *
  5. * SPDX-License-Identifier: Apache-2.0 OR MIT
  6. *
  7. */
  8. #pragma once
  9. #include <SceneAPI/SceneCore/DataTypes/GraphData/IMeshVertexColorData.h>
  10. namespace UnitTest
  11. {
  12. class MeshVertexColorDataStub
  13. : public AZ::SceneAPI::DataTypes::IMeshVertexColorData
  14. {
  15. public:
  16. const AZ::Name& GetCustomName() const override
  17. {
  18. return m_name;
  19. }
  20. size_t GetCount() const override
  21. {
  22. return m_colors.size();
  23. }
  24. const AZ::SceneAPI::DataTypes::Color& GetColor(size_t index) const override
  25. {
  26. return m_colors[index];
  27. }
  28. AZ::Name m_name;
  29. AZStd::vector<AZ::SceneAPI::DataTypes::Color> m_colors;
  30. };
  31. } // namespace UnitTest