1 // =============================================================================
2 // PROJECT CHRONO - http://projectchrono.org
3 //
4 // Copyright (c) 2014 projectchrono.org
5 // All rights reserved.
6 //
7 // Use of this source code is governed by a BSD-style license that can be found
8 // in the LICENSE file at the top level of the distribution and at
9 // http://projectchrono.org/license-chrono.txt.
10 //
11 // =============================================================================
12 
13 #ifndef CHOBJCONESHAPE_H
14 #define CHOBJCONESHAPE_H
15 
16 #include "chrono/assets/ChVisualization.h"
17 #include "chrono/geometry/ChCone.h"
18 
19 namespace chrono {
20 
21 /// Class for referencing a cone shape that can be visualized in some way.
22 class ChApi ChConeShape : public ChVisualization {
23   protected:
24     geometry::ChCone gcone;
25 
26   public:
ChConeShape()27     ChConeShape() {}
ChConeShape(const geometry::ChCone & mcone)28     ChConeShape(const geometry::ChCone& mcone) : gcone(mcone) {}
29 
~ChConeShape()30     virtual ~ChConeShape(){};
31 
32     // Access the sphere geometry
GetConeGeometry()33     geometry::ChCone& GetConeGeometry() { return gcone; }
34 
35     /// Method to allow serialization of transient data to archives.
36     virtual void ArchiveOUT(ChArchiveOut& marchive) override;
37 
38     /// Method to allow de-serialization of transient data from archives.
39     virtual void ArchiveIN(ChArchiveIn& marchive) override;
40 };
41 
42 CH_CLASS_VERSION(ChConeShape, 0)
43 
44 }  // end namespace chrono
45 
46 #endif
47