1 // Copyright 2009-2020 Intel Corporation
2 // SPDX-License-Identifier: Apache-2.0
3 
4 #pragma once
5 
6 #include "Geometry.h"
7 #include "common/Data.h"
8 
9 namespace ospray {
10 
11 struct OSPRAY_SDK_INTERFACE Mesh : public Geometry
12 {
13   Mesh();
14   virtual ~Mesh() override = default;
15 
16   virtual std::string toString() const override;
17 
18   virtual void commit() override;
19 
20   virtual size_t numPrimitives() const override;
21 
22  protected:
23   Ref<const DataT<vec3f>> vertexData;
24   Ref<const DataT<vec3f>> normalData;
25   Ref<const Data> colorData;
26   Ref<const DataT<vec2f>> texcoordData;
27   Ref<const Data> indexData;
28 };
29 
30 } // namespace ospray
31