Gazebo Rendering

API Reference

6.6.4
gz/rendering/ogre2/Ogre2Capsule.hh
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2021 Open Source Robotics Foundation
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  *
16 */
17 
18 #ifndef IGNITION_RENDERING_OGRE2_OGRE2CAPSULE_HH_
19 #define IGNITION_RENDERING_OGRE2_OGRE2CAPSULE_HH_
20 
21 #include <memory>
22 #include <vector>
23 
26 
27 namespace Ogre
28 {
29  class MovableObject;
30 }
31 
32 namespace ignition
33 {
34  namespace rendering
35  {
36  inline namespace IGNITION_RENDERING_VERSION_NAMESPACE {
37  // Forward declaration
38  class Ogre2CapsulePrivate;
39 
41  class IGNITION_RENDERING_OGRE2_VISIBLE Ogre2Capsule
42  : public BaseCapsule<Ogre2Geometry>
43  {
45  protected: Ogre2Capsule();
46 
48  public: virtual ~Ogre2Capsule();
49 
50  // Documentation inherited.
51  public: virtual void Init() override;
52 
53  // Documentation inherited.
54  public: virtual void Destroy() override;
55 
56  // Documentation inherited.
57  public: virtual Ogre::MovableObject *OgreObject() const override;
58 
59  // Documentation inherited.
60  public: virtual void PreRender() override;
61 
62  // Documentation inherited.
63  public: virtual MaterialPtr Material() const override;
64 
65  // Documentation inherited.
66  public: virtual void
67  SetMaterial(MaterialPtr _material, bool _unique) override;
68 
70  private: void Update();
71 
73  private: friend class Ogre2Scene;
74 
76  private: std::unique_ptr<Ogre2CapsulePrivate> dataPtr;
77  };
78  }
79  }
80 }
81 #endif
Base implementation of a Capsule Geometry.
Definition: gz/rendering/base/BaseCapsule.hh:37
Ogre 2.x implementation of a Capsule Geometry.
Definition: gz/rendering/ogre2/Ogre2Capsule.hh:43
virtual Ogre::MovableObject * OgreObject() const override
Get the ogre object representing this geometry.
virtual void SetMaterial(MaterialPtr _material, bool _unique) override
Set the materials of this Geometry.
virtual void PreRender() override
Prepare this object and any of its children for rendering. This should be called for each object in a...
virtual MaterialPtr Material() const override
Get the material of this geometry.
virtual void Destroy() override
Destroy any resources associated with this object. Invoking any other functions after destroying an o...
virtual ~Ogre2Capsule()
Destructor.
virtual void Init() override
Ogre2.x implementation of the scene class.
Definition: gz/rendering/ogre2/Ogre2Scene.hh:59
Definition: gz/rendering/ogre/OgreCamera.hh:28